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
Return the selected row as array. E.g.: $user = $db>get_row( "SELECT FROM user LIMIT 1" ); // return: array( 'user_id'=>1, 'name'=>'Rain', 'status'=>'admin' )
function get_row( $query = null ){ return mysql_fetch_assoc( $this->query( $query ) ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function fetchRow() : array\n\t{\n\t\treturn $this->handle->fetchRow($this->result);\n\t}", "public function get_row();", "public function fetch_row()\n\t{\n\t\t$row = array();\n\t\tif (current($this->result)) {\n\t\t\tforeach (current($this->result) AS $value) {\n\t\t\t\t$row[] = $value;\n\t\t\t}\n\t\t}else {\n\t\t\t$row = FALSE;\n\t\t}\n\t\tnext($this->result);\n\t\treturn $row;\n\t}", "public function getRow(){\n return oci_fetch_array($this->result);\n\n }", "public function GetSingleRow() : ARRAY\r\n {\r\n return($this->preparedStatement->fetch(\\PDO::FETCH_ASSOC));\r\n }", "protected function getUserRow(): array\n {\n\n /**\n * @var $_um LightUserManagerService\n */\n $_um = $this->getContainer()->get(\"user_manager\");\n $user = $_um->getOpenUser();\n if (false === $user->isValid()) {\n throw new LightKitStoreException(\"The user is not connected.\");\n }\n $userId = $user->getProp(\"id\");\n\n\n $userApi = $this->getKitStoreService()->getFactory()->getUserApi();\n return $userApi->getUserById($userId);\n }", "abstract public function getRowAsArray();", "function fetchRow ()\n {\n return pg_fetch_array($this->_result);\n }", "function db_get_row($query)\n{\n\t$args = func_get_args();\n\n\tif ($_result = call_user_func_array('db_query', $args)) {\n\n\t\t$result = driver_db_fetch_array($_result);\n\n\t\tdriver_db_free_result($_result);\n\n\t}\n\n\treturn is_array($result) ? $result : array();\n}", "protected function _get_row()\r\n {\r\n $result = $this->db->get()->row_array();\r\n\r\n //execute extends in child class.\r\n $result = $this->_extend_get_row($result);\r\n\r\n return $result;\r\n }", "function dbgetrow() {\n\t$output = array();\n\n\t$args = func_get_args();\n\t$result = call_user_func_array('dbquery', $args);\n\t$query = array_shift($args);\n\n\t// this only applies to SELECT queries!\n\tif (preg_match('/^SELECT/i', $query) && $result) {\n\t\t$output = dbfetch($result, DB_ASSOC);\n\t\t\n\t\tdbfree($result);\n\t} else {\n\t\tEWarning(EC_REALS_DATABASE, \"dbgetrow called with non-SELECT query!\", \"Non-select query\");\n\t}\n\n\treturn $output;\n}", "function getRowAsArray($query) {\n\t\topenDatabaseConnection();\n\t\t$result = mysql_query($query) or die(\"Invalid query: \" . mysql_error());\n\t\t# turn the result into an array\n\t\treturn mysql_fetch_assoc($result);\n\t}", "public function selectRow($row);", "function row($query_handle) {\n switch ($this->type) {\n case 'sqlite':\n return $query_handle->fetchArray();\n break;\n\n case 'mysql':\n break;\n }\n }", "public function get() {\n $where = func_get_args();\n $this->_set_where($where);\n\n $this->_callbacks('before_get', array($where));\n\n if ($this->result_mode == 'object') {\n $row = $this->db->get($this->_table())->row();\n } else {\n $row = $this->db->get($this->_table())->row_array();\n }\n\n $row = $this->_callbacks('after_get', array($row));\n\n return $row;\n }", "public function getArray()\n\t{\n\t\treturn $this->row;\n\t}", "public function getValues($row){\n $data = array();\n while( ($obj = oci_fetch_assoc($this->result)) != false ){\n $data[] = $obj[$row];\n }\n return $data;\n }", "function obtenerArray(){\r\n\t\treturn mysql_fetch_array( $this->rs() );\r\n\t}", "function sql_fetch_row($res)\n {\n $results = array();\n if ($res)\n $results = $res->fetch(PDO::FETCH_NUM); \n return $results;\n }", "function db_get_row($result)\n{\n\treturn $result->fetch_assoc();\n}", "function user_table_data($logged_user_id)\n\t{\n\t\t$select = array('user_file', 'created', 'sex', 'first_name', 'last_name', 'full_name');\n\t\t$this->db->select($select)->from('users')->where('id', $logged_user_id);\n\t $query = $this->db->get();\n\t\tif ($query->num_rows() > 0)\n\t\t{\n\t\t\treturn $query->row_array();\n\t\t}\n\t}", "public function queryRow()\n\t{\n\t\treturn $this->queryInternal('fetch',$this->_fetchMode);\n\t}", "function getRowByID($id)\r\n {\r\n $exc = \"SELECT * from \".$this->name.\" WHERE ID = \".strval($id).\" ;\";\r\n $ret = $this->db->query($exc);\r\n $row = $ret->fetchArray(SQLITE3_ASSOC);\r\n return $row;\r\n }", "public function result_row()\n {\n $output = is_bool($this->result) ? array() : $this->result->fetch_assoc();\n\n $this->free_result();\n\n return $output;\n }", "public function rowArray($id = 0) {\n return isset($this->result_array[$id]) ? $this->result_array[$id] : false;\n }", "public function fetchRow()\n\t{\n\t\t$this->_query();\n\n\t\treturn $this->stmt->fetch(\\PDO::FETCH_ASSOC);\n\t}", "public function getRow(){\n return $this->_row;\n }", "public function getUser(){\n return $this->db->get('tb_user')->result_array();\n }", "public function exec_SELECTgetSingleRow() {}", "function user_data($user_id){\n $this->db->select('*');\n $this->db->from('users');\n $this->db->where('user_id', $user_id);\n $query = $this->db->get();\n return $query->row_array();\n }", "function FetchRow() {\n\t\t\treturn pg_fetch_row($this->result);\n\t\t}", "public function fetch_row($query_id = \"\") {\r\n\t\treturn $this->fetch_array ( $query_id, \"assoc\" );\r\n\t}", "public function fetchRow();", "public function getRow()\n {\n return $this->row;\n }", "public function fetch_row()\n {\n return $this->fetch_assoc();\n }", "public static function getRow($query)\n {\n if ($_result = call_user_func_array(array('self', 'query'), func_get_args())) {\n\n $result = self::$_db->fetchRow($_result);\n\n self::$_db->freeResult($_result);\n\n }\n\n return is_array($result) ? $result : array();\n }", "public function get_single_row() {\n $userId = $_POST['userId'];\n // Returns a single object with user detail\n $userDetails = $this->user_model->get_user_details( $userId );\n if( !empty( $userDetails ) ) {\n $data[] = $userDetails;\n } \n // Send back the entry details as JSON. Error if empty (Should always return an entry)\n $this->json_library->print_array_json_unless_empty( $data );\n }", "public function GetRowArray($sql) \n {\n $this->connect();\n \n //connect to database\n if (!empty($sql)) \n {\n try\n {\n $q = $this->db->prepare($sql);\n $q->execute();\n return $q->fetch(PDO::FETCH_ASSOC);\n }\n catch(PDOException $e) \n {\n return $e->getMessage();\n }\n } else\n {\n return 'No query provided';\n die;\n }\n $this->disconnect();\n \n //disconnect from database\n \n \n }", "public function safe_fetch_array()\n {\n\n $m_arr_row = $this->c_obj_stmt->fetch(PDO::FETCH_ASSOC);\n return $m_arr_row;\n }", "public function get(){\n\t\t\t\t\t $this->db->setTablename($this->tablename);\n\t\t\t\t\t ;\n return $this->db->getRows(array(\"where\"=>$condition,\"return_type\"=>\"single\"));\n\t\t\t\t\t }", "function get_by_user_id($user_id) {\n $this->db->where('user_id', $user_id);\n $this->db->from('user');\n $resc = $this->db->get();\n return $resc->row_array();\n }", "public function PgGetArraySelect(){\n if ($this->SQuery){\n if (pg_num_rows($this->SQuery)){\n return pg_fetch_all($this->SQuery); \n }else{\n return Array();\n }\n \n } else {\n die(\"NO Existe Consulta SELECT Valida!\");\n }\n }", "public function getRow();", "function getAllUsers(){\n $sql = self::$connection->prepare(\"SELECT * FROM `user` WHERE role_id = 2\");\n $sql->execute();//return an object\n $items = array();\n $items = $sql->get_result()->fetch_all(MYSQLI_ASSOC);\n return $items; //return an array\n }", "public function getRow()\n\t {\n\t\tif (($this->_result instanceof mysqli_result) === false)\n\t\t {\n\t\t\treturn false;\n\t\t }\n\t\telse\n\t\t {\n\t\t\treturn $this->_result->fetch_assoc();\n\t\t }\n\t }", "function get() {\r\n\t\tif ($array = @mysql_fetch_array($this->result, MYSQL_ASSOC)) return $array;\r\n\t\telse return false;\t\t\r\n\t}", "function get_user($id)\n {\n return $this->db->get_where('users',array('id'=>$id))->row_array();\n }", "function get_user($id)\n {\n return $this->db->get_where('users',array('id'=>$id))->row_array();\n }", "function get_user($id)\n {\n return $this->db->get_where('users',array('id'=>$id))->row_array();\n }", "public function asRow() {\n\t\treturn $this->_sth->fetchAll(PDO::FETCH_NUM);\n\t}", "function getRow($query, $params = [])\r\n{\r\n $statement = performQuery($query, $params);\r\n\r\n if ($statement === false) {\r\n return [];\r\n }\r\n\r\n return $statement->fetch(PDO::FETCH_ASSOC);\r\n}", "function get_user_by_username($username) {\r\n // set connection var\r\n global $db;\r\n\r\n $sql = \"SELECT id\r\n FROM users\r\n WHERE is_active = '1' and username = '$username'\";\r\n\r\n $user_data = array();\r\n $user = array();\r\n foreach ($db->query($sql) as $key => $value) {\r\n $user_data[$key] = $value;\r\n foreach ($user_data[$key] as $subkey => $subvalue) {\r\n if (is_int($subkey)) {\r\n $user[] = $subvalue;\r\n }\r\n }\r\n }\r\n\r\n return $user;\r\n}", "function getRow() {\r\n\t\t\tif($this->privateVars['resultset']) {\r\n\t\t\t\t$resultArray = mysql_fetch_array($this->privateVars['resultset']);\r\n\t\t\t\tif ($resultArray !== false) $this->privateVars['resultpointer']++;\r\n\t\t\t\treturn $resultArray;\r\n\t\t\t}\r\n\t\t\treturn false;\r\n\t\t}", "public function get_row() {\n $email = $this->input->post('email');\n $password = $this->input->post('pwd');\n $query = $this->db->get_where('User_info', array('email' => $email, 'pwd' => $password));\n $row = $query->row();\n if(isset($row)){\n return $row;\n } else {\n return FALSE;\n }\n\n }", "function row($resource) {\n return mysql_fetch_assoc($resource);\n }", "public function getUserById(int $id) :array{\n\t\treturn $this->db->select(\"SELECT * FROM users WHERE id = :id\", [\"id\" => \"$id\"]);\n\t}", "function fetch_array()\n {\n return mysql_fetch_array($this->_queryResource, MYSQL_ASSOC);\n }", "public function get($user = ''){\r\n $this->query = ($user != '') ? \"SELECT * FROM users WHERE user = '$user'\" \r\n : \"SELECT * FROM users\";\r\n $this->get_query();\r\n //var_dump($this->rows);\r\n $num_rows = count($this->rows);\r\n $data = array();\r\n foreach ($this->rows as $key => $value) {\r\n array_push($data, $value);\r\n //$data[$key] = $value;\r\n }\r\n return $data;\r\n \r\n\r\n }", "public function getRow()\n {\n return $this->row;\n }", "public function FetchArray()\n\t{\n\t\tif (!$this->Result){\t//check if we have a valid result set\n\t\t\treturn false;\n\t\t}\n\n\t\t$row = mysqli_fetch_array($this->Result);\n\n\t\tif (!$row){\t//if last row, free the result set\n\t\t\tmysqli_free_result($this->Result);\n\t\t}\n\n\t\treturn $row;\n\t}", "function get_user() {\n $query = $this->db->where('user_type', 'user')->get('user');\n return $query->result_array();\n }", "abstract protected function getRow($row);", "function GetRow()\n {\n return $this->row;\n }", "public function getUserOne(){\n try{\n $query = \"Select id, fname, lname, phone, role_id, email, created_at, status From users ORDER BY id desc LIMIT 1\";\n $stmt = $this->getConnection($query);\n $stmt -> execute();\n $stmt -> bind_result($id, $fname, $lname, $phone, $role, $email, $date, $status);\n $stmt->fetch();\n $user[] = array(\n 'id' => $id,\n 'fname' => $fname,\n 'lname' => $lname,\n 'phone' => $phone,\n 'role' => $role,\n 'email' => $email,\n 'date' => $date,\n 'status' => $status\n );\n $stmt -> close();\n return $user;\n }catch (Exception $e){\n die('Error - cannot retrieve single user: ' . $e -> getMessage());\n }\n }", "public function singleRow(){\n $this->execute();\n return $this->statement->fetch(PDO::FETCH_OBJ);\n }", "public static function getRow($name) {\n\t\t// fetch the user's row\n\t\t$roleModel = new self ( );\n\t\t\t$select = $roleModel->select ();\n\t\t\t$select->where ( 'name = ? ', $name );\n\t\t\treturn $roleModel->fetchRow ( $select );\n\t}", "public function selectRow ($sql,$array) {\n $this->quick_prepare($sql,$array);\n return $this->fetch();\n }", "function getDataFromId($id)\n {\n return $this->db->get_where('users', ['id' => $id])->row_array();\n }", "function fetch_array()\n {\n return mysqli_fetch_array($this->_queryResource);\n }", "abstract public function getSpecificRow();", "public function getuser($id)\n {\n return $this->db->get_where(\"master_user\", array(\"employee_id\" => $id))->row_array();\n }", "function FetchRow($query){\n $rows = mysql_fetch_row($query);\n return $rows;\n }", "function getUser($id) {\n $this->db->select(\"*\");\n $this->db->join('user_role', 'user_role.roleID = user.roleID'); \n $this->db->where(\"userID\", $id);\n $query = $this->db->get('user');\n if ($query->num_rows() > 0) {\n return $query->result_array();\n }\n return array();\n }", "function GetRow($handle = false)\n {\n if ($handle) $handle = $this->_lastHandle;\n switch ($this->_DB) {\n case 'mysql':\n $row = mysqli_fetch_assoc($handle);\n break;\n }\n return $row;\n }", "public function fetch_row()\r\n{\r\n\t$tmp2 = $this->_result->fetch_row();\r\n\t$this->type = 1; // MYSQLI_ASSOC = 0, MYSQLI_NUM = 1, or MYSQLI_BOTH (To implement). \r\n\t$this->push_in($tmp2);\r\n\t\r\n\treturn $tmp2;\r\n}", "public function getRow($arg)\n {\n $result = $this->resulter($arg);\n return $this->hasRows() ? $result->fetch_assoc() : false;\n }", "function fetch_array()\r\n\t\t{\r\n\t\t\tif ($this->affected_rows <> 0)\r\n\t\t\t{\r\n\t\t\t\t$this->row_data = mysql_fetch_array($this->result);\t\t\r\n\t\t\t}\r\n\t\t}", "public function fetchArray() : array\n\t{\n\t\treturn $this->handle->fetchArray($this->result);\n\t}", "function fn_fetch_array($table,$name){\r\n\t\t\t$query = $this->query(\"select $name from $table where 1 \");\r\n\t\t\t$row = $this->fetch_array($query);\r\n\t\t\treturn $row;\r\n\t\t}", "function get_user_by_id($user_id) {\n// echo $user_id; die;\n $this->db->select(\"*\", false);\n $this->db->where(\"id\", $user_id);\n $query = $this->db->get($this->user_table);\n $result = $query->row_array();\n// pr($result); die;\n return $result;\n }", "function get_row($rowindex, $key_as_colvar = False) {\r\n /* return array equivalent of row, given rowindex\r\n @key_as_colvar = True to set colvar as key instead of the normal column name\r\n */\r\n $new_array = array();\r\n foreach (get_object_vars($this) as $colvar=>$values) $new_array[$colvar] = $values[$rowindex];\r\n return $new_array;\r\n }", "function getUsers($conn){\n\n\t$sql = \"SELECT Username, UserId, Email, AccessLevel FROM user\";\n\n\t$sth = $conn->prepare($sql);\n\t$sth->execute();\n\t\n\t$rows = array();\n\t\n\twhile($r = $sth->fetch(PDO::FETCH_ASSOC)) {\n\t\t$rows[] = $r;\n\t}\n\treturn $rows;\n}", "function get_user($value, $id)\n {\n $this->db->select($value);\n\t\t$this->db->from('tbl_users');\n\t\t$this->db->join('tbl_users_details', 'tbl_users.id=tbl_users_details.user_id');\n\t\t$this->db->where('tbl_users.id', $id);\n\t\t$query = $this->db->get();\n\t\treturn $query->row_array();\n }", "public function fetchAllUserSelect() {\n try {\n // Select all users\n $query = \"\n select id, email, username\n from tb_user \n where state = 1 and access = 1\n order by username\n \";\n // Create object to connect to MySQL using PDO\n $mysqlPDO = new MySQLPDO();\n // Prepare the query\n $statement = $mysqlPDO->getConnection()->prepare($query);\n // Execute the query without paramters\n $statement->execute();\n // Get affect rows in associative array\n $rows = $statement->fetchAll();\n // Foreach row in array\n foreach ($rows as $row) {\n // Create a User Select object\n $user = new UserSelect($row);\n //Create datatable row\n $tmp_data[] = $user;\n }\n // Export into DataTable json format if there's any record in $tmp_data\n if (isset($tmp_data) && count($tmp_data) > 0) {\n $data = $tmp_data;\n } else {\n $data = array();\n }\n return $data;\n } catch (PDOException $e) {\n die(\"Error message: \" . $e->getMessage());\n }\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 getRows($q){ // get array of rows objects\r\t\t$this->connect();\t//connect if not connected \r\t\t$query=$this->query($q);\r\t\t$result=array();\r\t\twhile ($data=sqlite_fetch_object($query)){\r\t\t\t$result[]=$data;\r\t\t}\r\t\treturn $result;\r\t}", "public function listUsers() {\n $db = CTSQLite::connect();\n $query = 'SELECT * FROM ic_user';\n $stmt = $db->prepare($query);\n $result = $stmt->execute();\n if (!$result) {\n return false;\n } else {\n // $id = $result->fetchArray();\n // return $id['id'];\n $row = $result->fetchArray();\n return $row;\n }\n $db->close();\n unset($db);\n }", "public function extractRow()\n\t{\n \n // extract the row data into a field array\n \n // validate each field\n \n // return field array\n \n }", "abstract public function get_rows();", "public function fetch_array($resource){\n\t\treturn @mysql_fetch_array($resource);\n\t}", "public function get() {\n $select_fields = '';\n foreach ($this->fields as $name => $value) {\n $select_fields .= '`' . $name . '`, ';\n }\n\n $select_fields = rtrim($select_fields, ', ');\n\n $query = 'SELECT ' . $select_fields . ' FROM `'\n . $this->table . '` ' . $this->where;\n\n $res = $this->connection->query($query);\n $result = $res->fetch_array(MYSQLI_ASSOC);\n $res->free();\n return $result;\n }", "function fetch_assoc_row($resource) {\n $result = array();\n if ($this->num_rows($resource) > 0) {\n $result = mysql_fetch_assoc($resource);\n }\n return $result;\n }", "function fetch_assoc_array($resource) {\n $result = array();\n if ($this->num_rows($resource) > 0) {\n while($row = mysql_fetch_assoc($resource)) {\n array_push($result, $row);\n }\n }\n\n return $result;\n }", "public function dbRetRow( $inst )\n {\n //var_dump(mysql_fetch_array( $this -> dbQueryRet[$inst] ));\n return mysqli_fetch_array($this -> dbQueryRet[$inst]);\n }", "public function Read()\n {\n $query = $this->db->prepare(\"SELECT * FROM users\");\n $query->execute();\n $data = array();\n while ($row = $query->fetch(PDO::FETCH_ASSOC)) {\n $data[] = $row;\n }\n return $data;\n }", "public function get_row($query)\n {\n \t$res=pg_query($this->connection,$query);\n \treturn pg_fetch_assoc($res);\n }", "function sql_fetch_array($res)\n {\n $results = array();\n if ($res)\n $results = $res->fetch(PDO::FETCH_BOTH);\n return $results;\n }", "public function getArray()\n {\n return mysqli_fetch_array($this->resulset);\n }", "function fetch_object_row($resource) {\n $result = array();\n if ($this->num_rows($resource) > 0) {\n $result = mysql_fetch_object($resource);\n }\n return $result;\n }", "public function getRowDataAsArray( $iRow )\r\n {\r\n return $this->data[$iRow];\r\n }", "public function get(){\n\t\t\t\t\t $this->db->setTablename($this->tablename);\n\t\t\t\t\t $condition = array(\"ide\" =>$this->ide);\n return $this->db->getRows(array(\"where\"=>$condition,\"return_type\"=>\"single\"));\n\t\t\t\t\t }" ]
[ "0.7334746", "0.71233284", "0.70990306", "0.7062828", "0.7062647", "0.6996709", "0.69349235", "0.69304544", "0.6928293", "0.6919744", "0.6863646", "0.6821417", "0.66567355", "0.6649095", "0.6584866", "0.65768737", "0.6538608", "0.6517769", "0.6499085", "0.64827645", "0.64551824", "0.6449166", "0.64462805", "0.64318705", "0.6413538", "0.63930184", "0.6369364", "0.6355317", "0.6354295", "0.6329606", "0.63228214", "0.6302629", "0.62974095", "0.62851506", "0.6277511", "0.62764305", "0.6265075", "0.62601644", "0.62549806", "0.62459296", "0.62411135", "0.6240088", "0.6239988", "0.6225438", "0.62239957", "0.62216973", "0.621338", "0.621338", "0.621338", "0.62123317", "0.62092763", "0.6204494", "0.6200908", "0.619496", "0.61815727", "0.6166197", "0.6161699", "0.61555874", "0.6152798", "0.6150099", "0.6144662", "0.61357987", "0.61246926", "0.6117069", "0.611561", "0.6113328", "0.61113495", "0.6109158", "0.6102189", "0.61016613", "0.61015177", "0.6098103", "0.6085745", "0.60838443", "0.6080143", "0.60715175", "0.606808", "0.6063283", "0.60609376", "0.6059196", "0.6050487", "0.6046602", "0.60445", "0.6043419", "0.60359836", "0.60334533", "0.60315937", "0.60240847", "0.6019801", "0.6019172", "0.60181844", "0.6017994", "0.60168344", "0.6015136", "0.60147333", "0.6013942", "0.6013755", "0.59990376", "0.5993551", "0.5989121", "0.5987879" ]
0.0
-1
Return the selected rows as array. E.g.: $user_list = $db>getArrayRow( "SELECT FROM user LIMIT 5" ); // return: $user_list => array( 0 => array( 'user_id'=>1, 'name'=>'Rain', 'status'=>'admin' ), ... , 4 => array( ... ) )
function get_list( $query = null, $key = null, $value = null ){ if( $key && $value ) while( $row = mysql_fetch_assoc( $this->query($query) ) ) $rows[ $row[$key] ] = $row[$value]; elseif( $key ) while( $row = mysql_fetch_assoc( $this->query($query) ) ) $rows[ $row[$key] ] = $row; else while( $row = mysql_fetch_assoc( $this->query( $query ) ) ) $rows[ ] = $row; return isset($rows)?$rows:null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract public function getRowAsArray();", "protected function getUserRow(): array\n {\n\n /**\n * @var $_um LightUserManagerService\n */\n $_um = $this->getContainer()->get(\"user_manager\");\n $user = $_um->getOpenUser();\n if (false === $user->isValid()) {\n throw new LightKitStoreException(\"The user is not connected.\");\n }\n $userId = $user->getProp(\"id\");\n\n\n $userApi = $this->getKitStoreService()->getFactory()->getUserApi();\n return $userApi->getUserById($userId);\n }", "public function fetchRow() : array\n\t{\n\t\treturn $this->handle->fetchRow($this->result);\n\t}", "function GetRows()\n {\n $arr = [];\n for ($i = 0, mysqli_data_seek($this->rs, 0); $this->Next(); $i++) $arr[$i] = $this->row;\n return $arr;\n }", "public function GetAllRows() : ARRAY\r\n {\r\n return($this->preparedStatement->fetchAll(\\PDO::FETCH_ASSOC));\r\n }", "public function getArray()\n\t{\n\t\treturn $this->row;\n\t}", "public function GetSingleRow() : ARRAY\r\n {\r\n return($this->preparedStatement->fetch(\\PDO::FETCH_ASSOC));\r\n }", "public function PgGetArraySelect(){\n if ($this->SQuery){\n if (pg_num_rows($this->SQuery)){\n return pg_fetch_all($this->SQuery); \n }else{\n return Array();\n }\n \n } else {\n die(\"NO Existe Consulta SELECT Valida!\");\n }\n }", "function obtenerArray(){\r\n\t\treturn mysql_fetch_array( $this->rs() );\r\n\t}", "public function getRows();", "public function getRows();", "function getRowAsArray($query) {\n\t\topenDatabaseConnection();\n\t\t$result = mysql_query($query) or die(\"Invalid query: \" . mysql_error());\n\t\t# turn the result into an array\n\t\treturn mysql_fetch_assoc($result);\n\t}", "public function getRows($q){ // get array of rows objects\r\t\t$this->connect();\t//connect if not connected \r\t\t$query=$this->query($q);\r\t\t$result=array();\r\t\twhile ($data=sqlite_fetch_object($query)){\r\t\t\t$result[]=$data;\r\t\t}\r\t\treturn $result;\r\t}", "function getArrayOfRows($dbQuery) {\n return mysqli_fetch_array($dbQuery, MYSQL_ASSOC);\n}", "public function fetch_row()\n\t{\n\t\t$row = array();\n\t\tif (current($this->result)) {\n\t\t\tforeach (current($this->result) AS $value) {\n\t\t\t\t$row[] = $value;\n\t\t\t}\n\t\t}else {\n\t\t\t$row = FALSE;\n\t\t}\n\t\tnext($this->result);\n\t\treturn $row;\n\t}", "public function getRow(){\n return oci_fetch_array($this->result);\n\n }", "public function fetchAllUserSelect() {\n try {\n // Select all users\n $query = \"\n select id, email, username\n from tb_user \n where state = 1 and access = 1\n order by username\n \";\n // Create object to connect to MySQL using PDO\n $mysqlPDO = new MySQLPDO();\n // Prepare the query\n $statement = $mysqlPDO->getConnection()->prepare($query);\n // Execute the query without paramters\n $statement->execute();\n // Get affect rows in associative array\n $rows = $statement->fetchAll();\n // Foreach row in array\n foreach ($rows as $row) {\n // Create a User Select object\n $user = new UserSelect($row);\n //Create datatable row\n $tmp_data[] = $user;\n }\n // Export into DataTable json format if there's any record in $tmp_data\n if (isset($tmp_data) && count($tmp_data) > 0) {\n $data = $tmp_data;\n } else {\n $data = array();\n }\n return $data;\n } catch (PDOException $e) {\n die(\"Error message: \" . $e->getMessage());\n }\n }", "public function getArray()\n {\n return mysqli_fetch_array($this->resulset);\n }", "public function getAllRows() {\n\t\t$rows = array();\n\t\t\n\t\tfor($x = 0; $x < $this->getNumRows(); $x++) {\n\t\t\t$rows[] = mysqli_fetch_assoc($this->_result);\n\t\t}\n\t\treturn $rows;\n\t}", "public function rowArray($id = 0) {\n return isset($this->result_array[$id]) ? $this->result_array[$id] : false;\n }", "public function getRowsAsArray(){\n $fieldNames=$this->getFieldNames();\n $result=[];\n if (!empty($this->valuesRows)){\n foreach($this->valuesRows as $valuesRow){\n $rowArr=[];\n foreach($fieldNames as $i=>$fieldName){\n if (isset($valuesRow[$i])){\n $rowArr[$fieldName]=$valuesRow[$i];\n }\n }\n $result[]=$rowArr;\n }\n }\n return $result;\n }", "public function get_rows() {\n\t\tif (!isset($this->rows)) {\n\t\t\t$this->rows = $this->get_array();\n\t\t\t// Take out the header\n\t\t\tarray_shift($this->rows);\n\t\t}\n\t\telse {\n\t\t\treset($this->rows);\n\t\t}\n\t\treturn $this->rows;\n\t}", "function get_all(){\r\n\t\t$rows = array();\r\n\t\twhile($row = $this->get_row()){\r\n\t\t\t$rows[] = $row;\r\n\t\t}\r\n\t\treturn $rows;\r\n\t}", "public function getUsers(){\n $sql=\"SELECT * FROM users\";\n $select=parent::connect_db()->prepare($sql);\n $select->execute();\n if($select->rowCount() > 0):\n return $select->fetchAll(\\PDO::FETCH_ASSOC);\n //return $results;\n else:\n return [];\n endif;\n }", "abstract public function get_rows();", "public function get_row();", "public function fetchArray() {\n return mysqli_fetch_array($this->result);\n }", "public function toArray(){\n\t\treturn json_decode(json_encode($this->rows), true);\n\t}", "public function getRows()\n {\n return $this->last->fetch_array(MYSQLI_ASSOC);\n \n }", "public function getRows()\n\t{\n\t\treturn $this->driver->getRows();\n\t}", "public function fetchArray() : array\n\t{\n\t\treturn $this->handle->fetchArray($this->result);\n\t}", "public function getArrayRows()\n {\n $result = [];\n /** @var \\Magento\\Framework\\Data\\Form\\Element\\AbstractElement */\n $element = $this->getElement();\n $aValue = $element->getValue(); // get values\n if (is_array($aValue) === false) { // no array given? -> value from config.xml\n $aValue = json_decode($aValue, true); // convert string to array\n }\n if ($aValue && is_array($aValue)) {\n foreach ($aValue as $rowId => $row) {\n $rowColumnValues = [];\n foreach ($row as $key => $value) {\n $row[$key] = $value;\n $rowColumnValues[$this->_getCellInputElementId($rowId, $key)] = $row[$key]; // add value the row\n }\n $row['_id'] = $rowId;\n $row['column_values'] = $rowColumnValues;\n $result[$rowId] = new \\Magento\\Framework\\DataObject($row);\n $this->_prepareArrayRow($result[$rowId]);\n }\n }\n return $result;\n }", "public function getUsers(){\n\t\t$query = $this->db->get('users');\n\t\treturn $query->result_array();\n\t}", "public function asRow() {\n\t\treturn $this->_sth->fetchAll(PDO::FETCH_NUM);\n\t}", "public function result_array()\n {\n $output = array();\n\n if (is_bool($this->result))\n {\n return $output;\n }\n\n while ($row = $this->result->fetch_assoc())\n {\n $output[] = $row;\n }\n\n $this->free_result();\n\n return $output;\n }", "function getAllUsers(){\n $sql = self::$connection->prepare(\"SELECT * FROM `user` WHERE role_id = 2\");\n $sql->execute();//return an object\n $items = array();\n $items = $sql->get_result()->fetch_all(MYSQLI_ASSOC);\n return $items; //return an array\n }", "function getUsers($conn){\n\n\t$sql = \"SELECT Username, UserId, Email, AccessLevel FROM user\";\n\n\t$sth = $conn->prepare($sql);\n\t$sth->execute();\n\t\n\t$rows = array();\n\t\n\twhile($r = $sth->fetch(PDO::FETCH_ASSOC)) {\n\t\t$rows[] = $r;\n\t}\n\treturn $rows;\n}", "abstract protected function getRows();", "public function GetRowArray($sql) \n {\n $this->connect();\n \n //connect to database\n if (!empty($sql)) \n {\n try\n {\n $q = $this->db->prepare($sql);\n $q->execute();\n return $q->fetch(PDO::FETCH_ASSOC);\n }\n catch(PDOException $e) \n {\n return $e->getMessage();\n }\n } else\n {\n return 'No query provided';\n die;\n }\n $this->disconnect();\n \n //disconnect from database\n \n \n }", "public function fetchIndexArray() {\n return mysqli_fetch_row ( $this->result );\n }", "function getResult() {\n $rows = array();\n while ($row = mysqli_fetch_assoc($this->theResult)) {\n $rows[] = $row;\n }\n return $rows;\n }", "public function getRows($arg)\n {\n $result = $this->resulter($arg);\n \n if( !$this->hasRows($result) ){\n return array();\n }\n \n $rows = array();\n while( $row = $result->fetch_array(MYSQLI_BOTH) ){\n $rows[] = $row;\n }\n \n return $rows;\n }", "function db_get_row($query)\n{\n\t$args = func_get_args();\n\n\tif ($_result = call_user_func_array('db_query', $args)) {\n\n\t\t$result = driver_db_fetch_array($_result);\n\n\t\tdriver_db_free_result($_result);\n\n\t}\n\n\treturn is_array($result) ? $result : array();\n}", "public function fetch_all_array(){\n $data = array();\n while( ($r = oci_fetch_assoc($this->result)) != false ){\n $data[] = $r;\n }\n return $data;\n }", "public function getAllResult() {\n $rowsArray = array();\n while($row = mysql_fetch_array($this->result)) {\n $rowsArray[] = $row;\n }\n return $rowsArray;\n }", "function fetchRow ()\n {\n return pg_fetch_array($this->_result);\n }", "private function get_all() {\n $result = $this->dbh->query($this->query_array['get_all'], array())->fetchAll();\n $users = [];\n foreach ($result as $row) {\n $user = new User($row['id'], $row['username']);\n $users[] = $user->to_array();\n }\n return $users;\n }", "public function listUsers() {\n $db = CTSQLite::connect();\n $query = 'SELECT * FROM ic_user';\n $stmt = $db->prepare($query);\n $result = $stmt->execute();\n if (!$result) {\n return false;\n } else {\n // $id = $result->fetchArray();\n // return $id['id'];\n $row = $result->fetchArray();\n return $row;\n }\n $db->close();\n unset($db);\n }", "public function fetch_array()\n\t{\n\t\t$array = array();\n\t\tif (current($this->result)) {\n\t\t\tforeach (current($this->result) AS $value) {\n\t\t\t\t$array[] = $value;\n\t\t\t}\n\t\t\tforeach (current($this->result) AS $key => $value) {\n\t\t\t\t$array[$key] = $value;\n\t\t\t}\n\t\t}else {\n\t\t\t$array = FALSE;\n\t\t}\n\t\tnext($this->result);\n\t\treturn $array;\n\t}", "function user_table_data($logged_user_id)\n\t{\n\t\t$select = array('user_file', 'created', 'sex', 'first_name', 'last_name', 'full_name');\n\t\t$this->db->select($select)->from('users')->where('id', $logged_user_id);\n\t $query = $this->db->get();\n\t\tif ($query->num_rows() > 0)\n\t\t{\n\t\t\treturn $query->row_array();\n\t\t}\n\t}", "public function getRows()\n {\n \treturn $this->previouslyExecuted->fetch_array(MYSQLI_ASSOC);\n }", "function getArrayResult($sql) {\n\t\tif ((! $res = $this->goSQL ( $sql )) || ($res->num_rows == 0))\n\t\t\treturn false;\n\t\tif ($res->num_rows == 1) {\n\t\t\treturn $res->fetch_assoc ();\n\t\t}\n\t\twhile ( $item = $res->fetch_assoc () ) {\n\t\t\t$items [] = $item;\n\t\t}\n\t\treturn $items;\n\t}", "function getUserList(){\n try{\n $query = \"Select id, fname, lname, email, phone, created_at FROM users ORDER BY id DESC\";\n $stmt = $this -> getConnection($query);\n $stmt ->execute();\n $stmt ->bind_result($id, $fname, $lname, $email, $phone, $since);\n $result = array();\n while ($stmt -> fetch()) {\n $result[] = array(\n 'id' => $id,\n 'fname'=>$fname,\n 'lname'=>$lname,\n 'email' => $email,\n 'phone' => $phone,\n 'since' => $since\n );\n }\n $stmt->close();\n \n return $result;\n }catch (exception $e){\n die('Error - cannot retrieve user list: ' . $e -> getMessage());\n }\n }", "public function getValues($row){\n $data = array();\n while( ($obj = oci_fetch_assoc($this->result)) != false ){\n $data[] = $obj[$row];\n }\n return $data;\n }", "public function getResultArray(): array\n {\n if (! empty($this->resultArray)) {\n return $this->resultArray;\n }\n\n // In the event that query caching is on, the result_id variable\n // will not be a valid resource so we'll simply return an empty\n // array.\n if (! $this->isValidResultId()) {\n return [];\n }\n\n if ($this->resultObject) {\n foreach ($this->resultObject as $row) {\n $this->resultArray[] = (array) $row;\n }\n\n return $this->resultArray;\n }\n\n if ($this->rowData !== null) {\n $this->dataSeek();\n }\n\n while ($row = $this->fetchAssoc()) {\n $this->resultArray[] = $row;\n }\n\n return $this->resultArray;\n }", "public function FetchArray()\n\t{\n\t\tif (!$this->Result){\t//check if we have a valid result set\n\t\t\treturn false;\n\t\t}\n\n\t\t$row = mysqli_fetch_array($this->Result);\n\n\t\tif (!$row){\t//if last row, free the result set\n\t\t\tmysqli_free_result($this->Result);\n\t\t}\n\n\t\treturn $row;\n\t}", "public function toArray(): array\n {\n $this->initialize();\n return $this->rows;\n }", "function dbgetarray() {\n\t$output = array();\n\t\n\t$args = func_get_args();\n\t$result = call_user_func_array('dbquery', $args);\n\t$query = array_shift($args);\n\n\t// this only applies to SELECT queries!\n\tif (preg_match('/^SELECT/i', $query)) {\n\t\twhile ($result && $row = dbfetch($result, DB_NUM)) {\n\t\t\tif (count($row) == 1) { // use integer keys\n\t\t\t\t$output[] = $row[0];\n\t\t\t} else if (count($row) == 2) { // use first column keys\n\t\t\t\t$output[$row[0]] = $row[1];\n\t\t\t} else { // use integer keys and array values\n\t\t\t\t$output[] = $row;\n\t\t\t}\n\t\t}\n\t\tdbfree($result);\n\t} else {\n\t\tEWarning(EC_REALS_DATABASE, \"dbgetarray called with non-SELECT query!\", \"Non-select query\");\n\t}\n\n\treturn $output;\n}", "public function GetRowsAsArray($sql, $dbCatalog = null, $args=null)\r\n\t{\r\n\t\t/**\r\n\t\t * @var $rows mysqli_result\r\n\t\t */\r\n\t\t$rowsPointer = $this->GetRows($sql, $dbCatalog);\r\n\t\t$rows\t\t = array();\r\n\t\tif (!is_object($rowsPointer))\r\n\t\t{\r\n\t\t\tthrow new Exception(\"Invalid data returned from MySql server for query: $sql\");\r\n\t\t}\r\n\t\twhile ($row = $rowsPointer->fetch_assoc())\r\n\t\t{\r\n\t\t\tarray_push($rows, $row);\r\n\t\t}\r\n\t\treturn $rows;\r\n\t}", "function get ()\n\t{\n\t\t$ ret = array ();\n\t\t\n\t\t// Loop por todos os registros no banco de dados\n\t\tfor ( $ x = 0 ; ( $ x < $ this -> num_records () && count ( $ ret ) < $ this -> _limit ); $ x ++)\n\t\t{\t\t\t\n\t\t\t$ row = $ this -> _px -> retrieve_record ( $ x );\n\t\t\t\n\t\t\tif ( $ this -> _test ( $ row ))\n\t\t\t{\n\t\t\t\tforeach ( $ row as $ key => $ val )\n\t\t\t\t{\n\t\t\t\t\t// Encontre todos os campos que não estão na matriz selecionada\n\t\t\t\t\tif (! in_array ( $ key , $ this -> _select ) &&! empty ( $ this -> _select )) unset ( $ row [ $ key ]);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$ ret [] = $ linha ;\n\t\t\t}\n\t\t}\n\t\t\n\t\treturn $ ret ;\n\t}", "public static function getRowsArray(): array {\n return range('A', 'J');\n }", "public function rows() {\n\t\treturn $this->row();\n\t}", "function fetch_array()\n {\n return mysqli_fetch_array($this->_queryResource);\n }", "public function toArray(\\Nette\\Database\\Table\\Selection $source,$fields=\"\"){\n if($fields!=\"\"){\n $source->select($fields); \n }\n else{\n $source->select(\"*\"); \n }\n return array_map('iterator_to_array', $source->fetchAll());\n }", "public function resultSet(){\r\n $this->execute();\r\n return $this->stmt->fetchAll(PDO::FETCH_OBJ);\r\n /*PDO::FETCH_OBJ\r\n assim podemos imprimir como objeto exemplo\r\n foreach($users as user){\r\n echo $user->name . '<br>';\r\n ao invés de echo $user['name];\r\n */\r\n }", "public function row(User $user): array\n {\n return [\n $user->name,\n $user->cour,\n $user->name,\n ];\n }", "function fetch_array()\n {\n return mysql_fetch_array($this->_queryResource, MYSQL_ASSOC);\n }", "public function asArray() {\n\t\treturn $this->_sth->fetchAll(PDO::FETCH_ASSOC);\n\t}", "public function getAllUsersDataArray()\n {\n $query = 'select userID, username, name, isAdmin, passwordPlaintext, email, isRSVP, isThankYouSent, address, gift, thankYouCardNotes, notesRSVP, lastLoginTime from users order by userID;';\n if ($this->connectedModel->runQuery($query)) //query\n {\n $arrayAllUsers = array();\n while ($row = $this->connectedModel->getResultsAssoc())\n {\n $arrayAllUsers[$row['userID']] = array(\n 'userID' => $row['userID'],\n 'username' => $row['username'],\n 'name' => $row['name'],\n 'isAdmin' => (($row['isAdmin'] == '1') ? true : false),\n 'passwordPlaintext' => $row['passwordPlaintext'],\n 'email' => $row['email'],\n 'isRSVP' => (($row['isRSVP'] == '1') ? true : false),\n 'isThankYouSent' => (($row['isThankYouSent'] == '1') ? true : false),\n 'address' => $row['address'],\n 'gift' => $row['gift'],\n 'thankYouCardNotes' => $row['thankYouCardNotes'],\n 'notesRSVP' => $row['notesRSVP'],\n 'lastLoginTime' => $row['lastLoginTime']\n );\n }\n return $arrayAllUsers;\n }\n else\n {\n return false;\n }\n }", "public function Read()\n {\n $query = $this->db->prepare(\"SELECT * FROM users\");\n $query->execute();\n $data = array();\n while ($row = $query->fetch(PDO::FETCH_ASSOC)) {\n $data[] = $row;\n }\n return $data;\n }", "public function getAllUsers(): array\r\n {\r\n $query = $this->db->query('SELECT `Firstname`, `Surname`, `DateOfBirth`, `PhoneNumber`, `Email` \r\n FROM `users` \r\n WHERE `Deleted` = 0;');\r\n\r\n return $query->fetchAll();\r\n }", "public function selectRows($fields='*', $table='users' ,$limit=10) {\n\t\tif(is_array($fields))\n\t\t{\n\t\t\t$fields = implode(\",\",$fields);\n\t\t}\n\t $sql = \"SELECT $fields from $table LIMIT $limit\"; \n $result = mysql_query($sql);\n\t\t$returnArray = array();\n\t\twhile($row = mysql_fetch_assoc($result))\n\t\t{\n\t\t\t$returnArray[] = $row;\n\t\t}\n\t\treturn $returnArray;\n }", "function db_result_to_array($result) {\n $res_array = array();\n\n for ($count=0; $row = $result->fetch_assoc(); $count++) {\n $res_array[$count] = $row;\n }\n\n return $res_array;\n}", "public final function rowsArray($table, $where, $limit = -1, $page = 1) \n {\n return AutoRecord::loadRowsWhere($this, $table, $where, $limit, $page);\n }", "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 }", "function db_select_into_array( $statement ) {\n\n $this->db_run_query( $statement );\n\n if( ! is_object( $this->dataset_obj )) return NULL;\n\n while( $this->db_fetch_next_row() ) {\n $this->dataset_array[] = $this->curr_row_array;\n }\n\n $this->dataset_obj->free(); # We don't need this any more as we have all the same data in an array\n\n return $this->dataset_array;\n }", "public function rows(string $query = null): array;", "function loadResultArray($numinarray = 0) {\n\t\tif (!($cur = $this->query())) {\n\t\t\treturn null;\n\t\t}\n\t\t$array = array();\n\t\twhile ($row = mysql_fetch_row( $cur )) {\n\t\t\t$array[] = $row[$numinarray];\n\t\t}\n\t\tmysql_free_result( $cur );\n\t\treturn $array;\n\t}", "public function getRowDataAsArray( $iRow )\r\n {\r\n return $this->data[$iRow];\r\n }", "function db_result_to_array($result) {\r\n $res_array = array();\r\n\r\n for ($count = 0; $row = $result->fetch_assoc(); $count++) {\r\n $res_array[$count] = $row;\r\n }\r\n return $res_array;\r\n }", "public function fetch_array() {\n\t\treturn $this->FetchArray();\n\t}", "function user_data($user_id){\n $this->db->select('*');\n $this->db->from('users');\n $this->db->where('user_id', $user_id);\n $query = $this->db->get();\n return $query->row_array();\n }", "function getRows($table_name)\n {\n $sql = sprintf(\"SELECT * FROM %s\", $table_name);\n $rows = array();\n\n $result = $this->query($sql);\n while($row = $result->fetchArray(SQLITE3_ASSOC))\n {\n array_push($rows, $row);\n }\n\n return $rows;\n }", "function returnArrays()\r\n\t\t{\r\n\t\tif (mysql_num_rows($this->result) > 0)\r\n\t\t\t{\r\n\t\t\twhile($row=mysql_fetch_assoc($this->result))\r\n\t\t\t\t{\r\n\t\t\t\t$arrays[]=$row;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\treturn $arrays;\r\n\t\t}", "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 }", "protected function _get_row()\r\n {\r\n $result = $this->db->get()->row_array();\r\n\r\n //execute extends in child class.\r\n $result = $this->_extend_get_row($result);\r\n\r\n return $result;\r\n }", "public function select($query) {\n $rows = array();\n $result = $this -> query($query);\n if($result === false) {\n return false;\n }\n while ($row = $result -> fetch_assoc()) {\n $rows[] = $row;\n }\n return $rows;\n }", "function fetchAll()\n {\n $rows=array();\n if ($this->consulta)\n {\n //la funcion oci_fetch_array devuelve cada fila de la consulta en forma de array\n while($row = oci_fetch_array($this->consulta, OCI_BOTH))\n { //luego cada fila (como un array) se agrega a otro array... creando un array de 2 dimsnesiones\n $rows[]=$row;\n }\n }\n return $rows;\n }", "public function select_all()\n {\n // TODO: Limit to id_user\n $query = $this->db->get($this->table);\n return $query;\n }", "public function fetchRowset()\n\t{\n\t\t$this->_query();\n\n\t\treturn $this->stmt->fetchAll(\\PDO::FETCH_ASSOC);\n\t}", "function dbgetrow() {\n\t$output = array();\n\n\t$args = func_get_args();\n\t$result = call_user_func_array('dbquery', $args);\n\t$query = array_shift($args);\n\n\t// this only applies to SELECT queries!\n\tif (preg_match('/^SELECT/i', $query) && $result) {\n\t\t$output = dbfetch($result, DB_ASSOC);\n\t\t\n\t\tdbfree($result);\n\t} else {\n\t\tEWarning(EC_REALS_DATABASE, \"dbgetrow called with non-SELECT query!\", \"Non-select query\");\n\t}\n\n\treturn $output;\n}", "public static function select_all() {\n $db = Database::getDB();\n\n $query = 'SELECT * FROM users ORDER BY lastName';\n $statement = $db->prepare($query);\n $statement->execute();\n $results = $statement->fetchAll();\n\n\n $users = array();\n foreach ($results as $row) {\n $user = new User($row['username'], $row['password'], $row['role']);\n $users[] = $user;\n }\n return $users;\n }", "public function getAll(): array\n {\n $query = \"select `username`, `age`, `role` from users where 1\";\n $sth = $this->db->prepare($query);\n $sth->execute();\n $resp = $sth->fetchAll(\\PDO::FETCH_OBJ);\n\n return $resp;\n }", "function db_result_to_array($result) {\n $res_array = array();\n \n for ($count=0; $row = $result->fetch_assoc(); $count++) {\n $res_array[$count] = $row;\n }\n \n return $res_array;\n }", "public function selectAllUsersIds(){\r\n $stmt = self::$con->prepare(\"SELECT id,name,email FROM users\");\r\n $stmt->execute();\r\n $results = $stmt->fetchAll(PDO::FETCH_ASSOC);\r\n return $results;\r\n }", "public function fetch_array()\n\t{\n\t\tif($this->num_rows() < 1)\n\t\t\treturn false;\n\n\t\t$data = $this->result_metadata();\n\t\t$fields = array();\n\t\t$out = array();\n\n\t\t$fields[0] = &$this;\n\t\t$count = 0;\n\n\t\twhile($field = $data->fetch_field()) {\n\t\t\t$fields[$count] = &$out[$field->name];\n\t\t\t$count++;\n\t\t}\n\n\t\tcall_user_func_array(array($this, 'bind_result'), $fields);\n\n\t\treturn ($this->fetch()) ? $out : false;\n }", "public function getUsers()\n {\n $stmt = $this->DB->prepare(\"select user, hash from users\");\n $stmt->execute();\n // fetchall returns all records in the set as an array\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\n }", "function FetchArray() {\n\t\t\t$this->ConnectServer();\n\t\t\t$array = pg_fetch_array($this->result, NULL, PGSQL_ASSOC);\n\t\t\t$this->DisconnectServer();\n\t\t\treturn $array;\n\t\t}", "function GetAllRows($handle = false)\n {\n if ($handle) $handle = $this->_lastHandle;\n $ret = array();\n switch ($this->_DB) {\n case 'mysql':\n while ($row = mysqli_fetch_assoc($handle)) {\n $ret[] = $row;\n }\n break;\n }\n return $ret;\n }", "function getResultArray($sql) {\n require_once(\"Y_DB_MySQL.class.php\");\n $db = new My();\n $array = array();\n $db->Query($sql);\n \n while ($db->NextRecord()) {\n array_push($array, $db->Record);\n }\n \n $db->Close();\n return $array;\n }", "function getList()\n {\n global $db;\n $sql = \" select * from \".$this->table.\" \"; \n $db->SetFetchMode(ADODB_FETCH_ASSOC);\n\t\t$info = $db->execute($sql);\n \t\t$item = $info->GetRows();\t\n\t\treturn $item;\n }" ]
[ "0.7267838", "0.7126076", "0.7049615", "0.68625486", "0.68165267", "0.6814943", "0.6797121", "0.67862135", "0.6749083", "0.670117", "0.670117", "0.67003316", "0.6672785", "0.6661492", "0.66379684", "0.6602265", "0.6565288", "0.6526044", "0.6525728", "0.65190536", "0.6464925", "0.6445157", "0.6435589", "0.6420298", "0.6412838", "0.6399292", "0.63887495", "0.6367386", "0.6365075", "0.6362358", "0.6353517", "0.63417554", "0.6338442", "0.63348705", "0.63221693", "0.632026", "0.6315404", "0.63001245", "0.629227", "0.6286188", "0.6277697", "0.6275975", "0.62694985", "0.62668717", "0.62657505", "0.6261458", "0.6259667", "0.6257399", "0.6252887", "0.62439847", "0.62333685", "0.6218436", "0.6214743", "0.62129074", "0.6210851", "0.61990607", "0.6189442", "0.6186876", "0.61856085", "0.6180471", "0.6179688", "0.6175663", "0.6173913", "0.616401", "0.61528254", "0.615248", "0.61447096", "0.61439604", "0.6139327", "0.61369", "0.61301166", "0.6127006", "0.6126298", "0.6116378", "0.6115073", "0.6107483", "0.6098952", "0.6098581", "0.6096514", "0.609568", "0.6094753", "0.6092934", "0.6092847", "0.60836756", "0.6083433", "0.60830325", "0.607988", "0.6079784", "0.6079771", "0.6071931", "0.6071038", "0.60699254", "0.6065003", "0.60630196", "0.60628396", "0.6062018", "0.60595125", "0.60588884", "0.60586596", "0.6058417", "0.6056634" ]
0.0
-1
Return the last inserted id of an insert query
function get_inserted_id( ){ return mysql_insert_id( $this->link ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function insert_id()\n\t{\n\t\tif ($this->db_type == 'pgsql')\n\t\t{\n\t\t\treturn $this->execute('SELECT lastval() as id')->current()->id;\n\t\t}\n\t\treturn $this->conn->lastInsertId();\n\t}", "public function insertId() {\n\t\treturn $this->_dbh->lastInsertId();\n\t}", "public function getLastInsertID();", "public function insertid()\n {\n $this->connect();\n\n return $this->connection->lastInsertId();\n }", "public static function getLastInsertId()\n {\n return self::$sql->lastInsertId();\n }", "public function insert_id() {\n\t\treturn $this->db->lastInsertId();\n\t}", "public function getLastInsertId(){\n\t\treturn $this->connection->insert_id;\n\t}", "function getLastInsertID(){\r\n\t\t\r\n\t\treturn $this->connection->insert_id;\r\n\t}", "public function getInsertId()\n {\n return $this->conn->lastInsertId();\n }", "function get_insert_id() {\n\t\t\treturn self::$db->last_inserted_id();\n\t\t}", "public function insert_id()\n\t{\n\t\treturn $this->lastInsertId();\n\t}", "public function insertId()\n\t{\n\t\treturn $this->pdo->lastInsertId();\n\t}", "public function getLastInsertId();", "public function getLastInsertId();", "public function getLastInsertId();", "public function getInsertId()\n\t\t{\n\t\t\treturn $this->connection->lastInsertId();\n\t\t}", "public function get_last_inserted_id(){\n\t\treturn $this->db->insert_id();\n\t}", "public function lastInsertID()\n\t{\n\t\treturn $this->_conn->insert_id;\n\t}", "function get_last_inserted_id() {\n return $this->db->insert_id();\n }", "function insertid() {\n return $this->last_insert_id;\n }", "public function lastInsert(){\n\t\treturn $this->dbh->lastInsertId();\n\t}", "public function getLastInsertID()\n {\n\t return $this->connections[ $this->activeConnection]->insert_id;\n }", "public function lastInsertId()\n\t{\n\t\treturn $this->connection->lastInsertId();\n\t}", "public function insertId () {\n\n return $this->_lastInsertId;\n }", "public function getInsertId();", "function lastInsertId()\n\t{\n\t\treturn @$this->functions['insert_id']($this->connection_master);\n\t}", "public function get_last_insert_id(){\n\t\treturn $this->db->insert_id();\n\t}", "public function last_insert_id() {\n\t\treturn $this->adapter->lastInsertId();\n\t}", "public function getInsertId()\n {\n return $this->_result !== null\n ? $this->_dbInstance->lastInsertId() : 'msg:data not inserted';\n }", "function get_last_inserted() {\n return $this->db->insert_id();\n }", "public function insertGetId()\n {\n return $this->lastId;\n }", "public function insertGetId()\n {\n return $this->lastId;\n }", "public function lastInsertedId() {\n return $this->_dbh->lastInsertId();\n\n }", "public function getInsertId() {\r\n\t\treturn $this->PDO->lastInsertId();\r\n\t}", "abstract public function getLastInsertId();", "public function LastInsertId() {\n\t\t\t\treturn $this->connection->lastInsertId();\n\t\t\t}", "public function lastInsertId() {\n return $this->connection->lastInsertId();\n }", "public function getLastInsertId()\t{\n\t\treturn $this->_hDb->lastInsertId();\n\t}", "public function insertId() {\r\n\t\treturn mysql_insert_id ( $this->_conn );\r\n\t}", "public function lastInsertId(){\n return $this->conn->lastInsertId();\n }", "protected function getLastInsertId(){\n $iLastInsertId = $this->objDbConn->lastInsertId();\n return $iLastInsertId;\n }", "public function lastInsertId();", "public function lastInsertId();", "public function lastInsertId();", "public function last_insert_id() {\n\t\t\n\t\treturn $this->pdo->lastInsertId();\n\t\n\t}", "public function getInsertId(){\n return $this->sqli->insert_id;\n }", "function last_inserted_id() {\n return mysql_insert_id($this->db_conn);\n }", "public function getLastInsertedID(){\n // Return last created id\n return $this->connection->insert_id();\n }", "public function lastInsertId () {\r\n return $this->cachedLastInsertId; // $this->db->lastInsertId();\r\n }", "public function lastInsertId()\n {\n return @db2_last_lastInsertId($this->connection);\n }", "public function insert_id() {\n\t\t// get the last id inserted over the current db connection\n\t\treturn mysqli_insert_id($this->connection);\n\t}", "function getLastInsertID() {\n return mysql_insert_id($this->CONNECTION);\n }", "public function getLastInsertedId()\r\n\t{\r\n\t\treturn $this->db->getLastInsertedId();\r\n\t}", "public function lastInsertId() {\r\n\t\tif ($this -> pdo) {\r\n\t\t\treturn $this -> link -> lastInsertId();\r\n\t\t} else {\r\n\t\t\treturn mysql_insert_id($this -> link);\r\n\t\t}\r\n\t}", "public function getLastInsertId()\n {\n return $this->getHandler()->getConnection()->lastInsertId();\n }", "public function getLastInsertId()\n {\n if (!$id = $this->db->Insert_Id()) {\n throw new Exception(\"Method 'Insert_Id' is not supported!\");\n }\n\n return $id;\n }", "function Insert_ID()\n\t{\n\t\treturn $this->GetOne($this->identitySQL);\n\t}", "public function last_insert()\n {\n return mysqli_insert_id($this->db);\n }", "protected function lastInsertId()\n {\n return $this->mysqli->insert_id;\n }", "public function getLastInsertId()\n {\n return $this->wpDatabase->insert_id;\n }", "function insertId()\n\t{\n\t\treturn mysql_insert_id($this->conn);\n\t}", "function getLastinsertId (){\n return $this->pdo->lastInsertId();\n }", "public function lastInsertedId()\n\t{\n\t\t// verify that a query was run\n\t\tif (is_resource($this->_results) === false)\n\t\t{\n\t\t\tthrow new DatabaseException('',\n\t\t\t\tDatabaseException::QUERY_NOT_RUN);\n\t\t}\n\n\t\t// check connection\n\t\t$this->_checkConnection();\n\n\t\t// get the last id\n\t\treturn mysql_insert_id($this->_connection);\n\t}", "public function get_insert_id() {\r\n\t\treturn mysql_insert_id ( $this->conn );\r\n\t}", "function db_last_inserted_id(){\n\tglobal $mysqli;\n\treturn intval($mysqli->insert_id);\n}", "function lastInsertId() {\n return mysql_insert_id();\n }", "public function getInsertId(){\n\t\treturn $this->con->insert_id;\n\t}", "public function last_insert_id ()\n\t{\n\t\treturn $this->db->lastInsertId();\n\t}", "public function GetLastInsertID()\r\n\t{\r\n\t\treturn $this->last_insert_id;\r\n\t}", "public function getInsertId()\n\t{\n\t\treturn $this->m_insert_id;\n\t}", "public function lastInsertId() {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId() {\n return $this->pdo->lastInsertId();\n }", "public function getLastID() {\n return $this->db->insert_id();\n }", "public function insert_id() {\n return mysql_insert_id($this->connection);\n }", "function insert_id() {\n\t\treturn $this->mysql_client->insert_id;\n\t}", "public function getLastInsertId()\n {\n return $this->PDO->lastInsertId();\n }", "function lastInsertId() {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->pdo->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->pdo->lastInsertId();\n }", "public function getLastId(){\n return $this->con->insertId();\n }", "public function getLastInsertId()\n {\n return $this->getPdo()->lastInsertId();\n }", "public function lastInsertId()\n {\n return $this->_adapter->lastInsertId();\n }", "public function lastInsertID() {\n return $this->_pdo->lastInsertId();\n }", "public function getInsertId()\n {\n return $this->insertId;\n }", "public function lastInsertId(){\n return $this->pdo->lastInsertId();\n }", "public function insert_id(){\n\t\treturn @mysql_insert_id($this->conn);\n\t}", "function db_last_insert() {\n $connection = db_connect();\n return $connection->insert_id;\n}", "public function insertId() {\n return mysqli_insert_id($this->connection);\n }", "public function get_last_insert_id()\n\t\t{\n\t\t\treturn( $this->last_insert_id );\n\t\t}", "function lastInsertId() {\n\t\treturn sqlite_last_insert_rowid($this->connection);\n\t}", "public function insertId()\n\t{\n\t\treturn mysqli_insert_id($this->conn);\n\t}", "public function insert_id() {\r\n return mysql_insert_id($this->connection);\r\n }", "public function inserted_id(){\n return $this->connection->insert_id;\n }", "public function getLastInsertId()\r\n {\r\n return $this->getMaster()->lastInsertId();\r\n }", "public function sql_insert_id()\n {\n return $this->link->insert_id;\n }", "function getInsertId(){\r\n\t\treturn $this->m_insertId;\r\n\t}", "final public function getInsertId() {\n return $this->_getInsertId();\n }" ]
[ "0.86645234", "0.8615922", "0.8418249", "0.841019", "0.83989596", "0.838976", "0.83887696", "0.83885026", "0.8386721", "0.83779943", "0.8363466", "0.8357726", "0.8356784", "0.8356784", "0.8356784", "0.8336251", "0.832631", "0.8309489", "0.8294475", "0.8289815", "0.8280867", "0.8279425", "0.8277336", "0.8269192", "0.82684803", "0.8263916", "0.8262644", "0.82502806", "0.8248743", "0.8246215", "0.82454085", "0.82454085", "0.82435685", "0.82309216", "0.82287806", "0.8227881", "0.82272625", "0.82064563", "0.8201342", "0.82003653", "0.8188101", "0.8179607", "0.8179607", "0.8179607", "0.81727934", "0.8164461", "0.8163624", "0.81608033", "0.81589895", "0.81523967", "0.8136844", "0.8134489", "0.8125439", "0.81244", "0.81207746", "0.8097098", "0.8095885", "0.8092863", "0.8089124", "0.8087563", "0.80863464", "0.8085661", "0.8085468", "0.8080083", "0.8078057", "0.8074586", "0.8068221", "0.80645955", "0.8061543", "0.80572855", "0.80560446", "0.80560446", "0.80470824", "0.803716", "0.8037076", "0.8031591", "0.8029181", "0.8023452", "0.8023452", "0.8023452", "0.8023452", "0.8023452", "0.8023452", "0.8022601", "0.80193174", "0.8019234", "0.80189705", "0.80188197", "0.8014789", "0.80116266", "0.8011036", "0.8010836", "0.80066895", "0.8004951", "0.80040956", "0.8002947", "0.80024123", "0.80000573", "0.7996737", "0.7993613", "0.79840684" ]
0.0
-1
Call this method at begining to profile the queries
function setProfiling(){ $this->query("SET profiling=1"); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function beforeStartProfile(Item $profile)\n {\n echo $profile->getSQLStatement();\n }", "public function run()\n {\n DB::disableQueryLog();\n parent::run();\n }", "public function init_save_queries()\n {\n }", "public static function enableQueryLog()\n {\n }", "public function __construct()\n {\n DB::enableQueryLog();\n }", "public function __construct(){\n DB::enableQueryLog();\n }", "public function beginDbProfile($token, $category='database'){\n\t\t$log = array(\"Begin SQL Profiling $token\", 8, $category, microtime(true));\n\t\t$this->_logs[] = $log;\n\t\t$this->_profiles[$token] = $log;\n $query_index = Doo::db()->getQueryCount();\n $this->_profiles[$token]['sqlstart'] = ($query_index<0)?0:$query_index;\n\t\t$this->_profiles[$token]['startmem'] = $this->memory_used();\n\t}", "protected function _begin() {\n $this->dataSource = $this->getDataSource();\n }", "function initProfiler()\r\n{\r\n global $TIME_START;\r\n $TIME_START=microtime(1);\r\n global $DB_ITEMS_LOADED;\r\n $DB_ITEMS_LOADED=0;\r\n\r\n global $g_count_db_statements;\r\n $g_count_db_statements = 0;\r\n}", "public function begin () {\n $this->connection->begin();\n $this->update_current_user_activity();\n }", "public function enableQueryLog()\n {\n $this->loggingQueries = true;\n }", "function query() {\n $this->add_additional_fields();\n }", "private function startCountingSelectQueries(): void\n {\n if ($this->showQueries !== self::SHOW_QUERIES_RESET) {\n throw new LogicException('showQueries wasnt reset, you did something wrong');\n }\n $this->showQueries = $_REQUEST['showqueries'] ?? null;\n // force showqueries on to count the number of SELECT statements via output-buffering\n // if this approach turns out to be too brittle later on, switch to what debugbar\n // does and use tractorcow/proxy-db which should be installed as a dev-dependency\n // https://github.com/lekoala/silverstripe-debugbar/blob/master/code/Collector/DatabaseCollector.php#L79\n $_REQUEST['showqueries'] = 1;\n ob_start();\n echo '__START_ITERATE__';\n }", "public function query()\n {\n }", "public function query()\n {\n }", "private function profilerInit(): void\n {\n\n Profiler::init();\n Profiler::xhprofStart();\n\n }", "private function initQuery()\n {\n // reset\n $this->result = false;\n \n $this->errorCode = 0;\n $this->errorMessage = '';\n }", "public function gatherSQLQueryData()\n {\n $queryTotals = array();\n\n $queryTotals['count'] = 0;\n $queryTotals['time'] = 0;\n\n $queries = array();\n\n if(isset($this->connection)) {\n $queryLog = $this->connection->getQueryLog();\n\n $queryTotals['count'] += count($queryLog);\n\n foreach($queryLog as $query) {\n if(isset($query['bindings']) && ! empty($query['bindings'])) {\n $query['sql'] = PdoDebugger::show($query['query'], $query['bindings']);\n } else {\n $query['sql'] = $query['query'];\n }\n\n $query = $this->attemptToExplainQuery($query);\n\n $queryTotals['time'] += $query['time'];\n\n $query['time'] = $this->getReadableTime($query['time']);\n\n //\n $queries[] = $query;\n }\n }\n\n $queryTotals['time'] = $this->getReadableTime($queryTotals['time']);\n\n $this->output['queries'] = $queries;\n $this->output['queryTotals'] = $queryTotals;\n }", "private function initQuery()\n {\n $this->_lastSql = null;\n $this->_limit = null;\n $this->_offset = null;\n $this->_order = array();\n $this->_group = array();\n $this->_table = null;\n $this->_stmt = null;\n\n $this->fromStates = array();\n $this->selectFields = array();\n $this->whereStates = array();\n $this->havingStates = array();\n $this->values = array();\n $this->joinStates = array();\n }", "public function logQueries()\n {\n // DbLoJack Helper\n $helper = app('db_lojack');\n\n // Log database queries for the request\n foreach ($helper->connections() as $connection) {\n $queries = DB::connection($connection)->getQueryLog();\n $helper->logQueries($queries, $connection );\n }\n }", "public function loadProfileInformation() {\n\t\t\t$procedure = \"get\" . $this->mode_ . \"Information\"; \n\t\t\t$this->profileInformation_ = $this->dbHandler_->call($procedure, \"%d\", array($this->id_));\n\t\t}", "public function profilerStart()\n {\n if (extension_loaded('xhprof')) {\n include_once($this->xhprofLibPath . 'utils/xhprof_lib.php');\n include_once($this->xhprofLibPath . 'utils/xhprof_runs.php');\n xhprof_enable(XHPROF_FLAGS_CPU + XHPROF_FLAGS_MEMORY);\n }\n }", "public static function query()\n {\n }", "function query_info()\r\n\t\t{\r\n\t\t\techo \"<u>Your Previous Query Consisted of:</u><br>\";\r\n\t\t\techo \"SQL = '\".$this->last_query[\"sql\"].\"'<br>\";\r\n\t\t\t$temp = ($this->last_query[\"end_time\"] - $this->last_query[\"start_time\"]);\r\n\t\t\t$temp *= 1000;\r\n\t\t\t$temp = number_format($temp, 3);\r\n\t\t\techo \"Time Elapsed: \".$temp.\"(ms)<br>\";\r\n\t\t\techo \"Number of Records: \".$this->numrows.\"<br>\";\r\n\t\t\techo \"Number of Rows Affected: \".$this->affected_rows;\r\n\t\t}", "public function onRun()\n {\n $user = Auth::getUser();\n $examList = Exam::paginate(10);\n\n if ($examList) {\n $this->page['exams'] = $examList;\n $this->page['scores'] = FinalScore::where('user_id', $user->id)\n ->orderBy('created_at', 'desc')\n ->get();\n }\n }", "function begin() {\n\t\t\tself::$db->begin();\n\t\t\t$this->begin_executed = true;\n\t\t}", "public function get_query_log()\n {\n }", "public function query_start($query)\n {\n if (($this->mode > 0) and (!$this->sql_query_running)) {\n $this->sql_query_running = true;\n $this->sql_query_start = microtime(true);\n $this->sql_query_string = $query;\n }\n }", "public function enableQueryLog()\n\t{\n\t\t$this->neoeloquent->enableQueryLog();\n\t}", "public static function flushQueryLog()\n {\n }", "function pre_query() {\n $this->view->field += $this->casetracker_fields;\n unset($this->view->field['cuid']); // this could be more surgical.\n }", "abstract protected function initQuery(): void;", "function devlyQueries() {\n\t\n\techo 'ran ' . get_num_queries() . ' queries in ' . timer_stop(1) . ' seconds';\n\t\n}", "public function actionDatabaseQueries() {\n echo \"Database Debug Log:\";\n $this->showLog('dbDebug.log');\n }", "public function pre_dispatch()\n\t{\n\t\t$this->_memID = currentMemberID();\n\t\t$this->_profile = MembersList::get($this->_memID);\n\t}", "function query() {\n }", "public function test_queries()\n\t{\n\t\t$this->setup_options_obj($input);\n\t\t$rpt = new Reports_Model($this->options);\n\t\t$rpt->set_option('start_time', 0);\n\t\t$rpt->set_option('end_time', time());\n\t\t$result = $rpt->test_summary_queries();\n\t\techo \"<pre>\\n\";\n\t\t$cnt = count($result);\n\t\techo $cnt . \" total different queries\\n\";\n\t\t$total_rows = 0.0;\n\t\tforeach ($result as $query => $ary) {\n\t\t\techo $query . \"\\n\";\n\t\t\tprint_r($ary);\n\t\t\t$total_rows += $ary['rows'];\n\t\t}\n\t\t$avg_rows = $total_rows / $cnt;\n\t\techo \"Average row-count: $avg_rows\\n\";\n\t\techo \"</pre>\\n\";\n\t\tdie;\n\t}", "function profiler() {\n $profiler = new Doctrine_Connection_Profiler();\n foreach (Doctrine_Manager::getInstance()->getConnections() as $conn) {\n $conn->setListener($profiler);\n }\n\n // query goes here\n\n $final = array();\n\n $q = Doctrine_Query::create()\n ->select('ac.name, COUNT(ar.id) AS num_archive')\n ->from('ACategory ac')\n ->leftJoin('ac.Archives ar')\n ->groupBy('ac.id')\n ;\n $result1 = $q->execute(array(), Doctrine_Core::HYDRATE_ARRAY);\n\n $q = Doctrine_Query::create()\n ->select('ac.name, ar.title')\n ->from('ACategory ac')\n ->leftJoin('ac.Archives ar')\n ;\n $result2 = $q->execute(array(), Doctrine_Core::HYDRATE_ARRAY);\n\n $q = Doctrine_Query::create()\n ->select('ar.title, COUNT(c.id) AS num_comment')\n ->from('Archive ar')\n ->leftJoin('ar.AComments c')\n ->groupBy('ar.id')\n ;\n $result3 = $q->execute(array(), Doctrine_Core::HYDRATE_ARRAY);\n\n $acat_archive = $result2;\n\n for($i = 0; $i < sizeof($result2); $i++) {\n for($j = 0; $j < sizeof($acat_archive[$i]['Archives']); $j++) {\n for($k = 0; $k < sizeof($result3); $k++) {\n if($acat_archive[$i]['Archives'][$j]['id'] == $result3[$k]['id']) {\n $acat_archive[$i]['Archives'][$j]['num_comment'] = $result3[$k]['num_comment'];\n }\n }\n }\n $acat_archive[$i]['num_archive'] = $result1[$i]['num_archive'];\n }\n\n $final = $acat_archive;\n\n // analyze the profiler data\n $time = 0;\n $events = array();\n foreach ($profiler as $event) {\n $time += $event->getElapsedSecs();\n if ($event->getName() == 'query' || $event->getName() == 'execute') {\n $event_details = array(\n \"type\" => $event->getName(),\n \"query\" => $event->getQuery(),\n \"time\" => sprintf(\"%f\", $event->getElapsedSecs())\n );\n if (count($event->getParams())) {\n $event_details[\"params\"] = $event->getParams();\n }\n $events []= $event_details;\n }\n }\n\n fb($final);\n fb($events);\n fb('Total Doctrine time: \" '.$time);\n fb('\"Peak Memory: \" '.memory_get_peak_usage());\n }", "function showProfile(){\r\n\t\tif( $profiles = $this->getArrayRow( \"SHOW profiles\" ) ){\r\n\t\t\t$html = '<table cellspacing=\"1\" cellpadding=\"10\" bgcolor=\"#cccccc\" style=\"font:11px Helvetica;\"><tr style=\"font-weight:bold\"><td>Query ID</td><td>exec time</td><td width=\"150\">%</td><td>Query</td></tr>';\r\n\t\t\tfor( $i=0, $execution_time = 0, $n=count($profiles); $i<$n; $i++ )\r\n\t\t\t\t$execution_time += $profiles[$i]['Duration'];\r\n\r\n\t\t\tforeach($profiles as $i => $p ){\r\n\t\t\t\t$perc = round( ( $p['Duration'] / $execution_time ) * 100, 2 );\r\n\t\t\t\t$width = ceil( $perc * 2 );\r\n\t \t\t\t$html .= '<tr bgcolor=\"#eeeeee\"><td>'.$p['Query_ID'].'</td><td>'.$p['Duration'].'</td><td><div style=\"float:left;width:50px;\">'.$perc.'%</div> <div style=\"display:inline; margin-top:3px;float:left;background:#ff0000;width:'.$width.'px;height:10px;\"></td><td>'.$p['Query'].'</td></tr>';\r\n\t\t\t}\r\n\t\t\treturn $html .= '</table>';\t\r\n\t\t}\r\n\t}", "protected function loadSubQueries()\n {\n foreach ($this->subQueries as $subQuery) {\n $subQuery($this->tableQuery);\n }\n }", "protected function load(){\r\n\t\r\n\t$qq1 = Db::result(\"SELECT * FROM \"._SQLPREFIX_.$this->tableName.\" WHERE \".$this->fieldName.\" = \".(int)$this->id);\r\n\t$this->profileData = count($qq1)>0 ? $qq1[0]: null; \r\n\t\r\n\tif($this->metaUse){\r\n\t\t$qq2 = Db::result(\"SELECT * FROM \"._SQLPREFIX_.$this->metaTypesTableName.\" WHERE active = 1 ORDER BY public_ord, id\");\r\n\t\t$this->metaData = count($qq2)>0 ? $qq2: array(); \r\n\t}\r\n}", "public function _query()\n {\n }", "protected function afterQuery() {\n\n // Make WP_User_Query behaves like WP_Query\n if ($this->query['number'] && $this->total_users) {\n $this->max_num_pages = ceil($this->total_users / $this->query['number']);\n }\n\n foreach ($this->results as $key => $user) {\n if ($user instanceof WP_User) {\n do_action('vtcore_wordpress_pre_get_user_object', $this->results[$key]);\n }\n }\n }", "function basey_query_load_time() {\n\n\tif (current_user_can( 'manage_options' )) { ?>\n\t\t<div class=\"uk-container uk-margin-bottom\">\n\t\t\t<div class=\"uk-panel uk-panel-box\">\n\t\t\t\t<strong><?php echo get_num_queries(); ?></strong> queries in <strong><?php timer_stop(1); ?></strong> seconds\n\t\t\t</div>\n\t\t</div>\n\t<?php }\n}", "public function query()\n\t{\n\t\t\n\t}", "public function setUp() {\n $this->databaseContents['profile_fields'] = $this->expectedResults;\n parent::setUp();\n }", "private function before_execute()\n {\n }", "function _visit_profile() {\n if (!$this->staff && !$this->has_arg('visit')) $this->_error('Access Denied', 403);\n\n $where = '';\n $args = array();\n\n if ($this->has_arg('bl')) {\n $where .= ' AND s.beamlinename LIKE :'. (sizeof($args)+1);\n array_push($args, $this->arg('bl'));\n }\n if ($this->has_arg('run')) {\n $where .= ' AND vr.runid = :' . (sizeof($args)+1);\n array_push($args, $this->arg('run'));\n }\n\n if ($this->has_arg('visit')) {\n $where .= \" AND CONCAT(CONCAT(CONCAT(p.proposalcode,p.proposalnumber), '-'), s.visit_number) LIKE :\".(sizeof($args)+1);\n array_push($args, $this->arg('visit'));\n }\n\n $dp = $this->db->pq(\"SELECT count(case when r.status='CRITICAL' then 1 end) as ccount, count(case when r.status!='SUCCESS' then 1 end) as ecount, count(case when r.status!='SUCCESS' then 1 end)/count(r.status)*100 as epc, count(case when r.status='CRITICAL' then 1 end)/count(r.status)*100 as cpc, count(r.status) as total, r.dewarlocation \n FROM robotaction r \n INNER JOIN blsession s on r.blsessionid=s.sessionid \n INNER JOIN proposal p ON p.proposalid = s.proposalid \n INNER JOIN v_run vr ON s.startdate BETWEEN vr.startdate AND vr.enddate\n WHERE r.actiontype LIKE 'LOAD' AND r.dewarlocation != 99 $where\n GROUP BY r.dewarlocation \n ORDER BY r.dewarlocation\", $args);\n \n \n $profile = array(array(\n array('label' => 'Total Loads', 'data' => array()),\n array('label' => '% Errors', 'data' => array(), 'yaxis' => 2),\n array('label' => '% Critical', 'data' => array(), 'yaxis' => 2),\n ),\n array());\n \n foreach ($dp as $e) {\n array_push($profile[0][0]['data'], array($e['DEWARLOCATION'], $e['TOTAL']));\n array_push($profile[0][2]['data'], array($e['DEWARLOCATION'], $e['CPC']));\n array_push($profile[0][1]['data'], array($e['DEWARLOCATION'], $e['EPC']));\n }\n \n $this->_output($profile);\n }", "function getProfile()\n{\n\tglobal $time_start, $db;\n\n\t$start = $time_start;\n\t$end = gettimeofday();\n\t$dbcalls = count($db->queries);\n\t$dbtime = $db->time;\n\n\t$total = (float)($end['sec'] - $start['sec']) + ((float)($end['usec'] - $start['usec'])/1000000);\n\t$script = $total - $dbtime;\n\t$scriptper = $script / $total;\n\n\t$ret = round($total, 3) . 's, ' . round(100 * $scriptper, 1) . '% PHP, ' . round(100* (1 - $scriptper), 1) . '% SQL with ' . $dbcalls . ' ' . makeLink('queries', $_SERVER['QUERY_STRING'] . '&sqlprofile');\n\n\treturn $ret;\n}", "public static function traceBegin() \n\t{\n\t\tacPhpCas::setReporting();\n\t\tphpCAS::traceBegin();\t\t\n\t}", "private function RunBasicQuery() {\n // Prepare the Query\n $this->stmt = $this->db->prepare($this->sql);\n \n // Run the Query in the Database\n $this->stmt->execute();\n \n // Store the Number Of Rows Returned\n $this->num_rows = $this->stmt->rowCount();\n \n // Work with the results (as an array of objects)\n $this->rs = $this->stmt->fetchAll();\n \n // Free the statement\n $this->stmt->closeCursor(); \n }", "public function check_queries() {\r\n\t\tQueryManager::check_queries();\r\n\t}", "public function run()\n {\n Statistic::insert([\n 'visits_count'=>0,\n 'docs_count'=>0,\n 'generating_number_count'=>0,\n 'messages_sent_count'=>0\n ]);\n }", "public function run()\n {\n $this->disableForeignKeys();\n $this->truncate('profile');\n\n $user1 = User::first()->id;\n $user2 = User::find(2)->id;\n $user3 = User::find(3)->id;\n $profile = [\n [\n 'user_id' => $user1,\n 'profession' => '医者',\n 'country' => 'Japan',\n 'self_introduction' => '私クラウドワークスのttt888と申します。',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n 'created_by' => 1,\n 'updated_by' => null,\n ],\n [\n 'user_id' => $user2,\n 'profession' => '医者',\n 'country' => 'Japan',\n 'self_introduction' => '私クラウドワークスのttt888と申します。',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n 'created_by' => 1,\n 'updated_by' => null,\n ],\n [\n 'user_id' => $user3,\n 'profession' => '医者',\n 'country' => 'Japan',\n 'self_introduction' => '私クラウドワークスのttt888と申します。',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n 'created_by' => 1,\n 'updated_by' => null,\n ],\n ];\n\n DB::table('profile')->insert($profile);\n\n $this->enableForeignKeys();\n }", "private function warmUp()\r\n\t{\r\n\t\t$this->loadPage( 1 );\r\n }", "public function preRetrieve();", "public function preExecute()\n {\n // store current URI incase we need to be redirected back to this page\n $request = $this->getRequest();\n if($request->getPathInfo() != '/getEbayResults')\n {\n $this->getUser()->setAttribute('lastPageUri', $request->getPathInfo());\n }\n }", "public static function resetQueryCount() {\n \tself::$queryCount = 0;\n }", "public function Query() {\n \n }", "public function run()\n {\n Setting::set('ingest_query_limit',1000,'integer');\n Setting::set('ingest_timeout',300,'integer');\n Setting::set('ingest_max_consecutive_timeouts',3,'integer');\n Setting::set('ingest_max_total_timeouts',10,'integer');\n Setting::set('ingest_max_queries',-1,'integer');\n Setting::set('ingest_event_print',true,'boolean');\n }", "public function setUp()\n {\n $_SERVER['HTTP_USER_AGENT'] = uniqid();\n $_SERVER['REMOTE_ADDR'] = uniqid();\n\n $this->query = new IndeedQuery();\n }", "public function setup() {\n\t\tparent::setup();\n\t\tincrease_time_limit_to();\n\n\t\t$restart = $this->currentStep == 0;\n\n\t\tif ($restart) {\n\t\t\t$this->pagesToProcess = DB::query('SELECT \"ID\" FROM SiteTree_Live WHERE ShowInSearch=1')->column();\n\t\t}\n\t}", "protected function _before() {\n\t\tparent::_before ();\n\t\t$this->dao = new SDAO ();\n\t\t$this->_startCache ();\n\t\t$this->dao->setModelDatabase ( Fortune::class, 'bench' );\n\t\t$this->_startDatabase ( $this->dao, 'bench' );\n\t}", "public function run()\n {\n DB::table('user_profiles')->insert([\n ['user_id' => '1', 'profiles_id' => '1'],\n ]);\n }", "public function preTest()\n {\n parent::preTest();\n \n // set up an SQL connection\n $this->_sql = Solar::factory(\n 'Solar_Sql',\n $this->_sql_config\n );\n $this->_sql->setProfiling(true);\n \n // set up a model catalog\n $this->_catalog = Solar::factory(\n 'Solar_Sql_Model_Catalog',\n $this->_catalog_config\n );\n \n // register the connection and catalog\n Solar_Registry::set('sql', $this->_sql);\n Solar_Registry::set('model_catalog', $this->_catalog);\n \n // set the class name for relateds\n $len = strlen('Test_');\n $this->_class = substr(get_class($this), $len);\n \n // populate everything\n $this->_populateAll();\n }", "function start() {\n // Warns if binary logging is not active\n //$r = $this->q(\"show variables like 'log_bin'\");\n //if (@mysql_fetch_object($r)->Value != 'ON') {\n // Binary log should be used for better data reliability\n // see http://dev.mysql.com/doc/refman/5.0/fr/commit.html\n // and http://dev.mysql.com/doc/refman/5.0/fr/binary-log.html\n // and http://www.cyberciti.biz/faq/what-is-mysql-binary-log/\n //}\n // Manages nested transactions:\n // only issues a BEGIN statement for the first transaction\n if (self::$started_transactions_count < 1) {\n // Backups current autocommit state\n self::$autocommit_state_backup = $this->autocommit();\n // Sets autocommit state to false\n $this->autocommit(false);\n // Begin transaction\n $this->q('BEGIN');\n // Resets internal variables\n self::$started_transactions_count = 0;\n $this->last_insert_id = null;\n $this->results = array();\n $this->exceptions = array();\n }\n // Manages transactions counter\n self::$started_transactions_count++;\n }", "public function startProfiling($label) {}", "public function flushQueryLog()\n {\n $this->queryLog = array();\n }", "protected function startTable() {}", "public function leggi(){\n\n\t\t\t//if (TYPE_PROFILE==1){\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pg_view\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"pg_view.id = \".$this->ipg_id;\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\t$this->ary_descpg = $query_all->GetNextRecord(true);\n\t\t\t\t}\n\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pg_abilities\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"pg_abilities.idpg = \".$this->ipg_id;\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\twhile($element = $query_all->GetNextRecord(true)){\n\t\t\t\t\t\t$this->ary_abilities[] = $element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pg_talenti\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"pg_talenti.PG = \".$this->ipg_id;\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\twhile($element = $query_all->GetNextRecord(true)){\n\t\t\t\t\t\t$this->ary_talents[] = $element;\n\t\t\t\t\t}\n\t\t\t\t}\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pg_incantesimi\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"pg_incantesimi.PG = \".$this->ipg_id;\n\t\t\t $query_all->sortfields = array(\"Classe\",\"LivRichiesto\",\"incantesimo\");\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\twhile($element = $query_all->GetNextRecord(true)){\n\t\t\t\t\t\t$this->ary_spells[] = $element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pg_oggetti\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"pg_oggetti.PG = \".$this->ipg_id;\n\t\t\t $query_all->sortfields = array(\"Categoria\",\"tipo\");\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\twhile($element = $query_all->GetNextRecord(true)){\n\t\t\t\t\t\t$this->ary_equipment[] = $element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pg_lingua\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"pg_lingua.PG = \".$this->ipg_id;\n\t\t\t $query_all->sortfields = array(\"Lingua\",\"Zona\");\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\twhile($element = $query_all->GetNextRecord(true)){\n\t\t\t\t\t\t$this->ary_lang[] = $element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"tblnotepg\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"tblnotepg.IdPg = \".$this->ipg_id;\n\t\t\t\t\n\t\t\t\t/*\n \t\t\t* if (!($this->ipg_id>0)){\n\t \t\t* \tthrow new Exception (\"No Pg to read from\");\n\t\t \t* }\n\t\t\t\t*/\n\t\t\t\tif ($query_all->Open()){\n\t\t\t\t\twhile($element = $query_all->GetNextRecord(true)){\n\t\t\t\t\t\t$this->ary_notes[] = $element;\n\t\t\t\t\t}\n\t\t\t\t}\n\n /*}else{\n \t\t\t$query_all = new Query();\n\t \t\t$query_all->tables = array(\"pgdb\");\n\t\t \t$query_all->fields = array(\"*\");\n\t\t\t $query_all->filters = \"ID = \".$this->ipg_id;\n\t\t\t\n \t\t\tif (!($this->ipg_id>0)){\n\t \t\t\tthrow new Exception (\"No Pg to read from\");\n\t\t \t}\n if($query_all->Open()){\n \t\t\t $this->ary_descpg = $query_all->GetNextRecord(true);\n }\n }*/\n\t\t}", "function addQuery() {}", "function startCountingAdded()\n {\n\t$this->resetCountAdded();\n\t$this->startCountingAddedLevels();\n\t$this->startCountingAddedVehicles();\n\t$this->doStartCountingAdded();\n }", "public function enableQueryStats($enable = true) {\n\t\t$this->_debug = $enable ? true : false;\n\t\t$this->zendDb()->getProfiler()->setEnabled($this->_debug);\n\t}", "public function afterRun()\n {\n if (Zend_Registry::get('config')->default->db->useTransactions > 0) {\n Zend_Db_Table::getDefaultAdapter()->commit();\n }\n App_Profiler::stop('Bootstrap::run');\n\n /*if ((APPLICATION_ENV != 'production') AND ( ! Zend_Controller_Front::getInstance()->getRequest()->isXmlHttpRequest())) {\n echo '<div style=\"float:left\"><pre>'\n . 'Total execution time: ' . (App_Profiler::fetch('Bootstrap::run') + App_Profiler::fetch('Bootstrap::init'))\n . \"\\r\\n\"\n . 'Memory usage:' . memory_get_usage() . '('.memory_get_usage(TRUE).')'\n . \"\\r\\n\"\n ;\n //Zend_Debug::dump(App_Profiler::getTimersSlice(array('sum', 'count')));\n echo '</pre></div>';\n\n }*/\n\n\n }", "public function start() {\n\t\t$this->writeTitle();\n\t\t\n\t\t$this->showAllTable();\n\t\t\n\t\t$this->addEntityForm();\n\t}", "public static function send()\n\t{\n\t\tif (static::isEnabled(static::DB_BENCHMARK) and count(static::$_queries))\n\t\t{\n\t\t\t$table = array(array('DB', 'Time', 'SQL', 'Bindings'));\n\t\t\tforeach(static::$_queries as $query)\n\t\t\t{\n\t\t\t\t$table[] = array($query['dbname'], (string)round($query['time'], 4), $query['sql'], $query['bindings']);\n\t\t\t}\n\t\t\tDebug\\FirePHP::getInstance()->table('Profiler - DB Benchmark', $table);\n\t\t}\n\n\t\tif (static::isEnabled(static::MARK_MEMORY) and count(static::$_memory_marks))\n\t\t{\n\t\t\t$table = array(array('Name', 'Type', 'Time', 'Memory'));\n\t\t\tforeach(static::$_memory_marks as $mark)\n\t\t\t{\n\t\t\t\t$table[] = array($mark['name'], $mark['type'], (string)round(($mark['time'] - APP_START_TIME), 4), (string)round($mark['memory'] / pow(1024, 2), 5) . 'MB');\n\t\t\t}\n\t\t\tDebug\\FirePHP::getInstance()->table('Profiler - Memory', $table);\n\t\t}\n\n\t\tif (static::isEnabled(static::MARK) and count(static::$_marks))\n\t\t{\n\t\t\t$table = array(array('Name', 'Time'));\n\t\t\tforeach(static::$_marks as $mark)\n\t\t\t{\n\t\t\t\tif($mark['stopped'])\n\t\t\t\t{\n\t\t\t\t\t$table[] = array($mark['name'], (string)round($mark['time'], 4));\n\t\t\t\t}\n\t\t\t}\n\t\t\t// Only displays the time marks if they're finished\n\t\t\tcount($table) > 2 and Debug\\FirePHP::getInstance()->table('Profiler - Time marks', $table);\n\t\t}\n\n\t\tif (static::isEnabled(static::APP_STATS))\n\t\t{\n\t\t\tDebug\\FirePHP::getInstance()->info('Execution time: ~' . round((microtime(true) - APP_START_TIME), 4) . ' - Memory usage: ' . round((memory_get_peak_usage() - APP_START_MEM) / pow(1024, 2), 3) . 'MB');\n\t\t}\n\t}", "public function analysis() : void\n {\n $this->strategy->analysis();\n }", "public static function firstRun(){\n\t\tparent::firstRun();\n\n\t}", "public function before_get_info() {\n\n\t\t$this->found_trash_count = 0;\n\t\t$this->found_akismet_count = 0;\n\n\t}", "function database_log_stats()\n {\n $query_timer_start = getmicrotime();\n \n // DO STUFF\n $time = time();\n $do_insert = FALSE;\n $insert_query = \"\n INSERT INTO se_debug_querylog\n (\n debug_querylog_query,\n debug_querylog_queryhash,\n debug_querylog_querylocation,\n debug_querylog_benchmark,\n debug_querylog_backtrace,\n debug_querylog_result,\n debug_querylog_count,\n debug_querylog_error,\n debug_querylog_time\n )\n VALUES\n \";\n \n foreach( $this->log_data as $log_index=>$log_data )\n {\n // LOG SINGLE QUERY\n if( $do_insert ) $insert_query .= \", \";\n \n $query_location = substr($log_data['backtrace'][0]['file_short'].\" [\".$log_data['backtrace'][0]['line'].\"]\", 0, 254);\n \n $insert_query .= \"(\n '\".$this->database_real_escape_string($log_data['query']).\"',\n '{$log_data['query_hash']}',\n '{$query_location}',\n '{$log_data['time']}',\n '', /* TODO */\n '\".( $log_data['result'] ? '1' : '0' ).\"',\n '{$log_data['count']}',\n '\".$this->database_real_escape_string($log_data['error']).\"',\n '{$time}'\n )\";\n \n $do_insert = TRUE;\n \n // LOG STATS\n $sql = \"\n INSERT INTO se_debug_querystats\n (\n debug_querystats_query_hash,\n debug_querystats_query_location,\n debug_querystats_query,\n debug_querystats_count,\n debug_querystats_count_failed,\n debug_querystats_count_slow,\n debug_querystats_time_total,\n debug_querystats_time_avg\n )\n VALUES\n (\n '{$log_data['query_hash']}',\n '{$query_location}',\n '\".$this->database_real_escape_string($log_data['query']).\"',\n '1',\n '\".( !$log_data['result'] ? '1' : '0' ).\"',\n '\".( $log_data['time']>$this->log_slow_threshold ? '1' : '0' ).\"',\n '{$log_data['time']}',\n '{$log_data['time']}'\n )\n ON DUPLICATE KEY UPDATE\n debug_querystats_count=debug_querystats_count+1,\n debug_querystats_count_failed=debug_querystats_count_failed+\".( !$log_data['result'] ? '1' : '0' ).\",\n debug_querystats_count_slow=debug_querystats_count_slow+\".( $log_data['time']>$this->log_slow_threshold ? '1' : '0' ).\",\n debug_querystats_time_total=debug_querystats_time_total+\".( $log_data['time'] ? $log_data['time'] : '0' ).\",\n debug_querystats_time_avg=(debug_querystats_count*debug_querystats_time_avg+\".( is_numeric($log_data['time']) ? $log_data['time'] : '0' ).\")/(debug_querystats_count+1)\n \";\n \n mysql_query($sql, $this->database_connection) or die(mysql_error($this->database_connection).\" \".$sql);\n }\n \n if( $do_insert ) mysql_query($insert_query, $this->database_connection) or die(mysql_error($this->database_connection).\" \".$insert_query);\n \n $query_timer_end = getmicrotime();\n $query_timer_total = round($query_timer_end-$query_timer_start, 7);\n\t}", "public static function disableQueryLog()\n {\n }", "public static function getQueryLog()\n {\n }", "public function stats()\n {\n }", "public function run()\n {\n DB::table('results')->insert([\n \t'finish_time' => Carbon\\Carbon::now(),\n 'score' => '8',\n 'user_id' => '1',\n 'test_id' => '1',\n ]);\n }", "function query() {}", "public function doQuery() {\n // Selects all of ads' title and writer's name\n $queryString = \"SELECT title, name FROM advertisements INNER JOIN users ON users.id = advertisements.userid ORDER BY advertisements.id DESC\";\n\n $getAds = $this->sql->query($queryString);\n\n // Store the result array in the $data variable, which can be available by getData() later\n while($rows = $getAds->fetch_array(MYSQLI_ASSOC)) {\n array_push($this->data, $rows);\n }\n }", "function start_cache()\r\n\t{\r\n\t\t$this->db->start_cache();\r\n\t}", "function do_personal()\r\n\t{\r\n\r\n\t\t$this->lib->do_profile();\r\n\r\n\t}", "function e107_db_debug() {\n\t\tglobal $eTimingStart;\n\n\t\t$this->aTimeMarks[0]=array(\n\t\t'Index' => 0,\n\t\t'What' => 'Start',\n\t\t'%Time' => 0,\n\t\t'%DB Time' => 0,\n\t\t'%DB Count' => 0,\n\t\t'Time' => ($eTimingStart),\n\t\t'DB Time' => 0,\n\t\t'DB Count' => 0\n\t\t);\n\t\t\n\t\tregister_shutdown_function('e107_debug_shutdown');\n\t}", "function get_num_queries()\n {\n }", "public function flushQueryLog()\n\t{\n\t\t$this->neoeloquent->flushQueryLog();\n\t}", "public function run()\n {\n foreach (Customer::all() as $customer)\n {\n $this->seedIIBBProfile($customer);\n }\n }", "protected function setUp() {\n\t\t$dsn = 'mysql:dbname=test;host=127.0.0.1';\n\t\t$user = 'root';\n\t\t$pass = '';\n\n\t\t$this->pdo = new PDO($dsn,$user,$pass);\n\t\t$this->profiler = new Profiler($this->pdo, 0, 0);\n\t}", "public function recordHit()\n {\n global $configArray;\n\n if ($configArray['Statistics']['enabled']) {\n // Setup Statistics Index Connection\n $solrStats = ConnectionManager::connectToIndex('SolrStats');\n\n // Save Record View\n $solrStats->saveRecordView($this->recordDriver->getUniqueID());\n unset($solrStats);\n }\n }", "public function Query(){\n\t}", "public function Query(){\n\t}", "public function Query(){\n\t}", "protected function initProcessing() {\n foreach ($this->requests as $k => $request) {\n if (isset($request->timeStart)) continue;\n $this->getDefaultOptions()->applyTo($request);\n $request->getOptions()->applyTo($request);\n $request->timeStart = microtime(true);\n }\n $this->active = true;\n }", "protected function begin()\n\t{\n\t\t$this->beginTransaction();\n\t}", "public function benchmarkStart()\n\t{\n\t\t$this->startTime = round(microtime(true) * 1000);\n\t}" ]
[ "0.6405013", "0.6209104", "0.6200284", "0.61350137", "0.6050763", "0.5996968", "0.59515333", "0.5947289", "0.59402645", "0.58585715", "0.58519244", "0.58342224", "0.5830912", "0.5826485", "0.5826485", "0.5812516", "0.5811265", "0.5797647", "0.57883763", "0.5770269", "0.576214", "0.5724886", "0.57214266", "0.57074046", "0.57036257", "0.57024384", "0.5693514", "0.5691144", "0.567627", "0.5646265", "0.557272", "0.55636054", "0.55598044", "0.5550236", "0.5543234", "0.5538212", "0.5537577", "0.5532831", "0.55175537", "0.55148184", "0.5510499", "0.5480254", "0.5477008", "0.5457844", "0.54545814", "0.5444693", "0.5442011", "0.5434687", "0.5417342", "0.5403991", "0.53944385", "0.53902835", "0.5388567", "0.5387514", "0.5383966", "0.53814447", "0.53810084", "0.5379274", "0.53785866", "0.5376175", "0.5375392", "0.5375287", "0.53669655", "0.53476447", "0.5342791", "0.533304", "0.53301704", "0.53238714", "0.5322227", "0.5310772", "0.53031045", "0.5290695", "0.529012", "0.5286033", "0.5279427", "0.5273168", "0.5251539", "0.5244191", "0.5242028", "0.5238923", "0.523883", "0.5238054", "0.5233153", "0.5205583", "0.5203112", "0.5200579", "0.51980746", "0.51973844", "0.51938343", "0.5188388", "0.51842153", "0.5154527", "0.51542413", "0.515238", "0.51478565", "0.51478565", "0.51478565", "0.5146918", "0.5145909", "0.5142718" ]
0.6785249
0
Return the number of executed query
function get_executed_query( ){ return mysql::$nquery; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function count() {\n\t\t$results = $this->execute();\n\t\treturn $results ? count($results) : 0;\n\t}", "public function getNumExecutedQueries()\n {\n return count($this->queries);\n }", "protected function _queryCount() {\n\t\treturn count($this->_queries());\n\t}", "function NumQueries() {\n\t\t\treturn $this->querycount;\n\t\t}", "function get_num_queries()\n {\n }", "public function count()\n\t{\n\t\t// Execute query and return count\n\t\t$result = $this->execute();\n\t\treturn ($result !== false) ? count($result) : 0;\n\t}", "public function queryCount()\n {\n return $this->_QUERYCOUNT;\n }", "public function count()\n\t{\n\t\treturn (int) $this->getStatement()->rowCount();\n\t}", "public function getNumQueries()\n {\n return $this->numQueries;\n }", "abstract public function NumQueries();", "public function count()\n\t{\n\t\treturn $this->query->rowCount();\n\t}", "public function getAllQueriesCount(){\n return Db::getQueriesCount();\n }", "public function count() {\n $prepareStatement = $this->pdo->prepare($this->sql);\n $prepareStatement->execute($this->param);\n\n # close connection\n Connection::disconnect();\n\n return $prepareStatement->rowCount();\n }", "public function count(): int\n {\n return $this->statement->rowCount();\n }", "public function count() {\n $this->_active_query->fields($this->func()->count());\n $query = $this->query( $this->_active_query->getQuery(), $this->_active_query->getParams() );\n return (int)$query->rowCount();\n }", "final public static function count( ) {\n\t\treturn self::$intQueryCount;\n\t}", "public function getQuerycount() : int\n {\n return $this->queryCount;\n }", "public function queryCount() {\n return $this->queryCount;\n }", "public function rowCount()\n {\n return $this->exec()->rowCount();\n }", "function count()\n{\n\tif (!$this->getSql()) return 0;\n\t$rows = $this->getClone()->select('count(*) as n');\n\treturn (int)$rows[0]['n'];\n}", "function count_query($query, array $params = array()) {\n\t$statement = run_query($query, $params);\n\treturn count($statement->fetchAll(PDO::FETCH_OBJ));\n}", "public function getNumRows()\n {\n \treturn $this->previouslyExecuted->num_rows;\n }", "function count()\n {\n $this->object->select($this->object->get_primary_key_column());\n $retval = $this->object->run_query(FALSE, FALSE, FALSE);\n return count($retval);\n }", "public function countQuery();", "public function countquery(){ \n\t\treturn $this->query_total; \n\t}", "public function getAffectedRowsCount(): int\n {\n }", "public function rowCount(): int\n {\n if (!$this->wasExecuted()) {\n $this->exec();\n }\n\n return $this->getAdapter()->getStatement()->rowCount();\n }", "public static function getQueryCount() {\n\t\tif(self::$con == null) return 0;\n\t\treturn self::$con->count();\n\t}", "public function execute(): int;", "public static function execute()\n {\n if(DEBUG_QUERIES)\n {\n $start = microtime();\n }\n $r = self::$stmt->execute();\n if(DEBUG_QUERIES)\n {\n $elapsed = round(microtime() - $start, 4);\n isset(Core::$benchmark['db']['count']) ? Core::$benchmark['db']['count']++ : Core::$benchmark['db']['count'] = 1;\n isset(Core::$benchmark['db']['elapsed']) ? (Core::$benchmark['db']['elapsed']+$elapsed) : Core::$benchmark['db']['elapsed'] = $elapsed;\n }\n if(self::$stmt->errorCode() !== '00000')\n {\n trigger_error(json_encode(self::$stmt->errorInfo()));\n }\n return $r;\n }", "public function executeNone(string $query): int\n {\n $this->realQuery($query);\n\n $n = $this->mysqli->affected_rows;\n\n if ($this->mysqli->more_results()) $this->mysqli->next_result();\n\n return $n;\n }", "public function getQueryCount()\n\t{\n\t\treturn count(self::$queryLog);\n\t}", "public function num_rows()\n\t{\n\t\t$regex = '/^SELECT\\s+(?:ALL\\s+|DISTINCT\\s+)?(?:.*?)\\s+FROM\\s+(.*)$/i';\n\t\t$output = array();\n\n\t\tif (preg_match($regex, $this->last_query, $output) > 0)\n\t\t{\n\t\t\t$stmt = $this->query(\"SELECT COUNT(*) FROM {$output[1]}\");\n\t\t\treturn (int) $stmt->fetchColumn();\n\t\t}\n\n\t\treturn NULL;\n\t}", "public function count(): int\n\t{\n\t\t$limit = $this->queryBuilder->getMaxResults();\n\t\t$offset = $this->queryBuilder->getFirstResult();\n\n\t\t$this->queryBuilder->setMaxResults(null);\n\t\t$this->queryBuilder->setFirstResult(null);\n\n\t\t$sql = $this->queryBuilder->getSQL();\n\n\t\t$this->queryBuilder->setMaxResults($limit);\n\t\t$this->queryBuilder->setFirstResult($offset);\n\n\t\t$stmt = $this->queryBuilder->getConnection()->prepare(\"\n\t\t\tSELECT COUNT(*) \n\t\t\tFROM ($sql) AS counter\n\t\t\");\n\n\n\t\tforeach ($this->queryBuilder->getParameters() as $name => $value) {\n\t\t\t$stmt->bindValue($name, $value, $this->queryBuilder->getParameterType($name));\n\t\t}\n\n\t\t$stmt->execute();\n\t\treturn $stmt->fetchColumn();\n\t}", "public function count(): int\n {\n return $this->makeQuery()->count();\n }", "function dbCount(){\r\n global $db_query;//voor alle code leesbaar\r\n return $db_query->rowCount();\r\n}", "function getCount()\n{\n if( $this->_count == -1 ){\n global $dbh;\n $SQL = $this->getCountSQL();\n $result = $dbh->getOne($SQL);\n dbErrorCheck($result);\n $this->_count = $result;\n return $result;\n }else{\n return $this->_count;\n }\n}", "public function count()\n {\n return $this->queryResult->getSize();\n }", "public function getQueryCount()\n\t{\n\t\treturn $this->query_count;\n\t}", "public function getNumRowsAffected(){\n\t\treturn $this->instance->getNumRowsAffected();\n\t}", "public function rowCount()\n {\n return sasql_num_rows($this->result);\n }", "public function rowCount($query)\r\n {\r\n $query = $this->db->prepare($query);\r\n $query->execute();\r\n $cantidad_registros = $query->rowCount();\r\n return $cantidad_registros;\r\n echo $cantidad_registros;\r\n $this->$db = null; \r\n }", "public static function count(){\n\t\t//Connect to the database\n\t\t$db = static::getDatabaseConnection();\n\t\t$query = \"SELECT count(id) FROM \" . static::$tableName;\n\t\t$statement = $db->prepare($query);\n\t\t$statement->execute();\n\t\t$result = $statement->fetchColumn(); \n\t\treturn $result;\n\t}", "function sql_num_rows($result) {\n\t\treturn pg_num_rows($result);\n\t}", "function executeSql( $sql ) {\r\n\t\t\t$result = $this->_connectAndExec( $sql );\r\n\t\t\treturn ocirowcount( $result );\r\n\t\t}", "public function getRowsCount()\n {\n if ($this->num_rows === 0 && count($this->resultArray()) > 0) {\n $this->num_rows = count($this->resultArray());\n @oci_execute($this->stmt_id, OCI_DEFAULT);\n\n if ($this->curs_id) {\n @oci_execute($this->curs_id, OCI_DEFAULT);\n }\n }\n\n return $this->num_rows;\n }", "public function getQueryCount()\n {\n return $this->query_count;\n }", "function sql_num_rows($res)\n {\n // DELETE, INSERT, UPDATE\n // do not use : SELECT\n return $res->rowCount();\n }", "public function getNumAffectedRows()\n {\n \treturn $this->connections[$this->activeConnection]->affected_rows;\n }", "public function count(): int\n {\n if ($this->clause('action') !== self::ACTION_READ) {\n return 0;\n }\n\n if (!$this->_result) {\n $this->_execute();\n }\n\n if ($this->_result) {\n /** @psalm-suppress PossiblyInvalidMethodCall, PossiblyUndefinedMethod */\n return (int)$this->_result->total();\n }\n\n return 0;\n }", "function dbExec( $sql ) {\n\t\tGLOBAL $db;\n\t\t\n\t\tif ( ($db instanceof PDO) === true ) {\n\t\t\t$count = $db->exec( formatSQL($sql) );\n\t\t\treturn $count;\n\t\t}\n\t}", "public function getResultCount($query)\n\t{\n\t\t\n\t\t$this->database->execQuery($query);\n\n\t\treturn $this->database->getNumResults();\n\t}", "public function count( )\n {\n if ( !$this->db_query_result )\n return 0;\n\n return @ mysql_num_rows( $this->db_query_result );\n }", "public function rowCount () {\n return $this->query->rowCount();\n }", "function get_total_all_records($connect,$query)\n{\n $statement = $connect->prepare($query);\n $statement->execute();\n return $statement->rowCount();\n}", "function numQueryResults($queryToRun){\r\nif(!$queryToRunResult = mysql_query($queryToRun)){echo ('Query failed: ' . mysql_error()) . \"QUERY TEXT: \" . $queryToRun; mysql_query(\"ROLLBACK\"); die();}\r\nreturn mysql_num_rows($queryToRunResult);\r\n}", "function num_rows($query)\n\t{\n\t\treturn pg_num_rows($query);\n\t}", "function Rows()\n\t{\n\t\tif(!$this->Ready(true))\n\t\t\treturn $this->Error('query.exec', __FUNCTION__);\n\t\t\t\n\t\t$q = $this->Run();\n\t\t$r = num_rows($q);\n\t\t\n\t\treturn $r;\n\t}", "public function rowCount()\n {\n return oci_num_rows($this->sth);\n }", "public function dbcount($result) {\n \treturn $result->num_rows;\n }", "public function rowCount() {\n return $this->stmt->rowCount();\n }", "public function count()\n {\n $result = new QueryResult($this);\n return $result->count();\n }", "public function countQuery(\n $sql\n ) \n {\n\t\tif (++self::$queryCount > self::$queryLimit\n &&(empty($GLOBALS['current_user']) || !is_admin($GLOBALS['current_user']))) {\n\t\t require_once('include/resource/ResourceManager.php');\n\t\t $resourceManager = ResourceManager::getInstance();\n\t\t $resourceManager->notifyObservers('ERR_QUERY_LIMIT');\n\t\t}\n }", "function getNumAffectedRows() {\r\n\t\t\treturn($this->privateVars['affectedrows']);\r\n\t\t}", "function NumRows() {\n\t\t\t$result = pg_num_rows($this->result);\n\t\t\treturn $result;\n\t\t}", "function execQuery($query, $params) {\r\n $statement = performQuery($query, $params);\r\n\r\n return $statement === false ? false : $statement->rowCount();\r\n}", "public static function rowCount(){\n $dbCon = self::getPdoCon();\n return $dbCon::rowCount;\n }", "public function computeCount() {\n migrate_instrument_start('MigrateSourceMSSQL count');\n if ($this->connect()) {\n $result = mssql_query($this->countQuery);\n $count = reset(mssql_fetch_object($result));\n }\n else {\n // Do something else?\n $count = FALSE;\n }\n migrate_instrument_stop('MigrateSourceMSSQL count');\n return $count;\n }", "function count()\n {\n $retval = 0;\n $key = $this->object->get_primary_key_column();\n $results = $this->object->run_query(\"SELECT COUNT(`{$key}`) AS `{$key}` FROM `{$this->object->get_table_name()}`\");\n if ($results && isset($results[0]->{$key})) {\n $retval = (int) $results[0]->{$key};\n }\n return $retval;\n }", "function nr($query) \n\t{\n\t\treturn mysqli_num_rows($query);\n\t}", "public function count(){\n $query = \"SELECT COUNT(*) as total_rows FROM \".$this->table_name. \"\";\n\n $stmt = $this->conn->prepare($query);\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n\n return $row['total_rows'];\n }", "public static function getQueryCount() \n {\n return self::$queryCount;\t\n }", "public function count(){\n\t\t\t$query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n\t\t\n\t\t\t$stmt = $this->conn->prepare( $query );\n\t\t\t$stmt->execute();\n\t\t\t$row = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t\n\t\t\treturn $row['total_rows'];\n\t\t}", "public function count(){\n $query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n \n return $row['total_rows'];\n }", "public function num_rows($query_result) {\n//\t\t\twhile ( OCIFetchINTO($query_result,$dumy,OCI_ASSOC) ) {\n//\t\t\t\t$i++;\n//\t\t\t}\n//\t\t\t//return ocifetchstatement($query_result,$dumy);\n//\t\t\treturn $i;\n\t\t}", "function db_exec_returning_rowcount( $statement ) {\n\n $this->pm_clear_dataset();\n $this->pm_store_statement( $statement );\n $this->pm_write_logfile( $statement );\n\n if( $this->query_is_select ) { # Use normal query method, which sets rowcount for selects.\n $this->db_run_query( $statement );\n }\n else { # Execute an insert, update or delete and return rowcount.\n\n $statement = addslashes( $statement );\n\n $statement = \"select dbf_exec_with_rowcount( '$statement' )\";\n\n $this->rowcount = $this->db_select_one_value( $statement ) ;\n }\n return $this->rowcount;\n }", "function record_count() {\n\t\tif ($this->QueryID) {\n\t\t\treturn mysqli_num_rows($this->QueryID);\n\t\t}\n\t}", "public function count(){\r\n\t$query = \"SELECT count(*) FROM \" . $this->table_name;\r\n\r\n\t// prepare query statement\r\n\t$stmt = $this->conn->prepare( $query );\r\n\r\n\t// execute query\r\n\t$stmt->execute();\r\n\r\n\t// get row value\r\n\t$rows = $stmt->fetch(PDO::FETCH_NUM);\r\n\r\n\t// return count\r\n\treturn $rows[0];\r\n}", "public function getCount()\n\t{\n\t\t$res = $this->pdo->queryOneRow('SELECT COUNT(id) AS num FROM xxxinfo');\n\t\treturn ($res === false ? 0 : $res['num']);\n\t}", "public function getNumResultsStored() : int{\n return $this->numResults;\n }", "public function execute($sql) {\n\tif (!is_resource($this->link)) {\n\t $this->connect();\n\t}\n\t$this->lastqueryid = mysql_query($sql, $this->link) or $this->halt(mysql_error(), $sql);\n\t$this->querycount++;\n\treturn $this->lastqueryid;\n }", "public function rowCount() {\n $this->stmt->rowCount();\n }", "public function rowCount()\r\n\t{\r\n\t\treturn $this->rowsAffected;\r\n\t}", "public function countAll(){\n \n $query = \"SELECT id FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n \n $num = $stmt->rowCount();\n \n return $num;\n}", "public function count($sql){\r\n\t\t\tglobal $link;\r\n\t\t\t$result = mysqli_query($link,$sql);\r\n\t\t\t//ham mysqli_num_rows su dung de lay tong so ban ghi da truy van duoc\r\n\t\t\treturn mysqli_num_rows($result);\r\n\t\t}", "public function getResultCount()\n {\n return ! empty($this->result) ? $this->result->getResultCount() : 0;\n }", "public function getNumRowsAffected() {\n\t\treturn $this->rowsAffected;\n\t}", "public function getResultCount()\n {\n return $this->count(self::_RESULT);\n }", "public function getResultCount()\n {\n return $this->count(self::_RESULT);\n }", "public function GetRowCount() : INT\r\n {\r\n return($this->preparedStatement->rowCount());\r\n }", "public function getAffectedRows(): int\n {\n return $this->pdoStatement->rowCount();\n }", "function getExecutionCount()\n {\n return $this->execution_count;\n }", "public function countRows($sql,$params)\n{\n $stmt = $this->dbh->prepare($sql);\n $stmt->execute($params);\n return $stmt->rowCount();\n}", "public function count()\n {\n $query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n \n return $row['total_rows'];\n }", "public function rowCount() {\n return $this->stmt->rowCount();\n }", "public function numRows($query=''){\t\n \t\t\tif(isset($this->stmt))return $this->stmt->rowCount();\n \t\t\telse return 0;\n\t\t}", "public function db_num($sql){\n $result = $this->mysqli->query($sql);\n return $result;\n }", "function NumAffected($result=null)\n\t{\n\t\treturn oci_num_rows($result);\n\t}", "public function countAll(){\n \n $query = \"SELECT id FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n \n $num = $stmt->rowCount();\n \n return $num;\n }", "public function countRows(): int\n {\n $result = $this->_getResult()->numRows(); // Returns an integer on success and an \\PEAR_Error object on failure\n return is_int($result) ? $result : 0;\n }" ]
[ "0.8028909", "0.7762293", "0.76306796", "0.7629886", "0.7628075", "0.7569993", "0.73760694", "0.7299255", "0.7251757", "0.7210035", "0.7178295", "0.7160571", "0.71602625", "0.71374524", "0.71082926", "0.70938355", "0.7056105", "0.70301056", "0.6991569", "0.6990331", "0.6987235", "0.698205", "0.69639486", "0.6962589", "0.6960396", "0.6947302", "0.69406444", "0.6920424", "0.69163615", "0.69150084", "0.691367", "0.69058543", "0.6893099", "0.689148", "0.686482", "0.6832941", "0.68288296", "0.6824151", "0.68198013", "0.6816081", "0.67889", "0.6783405", "0.67774725", "0.67769164", "0.67732537", "0.67705864", "0.67487264", "0.6747723", "0.67404157", "0.673528", "0.67178005", "0.67138", "0.67115957", "0.67082024", "0.6675232", "0.66751903", "0.6671369", "0.66691506", "0.6663766", "0.6660123", "0.66592574", "0.66356695", "0.66265076", "0.6624562", "0.66158074", "0.66110134", "0.66087437", "0.6605725", "0.66029966", "0.66027343", "0.66016406", "0.6600379", "0.6596409", "0.65918195", "0.6590131", "0.65892166", "0.65882206", "0.65859336", "0.6582752", "0.6579716", "0.6566609", "0.6555819", "0.65553105", "0.65519255", "0.65514606", "0.6548629", "0.65425056", "0.6540677", "0.6539702", "0.6537921", "0.6536951", "0.65366185", "0.6536283", "0.65307415", "0.6529361", "0.65215546", "0.650808", "0.6503498", "0.64999956", "0.6487372" ]
0.73341054
7
Call this method at end to get the profile
function showProfile(){ if( $profiles = $this->getArrayRow( "SHOW profiles" ) ){ $html = '<table cellspacing="1" cellpadding="10" bgcolor="#cccccc" style="font:11px Helvetica;"><tr style="font-weight:bold"><td>Query ID</td><td>exec time</td><td width="150">%</td><td>Query</td></tr>'; for( $i=0, $execution_time = 0, $n=count($profiles); $i<$n; $i++ ) $execution_time += $profiles[$i]['Duration']; foreach($profiles as $i => $p ){ $perc = round( ( $p['Duration'] / $execution_time ) * 100, 2 ); $width = ceil( $perc * 2 ); $html .= '<tr bgcolor="#eeeeee"><td>'.$p['Query_ID'].'</td><td>'.$p['Duration'].'</td><td><div style="float:left;width:50px;">'.$perc.'%</div> <div style="display:inline; margin-top:3px;float:left;background:#ff0000;width:'.$width.'px;height:10px;"></td><td>'.$p['Query'].'</td></tr>'; } return $html .= '</table>'; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function GetProfile()\n {\n return $this->profile;\n }", "public function profile() {\n return $this->profile;\n }", "public function getProfile()\n {\n return $this->profile;\n }", "public function getProfile()\n {\n return $this->profile;\n }", "public function getProfile()\n {\n return $this->profile;\n }", "function getProfile(){\n $profile = $this->loadUser();\n return $profile;\n }", "public function getProfile() {\n\t\treturn $this->profile;\n\t}", "abstract protected function getUserProfile();", "public function getUserProfile();", "public function getUserProfile(){\n\n\t\treturn $this->cnuser->getUserProfile($this->request->header('Authorization'));\n\t}", "private function getProfile() {\n if(!$this->profile = $this->getNikePlusFile('http://nikerunning.nike.com/nikeplus/v2/services/app/get_user_data.jsp?_plus=true')) {\n throw new Exception($this->feedErrorMessage);\n }\n }", "public function testDestiny2GetProfile()\n {\n // TODO: implement\n $this->markTestIncomplete('Not implemented');\n }", "public function loadProfileInformation() {\n\t\t\t$procedure = \"get\" . $this->mode_ . \"Information\"; \n\t\t\t$this->profileInformation_ = $this->dbHandler_->call($procedure, \"%d\", array($this->id_));\n\t\t}", "public function getProfile(){\n\t\treturn (new Profile($this->userName));\n\t}", "public function profile(){\n\t\t$this->common_lib->profile($this->user,$this->menu,$this->group->name);\n\t}", "public function public_profile_get() {\n $this->response(App\\Auth::profile(), REST_Controller::HTTP_OK);\n }", "function yz_profile() {\n\treturn Youzer_Profile::get_instance();\n}", "public function getProfile()\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->getProfile() : null;\r\n }", "function getUserProfile()\n\t{\n\t\t// refresh tokens if needed \n\t\t$this->refreshToken();\n\n\t\ttry{\n\t\t\t$authTest = $this->api->api( \"auth.test\" );\n\t\t\t$response = $this->api->get( \"users.info\", array( \"user\" => $authTest->user_id ) );\n\t\t}\n\t\tcatch( SlackException $e ){\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an error: $e\", 6 );\n\t\t}\n\n\t\t// check the last HTTP status code returned\n\t\tif ( $this->api->http_code != 200 ){\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an error. \" . $this->errorMessageByStatus( $this->api->http_code ), 6 );\n\t\t}\n\n\t\tif ( ! is_object( $response ) || ! isset( $response->user->id ) ){\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} api returned an invalid response.\", 6 );\n\t\t}\n\t\t# store the user profile. \n\t\t$this->user->profile->identifier\t\t=\t@$response->user->id;\n\t\t$this->user->profile->profileURL\t\t=\t\"\";\n\t\t$this->user->profile->webSiteURL\t\t=\t\"\";\n\t\t$this->user->profile->photoURL\t\t\t=\t@$response->user->profile->image_original;\n\t\t$this->user->profile->displayName\t\t=\t@$response->user->profile->real_name;\n\t\t$this->user->profile->description\t\t=\t\"\";\n\t\t$this->user->profile->firstName\t\t\t=\t@$response->user->profile->first_name;\n\t\t$this->user->profile->lastName\t\t\t=\t@$response->user->profile->last_name;\n\t\t$this->user->profile->gender\t\t\t=\t\"\";\n\t\t$this->user->profile->language\t\t\t=\t\"\";\n\t\t$this->user->profile->age\t\t\t\t=\t\"\";\n\t\t$this->user->profile->birthDay\t\t\t=\t\"\";\n\t\t$this->user->profile->birthMonth\t\t=\t\"\";\n\t\t$this->user->profile->birthYear\t\t\t=\t\"\";\n\t\t$this->user->profile->email\t\t\t\t=\t@$response->user->profile->email;\n\t\t$this->user->profile->emailVerified\t =\t\"\";\n\t\t$this->user->profile->phone\t\t\t\t=\t\"\";\n\t\t$this->user->profile->address\t\t\t=\t\"\";\n\t\t$this->user->profile->country\t\t\t=\t\"\";\n\t\t$this->user->profile->region\t\t\t=\t\"\";\n\t\t$this->user->profile->city\t\t\t\t=\t\"\";\n\t\t$this->user->profile->zip\t\t\t\t=\t\"\";\n\n\t\treturn $this->user->profile;\n\t}", "public function getInfoProfile(){\n return $this->get_user_by_id($this->getAccountID());\n }", "public function getCurrentProfile(){\n\n try{\n\n if( $this->hasToken() ){\n\n $account = $this->asObj( '/profile' );\n\n return $account->data;\n\n }\n else\n throw new ClientException(\"You need an authorization token, in order to request a profile.\");\n\n }\n catch (ResourceNotFoundException $e){\n //account does not exist\n return NULL;\n }\n\n }", "function profile_info() {\n $parameters = array(\n 'method' => __FUNCTION__\n );\n return $this->get_data($parameters);\n }", "public function getProfile()\n {\n return $this->getFieldValue(self::FIELD_PROFILE);\n }", "public function getProfile() {\n return $this->getGuardUser() ? $this->getGuardUser()->getProfile() : null;\n }", "public function getProfile()\n {\n $res = $this->getEntity()->getProfile();\n\t\tif($res === null)\n\t\t{\n\t\t\t$this->setProfile(SDIS62_Model_DAO_Abstract::getInstance($this::$type_objet)->findByCriteria('Profile', array('primary' => $this::getPrimary())));\n\t\t\treturn $this->getEntity()->getProfile();\n\t\t}\n return $res;\n }", "function getUserProfile()\n\t{\n\t\t// ask kakao api for user infos\n\t\t$data = $this->api->api( \"user/me\" ); \n \n\t\tif ( ! isset( $data->id ) || isset( $data->error ) ){\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an invalid response.\", 6 );\n\t\t}\n\n\t\t$this->user->profile->identifier = @ $data->id; \n\t\t$this->user->profile->displayName = @ $data->properties->nickname;\n\t\t$this->user->profile->photoURL = @ $data->properties->thumbnail_image;\n\n\t\treturn $this->user->profile;\n\t}", "public function profile(){\n // using the auth() helper we are returning the authenticated user info\n return auth('api')->user();\n }", "public function getProfile()\n {\n return $this->request('me');\n }", "public function getProfile()\n {\n ProfileResource::withoutWrapping();\n MinistryResource::withoutWrapping();\n\n if (request()->has('complete') && request()->complete) {\n return new ProfileResource(auth()->user());\n } else {\n return new MinistryResource(auth()->user());\n }\n }", "function getProfileID() {\n\t\treturn $this->_ProfileID;\n\t}", "function getProfileName() {\n\t\treturn $this->_ProfileName;\n\t}", "function getUserProfile()\n\t{\n\t\t$response = $this->api->get( 'user/get.json' );\n\n\t\t// check the last HTTP status code returned\n\t\tif ( $this->api->http_code != 200 )\n\t\t{\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an error: \" . $this->errorMessageByStatus( $this->api->http_code ), 6 );\n\t\t}\n\n\t\tif ( ! is_object( $response ) || ! isset( $response->id_user ) ){\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} api returned an invalid response.\", 6 );\n\t\t}\n\n\t\t# store the user profile.\n\t\t$this->user->profile->identifier = (property_exists($response,'id_user'))?$response->id_user:\"\";\n\t\t$this->user->profile->displayName = (property_exists($response,'username'))?$response->username:\"\";\n\t\t$this->user->profile->profileURL = (property_exists($response,'user_url'))?$response->user_url:\"\";\n\t\t$this->user->profile->photoURL = (property_exists($response,'avatar_url'))?$response->avatar_url:\"\";\n//unknown\t\t$this->user->profile->description = (property_exists($response,'description'))?$response->description:\"\";\n\t\t$this->user->profile->firstName = (property_exists($response,'firstname'))?$response->firstname:\"\";\n\t\t$this->user->profile->lastName = (property_exists($response,'name'))?$response->name:\"\";\n\n\t\tif( property_exists($response,'gender') ) {\n\t\t\tif( $response->gender == 1 ){\n\t\t\t\t$this->user->profile->gender = \"male\";\n\t\t\t}\n\t\t\telseif( $response->gender == 2 ){\n\t\t\t\t$this->user->profile->gender = \"female\";\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$this->user->profile->gender = \"\";\n\t\t\t}\n\t\t}\n\n\t\t$this->user->profile->language = (property_exists($response,'lang'))?$response->lang:\"\";\n\n\t\tif( property_exists( $response,'birth_date' ) && $response->birth_date ) {\n $birthday = date_parse($response->birth_date);\n\t\t\t$this->user->profile->birthDay = $birthday[\"day\"];\n\t\t\t$this->user->profile->birthMonth = $birthday[\"month\"];\n\t\t\t$this->user->profile->birthYear = $birthday[\"year\"];\n\t\t}\n\n\t\t$this->user->profile->email = (property_exists($response,'email'))?$response->email:\"\";\n\t\t$this->user->profile->emailVerified = (property_exists($response,'email'))?$response->email:\"\";\n\n//unknown\t\t$this->user->profile->phone = (property_exists($response,'unknown'))?$response->unknown:\"\";\n\t\t$this->user->profile->address = (property_exists($response,'address1'))?$response->address1:\"\";\n\t\t$this->user->profile->address .= (property_exists($response,'address2'))?$response->address2:\"\";\n\t\t$this->user->profile->country = (property_exists($response,'country'))?$response->country:\"\";\n//unknown\t\t$this->user->profile->region = (property_exists($response,'unknown'))?$response->unknown:\"\";\n\t\t$this->user->profile->city = (property_exists($response,'city'))?$response->city:\"\";\n\t\t$this->user->profile->zip = (property_exists($response,'postalcode'))?$response->postalcode:\"\";\n\n\t\treturn $this->user->profile;\n\t}", "public function setProfileInformation()\n {\n $view = \\Utility\\Singleton::getInstance(\"\\View\\Main\");\n\t\t$username=$view->get('userProfile');\n\t\t$this->getUserInformations($view,$username);\n\t\t$this->setResourcesUploaded($view,$username);\n\t\treturn $view->fetch('profile.tpl');\n\t}", "function getUserProfile()\n\t{\n\t\t$data = $this->api->api( \"v1/market/private/user/account.json\" );\n\t\tif ( ! isset( $data->account ) ){\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an invalid response.\", 6 );\n\t\t}\n\n\t\t$this->user->profile->identifier = @ $data->account->surname;\n\t\t$this->user->profile->displayName = @ $data->account->firstname . ' ' . $data->account->surname;\n\t\t$this->user->profile->photoURL = @ $data->account->image;\n\t\t$this->user->profile->profileURL = @ $data->account->image;\n\n\t\t// request user emails from envato api\n\t\ttry{\n\t\t\t$email = $this->api->api(\"v1/market/private/user/email.json\");\n\t\t\t$this->user->profile->email = @ $email->email;\n\t\t}\n\t\tcatch( Exception $e ){\n\t\t\tthrow new Exception( \"User email request failed! {$this->providerId} returned an error: $e\", 6 );\n\t\t}\n\n\t\treturn $this->user->profile;\n\t}", "public function profileDetails()\n {\n $processReaction = $this->userEngine->prepareProfileDetails();\n\n return __processResponse($processReaction, [], null, true);\n }", "function getProfile(){\n\t\t\t\t$this->__dataDecode();\n\t\t\t\t$data=$this->data;\n\t\t\t\t$playerId = $data['User']['playerId'];\n\t\t\t\t$token = $data['User']['secToken'];\n\t\t\t\t//pr($token);die('ok');\n\t\t\t\t$playerdetails = $this->User->find('first', array('conditions' => array('User.id' => $playerId,'User.secToken' => $token)));\n\t\t\t\t\t\t//pr($playerdetails);die;\t\n\t\t\t\t\t\tif($playerdetails)\n\t\t\t\t\t\t\t{\t\t\t\t\t\n\t\t\t\t\t\t$response['error']\t\t\t= 0;\n\t\t\t\t\t\t$response['response']['firstName'] \t= $playerdetails['User']['firstname'];\n\t\t\t\t\t\t$response['response']['wieght'] \t= $playerdetails['User']['wieght'];\n\t\t\t\t\t\t$response['response']['school'] \t= $playerdetails['User']['school'];\n\t\t\t\t\t\t$response['response']['profilePicture'] = LIVE_SITE.'/img/upload_userImages/'.$playerdetails['User']['image'];\n\t\t\t\t\t\t$this->set('response', $response);\n\t\t\t\t\t\techo json_encode($response);\n\t\t\t\t\t\tdie();\n\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$response['error']\t\t\t= 1;\n\t\t\t\t\t\t\t$response['response']['result'] \t= 'failure';\n\t\t\t\t\t\t\t$response['response']['message']\t= 'UnAuthorized User';\n\t\t\t\t\t\t\t$this->set('response', $response);\n\t\t\t\t\t\t\techo json_encode($response);\n\t\t\t\t\t\t\tdie();\n\n}\n}", "public function fetch(): object\n {\n return $this->get('userProfile/v1/internal/users/' . $this->accountId . '/profiles');\n }", "public function fetch(): object\n {\n return $this->get('userProfile/v1/internal/users/' . $this->accountId . '/profiles');\n }", "public function getProfileUrl()\n\t\t{\n\t\t return $this->profileUrl;\n\t\t}", "public function profileAction() {\n\t\t$this->view->assign('account', $this->accountManagementService->getProfile());\n\t}", "public function getUserProfile()\n {\n $this->sandbox = ($this->config[\"paypal_sandbox\"] == 'Y');\n\n // refresh tokens if needed\n $this->refreshToken();\n\n // store for seamless checkout\n Tygh::$app['session']['paypal_token'] = $this->token( \"access_token\" );\n\n // ask google api for user infos\n $response = $this->api->api( \"https://api\".($this->sandbox?'.sandbox' : '').\".paypal.com/v1/identity/openidconnect/userinfo/?schema=openid\" );\n\n if ( ! isset( $response->user_id ) || isset( $response->message ) ) {\n throw new Exception( \"User profile request failed! {$this->providerId} returned an invalid response.\", 6 );\n }\n\n $this->user->profile->identifier = (property_exists($response,'user_id'))? md5($response->user_id):\"\";\n $this->user->profile->firstName = (property_exists($response,'given_name'))?$response->given_name:\"\";\n $this->user->profile->lastName = (property_exists($response,'family_name'))?$response->family_name:\"\";\n $this->user->profile->displayName = (property_exists($response,'name'))?$response->name:\"\";\n $this->user->profile->photoURL = (property_exists($response,'picture'))?$response->picture:\"\";\n $this->user->profile->gender = (property_exists($response,'gender'))?$response->gender:\"\";\n $this->user->profile->email = (property_exists($response,'email'))?$response->email:\"\";\n $this->user->profile->emailVerified = (property_exists($response,'email_verified'))?$response->email_verified:\"\";\n $this->user->profile->language = (property_exists($response,'locale'))?$response->locale:\"\";\n $this->user->profile->phone = (property_exists($response,'phone_number'))?$response->phone_number:\"\";\n if (property_exists($response,'address')) {\n $address = $response->address;\n $this->user->profile->address = (property_exists($address,'street_address'))?$address->street_address:\"\";\n $this->user->profile->city = (property_exists($address,'locality'))?$address->locality:\"\";\n $this->user->profile->zip = (property_exists($address,'postal_code'))?$address->postal_code:\"\";\n $this->user->profile->country = (property_exists($address,'country'))?$address->country:\"\";\n $this->user->profile->region = (property_exists($address,'region'))?$address->region:\"\";\n }\n\n if ( property_exists($response,'birthdate') ) {\n if (strpos($response->birthdate, '-') === false) {\n if ($response->birthdate !== '0000') {\n $this->user->profile->birthYear = (int) $response->birthdate;\n }\n } else {\n list($birthday_year, $birthday_month, $birthday_day) = explode( '-', $response->birthdate );\n\n $this->user->profile->birthDay = (int) $birthday_day;\n $this->user->profile->birthMonth = (int) $birthday_month;\n if ($birthday_year !== '0000') {\n $this->user->profile->birthYear = (int) $birthday_year;\n }\n }\n }\n\n return $this->user->profile;\n }", "public function getProfile()\n {\n $profile = new \\login\\user\\Profile($this->db);\n if (array_key_exists('profile_id', $this->data)) {\n $profile->loadFromId($this->data['profile_id']);\n }\n return $profile;\n }", "public function getProfileUrl()\n {\n return $this->ProfileUrl;\n }", "function getUserProfile()\r\n\t{\r\n\t\ttry{ \r\n\t\t\t$data = $this->api->getProfile( $this->api->getCurrentUserId() );\r\n\t\t}\r\n\t\tcatch( Exception $e ){\r\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an error while requesting the user profile.\", 6 );\r\n\t\t}\r\n\r\n\t\tif ( ! is_object( $data ) )\r\n\t\t{\r\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an invalide response.\", 6 );\r\n\t\t} \r\n\r\n\t\t$this->user->profile->identifier = $this->api->getCurrentUserId();\r\n\t\t$this->user->profile->displayName \t= @ $data->basicprofile->name;\r\n\t\t$this->user->profile->description \t= @ $data->aboutme;\r\n\t\t$this->user->profile->gender \t= @ $data->basicprofile->gender;\r\n\t\t$this->user->profile->photoURL \t= @ $data->basicprofile->image;\r\n\t\t$this->user->profile->profileURL \t= @ $data->basicprofile->webUri;\r\n\t\t$this->user->profile->age \t\t\t= @ $data->age;\r\n\t\t$this->user->profile->country \t\t= @ $data->country;\r\n\t\t$this->user->profile->region \t\t= @ $data->region;\r\n\t\t$this->user->profile->city \t\t\t= @ $data->city;\r\n\t\t$this->user->profile->zip \t\t\t= @ $data->postalcode;\r\n\r\n\t\treturn $this->user->profile;\r\n\t}", "public function userProfile() {\n\t\t\t$request = $this->api(\"GET\", \"/me\");\n\t\t\t\n\t\t\t$request->execute();\n\t\t\t$response = $request->responseObject();\n\t\t\t$response->id = $response->ID;\n\t\t\treturn $response;\n\t\t}", "public function getAllProfiles()\n {\n return self::$profiles;\n }", "function getProfileConfig() {\n $this->load->model('Usermodel');\n $this->Usermodel->getProfileConfiguration();\n }", "protected function getUserProfile() {\n $profile = (new FacebookRequest(\n $this->fbSession, 'GET', '/me'\n ))->execute()->getGraphObject(GraphUser::className());\n //return\n return $profile;\n }", "public function getProfilePicture()\n {\n return $this->profilePicture;\n }", "public function run()\n {\n /** @var $userProfile UserProfileEntity.php */\n $userProfile = new $this->modelClass();\n\n return $userProfile->getProfileInformation(Yii::$app->user->identity->getId());\n }", "public function getProfile (){\r\n\t\trequire_once 'src/Google_Client.php';\r\n\t\trequire_once 'src/contrib/Google_Oauth2Service.php';\r\n\t\t$gClient = new Google_Client();\r\n\t\t$gClient->setApplicationName('iScout Tour');\r\n\t\t$gClient->setClientId(Configure::read('ExtAuth.Provider.Google.key'));\r\n\t\t$gClient->setClientSecret(Configure::read('ExtAuth.Provider.Google.secret'));\r\n\t\t$gClient->setRedirectUri(Configure::read('globalSiteURL').'/users/gauth');\r\n\t\t//$gClient->setDeveloperKey($google_developer_key);\r\n\r\n\t\t$google_oauthV2 = new Google_Oauth2Service($gClient);\r\n\r\n\t\t//If user wish to log out, we just unset Session variable\r\n\t\tif (isset($_REQUEST['reset'])) \r\n\t\t{\r\n\t\t unset($_SESSION['token']);\r\n\t\t $gClient->revokeToken();\r\n\t\t header('Location: ' . filter_var($google_redirect_url, FILTER_SANITIZE_URL)); //redirect user back to page\r\n\t\t}\r\n\r\n\t\t//If code is empty, redirect user to google authentication page for code.\r\n\t\t//Code is required to aquire Access Token from google\r\n\t\t//Once we have access token, assign token to session variable\r\n\t\t//and we can redirect user back to page and login.\r\n\t\tif (isset($_GET['code'])) \r\n\t\t{ \r\n\t\t\t$gClient->authenticate($_GET['code']);\r\n\t\t\t$_SESSION['token'] = $gClient->getAccessToken();\r\n\t\t\theader('Location: ' . filter_var($google_redirect_url, FILTER_SANITIZE_URL));\r\n\t\t\treturn;\r\n\t\t}\r\n\r\n\r\n\t\tif (isset($_SESSION['token'])) \r\n\t\t{ \r\n\t\t\t$gClient->setAccessToken($_SESSION['token']);\r\n\t\t}\r\n\r\n\r\n\t\tif ($gClient->getAccessToken()) \r\n\t\t{\r\n\t\t\t //For logged in user, get details from google using access token\r\n\t\t\t $user \t\t\t\t= $google_oauthV2->userinfo->get();\r\n\t\t\t $user_id \t\t\t\t= $user['id'];\r\n\t\t\t $user_name \t\t\t= filter_var($user['name'], FILTER_SANITIZE_SPECIAL_CHARS);\r\n\t\t\t $email \t\t\t\t= filter_var($user['email'], FILTER_SANITIZE_EMAIL);\r\n\t\t\t $profile_url \t\t\t= filter_var($user['link'], FILTER_VALIDATE_URL);\r\n\t\t\t $profile_image_url \t= filter_var($user['picture'], FILTER_VALIDATE_URL);\r\n\t\t\t $personMarkup \t\t= \"$email<div><img src='$profile_image_url?sz=50'></div>\";\r\n\t\t\t $_SESSION['token'] \t= $gClient->getAccessToken();\r\n\t\t}\r\n\t\telse \r\n\t\t{\r\n\t\t\t//For Guest user, get google login url\r\n\t\t\t$authUrl = $gClient->createAuthUrl();\r\n\t\t}\r\n\t\t\r\n\t\treturn $authUrl;\r\n\t}", "public function getProfiles()\n {\n return $this->profiles;\n }", "public function controlProfile(){\n\t\t$profilePage = \\Utility\\Singleton::getInstance('\\View\\Main');\n\t\t$data=\"\";\n\t\t\n\t\tswitch($profilePage->get('profileAction'))\n\t\t{\t\n\t\t\tcase 'hasAlreadyVoted':\n\t\t\t\t$data=$this->hasVoted();\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase 'getProfilePage':\n\t\t\t\t$data=$this->setProfileInformation();\n\t\t\t\tbreak;\n\t\t\t\t\n\t\t\tcase 'rateUser':\n\t\t\t\t$data=$this->rateUser();\n\t\t\t\tbreak;\n\n\t\t}\n\t\n\t\treturn $data;\n\t\t\n\t}", "public function getUserProfile() {\n\n\t\t$data = $this->api->get( 'people/~:('. implode(',', $this->config['fields']) .')?format=json' );\n\n\t\t// if the provider identifier is not received, we assume the auth has failed\n\t\tif ( ! isset( $data->id ) ) {\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} api returned an invalid response: \" . Hybrid_Logger::dumpData( $data ), 6 );\n\t\t}\n\n\t\t// # store the user profile.\n\t\t$this->user->profile->identifier = ( property_exists ( $data, 'id' ) ) ? $data->id : '';\n\t\t$this->user->profile->firstName = ( property_exists ( $data, 'firstName' ) ) ? $data->firstName : '';\n\t\t$this->user->profile->lastName = ( property_exists ( $data, 'lastName' ) ) ? $data->lastName : '';\n\t\t$this->user->profile->profileURL = ( property_exists ( $data, 'publicProfileUrl' ) ) ? $data->publicProfileUrl : '';\n\t\t$this->user->profile->email = ( property_exists ( $data, 'emailAddress' ) ) ? $data->emailAddress : '';\n\t\t$this->user->profile->emailVerified = ( property_exists ( $data, 'emailAddress' ) ) ? $data->emailAddress : '';\n\t\t$this->user->profile->photoURL = ( property_exists ( $data, 'pictureUrl' ) ) ? $data->pictureUrl : '';\n\t\t$this->user->profile->description = ( property_exists ( $data, 'summary' ) ) ? $data->summary : '';\n\t\t$this->user->profile->country = ( property_exists ( $data, 'country' ) ) ? strtoupper( $data->country ) : '';\n\t\t$this->user->profile->displayName = trim( $this->user->profile->firstName . ' ' . $this->user->profile->lastName );\n\n\t\tif ( property_exists( $data, 'phoneNumbers' ) && property_exists( $data->phoneNumbers, 'phoneNumber' ) ) {\n\t\t\t$this->user->profile->phone = (string) $data->phoneNumbers->phoneNumber;\n\t\t} else {\n\t\t\t$this->user->profile->phone = null;\n\t\t}\n\n\t\tif ( property_exists( $data, 'dateOfBirth' ) ) {\n\t\t\t$this->user->profile->birthDay = (string) $data->dateOfBirth->day;\n\t\t\t$this->user->profile->birthMonth = (string) $data->dateOfBirth->month;\n\t\t\t$this->user->profile->birthYear = (string) $data->dateOfBirth->year;\n\t\t}\n\n\t\treturn $this->user->profile;\n\t}", "public function getProfilePicture()\n\t{\n\t\treturn $this->info['profile_picture'];\n\t}", "public function getProfileName()\n\t\t{\n\t\t return $this->profileName;\n\t\t}", "public function getProfileImg()\n {\n return $this->profile_img;\n }", "private function getUser()\n {\n $userObj = new Core_Model_Users;\n return $userObj->profile();\n }", "function getUserProfile()\r\n\t{\r\n\t\ttry{ \r\n\t\t\t$data = $this->api->api('/me'); \r\n\t\t}\r\n\t\tcatch( Exception $e ){\r\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} returned an error while requesting the user profile.\", 6 );\r\n\t\t} \r\n\r\n\t\t// if the provider identifier is not recived, we assume the auth has failed\r\n\t\tif ( ! isset( $data[\"id\"] ) )\r\n\t\t{ \r\n\t\t\tthrow new Exception( \"User profile request failed! {$this->providerId} api returned an invalid response.\", 6 );\r\n\t\t}\r\n\r\n\t\t# store the user profile. \r\n\t\t$this->user->profile->identifier = @ $data['id'];\r\n\t\t$this->user->profile->displayName = @ $data['name'];\r\n\t\t$this->user->profile->firstName = @ $data['first_name'];\r\n\t\t$this->user->profile->lastName \t= @ $data['last_name'];\r\n\t\t$this->user->profile->photoURL = \"https://graph.facebook.com/\" . $this->user->profile->identifier . \"/picture\";\r\n\t\t$this->user->profile->profileURL \t= @ $data['link']; \r\n\t\t$this->user->profile->webSiteURL \t= @ $data['website']; \r\n\t\t$this->user->profile->gender \t= @ $data['gender'];\r\n\t\t$this->user->profile->description \t= @ $data['bio'];\r\n\t\t$this->user->profile->email \t= @ $data['email'];\r\n\t\t$this->user->profile->region \t= @ $data['hometown'][\"name\"];\r\n\r\n\t\tif( isset( $data['birthday'] ) ) {\r\n\t\t\tlist($birthday_month, $birthday_day, $birthday_year) = @ explode('/', $data['birthday'] );\r\n\r\n\t\t\t$this->user->profile->birthDay = $birthday_day;\r\n\t\t\t$this->user->profile->birthMonth = $birthday_month;\r\n\t\t\t$this->user->profile->birthYear = $birthday_year;\r\n\t\t}\r\n\r\n\t\treturn $this->user->profile;\r\n \t}", "public function getUserProfile()\n {\n $user = $this->security->getUser();\n return $user;\n }", "public function profile()\n\t{\n\t\t// echo $this->fungsi->user_login()->nik;\n\t\t$query = $this->user_m->get($this->fungsi->user_login()->nik);\n\t\t$data['data'] = $query->row();\n\t\t$this->template->load('template2', 'profile', $data);\n\t}", "protected function getResourceObject()\n {\n return new Profile($this->api);\n }", "public function getProfileImg()\n {\n return $this->profileImg;\n }", "public function profile()\n {\n return Auth::user();\n }", "public function getProfilePicture();", "function do_personal()\r\n\t{\r\n\r\n\t\t$this->lib->do_profile();\r\n\r\n\t}", "public function profile()\n {\n $breadCrumb = $this->userEngine->breadcrumbGenerate('profile');\n\n return $this->loadPublicView('user.profile', $breadCrumb['data']);\n }", "public function get_profile($user_profile_data){\n\t\t$user_name = $_SESSION['username'];\n\t\t// get user id for the logged in user\n\t\t$user_id = Database::user_id_query($user_name);\n\t\t//call static fucntion to get contents of user profile\n\t\t$user_profile_data = UserProfileHelper::get_user_profile($user_id);\n\t\treturn $user_profile_data;\n\t}", "public function getManageProfile() {\n\t\treturn $this->manageProfile;\n\t}", "public function profile()\n {\n $profile = $this->userRepository->getCurrentUserProfile();\n return response()->json(['user' => $profile], 200);\n }", "function getProfile( $profile_id ) {\n\n // update cache if required\n if ( $this->last_profile_id != $profile_id ) {\n $this->last_profile_object = new WPLA_AmazonProfile( $profile_id );\n $this->last_profile_id = $profile_id;\n }\n\n return $this->last_profile_object;\n }", "public function profileAction()\n\t{\n\t\t$store = $this->getBrowserStore();\n\n\t\t$params = $this->getRequest()->getPost();\n\t\tif(!isset($params['uri']) || empty($params['uri'])) {\n\t\t\t$this->_forward('error', 'api', null, array(\n\t\t\t\t'code' => 'RequiredError',\n\t\t\t\t'message' => 'Not all parameters given. This method requires: uri.'\n\t\t\t));\n\t\t\treturn;\n\t\t}\n\n\t\t$uri = $this->escape($params['uri'], 'uri');\n\t\tif(!($id = $this->loadUri($uri))) {\n\t\t\treturn;\n\t\t}\n\n\t\t$profile = $this->getProfile($id, $store);\n\t\tif($profile === false) \n\t\t\treturn;\n\n\t\t$this->outputXml('<result>' . $profile . '</result>');\n\t}", "public function loadGlobalProfile()\n {\n $globalProfile = UserProfile::find()\n ->where('user_id = ' . Yii::$app->user->id)\n ->one();\n Yii::$app->session->set('user.global_profile', $globalProfile);\n }", "public function profile_complete() {\n $data = array();\n if (!$this->user->is_logged_in()) {\n redirect(\"/account/info\");\n }\n\n $this->user->get_user($this->user->getMyId());\n $data['user'] = $this->user;\n\n $this->load->view('account/profile_complete', $data);\n }", "public function profile()\n {\n try {\n $user = auth('api')->user();\n return $this->sendResponse($user, trans('actions.get.success'));\n } catch (Exception $ex) {\n return $this->sendError([], trans('actions.get.failed'));\n }\n }", "public function getProfileData(){\n\t\t// Get stackoverflow id\n\t\t$userId = get_option('stackoverflowUser');\n\n\t\t// Get data from api\n\t\t$url ='https://api.stackexchange.com/2.2/users/' . $userId . '?site=stackoverflow';\n\t\t$ch = curl_init($url);\n\t\tcurl_setopt($ch, CURLOPT_ENCODING, 'gzip');\n\t\t// Set so curl_exec returns the result instead of outputting it.\n\t\tcurl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n\t\t// Get the response and close the channel.\n\t\t$response = json_decode(curl_exec($ch));\n\t\tcurl_close($ch);\n\n\t\t$profileData = array(\n\t\t\t'profileLink' => $response->items[\"0\"]->link,\n\t\t\t'reputation' => $response->items[\"0\"]->reputation,\n\t\t\t'goldBadges' => $response->items[\"0\"]->badge_counts->gold,\n\t\t\t'silverBadges' => $response->items[\"0\"]->badge_counts->silver,\n\t\t\t'bronzeBadges' => $response->items[\"0\"]->badge_counts->bronze,\n\t\t\t'lastFetch' => date('d-m-Y H:m:s')\n\t\t);\n\t\t// Update data\n\t\tupdate_option('StackoverflowData', $profileData);\n\t}", "public function profileInfo()\n {\n\n return response()->json(User::where('id', '=', Auth::user()->id)->get());\n }", "public function GetProfile(){ //GetProfile\n if($this->get_request_method()!= \"POST\"){\n $this->response('',406);\n }\n $user_id = $_POST['user_id'];\n $user_auth_key = $_POST['user_auth_key'];\n $source_user_id = $_POST['source_user_id'];\n $source_id = $_POST['source_id'];\n $ip_device = $_POST['ip_device'];\n $latitude = $_POST['latitude'];\n $longitude = $_POST['longitude'];\n $format = $_POST['format'];\n $db_access = $this->dbConnect();\n $conn = $this->db;\n $res = new getService();\n if(!empty($user_id)){\n $result = $res->CheckAuthentication($user_id, $user_auth_key, $conn);\n if($result != false){\n $res->get_profile($user_id, $source_user_id, $source_id, $ip_device, $latitude, $longitude, $conn);\n $this->dbClose();\n }\n else{\n $this->dbclose();\n $error = array('status' => \"0\", \"msg\" => \"Not Authorised To get detail\");\n ($_REQUEST['format']=='xml')?$this->response($this->xml($error), 200):$this->response($res->json($error), 200);\n }\n }\n else{\n $error = array('status' => \"0\", \"msg\" => \"Fill All Fields\");\n ($_REQUEST['format']=='xml')?$this->response($this->xml($error), 200):$this->response($res->json($error), 200);\n }\n }", "public function profile()\n {\n try {\n $user = $this->guard()->user();\n $success['users'] = $user;\n return Helper::successResponse($success, 'Successfully get profile');\n } catch (\\Exception $e) {\n return Helper::errorResponse($e->getCode(), $e->getMessage());\n }\n }", "public function getProfileAction()\n\t{\n\t\t// Find own profile by authorisation token\n\t\tif ($this->request->hasPost('token')) {\n\t\t\tif ($auth = AuthTokens::findFirstByToken($this->request->getPost('token'))) {\n\t\t\t\treturn $this->reply->asJson([\n\t\t\t\t\t'success' => true,\n\t\t\t\t\t'message' => '',\n\t\t\t\t\t'user' => [\n\t\t\t\t\t\t'firstname' => $auth->users->userFirstname,\n\t\t\t\t\t\t'lastname' => $auth->users->userLastname,\n\t\t\t\t\t\t'prefix' => $auth->users->userPrefix,\n\t\t\t\t\t\t'phone' => $auth->users->userPhone,\n\t\t\t\t\t\t'email' => $auth->users->userEmail,\n\t\t\t\t\t\t'points' => $auth->users->userPoints,\n\t\t\t\t\t]\n\t\t\t\t]);\n\t\t\t} else {\n\t\t\t\treturn $this->reply->withFail(Response::ERROR_INVALID_AUTH);\n\t\t\t}\n\n\t\t// Find another profile by user id\n\t\t} else if (\n\t\t\t$this->request->hasPost('id') &&\n\t\t\tis_numeric($this->request->getPost('id'))\n\t\t) {\n\t\t\tif ($user = Users::findFirst($this->request->getPost('id'))) {\n\t\t\t\treturn $this->reply->asJson([\n\t\t\t\t\t'success' => true,\n\t\t\t\t\t'message' => '',\n\t\t\t\t\t'user' => [\n\t\t\t\t\t\t'firstname' => $user->userFirstname,\n\t\t\t\t\t\t'lastname' => $user->userLastname,\n\t\t\t\t\t\t'prefix' => $user->userPrefix,\n\t\t\t\t\t\t'points' => $user->userPoints,\n\t\t\t\t\t]\n\t\t\t\t]);\n\t\t\t} else {\n\t\t\t\treturn $this->reply->asJson([\n\t\t\t\t\t'success' => false,\n\t\t\t\t\t'message' => 'Invalid user id.'\n\t\t\t\t]);\n\t\t\t}\n\n\t\t// Invalid parameters\n\t\t} else {\n\t\t\treturn $this->reply->withFail(Response::ERROR_INVALID_PARAMS);\n\t\t}\n\t}", "function requestProfile() {\n $username = $_GET['username'];\n\n $response = retrieveProfile($username);\n\n if ($response['status'] == 'SUCCESS') {\n echo json_encode($response['response']);\n } else {\n errorHandler($response['status'], $response['code']);\n }\n }", "public function profile()\n { \n $user = Auth::user();\n $profile = $user->student;\n return $user;\n \n }", "public static function current():Profile|null\n {\n try {\n return Auth::user()->activeProfile ?? null;\n } catch (\\Throwable $e) {\n report($e);\n }\n return null;\n }", "public function profile()\n {\n $user = User::get($_SESSION['id']);\n $page = Param::get('page_next', 'profile');\n $nextRank = $user->getRemainingCommentCount();\n $comment_count = $user->getCommentCount();\n\n switch ($page) {\n case 'profile':\n break;\n case 'profile_update':\n $new_username = Param::get('username');\n $new_password = Param::get('password');\n\n try {\n $user->updateProfile($new_username, $new_password);\n } catch (ValidationException $e) {\n $page = 'profile';\n }\n break;\n default:\n throw new PageNotFoundException('{$page} not found');\n }\n\n $this->set(get_defined_vars());\n $this->render($page);\n }", "public function show()\n\t{\n\t\t// get user model\n\t\tif (Auth::check()) {\n\t\t\t$user = Auth::user();\n\t\t\t$profile = Profile::find($user->id);\n\t\t\treturn $profile;\n\t\t} else {\n\t\t\treturn 'fail';\n\t\t}\n\t}", "public function profileLogout()\n {\n unset($this->getApp()->getSession()->BRACP_PROFILE_ID);\n self::$loggedUser = null;\n }", "public function getWebProfileList()\n {\n $url = $this->host . '/v1/payment-experience/web-profiles';\n $authorization = 'Authorization: Bearer ' . $this->clientCredentials->access_token;\n $curl = curl_init();\n curl_setopt($curl, CURLOPT_HTTPHEADER, array('Content-Type: application/json;charset=UTF-8', $authorization));\n curl_setopt($curl, CURLOPT_URL, $url);\n curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($curl, CURLOPT_POST, 1);\n\n $this->cUrl = $curl;\n return $this->sendRequest();\n //===\n }", "function GetProfileDetails(){\n\t\t$this->load->model('User_model');\n\t\t\n\t\t$this->user_id = $this->User_model->Get_User_ID_By_Token($this->user_auth_id); //Just Like a call to require ID of USER\n\t\t//Did this because the user_id might be set but above function just represents auth ID and sends to model to deliver real ID\n\t\t\n\t\t$this->db->select('firstname,lastname,auth_token,program_name,level,grad_year');\n\t\t$this->db->from('users');\n\t\t$this->db->join('programs', 'programs.program_id = users.program_id');\n\t\t$this->db->join('students', 'students.user_id = users.user_id');\n\t\t$this->db->where('users.user_id', $this->user_id);\n\t\t$query = $this->db->get();\n\t\t\n\t\t$results = $query->result_array();\n\t\t\n\t\treturn $results[0];\n\t}", "public function getProfilePictureFile()\n {\n return $this->profile_picture_file;\n }", "public function getProfile()\n {\n return $this->hasOne(Profile::className(), ['id' => 'profile_id']);\n }", "function getProfile($id){\n return $this->activity_model->fetchProfile($id)->row();;\n }", "public function profile()\n {\n return response()->json(['userPenaksir' => Auth::guard('api-penaksir')->user()], 200);\n }", "public function profile(): string\n {\n if ($this->profile) {\n return $this->profile;\n }\n\n return $this->app['opx.profile'] ?? 'default';\n }", "public function getProfileName() {\n\t\treturn ($this->profileName);\n\t}", "public function getProfileImage()\n {\n if ($this instanceof \\humhub\\modules\\space\\models\\Space) {\n return new \\humhub\\libs\\ProfileImage($this->guid, 'default_space');\n }\n return new \\humhub\\libs\\ProfileImage($this->guid);\n }", "private function getHtmlProfile()\n {\n $ch = curl_init($this->profileUrl);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, false);\n\n $html = curl_exec($ch);\n\n if (curl_error($ch)) {\n throw new Exception(curl_error($ch), self::ERROR_PROFILE_READ);\n } elseif (curl_getinfo($ch, CURLINFO_HTTP_CODE) == 301) {\n $url = curl_getinfo($ch, CURLINFO_REDIRECT_URL);\n $this->setProfileUrl($url);\n return $this->getHtmlProfile();\n }\n\n curl_close($ch);\n return $html;\n }", "public function afterEndProfile(Item $profile)\n {\n echo $profile->getTotalElapsedSeconds();\n }", "public function getProfile()\n {\n return $this->hasOne(Profile::className(), ['user_id' => 'id']);\n }", "public function getCurrentUserProfileInfo()\n {\n $user = Auth::user();\n $userDetails = DB::table('userProfileData')->where('user_id', $user->id)->first();\n return response()->json(['currentUserDetails' => $userDetails], $this-> successStatus);\n }", "public function index()\n {\n $user_id = Auth::id();\n $user_info = Profile::where('user_id', $user_id)->get();\n\n return $user_info;\n }", "public function getAvatar()\n\t{\n\t\treturn $this->instance->profile;\n\t}" ]
[ "0.7399241", "0.736816", "0.73618877", "0.73618877", "0.73618877", "0.7343203", "0.733042", "0.7321619", "0.7255204", "0.72535855", "0.7191027", "0.7177698", "0.7089464", "0.702097", "0.6982469", "0.6904922", "0.6901358", "0.68732375", "0.6852803", "0.684257", "0.6837896", "0.68104744", "0.67958987", "0.67857575", "0.67292", "0.666769", "0.6661284", "0.66518295", "0.66220826", "0.66026217", "0.6587131", "0.65733296", "0.6553735", "0.6551937", "0.6550014", "0.6466433", "0.6463229", "0.6463229", "0.64526206", "0.6442176", "0.64228535", "0.6421167", "0.64158756", "0.641516", "0.63996136", "0.6380643", "0.63780886", "0.63536406", "0.6337485", "0.6310169", "0.6300994", "0.629707", "0.62887484", "0.6283029", "0.6275547", "0.6273648", "0.62622446", "0.6260875", "0.62593764", "0.6240706", "0.62060004", "0.6200294", "0.6183883", "0.61678505", "0.6157627", "0.6156605", "0.61547637", "0.6153505", "0.6152356", "0.6149055", "0.6142995", "0.6103627", "0.6093877", "0.609337", "0.60846853", "0.60832196", "0.6081205", "0.60789984", "0.6077209", "0.60724515", "0.60687804", "0.60563886", "0.60563356", "0.60540485", "0.6052022", "0.6030251", "0.60294336", "0.6022683", "0.6015719", "0.6015389", "0.6013489", "0.6009804", "0.60096467", "0.60038656", "0.5993829", "0.5984316", "0.5980209", "0.5979364", "0.5969466", "0.59548795", "0.5938826" ]
0.0
-1
Overloaded method onSave() Executed whenever the user clicks at the save button
public function onSave() { // first, use the default onSave() $object = parent::onSave(); // if the object has been saved // if ($object instanceof Voo) // { // // $source_file = 'tmp/'.$object->photo_path; // // $target_file = 'images/' . $object->photo_path; // // $finfo = new finfo(FILEINFO_MIME_TYPE); // // // if the user uploaded a source file // if (file_exists($source_file) AND $finfo->file($source_file) == 'image/png') // { // // move to the target directory // // rename($source_file, $target_file); // // try // { // TTransaction::open($this->database); // // update the photo_path // // $object->photo_path = 'images/'.$object->photo_path; // $object->store(); // TTransaction::close(); // } // catch (Exception $e) // in case of exception // { // new TMessage('error', '<b>Error</b> ' . $e->getMessage()); // TTransaction::rollback(); // } // } // } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function onAfterSave();", "public function postSave() {}", "protected function _postSave()\r\n\t{\r\n\t}", "protected function hook_afterSave(){}", "public function afterSave()\n {\n\n }", "public function afterSave(){\n\t}", "public function onSave()\n {\n try\n {\n // open a transaction with database 'samples'\n TTransaction::open('samples');\n \n // get the form data into an active record Entry\n $object = $this->form->getData('AgendaEntry');\n \n $this->form->validate(); // form validation\n $object->store(); // stores the object\n $this->form->setData($object); // keep form data\n \n TTransaction::close(); // close the transaction\n $posAction = new TAction(array('AgendaView', 'reload'));\n // shows the success message\n new TMessage('info', TAdiantiCoreTranslator::translate('Record saved'), $posAction);\n }\n catch (Exception $e) // in case of exception\n {\n // shows the exception error message\n new TMessage('error', $e->getMessage());\n \n $this->form->setData( $this->form->getData() ); // keep form data\n \n // undo all pending operations\n TTransaction::rollback();\n }\n }", "public function save()\r\n {\r\n \r\n }", "public function save()\r\n {\r\n //\r\n }", "public function save()\n {\n }", "public final function save() {\n }", "protected function afterSave() {\n\n }", "function save()\n {\n parent::save();\n }", "function save()\n {\n parent::save();\n }", "function save()\n {\n parent::save();\n }", "public final function save()\n {\n }", "public function save() {}", "public function save() {}", "public function save() {\n\t\t\t\n\t\t}", "public function save() {}", "public function save() {\n }", "public function save()\n {\n }", "public function save()\n {\n }", "protected function saving() {\n // This will get reimplemented by children when necessary\n }", "public function save() {\n }", "public function save() {\n }", "public function save()\n\t{\n\n\t}", "public function save()\n {\n //\n }", "public function save()\n {\n // For V2.0\n }", "public function onBeforeSave();", "public function postSaveCallback()\n {\n $this->performPostSaveCallback();\n }", "public function postSaveCallback()\n {\n $this->performPostSaveCallback();\n }", "protected function onSaving()\n {\n return true;\n }", "public function saveAction() {\n parent::saveAction();\n }", "public\tfunction\tsave()\n\t\t{\n\t\t}", "function onsave(){\n\t\treturn true;\n\t}", "function save()\n {\n }", "function save()\n {\n }", "public function save(){\n }", "public function Save()\n {\n }", "function after_save() {}", "function save() {\n\n\t\t// calls generic ORM save (insert or update)\n\t\tparent::save();\n\n\t}", "public function preSave() {}", "public function preSave() { }", "public function save() {\n\n }", "public function afterSaveCommit(): void\n {\n }", "protected function saveUpdate()\n {\n }", "public function post_save(){\n\n }", "function onSave()\n {\n $object = parent::onSave();\n }", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "protected function onSaved()\n {\n return true;\n }", "public abstract function save();", "protected function onBeforeSave()\n {\n }", "function _save_post_hook()\n {\n }", "public function save():void;", "public function save()\n {\n return;\n }", "abstract public function save();", "abstract public function save();", "abstract public function save();", "abstract public function save();", "abstract public function save();", "protected function beforeSaveInDB(){}", "public function afterSave()\n\t{\n\t\t//annoying on every edit, move to a checkbox on form and handle in controller\n\t}", "protected function hook_beforeSave(){}", "function save();", "function save();", "public function save()\n {\n if($this->changed) {\n Item::saveNewValues($this->id, $this->name, $this->status);\n } else {\n echo 'Nothing changed!';\n }\n }", "public function onSaveEntry(SproutForms_OnSaveEntryEvent $event)\n\t{\n\t\t$this->raiseEvent('onSaveEntry', $event);\n\t}", "protected function afterSave()\n {\n return;\n }", "public function saveToDB()\n {\n }", "public function saveData()\r\n {\r\n \r\n }", "function onSave( $editor ) {\n\t\treturn;\n\t}", "public function saved($model)\n {\n }", "function preSave()\n {\n }", "public function toggleSave() : void\n {\n }", "function Save();", "public function onBeforeSave($event);", "public function saved($model)\n\t{\n\t}", "function preSave()\n\t{\n\n\t}", "function save() {\n //save the added fields\n }", "protected function postSave() {\n\t\treturn true;\n\t}", "protected function save()\n\t{\n\t\t$this->saveItems();\n\t\t//$this->saveAssignments();\n\t\t//$this->saveRules();\n\t}", "public function saving($model)\n {\n }" ]
[ "0.8339769", "0.80207014", "0.796396", "0.79182696", "0.78838193", "0.78722596", "0.7846453", "0.7794606", "0.77816784", "0.77785623", "0.77716124", "0.7747797", "0.77179545", "0.77179545", "0.77179545", "0.7717541", "0.7710978", "0.7710978", "0.7710469", "0.7708085", "0.76970875", "0.7692278", "0.7692278", "0.76794964", "0.7668124", "0.7668124", "0.7649585", "0.76306635", "0.76114184", "0.7590312", "0.758056", "0.758056", "0.7569507", "0.7568997", "0.75558937", "0.7539593", "0.75331885", "0.75331885", "0.7484529", "0.74837685", "0.7481021", "0.7467785", "0.74612004", "0.7454541", "0.7447909", "0.74363226", "0.74194807", "0.7403011", "0.73993564", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.7393211", "0.739308", "0.7331968", "0.7320704", "0.730718", "0.7297467", "0.7207629", "0.71999794", "0.71999794", "0.71999794", "0.71999794", "0.71999794", "0.71929604", "0.7174972", "0.71534204", "0.7108945", "0.7108945", "0.7094133", "0.7071855", "0.7068614", "0.70579976", "0.70454836", "0.7033081", "0.70145947", "0.7011141", "0.7001358", "0.6984424", "0.6984358", "0.69767845", "0.6971579", "0.6962604", "0.69511884", "0.69490576", "0.69440234" ]
0.74525774
44
API Returns the usernames of the users with this role
public function getUserNames() { $result = $this->getUsers()->all(); if( is_null( $result ) ) return []; return array_map( function($o) {return $o->namedId;}, $result ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getUserList() {\n $where = [];\n $this->usersModel->setTableName(\"cvd_users\");\n\n $role_name = $this->request->input(\"role_name\");\n if ($role_name) {\n $where[] = [\"roles.role_name\", \"=\", $role_name];\n }\n\n $user_id = $this->request->input(\"user_id\");\n if ($user_id) {\n $where[] = [\"users.user_id\", \"=\", $user_id];\n }\n $orderBy = \"users.user_id\";\n $this->usersModel->setWhere($where);\n $users = $this->usersModel->getUsers($orderBy);\n\n return $users;\n }", "function getUserNameList()\r\n\t{\r\n\t\treturn $this->UserNameList;\r\n\t}", "function get_users()\n\t{\n\n\t\trequire_once('modules/Users/User.php');\n\t\t\n\t\t$query = \"SELECT user_id as id FROM roles_users WHERE role_id='$this->id' AND deleted=0\";\n\t\t\n\t\treturn $this->build_related_list($query, new User());\n\t}", "public function getUserList() {\n return $this->users;\n }", "function listUsers() {\n return $this->users;\n }", "public function getRoleUsers()\n {\n return $this->getResource()->getRoleUsers($this);\n }", "public function getUsers()\n {\n return Security::getUserList();\n }", "public function getUserList()\n {\n return $this->userDao->getUserList();\n }", "public function getUserList()\n {\n $responseMap = $this->_postCommand(static::$COMMAND_GET_USER_LIST);\n \n // From the response, filter out only the users that matched this environment Prefix\n $userIdList = [];\n foreach ($responseMap['ids'] as $userId) {\n $unprefixedUserId = PrefixHelper::unprefix($userId);\n \n if ($unprefixedUserId !== false) {\n $userIdList[] = $unprefixedUserId;\n }\n }\n \n return $userIdList;\n }", "private function getUserList()\n {\n $users = User::getUsers();\n $users = ArrayHelper::map($users, 'id', 'username');\n \n return $users;\n }", "public function getUsers();", "public function getUsers();", "public function getUsers();", "public function getUsersListAttribute()\n {\n return User::orderBy('name')->get();\n }", "public function index()\n {\n $users = User::get()->load('roles');\n return $users;\n }", "public function getUsers()\n {\n return $this->users->getValues();\n }", "public static function allUser() {\n $listado = DB::table('users')->join('role_user', 'role_user.user_id', '=', 'users.id')\n ->join('roles', 'roles.id', '=', 'role_user.role_id')\n ->select('users.*', 'roles.description')\n ->get();\n\n return $listado;\n }", "public function getRoleUsers($role) {\n $ids = \\Drupal::entityQuery('user')\n ->condition('status', 1)\n ->condition('roles', $role)\n ->execute();\n $users = User::loadMultiple($ids);\n $results = [];\n //var_dump($users);die();\n foreach($users as $user) {\n $uid = $user->get('uid')->value;\n $name = $user->get('field_name')->value;\n $surname = $user->get('field_surname')->value;\n $results[] = [\n 'value' => $uid,\n 'text' => $name . ' ' . $surname,\n ];\n }\n return new JsonResponse($results);\n }", "public function getUsers() : array\n {\n return $this->_getRelationships('users_roles');\n }", "public function getUsersList()\n {\n }", "protected function get_users() {\n\t\t\t$users = wp_cache_get( 'mycred_users' );\n\n\t\t\tif ( false === $users ) {\n\t\t\t\t$users = array();\n\t\t\t\t$blog_users = get_users( array( 'orderby' => 'display_name' ) );\n\t\t\t\tforeach ( $blog_users as $user ) {\n\t\t\t\t\tif ( false === $this->core->exclude_user( $user->ID ) )\n\t\t\t\t\t\t$users[ $user->ID ] = $user->display_name;\n\t\t\t\t}\n\t\t\t\twp_cache_set( 'mycred_users', $users );\n\t\t\t}\n\n\t\t\treturn apply_filters( 'mycred_log_get_users', $users );\n\t\t}", "public function getUserslistToInvite()\n\t{\n\t\t//get current login user session\n\t\t$results = array();\n\t\t$user = $this->Session->read('UserData.userName');\n\t\t$userCourse = $this->Session->read('UserData.usersCourses');\n\t\t$user_course_section = $userCourse[0];\n\t\t\n\t\t//get Course and section name\n\t\t$course_info = $this->getCourseNameOfUser($user_course_section);\n\t\t$course_name = $course_info->course_name;\n\t\t$course_section = $course_info->section_name;\n\t\t//get allsection setting sections for same course\n\t\t$sections_list = $this->__allSections();\n\t\t$options = array('course'=>$course_name,'section'=>$sections_list,'userName !='=>$user);\n\t\t$results = $this->PleUser->find('all',array('conditions'=>$options,'fields'=>array('userName','name'),'order' => array('PleUser.name ASC')));\n\t\tif ($results) {\n\t\t\treturn $results;\n\t\t}\n\t\treturn $results;\n\t}", "public function getRolesNames ();", "public function get_user_list() {\n\n $sql = \" SELECT userId, concat(firstName, ' ', surname) AS `name`\n FROM time_user\"; \n return $this->db->query( $sql );\n }", "private function listUsers()\n {\n $users = get_users();\n $user_ids = array();\n\n foreach ($users as $u) {\n $user_ids[] = $u['id'];\n }\n\n if (count($this->ids) != 0) {\n return array_intersect($this->ids, $user_ids);\n } else {\n return $user_ids;\n }\n }", "function list_users(){\r\n\t\t$query = $this->db->query(\"SELECT userid, concat(fname, ' ', lname, ' (', username, ')') as name FROM nf_users\");\r\n\t\t$return = array();\r\n\t\tforeach($query->result() as $row){\r\n\t\t\t$return[$row->userid] = $row->name;\r\n\t\t}\r\n\t\treturn $return;\r\n\t}", "public function username()\n {\n return ['email', 'username'];\n }", "function get_all_usernames(){\n\t\t\t\n\t\t\t$this->db->select('admin_username');\n\t\t\t$this->db->from($this->table);\n\t\t\t$q = $this->db->get();\n\t\t\t\n\t\t\treturn $q->result_array();\n\n\t\t}", "public function getUsers() {\n return $this->userHandler->getUsers();\n }", "public function listUsers() {\n\t\t$users = Common::loadJSON(\"users\");\n\t\t$temp = array();\n\n\t\t//Remove the user in session.\n\t\tforeach ($users as $username => $data) {\n\t\t\tif ($username == $this->activeUser) continue;\n\t\t\t$temp[] = $username;\n\t\t}\n\n\t\treturn $temp;\n\t}", "function listOfUsers(){\n\t\n\t\t$users = [];\n\t\tforeach ($this->members as $obj){\n\t\t\t$user = array('name'=> $obj->getUserFullName(),'id'=>$obj->getUserID());\n\t\t\tarray_push($users, $user);\n\t\t}\n\t\treturn $users;\n\t}", "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 static function getAllUsersNames()\n {\n $sql = \"SELECT idUser, CONCAT(FirstName,' ',LastName) AS Name FROM users ORDER BY LastName, FirstName\";\n $req = DbConnection::getInstance()->prepare($sql);\n //$req->setFetchMode(PDO::FETCH_OBJ);\n $req->execute();\n return $req->fetchAll(PDO::FETCH_KEY_PAIR);\n }", "public function get_users_list() {\n\n\t\t\t$users = get_users();\n\n\t\t\t$result = array( '0' => esc_html__( 'Select a user', 'cherry' ) );\n\n\t\t\tif ( empty( $users ) ) {\n\t\t\t\treturn array();\n\t\t\t}\n\n\t\t\tforeach ( $users as $user ) {\n\t\t\t\t$result[ $user->data->ID ] = $user->data->user_nicename;\n\t\t\t}\n\n\t\t\treturn $result;\n\t\t}", "public function getUserList(): array {\n\t\t$sql = 'SELECT u.id, u.login, u.mail, r.name role FROM users u\n\t\t\t\tINNER JOIN roles r ON u.role = r.id\n\t\t\t\tWHERE u.login != :mylogin';\n\n\t\treturn $this->queryRows($sql, ['mylogin' => $_SESSION['user']['login']]);\n\t}", "public function getUsers() {\n return $this->getRelation(\"users\");\n }", "public static function getPersonsUsers(){\n return self::getPersonsByRole();\n }", "public function getAllUsers()\n {\n return \"users from mongo\";\n }", "private function getUsers()\n {\n $url = $this->base_uri.'user/assignable/multiProjectSearch?projectKeys='.$this->project;\n $users = $this->request($url);\n if (!$this->infos['errorBoolean']) {\n return json_decode($users);\n }\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 getUsers() {\n\t\t$dbObject = getDatabase();\n\t\t\n\t\t// now the sql again\n\t\t$sql = \"select users_username from users\";\n\t\t\n\t\t// run the query\n\t\t$result = $dbObject->query($sql);\n\t\t\n\t\t// iterate over the results - we expect a simple array containing\n\t\t// a list of usernames\n\t\t$i = 0;\n\t\t$users = array();\n\t\tforeach($result as $row) {\n\t\t\t$users[$i] = $row[\"username\"];\n\t\t\t$i++;\n\t\t}\n\t\t\n\t\t// now return the list\n\t\treturn $users;\n\t}", "public function index()\n {\n return $this->userRepo->getUsers();\n }", "public function getNames()\n {\n return (array) ldap_get_names($this->username);\n }", "public function getAllUser(){\n return $this->users;\n }", "public function getUsers()\n {\n return $this->getRelation('users');\n }", "public function getOrgUsers(){\n $return_array = array();\n $current_campaign=Yii::app()->session->get('current_campaign');\n $campaign = Definition::model()->findByPk($current_campaign);\n if($campaign){\n $users = Users::model()->findAllByAttributes(array('fk_org_id'=>$campaign->fk_org_id));\n foreach($users as $user){\n $return_array[$user->id] = $user->username;\n }\n }\n \n return $return_array;\n }", "function getUsers() {\n $users = $this->users;\n if (is_string($users)) {\n $users = explode(',', $users);\n }\n return $users;\n }", "public function getLTIUsers();", "public function getUsers()\n {\n return $this->users;\n }", "public function getAllUsers(): array\n {\n return $this->users;\n }", "public function getUsers()\n {\n $sql = \"SELECT * FROM users\";\n return $this->get($sql, array());\n }", "public function getUsers() {\n return $this->users;\n }", "public function getUsers() {\n\n $users = $this->users_model->getallusers();\n exit;\n }", "public function findAllUsers()\n {\n return array_map(\n function (UserResponse $response) {\n return $response->getUser();\n },\n $this->apiClient->findAllUsers()\n );\n }", "public function users_list() {\n return response()->json(User::latest()->get());\n }", "public function getUserListAttribute()\n {\n return $this->users->pluck('id')->all();\n }", "public function getList()\r\n {\r\n $result = $this->query(\r\n \"SHOW USERS\",\r\n $this->getValueBuilder('Aviogram\\InfluxDB\\Entity\\Admin\\User')\r\n ->addField('user', 'getName', 'setName')\r\n ->addField('admin', 'isAdmin', 'setAdmin')\r\n );\r\n\r\n $return = new Collection\\Admin\\User();\r\n\r\n foreach ($result->getSeries() as $serie) {\r\n foreach($serie->getValues() as $value) {\r\n $return->append($value);\r\n }\r\n }\r\n\r\n return $return;\r\n }", "public function getAllUsers(){\n\t\treturn $this->user;\n\t}", "function getAllUsersWithRoles() {\n $statement = 'SELECT user.id, username, role, email, banned FROM user INNER JOIN \n role_lov role_lov ON user.role_id = role_lov.id ORDER BY user.id';\n $query = $this->prepare($statement);\n $query->execute();\n return $query->fetchAll();\n }", "public function memberList()\n {\n return User::where('status', 1)->where('role_id', 2)->get();\n }", "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 listUsers()\n {\n $query = new Query();\n\n $rows = $query->select(['id', 'name'])\n ->from('users')\n ->orderBy(['date_add' => SORT_DESC])\n ->all();\n\n return $rows;\n }", "public function get_users()\n\t{\n\t\t$sql=\"SELECT * FROM waf_users WHERE 1=1\";\n\t\t$result=$this->db->LIST_Q($sql);\n\t\treturn $result;\n\t}", "protected function getUserList() {\n\t$controller = new ChatMySQLDAO();\n\tif(!isset($_SESSION['username'])) {\n\t return;\n\t}\n\t$users = $controller->getUserList($_SESSION['username']);\n\t$data = array();\n\t$i = 0;\n\tforeach ($users as $user) {\n\t $data[$i++] = $user['user_name'];\n\t}\n\treturn $data;\n }", "public function getValidUsers()\n {\n $result = array();\n $logins = Login::model()->findAll(\"LoginRoleId=:role OR LoginRoleId=:admin OR LoginRoleId=:sadmin\",\n array(\":role\"=>LoginRole::SUPPLIER, ':admin' => LoginRole::ADMINISTRATOR, \":sadmin\" => LoginRole::SUPER_ADMIN));\n foreach ($logins as $login) {\n $result[] = $login->UserName;\n }\n return $result;\n }", "function getUsernames(){\n $arr = array();\n for($x=0;$x<count($this->names);$x++){\n array_push($arr,$this->names[$x]);\n }\n return $arr;\n }", "public function getUsers(){\n\t\treturn $this->users;\n\t}", "public static function listUsers()\n {\n //Init curl\n $curl = new curl\\Curl();\n\n // GET request to api\n $response = $curl->get(Yii::$app->params['listUsers']);\n\n $records = json_decode($response, true);\n\n foreach($records as $users){\n foreach($users as $user){\n $list[$user['id']] = $user['name'] . ' ' . $user['last_name'];\n }\n }\n\n return $list;\n }", "public function getAll()\n {\n return $this->appUser->orderBy('first_name')->get()->toArray();\n }", "public function getAllUsers()\n {\n $result = self::$dbInterface -> query(\"SELECT userID, userName, email FROM user\");\n return $result;\n }", "public function users()\n {\n return $this->getUsers(\n config('auth.model') ?: config('auth.providers.users.model')\n );\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 userList() \n { \n $user = User::get(); \n return response([ 'data' => ToArray::collection($user), 'message' => 'Users list retrieved successfully'], $this->successStatus);\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 getUsers()\n {\n return User::where('user_status', 1)->get();\n }", "public static function getUsers() {\n\t\t$res = self::$db->query(\"SELECT id, email, username, logins, last_login FROM `\".self::$users_tbl.\"` ORDER BY username\");\n\t\t$row = $res->fetchAll(PDO::FETCH_ASSOC);\n\t\treturn $row;\n\t}", "public function getUserList() {\n $users = DB::select(\"select * from users\");\n $count = DB::table(\"users\") -> count();\n $data = [];\n foreach ($users as $user) {\n array_push($data, array(\n \"id\" => $user -> id,\n \"role\" => ($user -> role == 0)?\"Inactive\":($user -> role == 1?\"Active\":'[ Admin ]'),\n \"fname\" => $user -> fname,\n \"lname\" => $user -> lname,\n \"affiliation\" => $user -> affiliation,\n \"email\" => $user -> email,\n \"created_at\" => $user -> created_at,));\n };\n return array(\"code\" => 0, \"msg\" => \"\", \"count\" => $count, \"data\" => $data);\n }", "public function getUsers()\n {\n $em = $this->container->get('doctrine')->getEntityManager();\n $builder = $em->getRepository('AppWebBundle:User')->createQueryBuilder('u');\n \n return $builder->getQuery()->getResult();\n }", "public function getAllUsers()\n {\n $users = User::all();\n return $users;\n }", "function get_course_users() {\n\t\t$user_list = CourseManager::get_user_list_from_course_code ( api_get_course_id () );\n\t\treturn $user_list;\n\t}", "public function index()\n {\n $this->authorize('read_users');\n return User::withOutSuperAdmin()->with('roles')->get();\n }", "public function getUsers() {\n \n // Call getAllUsers method in userDataService and set to variable\n $users = $this->getAllUsers();\n \n // Return array of users\n return $users;\n }", "public function getUsers()\n {\n $users = $this->usersController->getUsers();\n echo json_encode($users);\n return $users;\n }", "function get_user_list(){\n\t\treturn array();\n\t}", "public function getAll()\n {\n $sql = \"SELECT * FROM users WHERE role_id = 2;\";\n $stm = App::$db->prepare($sql);\n $stm->setFetchMode(\\PDO::FETCH_OBJ);\n $stm->execute();\n return $stm->fetchAll();\n }", "public function getUsersRoles()\n\t{\n\t\t$db = $this->getDbTable()->getAdapter();\n\t\t$select = $db->select()\n\t\t\t->from(array('u' => 'users'), array('user_id', 'name', 'surname', 'patronymic'))\n\t\t\t->joinLeft(array('ur' => 'users_roles'),\n\t\t\t\t'ur.user_id = u.user_id', array('role_id'));\n\t\treturn $db->fetchAll($select);\t\n\t}", "public function getUsersNameAttribute()\n {\n return $this->user->name;\n }", "public function get_users()\n\t{\n\t\t\n\t\t$query=$this->db->get('ag_users');\n\t\t\n\t\treturn $query->result() ;\n\t}", "public function getUsers(){\n //write the query to select all users with their role title\n $userrolequery = \"SELECT * FROM users;\";\n\n //check if the query() runs the sql statement\n if ($result = $this->dbobj->dbcon->query($userrolequery)) {\n $row = $result->fetch_all(MYSQLI_ASSOC);\n\n }\n else{\n echo \"Error\" .$this->dbobj->dbcon->error;\n }\n return $row;\n }", "public function getUsers()\n {\n\t\treturn $this->api->listUsersOfGroup($this->getID());\n }", "public function get_app_users() {\n $this -> db -> select(\"users.Id,users.FirstName,users.LastName,CONCAT_WS( ' ', users.FirstName, users.LastName ) as FullName,users.Email,users.Mobile\");\n $this -> db -> where(\n array(\n 'users.IsActive'=>1,\n 'users.IsRemoved' => 0\n ));\n $whereCond = '( users.UserRole = 0 or users.UserRole = 4 )';\n $this -> db -> where($whereCond);\n \n $this-> db -> order_by(\"FullName\",\"ASC\");\n \n $query = $this -> db -> get('users');\n //echo $this->db->last_query();exit;\n return $query -> result_array();\n }", "public function index()\n {\n return $this->users->getAll('first_name', 'asc', ['departments', 'sectors', 'meta']);\n }", "public function getUsers():array\n\t{\n\t\treturn $this->_users;\n\t}", "public function fetchAllUsers()\n {\n return UserAuthorityModel::leftjoin('users', 'user_authorities.users__id', '=', 'users._id')\n ->where('user_authorities.user_roles__id', '!=', 1)\n ->select(\n __nestedKeyValues([\n 'users' => [\n '_id',\n 'status',\n ],\n 'user_authorities' => [\n 'user_roles__id',\n ]\n ])\n )\n ->get();\n }", "public function indexAdmin ()\n {\n $listOfUsers = $this->userRequest->usersIndexForAdmin();\n return $listOfUsers;\n }", "public function index()\n {\n return $this->user->all();\n }", "public function getUsers(){\n\t\t\t$users = $this->db->get(\"users\");\n\t\t\treturn $users;\n\t\t}", "public function usersList()\n {\n return app(UsersList::class)($this);\n }", "public function usersListAction()\n\t{\n\t\t$em = $this->getDoctrine()->getEntityManager();\n\n\t\t$users = $em->getRepository('McmsUserBundle:User')->findAll();\n\n\t\treturn array('users' => $users);\n\t}", "public function users() {\n\t\treturn $this->users;\n\t}" ]
[ "0.744856", "0.73999196", "0.73464906", "0.7234324", "0.7234141", "0.71664375", "0.71413344", "0.7111044", "0.7095264", "0.7069081", "0.7027383", "0.7027383", "0.7027383", "0.70248526", "0.7011642", "0.6952047", "0.6948848", "0.68979174", "0.68967164", "0.68720585", "0.6870119", "0.6865752", "0.68594587", "0.6853868", "0.6853042", "0.6833343", "0.68307835", "0.681612", "0.681448", "0.68057686", "0.67852", "0.67787284", "0.67504215", "0.67488796", "0.6747235", "0.6745102", "0.67441785", "0.673771", "0.6736509", "0.67327815", "0.6701275", "0.6693972", "0.66937464", "0.6692994", "0.6686255", "0.6685501", "0.6680677", "0.6670683", "0.6663537", "0.66440934", "0.6642483", "0.6628419", "0.6616254", "0.6611477", "0.6602849", "0.65975076", "0.65972334", "0.6588466", "0.6584984", "0.65819913", "0.6577298", "0.65714073", "0.6567606", "0.6558526", "0.65576214", "0.6548257", "0.65445614", "0.6526221", "0.6511702", "0.65081203", "0.65038395", "0.648014", "0.64779335", "0.64761627", "0.647128", "0.6470367", "0.6467411", "0.64643645", "0.64622515", "0.6460614", "0.645517", "0.64531904", "0.6447579", "0.6446933", "0.6439864", "0.64383894", "0.6431566", "0.6430965", "0.6419673", "0.6418478", "0.640791", "0.6403654", "0.6394887", "0.63945657", "0.6391803", "0.63875425", "0.6378424", "0.63729876", "0.63719785", "0.63717157" ]
0.72402847
3
Returns the names of the datasources that are accessible to this role
public function getDatasourceNames() { $result = $this->getDatasources()->all(); if( is_null( $result ) ) return []; return array_map( function($o) {return $o->namedId;}, $result ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getDatasources()\n {\n return $this->datasources;\n }", "public function getDataSourcesList() {\n return $this->_get(8);\n }", "public function getDataSourcesList() {\n return $this->_get(1);\n }", "public function getDataSourcesList() {\n return $this->_get(10);\n }", "public function getDatasourceName()\n {\n return $this->datasource;\n }", "public function getOtherDataSourcesList() {\n return $this->_get(10);\n }", "public function hasDataSources() {\n return $this->_has(1);\n }", "public function getAdministrativeDatabasesList() {\n return $this->_get(9);\n }", "public function getDatasourceFunctions() {\n return array();\n }", "public function getAvailablePaths()\n {\n $paths = [];\n $datasources = array_reverse($this->datasources);\n foreach ($datasources as $datasource) {\n $paths = array_merge($paths, $datasource->getAvailablePaths());\n }\n return $paths;\n }", "public function hasDataSources() {\n return $this->_has(8);\n }", "public function getPoolSourceslist()\n\t{\n\t\treturn($this->getProperty('sourceslist'));\n\t}", "public function showDatabases(){\n\t\treturn $this->instance->listDatabases();\n\t}", "public function getConnectionNames();", "public function getDatasource()\n {\n return $this->datasource;\n }", "public function getDatasource()\n {\n return $this->datasource;\n }", "public function getConnectionNames()\n {\n // TODO: Implement getConnectionNames() method.\n }", "public function listDatabases(){\n\t\treturn $this->instance->listDatabases();\n\t}", "public function hasDataSources() {\n return $this->_has(10);\n }", "function listSources() {\n\t\t$cache = parent::listSources();\n\t\tif ($cache != null) {\n\t\t\treturn $cache;\n\t\t}\n\t\t$result = $this->_execute('SHOW TABLES FROM ' . $this->name($this->config['database']) . ';');\n\n\t\tif (!$result) {\n\t\t\treturn array();\n\t\t} else {\n\t\t\t$tables = array();\n\n\t\t\twhile ($line = mysql_fetch_row($result)) {\n\t\t\t\t$tables[] = $line[0];\n\t\t\t}\n\t\t\tparent::listSources($tables);\n\t\t\treturn $tables;\n\t\t}\n\t}", "public function getDatasource()\n {\n return static::resolveDatasource($this->datasource);\n }", "protected function getActiveDatasource()\n {\n return $this->datasources[$this->activeDatasourceKey];\n }", "public function getDatasetNameList() {\n return $this->_get(6);\n }", "public function datasource() { \n return $this->HasMany('App\\Datasource');\n }", "public function getDatasetNameList() {\n return $this->_get(17);\n }", "public function datasource() {\n if (!isset($this->datasource)) {\n $this->datasource = search_api_get_datasource_controller($this->item_type);\n }\n return $this->datasource;\n }", "public function admin_get_dbs() {}", "public function getDatasourceOverviewData()\n {\n\n // create the ArrayList instance\n $datasources = new ArrayList();\n\n // load all virtual host nodes\n foreach ($this->getDatasourceRepository()->findAll() as $datasourceNode) {\n $datasources->add($this->toDatasourceOverviewData($datasourceNode));\n }\n\n // return the ArrayList instance\n return $datasources;\n }", "public static function getDataSource()\n {\n return static::$_dataSource;\n }", "public function getPermissionSources()\n\t{\n\t\treturn $this->getPermissions(empty($this->permissionSources), 'permission', true);\n\t}", "public function getConnectionNames()\n {\n return $this->connections;\n }", "function listSources() {\n\t\t$db = $this->config['database'];\n\t\t$this->config['database'] = basename($this->config['database']);\n\n\t\t$cache = parent::listSources();\n\t\tif ($cache != null) {\n\t\t\treturn $cache;\n\t\t}\n\n\t\t$result = $this->fetchAll(\"SELECT name FROM sqlite_master WHERE type='table' ORDER BY name;\");\n\n\t\tif (!$result || empty($result)) {\n\t\t\treturn array();\n\t\t} else {\n\t\t\t$tables = array();\n\t\t\tforeach ($result as $table) {\n\t\t\t\t$tables[] = $table[0]['name'];\n\t\t\t}\n\t\t\tparent::listSources($tables);\n\n\t\t\t$this->config['database'] = $db;\n\t\t\treturn $tables;\n\t\t}\n\t\t$this->config['database'] = $db;\n\t\treturn array();\n\t}", "public function get_database_names() {\n return UPS_SUCCESS;\n }", "function findAllAdministrators() {\r\n\r\n\t\treturn ($this->query('SELECT * FROM admins;'));\r\n\r\n\t}", "function databases(){\n $this->execute(\"SELECT datname FROM pg_database WHERE datistemplate = false;\");\n $aDatabases = array();\n while ($aReg = $this->fetchRow()){\n $aDatabases[] = $aReg[0];\n }\n return $aDatabases;\n }", "public function getDataSource()\n\t{\n\t\treturn $this->dataSource;\n\t}", "public function listSources() {\n $this->resolve();\n return $this->sources;\n }", "public function getAdmins()\n {\n $role = Role::where('name', 'admin')->first();\n return $role->users;\n }", "public function listPersistedDatabases(): array\n {\n return $this->dataReader->listPersistedDatabases();\n }", "function database_list(){\n\t\treturn($this->q2obj(\"show databases\"));\n\t}", "public function readAdmins(){\r\n $results = array();\r\n\r\n if ( null !== $this->getDB() ) {\r\n $dbs = $this->getDB()->prepare('select * from admin');\r\n\r\n if ( $dbs->execute() && $dbs->rowCount() > 0 ) {\r\n $results = $dbs->fetchAll(PDO::FETCH_ASSOC);\r\n }\r\n } \r\n return $results;\r\n }", "public function listDatabases(): array\n {\n if ($this->allDatabaseIdentifiers === null) {\n $this->allDatabaseIdentifiers = array_combine(\n $this->listPersistedDatabases(),\n $this->listPersistedDatabases()\n );\n }\n\n return array_values($this->allDatabaseIdentifiers);\n }", "public function getDsn()\n {\n assert(is_array($this->_dsn), 'is_array($this->_dsn)');\n return (array) $this->_dsn;\n }", "public function getDatabases() {\n\t\treturn $this->databases;\n\t}", "public function getDataSource() {\n\t\treturn $this->dataSource;\n\t}", "public function getAliases()\n {\n return $this->aliases;\n }", "public function getAliases()\n {\n return [];\n }", "public function getAliases()\n {\n return [];\n }", "public function getAliasList();", "public function getConnectionNames()\n {\n return ['default'];\n }", "public function provides()\n {\n return array_keys($this->aliases);\n }", "public function getDBConnections(): array {\n return $this->configVars['database-connections'];\n }", "public function getAliases(): array\n {\n return $this->aliases;\n }", "public function getAliases() : array\n {\n return $this->aliases;\n }", "public function getSources(): array\n {\n return $this->config['source'] ?? [];\n }", "public function getGeneralPopulationSourcesList() {\n return $this->_get(2);\n }", "public function getRoles() {\n $ds = \\dibi::dataSource(\"\n SELECT r.*, rr.name AS parent_name\n FROM users_roles AS r\n LEFT JOIN users_roles AS rr ON rr.id = r.parent_id\n \");\n\n return $ds;\n }", "public function getAliases( )\n {\n return $this->aliases;\n }", "protected function getConfiguredServerNames() {\n\t\t$factory = new CmisObjectFactory();\n\t\treturn $factory->getConfiguredServerNames();\n\t}", "function dsnArray()\n\t{\n\t\t$conn_info = Db::getConnection($this->conn_name);\n\t\tif (empty($conn_info['dsn']))\n\t\t\tthrow new Exception('No dsn string found for the connection ' \n\t\t\t. $this->conn_name);\n\t\treturn Db::parseDsnString($conn_info['dsn']);\n\t}", "public function getSource()\n {\n return 'acl_roles';\n }", "public function listSources() {\n return null;\n }", "public function getConnectionLocations()\n {\n return $this->connectionLocations;\n }", "private function getAllSourcesFromDB() {\n return $this->database->table(\"source\")->fetchAll();\n }", "public function showdbs()\n {\n $this->_validate(array());\n $this->_QUERYCOUNT++;\n\n return $this->_query->showdatabases();\n }", "public function getSpecificPopulationSourcesList() {\n return $this->_get(3);\n }", "public function getAdmins()\n {\n $query = $this->newQuery();\n $query->where('admin', true);\n\n return $this->doQuery($query, false, false);\n }", "public function getPoolImportedFromSourceslist()\n\t{\n\t\treturn($this->getProperty('importedFromImportedFromSourceslist'));\n\t}", "public function getConnections()\n {\n return [$this->entityManager->getConnection()];\n }", "public function getDataSourceCollection(): SourceCollection {\n\n return $this->dataSourceCollection;\n\n }", "public function list_databases() {\n $sql = \"SHOW DATABASES\";\n try {\n if ($this->conn == null) {\n echo \"conn is null<br>\";\n }\n $result = $this->conn->query($sql);\n $dbs = array();\n foreach($result as $row) {\n if ($row['Database'] != 'mysql' &&\n $row['Database'] != 'information_schema' &&\n $row['Database'] != 'performance_schema' &&\n $row['Database'] != 'sys') {\n array_push($dbs, $row['Database']);\n }\n }\n return $dbs;\n } catch (PDOException $e) {\n die(\"DB ERROR: \".$e->getMessage());\n }\n }", "public function connections()\n {\n return config()\n ->database\n ->adapters\n ->toArray();\n }", "function readDataSource() {return $this->_datasource;}", "function getAllAccess() {\n return ['download', 'remoteAccess', 'remoteService', 'enclave','notAvailable'];\n}", "public function getSitesList()\n {\n return Db::fetchAll(\"SELECT idsite, name\"\n . \"\\n FROM \" . Common::prefixTable('site')\n . \"\\n ORDER BY idsite\");\n }", "public function getSourceAccessionsList(){\n return $this->_get(6);\n }", "public function getServers() {\n\t\treturn $this->dbHandler->getAllServer();\n\t}", "public function getRoleDataSource()\n\t{\n\t\tif ($this->_roleDataSource === null)\n\t\t{\n\t\t\t$this->_roleDataSource = new Application_Model_RoleMapper;\n\t\t}\n\t\t\n\t\treturn $this->_roleDataSource;\n\t}", "public function getDatabases(){\n $pdo = $this->pdo;\n $databases = $pdo->prepare(\"SHOW DATABASES;\");\n $databases->execute();\n $databases = $databases->fetchAll($pdo::FETCH_NUM);\n foreach($databases as &$database)\n $database = $database[0];\n return $databases;\n }", "public function get_dbs()\n\t{\n\t\treturn $this->driver_query('db_list');\n\t}", "public function getSourceAccessionsList(){\n return $this->_get(8);\n }", "function AliasNameList ( ) { return $this->_AliasNameList; }", "function GetSources()\n\t{\n\t\t$result = $this->sendRequest(\"GetSources\", array());\t\n\t\treturn $this->getResultFromResponse($result);\n\t}", "public function getDatasourceRepository()\n {\n return $this->datasourceRepository;\n }", "public function getSources()\n {\n return $this->sources;\n }", "public function get_databases()\n\t{\n\t\treturn $this->databases;\n\t}", "private function load_roles() {\n $query = $this->PDO->prepare(\"SELECT * FROM rol\");\n $query->execute();\n return $query->fetchAll(PDO::FETCH_ASSOC);\n }", "public function getDestinations() : array\n {\n return $this->destinations;\n }", "public function getListDbConnConfigs() {\n\t\treturn $this->_getConfigValueArray('configDBconn');\n\t}", "public function getDatasetsList() {\n return $this->_get(4);\n }", "public function getStudyNameList() {\n return $this->_get(9);\n }", "function getDataSource() { return $this->_datasource; }", "public function getServers();", "public function getDatasetsList() {\n return $this->_get(3);\n }", "public function getRolesNames ();", "public function getDestinationList() {\n return $this->packageDao->getDestinationList();\n }", "public static function getDataSourceKey()\n {\n return self::getConfig()->get('dataSourceKey');\n }", "public function getAvailableRoles() ;", "public function getAliases()\n {\n return array_values($this->aliases);\n }", "public function findAllAdmin() {\n\t\t\t$result = $this->createQuery()->execute();\n\t\t\treturn $result;\n\t\t}" ]
[ "0.7779208", "0.70564157", "0.7053952", "0.69425607", "0.63833404", "0.62551284", "0.61401105", "0.60848486", "0.60242116", "0.59897184", "0.5966947", "0.59334326", "0.59220344", "0.5896089", "0.5874414", "0.5874414", "0.58680254", "0.5850192", "0.5820964", "0.5809677", "0.57626486", "0.57464033", "0.5708562", "0.57053643", "0.57026744", "0.5687584", "0.5685164", "0.56341445", "0.5579503", "0.5569835", "0.5531675", "0.5524699", "0.5520993", "0.55203676", "0.5504763", "0.55025613", "0.5482041", "0.5472928", "0.546588", "0.5450165", "0.5448374", "0.544796", "0.5438699", "0.5435968", "0.542711", "0.5418063", "0.54111266", "0.54111266", "0.5406919", "0.53967404", "0.5385656", "0.5373978", "0.5372005", "0.5365189", "0.53619343", "0.5361335", "0.534723", "0.5346014", "0.53427756", "0.5339068", "0.5336666", "0.53218734", "0.53177524", "0.53090596", "0.53059834", "0.5300499", "0.52995974", "0.52937007", "0.52882195", "0.5287376", "0.5286662", "0.52861995", "0.5269262", "0.52590305", "0.52444065", "0.52444047", "0.5244294", "0.5240376", "0.52397966", "0.52292573", "0.52230906", "0.52223", "0.52184516", "0.52097386", "0.52055186", "0.51991946", "0.51922536", "0.5190228", "0.51853895", "0.51829505", "0.5182356", "0.51797384", "0.517902", "0.5177298", "0.5173559", "0.51727515", "0.51667386", "0.51649857", "0.51632", "0.5160082" ]
0.7036354
3
Returns the names of permissions connected to the active record.
public function getPermissionNames() { $result = $this->getPermissions()->all(); if( is_null( $result ) ) return []; return array_map( function($o) {return $o->namedId;}, $result ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function permissions()\n {\n return $this->permissionModel->findAll();\n }", "static function getPermissionNames() {\n return static::getPermissions()->keys();\n }", "public function getPermissionNames()\n\t{\n\t\treturn $this->getPermissions(true, 'name');\n\t}", "public function permissions()\n {\n\n return Permission::all();\n }", "public function getPermissionNames() {\n return $this->getGuardUser() ? $this->getGuardUser()->getPermissionNames() : array();\n }", "public function getPermissionNames()\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->getPermissionNames() : array();\r\n }", "public function getAllPermissionNames() {\n return $this->getGuardUser() ? $this->getGuardUser()->getAllPermissionNames() : array();\n }", "public function getAllPermissionNames()\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->getAllPermissionNames() : array();\r\n }", "public function getAllPermissions();", "public function getAllPermissions();", "public static function getAllPermissions()\n\t{\n\t\treturn Permission::all();\n\t}", "public function getPermissionsListAttribute()\n {\n return Permission::orderBy('resource')->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 permissions()\n {\n return $this->permissions;\n }", "public function getAllPermissions()\n {\n return $this->repository->getAllPermissions();\n }", "public function permissions()\n\t{\n\t\treturn $this->get('permissions');\n\t}", "public function getPermissions();", "public function getPermissions()\n {\n return $this->get(self::PERMISSIONS);\n }", "protected function getPermissions()\n {\n if (!$this->tablePermissionsExists()) {\n return [];\n }\n return Permission::with('roles')->get();\n }", "public function getPermissionNames(): array\n {\n return $this->roleManagement->getPermissionNames();\n }", "function get_permission_list() {\n\t\treturn $this->db->get('system_security.security_permission');\n\t\t\n\t}", "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() {\n return $this->getGuardUser()->getPermissions();\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 getPermissions()\r\n {\r\n return $this->getGuardUser()->getPermissions();\r\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}", "protected function getPermissions()\n {\n return Permission::with('roles')->get();\n }", "public function permissions() {\n\t$this->loadPermissions();\n\treturn $this->permissions;\n}", "public function getPermissions() {}", "public function getPermissions() {}", "public function getAllPermissions(): array;", "public static function getAllPermissions()\n {\n return Cache::rememberForever('permissions.all', function() {\n return self::all();\n });\n }", "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}", "public function getPossiblePermissions();", "public function getAllInUse()\n {\n return $this->auth->getAllPermissions();\n }", "public function permissions()\n {\n $model = config('authorization.permission');\n\n return $this->belongsToMany($model);\n }", "public function allowedPermissions()\n {\n return $this->permissions()->wherePivot('has_access', true)->orderBy('name');\n }", "public function getAllPermissions() {\n return $this->getGuardUser() ? $this->getGuardUser()->getAllPermissions() : array();\n }", "public function getPossiblePermissions()\n {\n return array_keys($this->map);\n }", "public function getAllPermissions()\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->getAllPermissions() : array();\r\n }", "public function getPermissions() {\n\t\treturn $this->addressBookInfo['permissions'];\n\t}", "public function getPermissions(): array {\n\t\treturn [];\n\t}", "public static function getAll()\n {\n $pdo = Database::getConnection();\n $query = \"SELECT * FROM permissions\";\n try {\n $stm = $pdo->query($query);\n return $stm->fetchAll(\\PDO::FETCH_ASSOC);\n } catch (PDOException $e) {\n return false;\n }\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 }", "private function getPermissionsPermissions()\n {\n return [\n [\n 'name' => 'Permissions - List all permissions',\n 'description' => 'Allow to list all permissions.',\n 'slug' => PermissionsPolicy::PERMISSION_LIST,\n ],\n [\n 'name' => 'Permissions - View a permission',\n 'description' => 'Allow to view the permission\\'s details.',\n 'slug' => PermissionsPolicy::PERMISSION_SHOW,\n ],\n [\n 'name' => 'Permissions - Update a permission',\n 'description' => 'Allow to update a permission.',\n 'slug' => PermissionsPolicy::PERMISSION_UPDATE,\n ],\n ];\n }", "public function getPermissionsDescription()\n {\n if (class_exists(Subsite::class)) {\n Subsite::disable_subsite_filter(true);\n }\n\n $permissionsUsr = Permission::permissions_for_member($this->owner->ID);\n $permissionsSrc = Permission::get_codes(true);\n sort($permissionsUsr);\n\n $permissionNames = array();\n foreach ($permissionsUsr as $code) {\n $code = strtoupper($code ?? '');\n foreach ($permissionsSrc as $k => $v) {\n if (isset($v[$code])) {\n $name = empty($v[$code]['name'])\n ? _t(__CLASS__ . '.UNKNOWN', 'Unknown')\n : $v[$code]['name'];\n $permissionNames[] = $name;\n }\n }\n }\n\n $result = $permissionNames\n ? implode(', ', $permissionNames)\n : _t(__CLASS__ . '.NOPERMISSIONS', 'No Permissions');\n\n if (class_exists(Subsite::class)) {\n Subsite::disable_subsite_filter(false);\n }\n return $result;\n }", "public function getAllAvailable()\n {\n return $this->allPermissions;\n }", "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 }", "public function getPermissions() :array\n {\n return $this->permissions;\n }", "public function getRolePermissions()\n {\n return self::select(\"r.*, p.*\")\n ->leftJoin('role_permissions rp', 'r.roleID = rp.roleID')\n ->leftJoin('permissions p', 'p.permissionID = rp.permissionID')\n ->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 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 fetchAll()\n\t{\n\t\t$permissions = $this->getRoleModel()->fetchAll();\n\t\treturn $permissions;\n\t}", "public function get_permissions()\n\t{\n\t\treturn $this->area->get_permissions($this->path);\n\t}", "public function permissions()\n {\n return $this->belongsToMany(config('rbac.models.permission'))->withTimestamps()->withPivot('granted');\n }", "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 }", "public function permissions()\n {\n return [\n 'add parcels', 'edit parcels', 'delete parcels', 'send parcels', 'pick parcels'\n ];\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 static function getAll()\n {\n return Role::with(['permissions'])->get();\n }", "public static function getPermissions(): array\n {\n return [];\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 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 static function permissions(): array\n {\n return [];\n }", "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 getAll()\n {\n $permissionArray = [];\n foreach ($this->permissions as $permission => $status) {\n if ($status) {\n $permissionArray[] = $permission;\n }\n }\n return $permissionArray;\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}", "protected static function getPermissions(): Collection\n {\n return app(PermissionRegistrar::class)->getPermissions();\n }", "protected static function getPermissions(): Collection\n {\n return app(PermissionRegistrar::class)->getPermissions();\n }", "public function permissions()\n {\n return $this->hasMany(Permission::class);\n }", "public function permissions()\n {\n return $this->embedsMany(\n config('laravel-permission.table_names.role_has_permissions')\n );\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 & GetPermissions ();", "public function getObjectPermissions(): array;", "public function permList()\n {\n return $this->getParent()->channelGroupPermList($this->getId());\n }", "public function index()\n {\n return $permissions = $this->permission->all();\n }", "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 }", "abstract public function getPermissions();", "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 all() : Collection\n {\n return Permission::all();\n }", "public function getDirectPermissions(): Collection\n {\n return $this->permissions;\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 }", "public function perms()\n {\n return $this->belongsToMany(Config::get('entrust-branch.permission'), Config::get('entrust-branch.permission_role_table'));\n }", "public function getCurrentUserPermissions()\n {\n return $this->permissions()\n ->whereNull('expires_at')\n ->orWhere('expires_at', '>', now())\n ->get();\n }", "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 permissions(): array\n {\n $permissions = $this->getAttribute('permissions') ?: [];\n\n if ( ! is_array($permissions)) {\n $permissions = (array) $permissions;\n }\n\n return $permissions;\n }", "public function getPermissionsViaRole()\n {\n return $this->roles->map(function (Role $role) {\n return $role->getAllPermissions();\n })->flatten();\n }", "public function getAdminPermissions(): array;", "public function get_allPermission() {\n\t\t$allPermission = '';\n\t\t$_t = $this->select();\n\t\tif(!empty($_t)) {\n\t\t\tforeach($_t as $mp) {\n\t\t\t\t$allPermission .= $mp['mp_content'] . ',';\n\t\t\t}\n\t\t}\n\t\t$allPermission = rtrim($allPermission, ',');\n\t\treturn $allPermission;\n\t}", "public function permissions()\n {\n return $this->belongsToMany('Bican\\Roles\\Permission');\n }", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions();", "public function permissions() {\n return $this->belongsToMany(Permission::class);\n }", "public function permissions()\n {\n return $this->belongsToMany(Permission::class);\n }", "public function permissions()\n {\n return $this->belongsToMany(Permission::class);\n }", "public function permissions()\n {\n return $this->belongsToMany(Permission::class);\n }" ]
[ "0.7957452", "0.7656528", "0.7504575", "0.7450173", "0.7391873", "0.7374675", "0.73653704", "0.7332183", "0.7329349", "0.7329349", "0.7321925", "0.72916263", "0.72637844", "0.72047424", "0.7203576", "0.71662134", "0.71152586", "0.7080189", "0.7074912", "0.70737183", "0.7023319", "0.7023123", "0.70097256", "0.7006508", "0.7006508", "0.7006508", "0.70005065", "0.6999547", "0.69882274", "0.69617534", "0.6946555", "0.6946555", "0.69451666", "0.69405365", "0.68564785", "0.68484765", "0.6843579", "0.6824297", "0.68158937", "0.68134886", "0.68117416", "0.67953265", "0.67767256", "0.67413247", "0.6727021", "0.66621006", "0.66353256", "0.662745", "0.6612255", "0.6598816", "0.6595468", "0.65930885", "0.6585728", "0.65796953", "0.65790784", "0.6558688", "0.6549716", "0.65440613", "0.65421724", "0.6530051", "0.65261424", "0.6513421", "0.6509453", "0.65007204", "0.6495384", "0.6492848", "0.64879173", "0.647952", "0.6478828", "0.6478828", "0.6470698", "0.64655226", "0.6463302", "0.6453002", "0.6452888", "0.64514065", "0.6435953", "0.64327043", "0.64291775", "0.64213943", "0.64177424", "0.64011985", "0.6395807", "0.63708043", "0.63706833", "0.63564247", "0.63512117", "0.63484", "0.62971383", "0.62892985", "0.62892616", "0.6263734", "0.6263734", "0.6263734", "0.6263734", "0.6263734", "0.626076", "0.62535286", "0.62535286", "0.62535286" ]
0.7225324
13
Returns true if the role includes the given permission
public function hasPermission( $permission ) { return in_array( $permission, $this->getPermissionNames() ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function hasRole(string $role): bool;", "public function hasPermissionThroughRole($permission)\n {\n foreach ($permission->roles as $role){\n if($this->roles->contains($role)) return true;\n }\n return false;\n }", "public function hasRole() {\n return $this->_has(2);\n }", "public function havePermission($permission){\n $roles_user = $this->roles;\n\n //recorro cada rol y lo comparo\n foreach ($roles_user as $role) {\n //si tiene full acceso a los permisos regreso true\n if ($role['full-access'] == 'Si') {\n return true;\n }\n //recorro los permisos correspondientes al rol\n foreach ($role->permissions as $permission_user) {\n //verifico si tiene entre sus permisos el permiso a verificar en la function\n //si lo tiene regreso true\n if ($permission_user->slug == $permission) {\n return true;\n }\n }\n }\n //sino tiene ningun permiso regreso false\n return false;\n }", "public function hasRole($role)\n {\n return $this->isGranted($role); \n }", "public function isGranted($role)\n {\n return in_array($role, $this->getRoles());\n }", "public function roleInUse(string $role): bool;", "public function hasPermissions()\n {\n return $this->roles()->count() > 1;\n }", "protected function hasPermissionThroughRole($permission)\n\t{\n\t\tforeach ($permission->roles as $role) {\n\t\t\tif ($this->roles->contains($role)) {\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}", "public function hasRoleAccess()\n {\n $roles = $this->map[$this->uri]['roles'];\n\n if ($roles === self::ROLE_PUBLIC) {\n\n return true;\n }\n\n $this->isArray($roles);\n\n $this->collectMissingRoles($roles);\n\n return count(array_intersect($this->currentUserRoles, $roles)) > 0;\n }", "public function has(Role $role, Permission $permission)\n {\n // todo: implement method\n }", "protected function hasPermissionThroughRole($permission): bool\n {\n if ($this->hasRoles()) {\n foreach ($this->roles as $role) {\n if ($this->roles->contains($role)) {\n return true;\n }\n }\n }\n\n return false;\n }", "public function HasPermission()\n\t\t{\n\t\t\tstatic $perms = null;\n\t\t\tif ($perms === null) {\n\t\t\t\t$perms = $GLOBALS[\"ISC_CLASS_ADMIN_AUTH\"]->GetPermissions();\n\t\t\t}\n\n\t\t\tif (in_array(AUTH_Edit_Customers, $perms)\n\t\t\t\t&& in_array(AUTH_Edit_Orders, $perms)\n\t\t\t\t&& in_array(AUTH_Newsletter_Subscribers, $perms)) {\n\t\t\t\t\treturn true;\n\t\t\t} else {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}", "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 current_role_can(string $action): bool;", "public function hasAccess($permission);", "public function authorize() {\n\t\treturn $this->user()->hasPermission('edit.roles');\n\t}", "public function authorize()\n {\n return auth()->user()->can('role@create') || auth()->user()->can('role@edit');\n }", "function hasRole($role)\n{\n\treturn $this->loggedUser? $this->loggedUser->hasRole($role) : false;\n}", "public function hasPrivilege($perm) {\n foreach ($this->roles as $role) {\n if ($role->hasPerm($perm)) {\n return true;\n }\n }\n return false;\n }", "public function authorize()\n {\n return auth()->user()->can('updatePermissions', [Role::class, request('role')]);\n }", "public function roleExists(string $role): bool;", "function check_acl($role = '', $resource, $permission)\n\t{\n\t\tif (!$this->acl->has($resource))\n\t\t{\n\t\t\treturn 1;\n\t\t}\n\t\tif (empty($role)) {\n\t\t\tif (isset($this->CI->session->userdata['role'])) {\n\t\t\t\t$role = $this->CI->session->userdata['role'];\n\t\t\t}\n\t\t}\n\t\tif (empty($role)) {\n\t\t\treturn false;\n\t\t}\n\t\treturn $this->acl->isAllowed($role, $resource, $permission);\n\t}", "public function hasRole(string $role, FilterInterface $filter = null):bool;", "public function hasPerm($permission) {\n return array_search($permission, $this->role_perm);\n }", "function isAllowed($role, $resource, $privilege)\n\t{\n\t\tif ($this->mode == self::MODE_OPTIMISTIC) {\n\t\t\t$roles = $this->aclModel->getTableSelection()\n\t\t\t\t->select('role')\n\t\t\t\t->where('namespace', $this->getNamespaceRepository()->getCurrentNamespace())\n\t\t\t\t->where('resource', $resource)\n\t\t\t\t->where('privilege', $privilege)\n\t\t\t\t->fetchPairs('role', 'role');\n\t\t\treturn count($roles) == 0 || array_key_exists($role, $roles);\n\t\t} elseif($this->mode == self::MODE_PESSIMISTIC) {\n\t\t\treturn (bool) $this->aclModel->getTableSelection()\n\t\t\t\t->select('id')\n\t\t\t\t->where('namespace', $this->getNamespaceRepository()->getCurrentNamespace())\n\t\t\t\t->where('role', $role)\n\t\t\t\t->where('resource', $resource)\n\t\t\t\t->where('privilege', $privilege)\n\t\t\t\t->count();\n\t\t}\n\t}", "public function hasRole(): bool\n {\n return isset($this->role);\n }", "function HasPermission($Role, $Permission)\n\t{\n\t\t$Res = jf::SQL ( \"\n\t\tSELECT COUNT(*) AS Result\n\t\tFROM {$this->TablePrefix()}rbac_rolepermissions AS TRel\n\t\tJOIN {$this->TablePrefix()}rbac_permissions AS TP ON ( TP.ID= TRel.PermissionID)\n\t\tJOIN {$this->TablePrefix()}rbac_roles AS TR ON ( TR.ID = TRel.RoleID)\n\t\tWHERE TR.Lft BETWEEN\n\t\t(SELECT Lft FROM {$this->TablePrefix()}rbac_roles WHERE ID=?)\n\t\tAND\n\t\t(SELECT Rght FROM {$this->TablePrefix()}rbac_roles WHERE ID=?)\n\t\t/* the above section means any row that is a descendants of our role (if descendant roles have some permission, then our role has it two) */\n\t\tAND TP.ID IN (\n\t\tSELECT parent.ID\n\t\tFROM {$this->TablePrefix()}rbac_permissions AS node,\n\t\t{$this->TablePrefix()}rbac_permissions AS parent\n\t\tWHERE node.Lft BETWEEN parent.Lft AND parent.Rght\n\t\tAND ( node.ID=? )\n\t\tORDER BY parent.Lft\n\t\t);\n\t\t/*\n\t\tthe above section returns all the parents of (the path to) our permission, so if one of our role or its descendants\n\t\thas an assignment to any of them, we're good.\n\t\t*/\n\t\t\", $Role, $Role, $Permission );\n\t\treturn $Res [0] ['Result'] >= 1;\n\t}", "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 role_can(Role $Role, string $action): bool;", "public function is($role);", "public function isGranted($role) {\n $granted = false;\n $user = $this->getUser();\n\n if ($user) {\n $granted = in_array($role, $user->getRoles());\n }\n\n return $granted;\n }", "public function hasRole($name);", "public function hasRole($role){\n if($this->roles()->where('name', $role)->first()){\n return true;\n }\n return false;\n }", "function hasRole($role, $userId = null);", "public function hasRole($role) {\n return in_array((string)$role, $this->roles);\n }", "public function hasRole($role)\n {\n return in_array($role, $this->getRoles());\n }", "public function isGranted($userOrId, $permission);", "public function authorize()\n {\n return $this->user()->hasRole(['admin', 'superadmin']);\n }", "public function hasRole($role){\n return null !== $this->role()->where('name', $role)->first();\n }", "public function hasPermissionTo($permission){\n\n return $this->hasDirectPermission($permission) || $this->hasPermissionViaRole($permission);\n }", "public function isAllowed($resourceType, $folderPath, $permission, $role = null);", "public function authorize()\n {\n return request()->loggedin_role === 1;\n }", "function check_role( $role_in ) {\n global $_SESSION;\n\n // read the permissions database\n $d = loadDB();\n\n // check if the current user\n $user_name = $_SESSION[\"logged\"];\n // has a specified role\n $roles = array(); // collect all roles for this user\n foreach ( $d[\"users\"] as $key => $value ) {\n if ($value[\"name\"] == $user_name) {\n $roles = array_merge($roles, $value[\"roles\"]);\n }\n }\n \n foreach ( $roles as $role ) {\n if ($role == $role_in) {\n audit( \"check_role\", $role_in.\" as \".$user_name);\n return true;\n }\n }\n audit( \"check_role failed\", $role_in.\" as \".$user_name);\n return false;\n }", "function can($permission, $accessType) {\n\n $userPermissions = app('request')->user()->getAllPermissionsFormAllRoles();\n if ($userPermissions->get($permission) != $accessType && $userPermissions->get($permission) != \"full_access\") {\n return false;\n }\n\n return true;\n }", "public function is_role($role)\n {\n }", "public function hasRole($role) {\n foreach ($this->groups as $group) {\n\n if($group->hasRole($role))\n return true;\n }\n\n return false;\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 return $this->user()->hasRole('admin');\n }", "public function authorize()\n {\n $user = User::findOrFail($this->route('id'));\n\n return $user->hasRole('admin') || $user->hasRole('teacher');\n }", "public function authorize()\n {\n return auth()->user()->hasRole('superadmin|admin');\n }", "public function HasRole ($roleName = NULL, $idRole = NULL);", "function isAuthorized($role_policy) {\n global $SEC_ROLES;\n $user_role = $_SESSION['user']['role'];\n $sub_roles = $SEC_ROLES[$user_role];\n if ($user_role !== $role_policy && !in_array($role_policy, $sub_roles)) {\n return false;\n }\n return true;\n}", "protected function hasRole($role)\n {\n $right = session()->get(\"role\");\n $result = in_array($right, (array)$role);\n return $result;\n }", "public function hasPerm($perm) {\n return $this->roles->hasPerm($perm);\n }", "function check_permission( $permission ) {\n global $_SESSION;\n\n // read the permissions database\n $d = loadDB();\n\n // check if the current user\n $user_name = $_SESSION[\"logged\"];\n // is allowed to use permission\n $roles = array();\n foreach ( $d[\"users\"] as $key => $value ) {\n if ($value[\"name\"] == $user_name) {\n $roles = array_merge($roles, $value[\"roles\"]);\n }\n }\n\n // for each role find the list of permissions\n $userpermissions = array();\n foreach ($d[\"roles\"] as $key => $value) { // all known roles \n foreach ($roles as $role) { // roles of the current user\n if ($value[\"id\"] == $role) {\n $userpermissions = array_merge($userpermissions, $value[\"permissions\"]);\n }\n }\n }\n // print_r($userpermissions);\n \n // for each found permission find the name and compare to requested permission\n foreach ($userpermissions as $perm) {\n foreach ($d[\"permissions\"] as $key => $value) {\n if ($perm == $value[\"id\"] && \n $value[\"name\"] == $permission) {\n audit( \"check_permission\", $permission.\" as \".$user_name);\n return true;\n }\n }\n }\n\n audit( \"check_permission failed\", $permission.\" as \".$user_name);\n return false;\n }", "function has_module_permission($module_id, $user_id, $role_id) {\n if ($module_id == null) {\n return true;\n }\n $this->db->distinct();\n $this->db->from('permissions');\n $this->db->select('module_id');\n $this->db->join('user','user.role_id = permissions.role_id');\n $this->db->where('status',1);\n $this->db->where('module_id',$module_id);\n $this->db->where('user_id',$user_id);\n $this->db->where('permissions.role_id',$role_id);\n $query = $this->db->get();\n return $query->num_rows()==1;\n }", "public function hasRole($role)\n {\n return $this->hakAksesPengguna()\n ->where('nama', strtolower($role))\n ->where('status_request', RequestStatus::APPROVED)->count() > 0;\n }", "public function authorize()\n {\n return Auth::user()->hasAnyRole(['kuchar', 'manager']);\n }", "public function has_permission($permission) {\n\t\t\n\t}", "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 hasRole($role)\n {\n return $this->role == $role;\n }", "public function can($permission);", "public function hasRole($user, string $role = 'login'): bool {}", "public function authorize()\n {\n return $this->user() && $this->user()->role === Constants::USER_ROLE_ADMIN;\n }", "public function has_role($role)\n\t{\n\t\t// Check what sort of argument we have been passed\n\t\tif ($role instanceof Sprig)\n\t\t{\n\t\t\t$key = 'id';\n\t\t\t$val = $role->id;\n\t\t}\n\t\telseif (is_string($role))\n\t\t{\n\t\t\t$key = 'name';\n\t\t\t$val = $role;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$key = 'id';\n\t\t\t$val = (int) $role;\n\t\t}\n\n\t\t$values = $this->refresh('roles')->as_array(NULL,$key);\n\t\treturn (in_array($val, $values));\n\t}", "abstract public function hasRole($roleName);", "function auth_roles()\n {\n if (auth_isAnonymous()) {\n return false;\n }\n\n $auth = auth_prerequisite();\n $field = $auth['fields']['role'];\n $session = auth_get();\n $roles = func_get_args();\n\n return in_array($session->$field, $roles);\n }", "function auth_role($role)\n {\n if (auth_isAnonymous()) {\n return false;\n }\n\n $auth = auth_prerequisite();\n $field = $auth['fields']['role'];\n $session = auth_get();\n\n return $session->$field == $role;\n }", "private function canList()\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 hasPermission(array $permissions);", "public function isRole(){\n $r=Cache::get('role');\n if ((int)$r ==2)\n {\n return true;\n }\n else\n return false;\n }", "function role_exists($role)\n{\n\n if (!empty($role))\n {\n return $GLOBALS['wp_roles']->is_role($role);\n }\n\n return false;\n}", "public function hasPermission($permission)\n {\n if(is_string($permission)) {\n return $this->hasRole(Permission::whereName($permission)->firstOrFail()->roles);\n }\n return $this->hasRole($permission->roles);\n }", "public function hasRole(): bool\n {\n return $this->has(AttributeType::OID_ROLE);\n }", "public function hasPermission($permission)\n {\n if (null === $this->permissions) {\n\n $this->permissions = [];\n\n foreach ($this->getRoles() as $role) {\n $this->permissions = array_merge($this->permissions, $role->getPermissions());\n }\n }\n\n return in_array($permission, $this->permissions);\n }", "function hasAccess(): bool\n {\n return isLoggedInAndHasRole($this->ci, [Role::ROLE_ADMIN]);\n }", "public function has_role($params) {\n global $DB;\n\n if($params['role'] == 'teacher') {\n $roles = $this->get_teacher_roles();\n } elseif($params['role'] == 'student') {\n $roles = $this->get_student_roles();\n }\n\n $rolefilter = new in_filter($roles, \"role\");\n\n return $DB->record_exists_sql(\n \"SELECT ra.*\n FROM {role_assignments} ra\n WHERE ra.userid = :userid AND\n ra.roleid \". $rolefilter->get_sql(),\n array_merge(['userid' => $params['userid']], $rolefilter->get_params())\n );\n\n }", "public function authorize()\n\t{\n\t\treturn Auth::user()->hasRole('admin');\n\t}", "public function authorize()\n\t{\n\t\treturn Auth::user()->hasRole('admin');\n\t}", "function passes_required_role($requiredrole,$loggedrole){\n\t$ret=false;\n\tif($loggedrole==1) $ret=true;//admin sees everything\n\telse if(is_array($requiredrole) and in_array($loggedrole,$requiredrole)) $ret=true;\n\telse if(!is_array($requiredrole) and ($requiredrole>=$loggedrole)) $ret=true;\n\treturn $ret;\n}", "public function authorize()\n {\n return auth()->user()->role === \"admin\";\n }", "public function hasRole($name, $requireAll = false);", "public function authorize()\n {\n // if ($this->hasRole(['admin','superadmin'])) {\n // return true;\n // }\n // else {\n // return false;\n // }\n\n return true;\n }", "protected function _hasModPermission(){\n global $auth;\n return $auth->acl_get('m_inttree');\n }", "public function hasRole($role)\n {\n return in_array(strtoupper($role), $this->getRoles(), true);\n }", "public function hasRole($role)\n {\n return in_array(strtoupper($role), $this->getRoles(), true);\n }", "public function hasRole($role)\n {\n return in_array(strtoupper($role), $this->getRoles(), true);\n }", "public function authorize()\n {\n return auth()->user()->hasRole('admin');\n }", "public function authorize()\n {\n return auth()->user()->hasRole('admin');\n }", "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 authorize()\n\t{\n if (!$this->auth->check())\n return false;\n if (!$this->auth->user()->can('manage_roles'))\n return false;\n\n return true;\n\t}", "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 }", "private function isOnlyRole($role = 'user') : bool\n {\n return $this->maxRole() === $role;\n }", "public function hasPrivilege($perm) {\n if ($this->role->hasPerm($perm)) {\n return true;\n }\n return false;\n }", "public function hasRole($role)\n {\n $user = $this->view->user();\n if ($user && in_array($role, $user->roles)) {\n return TRUE;\n }\n return FALSE;\n }", "private function wf_user_permission(){\n\t\t$current_user = wp_get_current_user();\n\t\t$user_ok = false;\n\t\tif ($current_user instanceof WP_User) {\n\t\t\tif (in_array('administrator', $current_user->roles) || in_array('shop_manager', $current_user->roles)) {\n\t\t\t\t$user_ok = true;\n\t\t\t}\n\t\t}\n\t\treturn $user_ok;\n\t}", "public function authorize()\n {\n\n $user = auth()->user();\n return ($user->hasRole(1)&&$user->hasStatus(3));\n }" ]
[ "0.7563469", "0.7393231", "0.73481655", "0.72912556", "0.72843385", "0.72835743", "0.72613025", "0.72395223", "0.71334106", "0.71052694", "0.7087561", "0.7084578", "0.7037995", "0.701186", "0.70054626", "0.70048094", "0.700316", "0.69555396", "0.6952666", "0.6947541", "0.6941939", "0.69208443", "0.6916316", "0.690859", "0.6863627", "0.68621147", "0.6854648", "0.6838272", "0.6820576", "0.6820241", "0.6816245", "0.68161017", "0.68133116", "0.67840624", "0.676025", "0.67400277", "0.6733363", "0.67226183", "0.6716982", "0.67069376", "0.6700239", "0.66919637", "0.6686458", "0.66789645", "0.6670884", "0.6659626", "0.6658592", "0.6650454", "0.6640816", "0.6633059", "0.66264343", "0.6624431", "0.6621359", "0.6611879", "0.6611586", "0.6607172", "0.66063595", "0.6604296", "0.66039705", "0.65938276", "0.65927577", "0.65873367", "0.6582115", "0.65791976", "0.6578133", "0.6578063", "0.6565636", "0.656275", "0.65601605", "0.65570813", "0.6554009", "0.6551855", "0.65501046", "0.6544272", "0.65424037", "0.6528842", "0.6518869", "0.6513785", "0.6508564", "0.6508564", "0.6506483", "0.6502767", "0.6495212", "0.64888453", "0.6487666", "0.6485214", "0.6485214", "0.6485214", "0.64803386", "0.64803386", "0.64771485", "0.64712614", "0.6463887", "0.6463887", "0.6463887", "0.6463887", "0.64630675", "0.64622617", "0.6458163", "0.6457616", "0.64549047" ]
0.0
-1
Retrieves a list of models based on the current search/filter conditions. Typical usecase: Initialize the model fields with values from filter form. Execute this method to get CActiveDataProvider instance which will filter models according to data in model fields. Pass data provider to CGridView, CListView or any similar widget.
public function search() { // @todo Please modify the following code to remove attributes that should not be searched. $criteria=new CDbCriteria; $criteria->compare('uid',$this->uid); $criteria->compare('username',$this->username,true); $criteria->compare('screen_name',$this->screen_name,true); $criteria->compare('password',$this->password,true); $criteria->compare('salt',$this->salt,true); $criteria->compare('sns_uid',$this->sns_uid,true); $criteria->compare('access_token',$this->access_token,true); $criteria->compare('avatar',$this->avatar,true); $criteria->compare('tel',$this->tel); $criteria->compare('gender',$this->gender,true); $criteria->compare('location',$this->location,true); $criteria->compare('role',$this->role); $criteria->compare('reg_datetime',$this->reg_datetime); return new CActiveDataProvider($this, array( 'criteria'=>$criteria, )); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t//$criteria->compare('object_id',$this->object_id);\n\t\t$criteria->compare('object_type_id',$this->object_type_id);\n\t\t$criteria->compare('data_type_id',$this->data_type_id);\n\t\t$criteria->compare('create_date',$this->create_date,true);\n\t\t$criteria->compare('client_ip',$this->client_ip,true);\n\t\t$criteria->compare('url',$this->url,true);\n\t\t$criteria->compare('url_origin',$this->url_origin,true);\n\t\t$criteria->compare('device',$this->device,true);\n\t\t$criteria->compare('country_name',$this->country_name,true);\n\t\t$criteria->compare('country_code',$this->country_code,true);\n\t\t$criteria->compare('regionName',$this->regionName,true);\n\t\t$criteria->compare('cityName',$this->cityName,true);\n\t\t$criteria->compare('browser',$this->browser,true);\n\t\t$criteria->compare('os',$this->os,true);\n\t\t\t// se agrego el filtro por el usuario actual\n\t\t$idUsuario=Yii::app()->user->getId();\n\t\t$model = Listings::model()->finbyAttributes(array('user_id'=>$idUsuario));\n\t\tif($model->id!=\"\"){\n\t\t\t$criteria->compare('object_id',$model->id);\t\n\t\t}else{\n\t\t\t$criteria->compare('object_id',\"Null\");\t\n\t\t}\n\t\t\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria=new CDbCriteria;\n\n $criteria->compare('id',$this->id);\n $criteria->compare('model_id',$this->model_id,true);\n $criteria->compare('color',$this->color,true);\n $criteria->compare('is_in_pare',$this->is_in_pare);\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('generator_id',$this->generator_id,true);\n\t\t$criteria->compare('serial_number',$this->serial_number,true);\n\t\t$criteria->compare('model_number',$this->model_number,true);\n\t\t$criteria->compare('manufacturer_name',$this->manufacturer_name,true);\n\t\t$criteria->compare('manufacture_date',$this->manufacture_date,true);\n\t\t$criteria->compare('supplier_name',$this->supplier_name,true);\n\t\t$criteria->compare('date_of_purchase',$this->date_of_purchase,true);\n\t\t$criteria->compare('date_of_first_use',$this->date_of_first_use,true);\n\t\t$criteria->compare('kva_capacity',$this->kva_capacity);\n\t\t$criteria->compare('current_run_hours',$this->current_run_hours);\n\t\t$criteria->compare('last_serviced_date',$this->last_serviced_date,true);\n\t\t$criteria->compare('engine_make',$this->engine_make,true);\n\t\t$criteria->compare('engine_model',$this->engine_model,true);\n\t\t$criteria->compare('fuel_tank_capacity',$this->fuel_tank_capacity);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('model',$this->model,true);\n\t\t$criteria->compare('idmodel',$this->idmodel);\n\t\t$criteria->compare('usuario_anterior',$this->usuario_anterior);\n\t\t$criteria->compare('usuario_nuevo',$this->usuario_nuevo);\n\t\t$criteria->compare('estado_anterior',$this->estado_anterior,true);\n\t\t$criteria->compare('estado_nuevo',$this->estado_nuevo,true);\n\t\t$criteria->compare('fecha',$this->fecha,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('model',$this->model,true);\n\t\t$criteria->compare('brand',$this->brand,true);\n\t\t$criteria->compare('status',$this->status,true);\n\t\t$criteria->compare('width',$this->width);\n\t\t$criteria->compare('height',$this->height);\n\t\t$criteria->compare('goods_thumb',$this->goods_thumb,true);\n\t\t$criteria->compare('goods_img',$this->goods_img,true);\n\t\t$criteria->compare('model_search',$this->model_search,true);\n\t\t$criteria->compare('brand_search',$this->brand_search,true);\n\t\t$criteria->compare('brand2',$this->brand2,true);\n\t\t$criteria->compare('brand2_search',$this->brand2_search,true);\n\t\t$criteria->compare('brand3',$this->brand3,true);\n\t\t$criteria->compare('brand3_search',$this->brand3_search,true);\n\t\t$criteria->compare('brand4',$this->brand4,true);\n\t\t$criteria->compare('brand4_search',$this->brand4_search,true);\n\t\t$criteria->compare('model2',$this->model2,true);\n\t\t$criteria->compare('model2_search',$this->model2_search,true);\n\t\t$criteria->compare('model3',$this->model3,true);\n\t\t$criteria->compare('model3_search',$this->model3_search,true);\n\t\t$criteria->compare('model4',$this->model4,true);\n\t\t$criteria->compare('model4_search',$this->model4_search,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('sex',$this->sex);\n\t\t$criteria->compare('car',$this->car,true);\n\t\t$criteria->compare('source_id',$this->source_id,true);\n\t\t$criteria->compare('city',$this->city,true);\n\t\t$criteria->compare('client_type_id',$this->client_type_id,true);\n\t\t$criteria->compare('create_date',$this->create_date,true);\n\t\t$criteria->compare('link',$this->link,true);\n\t\t$criteria->compare('other',$this->other,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('ID',$this->ID);\n\t\t$criteria->compare('UserID',$this->UserID);\n\t\t$criteria->compare('ProviderID',$this->ProviderID);\n\t\t$criteria->compare('Date',$this->Date,true);\n\t\t$criteria->compare('RawID',$this->RawID);\n\t\t$criteria->compare('Document',$this->Document,true);\n\t\t$criteria->compare('State',$this->State,true);\n\t\t$criteria->compare('Temperature',$this->Temperature,true);\n\t\t$criteria->compare('Conditions',$this->Conditions,true);\n\t\t$criteria->compare('Expiration',$this->Expiration,true);\n\t\t$criteria->compare('Comments',$this->Comments,true);\n\t\t$criteria->compare('Quantity',$this->Quantity,true);\n\t\t$criteria->compare('Type',$this->Type,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t\t'pagination'=>array(\n \t'pageSize'=>Yii::app()->params['defaultPageSize'], \n ),\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search() {\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t// $criteria->compare('text',$this->text,true);\n\t\t// $criteria->compare('record',$this->record,true);\n\t\t$criteria->compare('user',$this->user,true);\n\t\t$criteria->compare('createdBy',$this->createdBy,true);\n\t\t$criteria->compare('viewed',$this->viewed);\n\t\t$criteria->compare('createDate',$this->createDate,true);\n\t\t$criteria->compare('type',$this->type,true);\n\t\t$criteria->compare('comparison',$this->comparison,true);\n\t\t// $criteria->compare('value',$this->value,true);\n\t\t$criteria->compare('modelType',$this->modelType,true);\n\t\t$criteria->compare('modelId',$this->modelId,true);\n\t\t$criteria->compare('fieldName',$this->fieldName,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\r\n\t{\r\n\t\t// Warning: Please modify the following code to remove attributes that\r\n\t\t// should not be searched.\r\n\r\n\t\t$criteria=new CDbCriteria;\r\n\r\n\t\t$criteria->compare('Currency_ID',$this->Currency_ID);\n\t\t$criteria->compare('CurrencyNo',$this->CurrencyNo,true);\n\t\t$criteria->compare('ExchangeVND',$this->ExchangeVND,true);\n\t\t$criteria->compare('AppliedDate',$this->AppliedDate,true);\n\r\n\t\treturn new CActiveDataProvider($this, array(\r\n\t\t\t'criteria'=>$criteria,\r\n\t\t));\r\n\t}", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('entity_id', $this->entity_id);\n $criteria->compare('dbname', $this->dbname, true);\n $criteria->compare('isfiltered', $this->isfiltered);\n $criteria->compare('filtertype', $this->filtertype);\n $criteria->compare('alias', $this->alias, true);\n $criteria->compare('enabled', $this->enabled);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n 'pagination' => false,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('firm',$this->firm,true);\n\t\t$criteria->compare('change_date',$this->change_date,true);\n\t\t$criteria->compare('item_id',$this->item_id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('availability',$this->availability,true);\n\t\t$criteria->compare('price',$this->price,true);\n\t\t$criteria->compare('bonus',$this->bonus,true);\n\t\t$criteria->compare('shipping_cost',$this->shipping_cost,true);\n\t\t$criteria->compare('product_page',$this->product_page,true);\n\t\t$criteria->compare('sourse_page',$this->sourse_page,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('column_id',$this->column_id);\n\t\t$criteria->compare('model_id',$this->model_id);\n\t\t$criteria->compare('value',$this->value,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('type',$this->type);\n\t\t$criteria->compare('condition',$this->condition,true);\n\t\t$criteria->compare('value',$this->value,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('industry',$this->industry,true);\n\t\t$criteria->compare('industry_sub',$this->industry_sub,true);\n\t\t$criteria->compare('area',$this->area,true);\n\t\t$criteria->compare('province',$this->province,true);\n\t\t$criteria->compare('city',$this->city,true);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('contact_name',$this->contact_name,true);\n\t\t$criteria->compare('contact_tel',$this->contact_tel,true);\n\t\t$criteria->compare('ip',$this->ip,true);\n\t\t$criteria->compare('source',$this->source,true);\n $criteria->compare('status',$this->status);\n\t\t$criteria->compare('update_time',$this->update_time);\n\t\t$criteria->compare('create_time',$this->create_time);\n\t\t$criteria->compare('notes',$this->notes);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('phone',$this->phone,true);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('university',$this->university,true);\n\t\t$criteria->compare('major',$this->major,true);\n\t\t$criteria->compare('gpa',$this->gpa,true);\n\t\t$criteria->compare('appl_term',$this->appl_term);\n\t\t$criteria->compare('toefl',$this->toefl);\n\t\t$criteria->compare('gre',$this->gre);\n\t\t$criteria->compare('appl_major',$this->appl_major,true);\n\t\t$criteria->compare('appl_degree',$this->appl_degree,true);\n\t\t$criteria->compare('appl_country',$this->appl_country,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that should not be searched.\n\t\t$criteria = new \\CDbCriteria;\n\n\t\tforeach (array_keys($this->defineAttributes()) as $name)\n\t\t{\n\t\t\t$criteria->compare($name, $this->$name);\n\t\t}\n\n\t\treturn new \\CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('goods_code',$this->goods_code,true);\n\t\t$criteria->compare('type_id',$this->type_id);\n\t\t$criteria->compare('brand_id',$this->brand_id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('kind',$this->kind,true);\n\t\t$criteria->compare('color',$this->color,true);\n\t\t$criteria->compare('size',$this->size,true);\n\t\t$criteria->compare('material',$this->material,true);\n\t\t$criteria->compare('quantity',$this->quantity);\n\t\t$criteria->compare('purchase_price',$this->purchase_price,true);\n\t\t$criteria->compare('selling_price',$this->selling_price,true);\n\t\t$criteria->compare('status',$this->status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('model',$this->model,true);\n\t\t$criteria->compare('model_id',$this->model_id);\n\t\t$criteria->compare('meta_title',$this->meta_title,true);\n\t\t$criteria->compare('meta_keywords',$this->meta_keywords,true);\n\t\t$criteria->compare('meta_description',$this->meta_description,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('ContractsDetailID',$this->ContractsDetailID,true);\n\t\t$criteria->compare('ContractID',$this->ContractID,true);\n\t\t$criteria->compare('Type',$this->Type,true);\n\t\t$criteria->compare('CustomerID',$this->CustomerID,true);\n\t\t$criteria->compare('Share',$this->Share);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\n\t\t$criteria->compare('type_key',$this->type_key,true);\n\n\t\t$criteria->compare('type_name',$this->type_name,true);\n\n\t\t$criteria->compare('model',$this->model,true);\n\n\t\t$criteria->compare('status',$this->status,true);\n\t\t\n\t\t$criteria->compare('seo_title',$this->seo_title,true);\n\t\t\n\t\t$criteria->compare('seo_keywords',$this->seo_keywords,true);\n\t\t\n\t\t$criteria->compare('seo_description',$this->seo_description,true);\n\n\t\treturn new CActiveDataProvider('ModelType', array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search() {\r\n\t\t// Warning: Please modify the following code to remove attributes that\r\n\t\t// should not be searched.\r\n\r\n\t\t$criteria = $this->criteriaSearch();\r\n\t\t$criteria->limit = 10;\r\n\r\n\t\treturn new CActiveDataProvider($this, array(\r\n\t\t\t'criteria' => $criteria,\r\n\t\t));\r\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('organizationName',$this->organizationName,true);\n\t\t$criteria->compare('contactNo',$this->contactNo,true);\n\t\t$criteria->compare('partnerType',$this->partnerType);\n\t\t$criteria->compare('city',$this->city,true);\n\t\t$criteria->compare('area',$this->area,true);\n\t\t$criteria->compare('category',$this->category,true);\n\t\t$criteria->compare('emailId',$this->emailId,true);\n\t\t$criteria->compare('password',$this->password,true);\n\t\t$criteria->compare('firstName',$this->firstName,true);\n\t\t$criteria->compare('lastName',$this->lastName,true);\n\t\t$criteria->compare('gender',$this->gender,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare(Globals::FLD_NAME_ACTIVITY_ID,$this->{Globals::FLD_NAME_ACTIVITY_ID},true);\n\t\t$criteria->compare(Globals::FLD_NAME_TASK_ID,$this->{Globals::FLD_NAME_TASK_ID},true);\n\t\t$criteria->compare(Globals::FLD_NAME_BY_USER_ID,$this->{Globals::FLD_NAME_BY_USER_ID},true);\n\t\t$criteria->compare(Globals::FLD_NAME_ACTIVITY_TYPE,$this->{Globals::FLD_NAME_ACTIVITY_TYPE},true);\n\t\t$criteria->compare(Globals::FLD_NAME_ACTIVITY_SUBTYPE,$this->{Globals::FLD_NAME_ACTIVITY_SUBTYPE},true);\n\t\t$criteria->compare(Globals::FLD_NAME_COMMENTS,$this->{Globals::FLD_NAME_COMMENTS},true);\n\t\t$criteria->compare(Globals::FLD_NAME_CREATED_AT,$this->{Globals::FLD_NAME_CREATED_AT},true);\n\t\t$criteria->compare(Globals::FLD_NAME_SOURCE_APP,$this->{Globals::FLD_NAME_SOURCE_APP},true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('manufacturers_image',$this->manufacturers_image,true);\n\t\t$criteria->compare('date_added',$this->date_added);\n\t\t$criteria->compare('last_modified',$this->last_modified);\n\t\t$criteria->compare('url',$this->url,true);\n\t\t$criteria->compare('url_clicked',$this->url_clicked);\n\t\t$criteria->compare('date_last_click',$this->date_last_click);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('type_id',$this->type_id);\n\t\t$criteria->compare('user_id',$this->user_id);\n\t\t$criteria->compare('date',$this->date);\n\t\t$criteria->compare('del',$this->del);\n\t\t$criteria->compare('action_id',$this->action_id);\n\t\t$criteria->compare('item_id',$this->item_id);\n\t\t$criteria->compare('catalog',$this->catalog,true);\n\t\t$criteria->compare('is_new',$this->is_new);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('case',$this->case);\n\t\t$criteria->compare('basis_doc',$this->basis_doc);\n\t\t$criteria->compare('calc_group',$this->calc_group);\n\t\t$criteria->compare('time',$this->time,true);\n\t\t$criteria->compare('value',$this->value,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('create_date',$this->create_date,true);\n\t\t$criteria->compare('competition',$this->competition);\n\t\t$criteria->compare('partner',$this->partner);\n\t\t$criteria->compare('country',$this->country,true);\n\t\t$criteria->compare('website',$this->website,true);\t\t\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('data_attributes_fields',$this->data_attributes_fields,true);\n\t\t$criteria->compare('is_active',$this->is_active);\n\t\t$criteria->compare('created',$this->created,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('skill_id',$this->skill_id);\n\t\t$criteria->compare('model_id',$this->model_id);\n\t\t$criteria->compare('account_id',$this->account_id);\n\t\t$criteria->compare('field_name',$this->field_name);\n\t\t$criteria->compare('content',$this->content);\n\t\t$criteria->compare('old_data',$this->old_data,true);\n\t\t$criteria->compare('new_data',$this->new_data,true);\n\t\t$criteria->compare('status',$this->status);\n\t\t$criteria->compare('type',$this->type);\n\t\t$criteria->compare('date_created',$this->date_created,true);\n\t\t$criteria->compare('date_updated',$this->date_updated,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('company_id',$this->company_id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('type',$this->type,true);\n\t\t$criteria->compare('validator',$this->validator,true);\n\t\t$criteria->compare('position',$this->position);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n $criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id', $this->id);\n\t\t$criteria->compare('display_name',$this->display_name,true);\n $criteria->compare('actionPrice',$this->actionPrice);\n\t\t$criteria->compare('translit',$this->translit,true);\n\t\t$criteria->compare('title',$this->title,true);\n\t\t$criteria->compare('display_description',$this->display_description,true);\n\t\t$criteria->compare('meta_keywords',$this->meta_keywords,true);\n\t\t$criteria->compare('meta_description',$this->meta_description,true);\n\t\t$criteria->compare('editing',$this->editing);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n 'pagination' => array(\n 'pageSize' => 15,\n ),\n\t\t));\n\t}", "public function search() {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('BrandID', $this->BrandID);\n $criteria->compare('BrandName', $this->BrandName, true);\n $criteria->compare('Pinyin', $this->Pinyin, true);\n $criteria->compare('Remarks', $this->Remarks, true);\n $criteria->compare('OrganID', $this->OrganID);\n $criteria->compare('UserID', $this->UserID);\n $criteria->compare('CreateTime', $this->CreateTime);\n $criteria->compare('UpdateTime', $this->UpdateTime);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria = new CDbCriteria;\n\n\t\t$criteria->compare('id', $this->id);\n\t\t$criteria->compare('code', $this->code, true);\n\t\t$criteria->compare('name', $this->name, true);\n\t\t$criteria->compare('printable_name', $this->printable_name, true);\n\t\t$criteria->compare('iso3', $this->iso3, true);\n\t\t$criteria->compare('numcode', $this->numcode);\n\t\t$criteria->compare('is_default', $this->is_default);\n\t\t$criteria->compare('is_highlight', $this->is_highlight);\n\t\t$criteria->compare('is_active', $this->is_active);\n\t\t$criteria->compare('date_added', $this->date_added);\n\t\t$criteria->compare('date_modified', $this->date_modified);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('componente_id',$this->componente_id);\n\t\t$criteria->compare('tipo_dato',$this->tipo_dato,true);\n\t\t$criteria->compare('descripcion',$this->descripcion,true);\n\t\t$criteria->compare('cruce_automatico',$this->cruce_automatico,true);\n\t\t$criteria->compare('sw_obligatorio',$this->sw_obligatorio,true);\n\t\t$criteria->compare('orden',$this->orden);\n\t\t$criteria->compare('sw_puntaje',$this->sw_puntaje,true);\n\t\t$criteria->compare('sw_estado',$this->sw_estado,true);\n\t\t$criteria->compare('todos_obligatorios',$this->todos_obligatorios,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\r\n\t{\r\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\r\n\r\n\t\t$criteria=new CDbCriteria;\r\n\r\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('user_id',$this->user_id);\n\t\t$criteria->compare('real_name',$this->real_name,true);\n\t\t$criteria->compare('mobile',$this->mobile,true);\n\t\t$criteria->compare('zip_code',$this->zip_code,true);\n\t\t$criteria->compare('province_id',$this->province_id);\n\t\t$criteria->compare('city_id',$this->city_id);\n\t\t$criteria->compare('district_id',$this->district_id);\n\t\t$criteria->compare('district_address',$this->district_address,true);\n\t\t$criteria->compare('street_address',$this->street_address,true);\n\t\t$criteria->compare('is_default',$this->is_default);\n\t\t$criteria->compare('create_time',$this->create_time);\n\t\t$criteria->compare('update_time',$this->update_time);\n\r\n\t\treturn new CActiveDataProvider($this, array(\r\n\t\t\t'criteria'=>$criteria,\r\n\t\t));\r\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('EMCE_ID',$this->EMCE_ID);\n\t\t$criteria->compare('MOOR_ID',$this->MOOR_ID);\n\t\t$criteria->compare('EVCR_ID',$this->EVCR_ID);\n\t\t$criteria->compare('EVES_ID',$this->EVES_ID);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('customerName',$this->customerName,true);\n\t\t$criteria->compare('agencyHead',$this->agencyHead,true);\n\t\t$criteria->compare('region_id',$this->region_id);\n\t\t$criteria->compare('province_id',$this->province_id);\n\t\t$criteria->compare('municipalityCity_id',$this->municipalityCity_id);\n\t\t$criteria->compare('barangay_id',$this->barangay_id);\n\t\t$criteria->compare('houseNumber',$this->houseNumber,true);\n\t\t$criteria->compare('tel',$this->tel,true);\n\t\t$criteria->compare('fax',$this->fax,true);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('type_id',$this->type_id);\n\t\t$criteria->compare('nature_id',$this->nature_id);\n\t\t$criteria->compare('industry_id',$this->industry_id);\n\t\t$criteria->compare('created_by',$this->created_by);\n\t\t$criteria->compare('create_time',$this->create_time,true);\n\t\t$criteria->compare('update_time',$this->update_time,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('type',$this->name,true);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('state',$this->address,true);\n\t\t$criteria->compare('country',$this->address,true);\n\t\t$criteria->compare('contact_number',$this->contact_number,true);\n\t\t$criteria->compare('created_by',$this->created_by,true);\n\t\t$criteria->compare('is_deleted',$this->is_deleted);\n\t\t$criteria->compare('deleted_by',$this->deleted_by,true);\n\t\t$criteria->compare('created_at',$this->created_at,true);\n\t\t$criteria->compare('updated_at',$this->updated_at,true);\n\t\tif(YII::app()->user->getState(\"role\") == \"admin\") {\n\t\t\t$criteria->condition = 'is_deleted = 0';\n\t\t}\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('user_id',$this->user_id);\n\t\t$criteria->compare('industry_id',$this->industry_id);\n\t\t$criteria->compare('professional_status_id',$this->professional_status);\n\t\t$criteria->compare('birthday',$this->birthday);\n\t\t$criteria->compare('location',$this->location);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n {\n // Warning: Please modify the following code to remove attributes that\n // should not be searched.\n\n $criteria=$this->criteriaSearch();\n $criteria->limit=10;\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search()\n\t{\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('type',$this->type,true);\n\t\t$criteria->compare('memo',$this->memo,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\r\r\n\t{\r\r\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\r\r\n\r\r\n\t\t$criteria=new CDbCriteria;\r\r\n\r\r\n\t\t$criteria->compare('id',$this->id);\r\r\n\t\t$criteria->compare('user_id',$this->user_id);\r\r\n\t\t$criteria->compare('adds',$this->adds);\r\r\n\t\t$criteria->compare('edits',$this->edits);\r\r\n\t\t$criteria->compare('deletes',$this->deletes);\r\r\n\t\t$criteria->compare('view',$this->view);\r\r\n\t\t$criteria->compare('lists',$this->lists);\r\r\n\t\t$criteria->compare('searches',$this->searches);\r\r\n\t\t$criteria->compare('prints',$this->prints);\r\r\n\r\r\n\t\treturn new CActiveDataProvider($this, array(\r\r\n\t\t\t'criteria'=>$criteria,\r\r\n\t\t));\r\r\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('applyId',$this->applyId);\n\t\t$criteria->compare('stuId',$this->stuId);\n\t\t$criteria->compare('stuName',$this->stuName,true);\n\t\t$criteria->compare('specification',$this->specification,true);\n\t\t$criteria->compare('assetName',$this->assetName,true);\n\t\t$criteria->compare('applyTime',$this->applyTime,true);\n\t\t$criteria->compare('loanTime',$this->loanTime,true);\n\t\t$criteria->compare('returnTime',$this->returnTime,true);\n\t\t$criteria->compare('RFID',$this->RFID,true);\n\t\t$criteria->compare('stuTelNum',$this->stuTelNum,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria=$this->getBaseCDbCriteria();\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('itemcode', $this->itemcode, true);\n $criteria->compare('product_id', $this->product_id, true);\n $criteria->compare('delete_flag', $this->delete_flag);\n $criteria->compare('status', $this->status);\n $criteria->compare('expire', $this->expire, true);\n $criteria->compare('date_input', $this->date_input, true);\n $criteria->compare('d_update', $this->d_update, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('verid',$this->verid);\n\t\t$criteria->compare('appversion',$this->appversion,true);\n\t\t$criteria->compare('appfeatures',$this->appfeatures,true);\n\t\t$criteria->compare('createtime',$this->createtime,true);\n\t\t$criteria->compare('baseNum',$this->baseNum);\n\t\t$criteria->compare('slave1Num',$this->slave1Num);\n\t\t$criteria->compare('packagename',$this->packagename,true);\n\t\t$criteria->compare('ostype',$this->ostype);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('client_id',$this->client_id,true);\n\t\t$criteria->compare('extension',$this->extension,true);\n\t\t$criteria->compare('rel_type',$this->rel_type,true);\n\t\t$criteria->compare('rel_id',$this->rel_id,true);\n\t\t$criteria->compare('meta_key',$this->meta_key,true);\n\t\t$criteria->compare('meta_value',$this->meta_value,true);\n\t\t$criteria->compare('date_entry',$this->date_entry,true);\n\t\t$criteria->compare('date_update',$this->date_update,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('column_id',$this->column_id,true);\n\t\t$criteria->compare('research_title',$this->research_title,true);\n\t\t$criteria->compare('research_url',$this->research_url,true);\n\t\t$criteria->compare('column_type',$this->column_type);\n\t\t$criteria->compare('filiale_id',$this->filiale_id,true);\n\t\t$criteria->compare('area_name',$this->area_name,true);\n\t\t$criteria->compare('user_id',$this->user_id);\n\t\t$criteria->compare('trigger_config',$this->trigger_config);\n\t\t$criteria->compare('status',$this->status);\n $criteria->compare('terminal_type',$this->terminal_type);\n\t\t$criteria->compare('start_time',$this->start_time,true);\n\t\t$criteria->compare('end_time',$this->end_time,true);\n\t\t$criteria->compare('explain',$this->explain,true);\n\t\t$criteria->compare('_delete',$this->_delete);\n\t\t$criteria->compare('_create_time',$this->_create_time,true);\n\t\t$criteria->compare('_update_time',$this->_update_time,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function backendSearch()\n {\n $criteria = new CDbCriteria();\n\n return new CActiveDataProvider(\n __CLASS__,\n array(\n 'criteria' => $criteria,\n )\n );\n }", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('city',$this->city,true);\n\t\t$criteria->compare('birthday',$this->birthday,true);\n\t\t$criteria->compare('sex',$this->sex);\n\t\t$criteria->compare('photo',$this->photo,true);\n\t\t$criteria->compare('is_get_news',$this->is_get_news);\n\t\t$criteria->compare('user_id',$this->user_id);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('tbl_customer_supplier', $this->tbl_customer_supplier, true);\n $criteria->compare('id_customer', $this->id_customer, true);\n $criteria->compare('id_supplier', $this->id_supplier, true);\n $criteria->compare('title', $this->title, true);\n $criteria->compare('date_add', $this->date_add, true);\n $criteria->compare('date_upd', $this->date_upd, true);\n $criteria->compare('active', $this->active);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('order_id',$this->order_id);\n\t\t$criteria->compare('device_id',$this->device_id,true);\n\t\t$criteria->compare('money',$this->money,true);\n\t\t$criteria->compare('status',$this->status);\n\t\t$criteria->compare('add_time',$this->add_time);\n\t\t$criteria->compare('recharge_type',$this->recharge_type);\n\t\t$criteria->compare('channel',$this->channel,true);\n\t\t$criteria->compare('version_name',$this->version_name,true);\n\t\t$criteria->compare('pay_channel',$this->pay_channel);\n\t\t$criteria->compare('chanel_bid',$this->chanel_bid);\n\t\t$criteria->compare('chanel_sid',$this->chanel_sid);\n\t\t$criteria->compare('versionid',$this->versionid);\n\t\t$criteria->compare('chanel_web',$this->chanel_web);\n\t\t$criteria->compare('dem_num',$this->dem_num);\n\t\t$criteria->compare('last_watching',$this->last_watching,true);\n\t\t$criteria->compare('pay_type',$this->pay_type);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\r\n {\r\n // @todo Please modify the following code to remove attributes that should not be searched.\r\n\r\n $criteria = new CDbCriteria;\r\n\r\n $criteria->compare('id', $this->id);\r\n $criteria->compare('country_id', $this->country_id);\r\n $criteria->compare('user_id', $this->user_id);\r\n $criteria->compare('vat', $this->vat);\r\n $criteria->compare('manager_coef', $this->manager_coef);\r\n $criteria->compare('curator_coef', $this->curator_coef);\r\n $criteria->compare('admin_coef', $this->admin_coef);\r\n $criteria->compare('status', $this->status);\r\n\r\n return new CActiveDataProvider($this, array(\r\n 'criteria' => $criteria,\r\n ));\r\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('code',$this->code,true);\n\t\t$criteria->compare('purchase_price',$this->purchase_price);\n\t\t$criteria->compare('sell_price',$this->sell_price);\n\t\t$criteria->compare('amount',$this->amount);\n\t\t$criteria->compare('measurement',$this->measurement,true);\n\t\t$criteria->compare('date_create',$this->date_create,true);\n\t\t$criteria->compare('date_update',$this->date_update,true);\n\t\t$criteria->compare('date_out',$this->date_out,true);\n\t\t$criteria->compare('date_in',$this->date_in,true);\n\t\t$criteria->compare('firma_id',$this->firma_id,true);\n\t\t$criteria->compare('image_url',$this->image_url,true);\n\t\t$criteria->compare('instock',$this->instock);\n\t\t$criteria->compare('user_id',$this->user_id);\n $criteria->compare('warning_amount',$this->warning_amount);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('fname',$this->fname,true);\n\t\t$criteria->compare('mname',$this->mname,true);\n\t\t$criteria->compare('lname',$this->lname,true);\n\t\t$criteria->compare('photo',$this->photo,true);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('gender',$this->gender,true);\n\t\t$criteria->compare('date_of_birth',$this->date_of_birth,true);\n\t\t$criteria->compare('mobile',$this->mobile,true);\n\t\t$criteria->compare('landline',$this->landline,true);\n\t\t$criteria->compare('em_contact_name',$this->em_contact_name,true);\n\t\t$criteria->compare('em_contact_relation',$this->em_contact_relation,true);\n\t\t$criteria->compare('em_contact_number',$this->em_contact_number,true);\n\t\t$criteria->compare('created_by',$this->created_by,true);\n\t\t$criteria->compare('created_date',$this->created_date,true);\n\n return new CActiveDataProvider( $this, array(\n 'criteria' => $criteria,\n 'pagination' => array(\n 'pageSize' => Yii::app()->user->getState( 'pageSize', Yii::app()->params[ 'defaultPageSize' ] ),\n ),\n ) );\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\t\t\n\t\t$criteria=new CDbCriteria;\n\t\t\n\t\t$criteria->compare('COMPETITOR_ID',$this->COMPETITOR_ID);\n\t\t$criteria->compare('WSDC_NO',$this->WSDC_NO);\n\t\t$criteria->compare('FIRST_NAME',$this->FIRST_NAME,true);\n\t\t$criteria->compare('LAST_NAME',$this->LAST_NAME,true);\n\t\t$criteria->compare('COMPETITOR_LEVEL',$this->COMPETITOR_LEVEL);\n\t\t$criteria->compare('REMOVED',$this->REMOVED);\n\t\t$criteria->compare('ADDRESS',$this->ADDRESS,true);\n\t\t$criteria->compare('CITY',$this->CITY,true);\n\t\t$criteria->compare('STATE',$this->STATE,true);\n\t\t$criteria->compare('POSTCODE',$this->POSTCODE);\n\t\t$criteria->compare('COUNTRY',$this->COUNTRY,true);\n\t\t$criteria->compare('PHONE',$this->PHONE,true);\n\t\t$criteria->compare('MOBILE',$this->MOBILE,true);\n\t\t$criteria->compare('EMAIL',$this->EMAIL,true);\n\t\t$criteria->compare('LEADER',$this->LEADER);\n\t\t$criteria->compare('REGISTERED',$this->REGISTERED);\n\t\t$criteria->compare('BIB_STATUS',$this->BIB_STATUS);\n\t\t$criteria->compare('BIB_NUMBER',$this->BIB_NUMBER);\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('sys_name',$this->sys_name,true);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('status',$this->status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('CustomerId',$this->CustomerId,true);\n\t\t$criteria->compare('AddressId',$this->AddressId,true);\n\t\t$criteria->compare('CustomerStatusId',$this->CustomerStatusId,true);\n\t\t$criteria->compare('DateMasterId',$this->DateMasterId,true);\n\t\t$criteria->compare('FirstName',$this->FirstName,true);\n\t\t$criteria->compare('LastName',$this->LastName,true);\n\t\t$criteria->compare('CustomerPhoto',$this->CustomerPhoto,true);\n\t\t$criteria->compare('CustomerCode',$this->CustomerCode);\n\t\t$criteria->compare('Telephone',$this->Telephone,true);\n\t\t$criteria->compare('Mobile',$this->Mobile,true);\n\t\t$criteria->compare('EmailId',$this->EmailId,true);\n\t\t$criteria->compare('Status',$this->Status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria = new CDbCriteria;\n\n\t\t$criteria->compare('id', $this->id);\n\t\t$criteria->compare('company_id', $this->company_id);\n\t\t$criteria->compare('productId', $this->productId);\n\t\t$criteria->compare('upTo', $this->upTo);\n\t\t$criteria->compare('fixPrice', $this->fixPrice);\n\t\t$criteria->compare('isActive', $this->isActive);\n\t\t$criteria->order = 'company_id';\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t\t\t'criteria' => $criteria,\n\t\t\t\t));\n\t}", "public function search() {\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$parameters = array('limit'=>ceil(Profile::getResultsPerPage()));\n\t\t$criteria->scopes = array('findAll'=>array($parameters));\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('type',$this->type,true);\n\t\t$criteria->compare('itemId',$this->itemId);\n\t\t$criteria->compare('changedBy',$this->changedBy,true);\n\t\t$criteria->compare('recordName',$this->recordName,true);\n\t\t$criteria->compare('fieldName',$this->fieldName,true);\n\t\t$criteria->compare('oldValue',$this->oldValue,true);\n\t\t$criteria->compare('newValue',$this->newValue,true);\n\t\t$criteria->compare('diff',$this->diff,true);\n\t\t$criteria->compare('timestamp',$this->timestamp);\n\n\t\treturn new SmartActiveDataProvider(get_class($this), array(\n\t\t\t'sort'=>array(\n\t\t\t\t'defaultOrder'=>'timestamp DESC',\n\t\t\t),\n\t\t\t'pagination'=>array(\n\t\t\t\t'pageSize'=>Profile::getResultsPerPage(),\n\t\t\t),\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('city_id',$this->city_id);\n\t\t$criteria->compare('locality',$this->locality,true);\n\t\t$criteria->compare('status',$this->status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\r\n\t{\r\n\t\t// Warning: Please modify the following code to remove attributes that\r\n\t\t// should not be searched.\r\n\r\n\t\t$criteria=new CDbCriteria;\r\n\r\n\t\t$criteria->compare('id',$this->id);\r\n\t\t$criteria->compare('user_id',$this->user_id);\r\n\t\t$criteria->compare('mem_type',$this->mem_type);\r\n\t\t$criteria->compare('business_type',$this->business_type);\r\n\t\t$criteria->compare('product_name',$this->product_name,true);\r\n\t\t$criteria->compare('panit',$this->panit,true);\r\n\t\t$criteria->compare('sex',$this->sex);\r\n\t\t$criteria->compare('tname',$this->tname);\r\n\t\t$criteria->compare('ftname',$this->ftname,true);\r\n\t\t$criteria->compare('ltname',$this->ltname,true);\r\n\t\t$criteria->compare('etname',$this->etname);\r\n\t\t$criteria->compare('fename',$this->fename,true);\r\n\t\t$criteria->compare('lename',$this->lename,true);\r\n\t\t$criteria->compare('birth',$this->birth,true);\r\n\t\t$criteria->compare('email',$this->email,true);\r\n\t\t$criteria->compare('facebook',$this->facebook,true);\r\n\t\t$criteria->compare('twitter',$this->twitter,true);\r\n\t\t$criteria->compare('address',$this->address,true);\r\n\t\t$criteria->compare('province',$this->province);\r\n\t\t$criteria->compare('prefecture',$this->prefecture);\r\n\t\t$criteria->compare('district',$this->district);\r\n\t\t$criteria->compare('postcode',$this->postcode,true);\r\n\t\t$criteria->compare('tel',$this->tel,true);\r\n\t\t$criteria->compare('mobile',$this->mobile,true);\r\n\t\t$criteria->compare('fax',$this->fax,true);\r\n\t\t$criteria->compare('high_education',$this->high_education);\r\n\t\t$criteria->compare('career',$this->career);\r\n\t\t$criteria->compare('skill_com',$this->skill_com);\r\n\t\t$criteria->compare('receive_news',$this->receive_news,true);\r\n\r\n\t\treturn new CActiveDataProvider($this, array(\r\n\t\t\t'criteria'=>$criteria,\r\n\t\t));\r\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('item_id',$this->item_id);\n\t\t$criteria->compare('table_id',$this->table_id);\n\t\t$criteria->compare('status',$this->status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('cou_id',$this->cou_id);\n\t\t$criteria->compare('thm_id',$this->thm_id);\n\t\t$criteria->compare('cou_nom',$this->cou_nom,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria=$this->getBaseCDbCriteria();\n\n return new CActiveDataProvider($this, array(\n 'criteria'=>$criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n// $criteria->compare('name', $this->name, true);\n $criteria->compare('description', $this->description, true);\n// $criteria->compare('alias', $this->alias, true);\n// $criteria->compare('module', $this->module, true);\n $criteria->compare('crud', $this->crud, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('idempleo',$this->idempleo);\n\t\t$criteria->compare('administrativo',$this->administrativo,true);\n\t\t$criteria->compare('comercial',$this->comercial,true);\n\t\t$criteria->compare('artes',$this->artes,true);\n\t\t$criteria->compare('informatica',$this->informatica,true);\n\t\t$criteria->compare('salud',$this->salud,true);\n\t\t$criteria->compare('marketing',$this->marketing,true);\n\t\t$criteria->compare('servicio_domestico',$this->servicio_domestico,true);\n\t\t$criteria->compare('construccion',$this->construccion,true);\n\t\t$criteria->compare('agricultura',$this->agricultura,true);\n\t\t$criteria->compare('ganaderia',$this->ganaderia,true);\n\t\t$criteria->compare('telecomunicaciones',$this->telecomunicaciones,true);\n\t\t$criteria->compare('atencion_cliente',$this->atencion_cliente,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('ID_VALOR',$this->ID_VALOR);\n\t\t$criteria->compare('ID_UBICACION',$this->ID_UBICACION);\n\t\t$criteria->compare('ID_VISITA',$this->ID_VISITA);\n\t\t$criteria->compare('VALOR',$this->VALOR);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t\n\t\t$criteria->compare('id_aspecto',$this->id_aspecto,true);\n\t\t$criteria->compare('tbl_Programa_id_programa',$this->tbl_Programa_id_programa,true);\n\t\t$criteria->compare('tbl_Factor_id_factor',$this->tbl_Factor_id_factor);\n\t\t$criteria->compare('tbl_caracteristica_id_caracteristica',$this->tbl_caracteristica_id_caracteristica,true);\n\t\t$criteria->compare('num_aspecto',$this->num_aspecto,true);\n\t\t$criteria->compare('aspecto',$this->aspecto,true);\n\t\t$criteria->compare('instrumento',$this->instrumento,true);\n\t\t$criteria->compare('fuente',$this->fuente,true);\n\t\t$criteria->compare('documento',$this->documento,true);\n\t\t$criteria->compare('link',$this->link,true);\n\t\t$criteria->compare('Observaciones',$this->Observaciones,true);\n\t\t$criteria->compare('cumple',$this->cumple,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t\t\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('sex',$this->sex,true);\n\t\t$criteria->compare('website_url',$this->website_url,true);\n\t\t$criteria->compare('summary',$this->summary,true);\n\t\t$criteria->compare('user_name',$this->user_name,true);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('password',$this->password,true);\n\t\t$criteria->compare('created_datetime',$this->created_datetime,true);\n\t\t$criteria->compare('icon_src',$this->icon_src,true);\n\t\t$criteria->compare('show_r18',$this->show_r18);\n\t\t$criteria->compare('show_bl',$this->show_bl);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('creationDate',$this->creationDate,true);\n\t\t$criteria->compare('year',$this->year);\n\t\t$criteria->compare('term',$this->term,true);\n\t\t$criteria->compare('activated',$this->activated);\n\t\t$criteria->compare('startingDate',$this->startingDate,true);\n\t\t$criteria->compare('activation_userId',$this->activation_userId);\n\t\t$criteria->compare('parent_catalogId',$this->parent_catalogId);\n $criteria->compare('isProspective', $this->isProspective);\n $criteria->compare('creatorId', $this->creatorId);\n $criteria->compare('isProposed', $this->isProposed);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('FirstName',$this->FirstName,true);\n\t\t$criteria->compare('LastName',$this->LastName,true);\n\t\t$criteria->compare('location',$this->location);\n\t\t$criteria->compare('theripiest',$this->theripiest);\n\t\t$criteria->compare('phone',$this->phone,true);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('gender',$this->gender,true);\n\t\t$criteria->compare('dob',$this->dob,true);\n\t\t$criteria->compare('inurancecompany',$this->inurancecompany,true);\n\t\t$criteria->compare('injurydate',$this->injurydate,true);\n\t\t$criteria->compare('therapy_start_date',$this->therapy_start_date,true);\n\t\t$criteria->compare('ASIA',$this->ASIA,true);\n\t\t$criteria->compare('injury',$this->injury,true);\n\t\t$criteria->compare('medication',$this->medication,true);\n\t\t$criteria->compare('notes',$this->notes,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search () {\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria = new CDbCriteria;\n\n\t\t$criteria->compare('formId', $this->formId, true);\n\t\t$criteria->compare('data', $this->data, true);\n\t\t$criteria->compare('ctime', $this->ctime);\n\t\t$criteria->compare('mtime', $this->mtime);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t 'criteria' => $criteria,\n\t\t ));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('imputetype_id',$this->imputetype_id);\n\t\t$criteria->compare('project_id',$this->project_id);\n\n\t\treturn new ActiveDataProvider(get_class($this), array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('category_id',$this->category_id);\n\t\t$criteria->compare('amount',$this->amount);\n\t\t$criteria->compare('price_z',$this->price_z);\n\t\t$criteria->compare('price_s',$this->price_s);\n\t\t$criteria->compare('price_m',$this->price_m);\n\t\t$criteria->compare('dependence',$this->dependence,true);\n\t\t$criteria->compare('barcode',$this->barcode,true);\n\t\t$criteria->compare('unit',$this->unit,true);\n\t\t$criteria->compare('minimal_amount',$this->minimal_amount);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n 'pagination' => array('pageSize' => 100),\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('image',$this->image,true);\n\t\t$criteria->compare('manager',$this->manager);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('tel',$this->tel,true);\n\t\t$criteria->compare('realname',$this->realname,true);\n\t\t$criteria->compare('identity',$this->identity,true);\n\t\t$criteria->compare('mobile',$this->mobile,true);\n\t\t$criteria->compare('bussiness_license',$this->bussiness_license,true);\n\t\t$criteria->compare('bankcode',$this->bankcode,true);\n\t\t$criteria->compare('banktype',$this->banktype,true);\n\t\t$criteria->compare('is_open',$this->is_open,true);\n\t\t$criteria->compare('introduction',$this->introduction,true);\n\t\t$criteria->compare('images_str',$this->images_str,true);\n\t\t$criteria->compare('gmt_created',$this->gmt_created,true);\n\t\t$criteria->compare('gmt_modified',$this->gmt_modified,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('id_user',$this->id_user);\n\t\t$criteria->compare('url',$this->url,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('email_admin',$this->email_admin,true);\n\t\t$criteria->compare('password_api',$this->password_api,true);\n\t\t$criteria->compare('url_result_api',$this->url_result_api,true);\n\t\t$criteria->compare('id_currency_2',$this->id_currency_2);\n\t\t$criteria->compare('id_currency_1',$this->id_currency_1,true);\n\t\t$criteria->compare('is_test_mode',$this->is_test_mode);\n\t\t$criteria->compare('is_commission_shop',$this->is_commission_shop);\n\t\t$criteria->compare('commission',$this->commission);\n\t\t$criteria->compare('is_enable',$this->is_enable);\n\t\t$criteria->compare('is_active',$this->is_active);\n\t\t$criteria->compare('create_date',$this->create_date,true);\n\t\t$criteria->compare('mod_date',$this->mod_date,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('ID',$this->ID,true);\n\t\t$criteria->compare('userID',$this->userID,true);\n\t\t$criteria->compare('mtID',$this->mtID,true);\n\t\t$criteria->compare('fxType',$this->fxType);\n\t\t$criteria->compare('leverage',$this->leverage);\n\t\t$criteria->compare('amount',$this->amount,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\t\t/*\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('percent_discount',$this->percent_discount,true);\n\t\t$criteria->compare('taxable',$this->taxable);\n\t\t$criteria->compare('id_user_created',$this->id_user_created);\n\t\t$criteria->compare('id_user_modified',$this->id_user_modified);\n\t\t$criteria->compare('date_created',$this->date_created,true);\n\t\t$criteria->compare('date_modified',$this->date_modified,true);\n\n\t\treturn new CActiveDataProvider(get_class($this), array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t\t*/\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('surname',$this->surname,true);\n\t\t$criteria->compare('comany_name',$this->comany_name,true);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('password',$this->password,true);\n\t\t$criteria->compare('phone',$this->phone,true);\n\t\t$criteria->compare('uuid',$this->uuid,true);\n\t\t$criteria->compare('is_admin',$this->is_admin);\n\t\t$criteria->compare('paid_period_start',$this->paid_period_start,true);\n\t\t$criteria->compare('ftp_pass',$this->ftp_pass,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('price',$this->price,true);\n\n\t\t$criteria->compare('type',$this->type,true);\n\t\t$criteria->compare('breed',$this->breed,true);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('date_birthday',$this->date_birthday,true);\n\t\t$criteria->compare('sex',$this->sex,true);\n\t\t$criteria->compare('color',$this->color,true);\n\t\t$criteria->compare('tattoo',$this->tattoo,true);\n\t\t$criteria->compare('sire',$this->sire,true);\n\t\t$criteria->compare('dame',$this->dame,true);\n\t\t$criteria->compare('owner_type',$this->owner_type,true);\n\t\t$criteria->compare('honors',$this->honors,true);\n\t\t$criteria->compare('photo_preview',$this->photo_preview,true);\n\t\t$criteria->compare('date_created',$this->date_created,true);\n\t\t$criteria->compare('pet_status',$this->pet_status,true);\n\t\t$criteria->compare('about',$this->about,true);\n\t\t$criteria->compare('uid',$this->uid);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('veterinary',$this->veterinary,true);\n\t\t$criteria->compare('vaccinations',$this->vaccinations,true);\n\t\t$criteria->compare('show_class',$this->show_class,true);\n\t\t$criteria->compare('certificate',$this->certificate,true);\n $criteria->compare('neutered_spayed',$this->certificate,true);\n \n\n $criteria->compare('country',$this->country,true);\n\t\t$criteria->compare('city',$this->city,true);\n\n \n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('ID',$this->ID);\n\t\t$criteria->compare('HISTORY',$this->HISTORY,true);\n\t\t$criteria->compare('WELCOME_MESSAGE',$this->WELCOME_MESSAGE,true);\n\t\t$criteria->compare('LOCATION',$this->LOCATION,true);\n\t\t$criteria->compare('PHONES',$this->PHONES,true);\n\t\t$criteria->compare('FAX',$this->FAX,true);\n\t\t$criteria->compare('EMAIL',$this->EMAIL,true);\n\t\t$criteria->compare('MISSION',$this->MISSION,true);\n\t\t$criteria->compare('VISION',$this->VISION,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id, true);\n $criteria->compare('company_id', Yii::app()->user->company_id);\n $criteria->compare('zone_id', $this->zone_id, true);\n $criteria->compare('low_qty_threshold', $this->low_qty_threshold);\n $criteria->compare('high_qty_threshold', $this->high_qty_threshold);\n $criteria->compare('created_date', $this->created_date, true);\n $criteria->compare('created_by', $this->created_by, true);\n $criteria->compare('updated_date', $this->updated_date, true);\n $criteria->compare('updated_by', $this->updated_by, true);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('orgName',$this->orgName,true);\n\t\t$criteria->compare('noEmp',$this->noEmp);\n\t\t$criteria->compare('phone',$this->phone);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('addr1',$this->addr1,true);\n\t\t$criteria->compare('addr2',$this->addr2,true);\n\t\t$criteria->compare('state',$this->state,true);\n\t\t$criteria->compare('country',$this->country,true);\n\t\t$criteria->compare('orgType',$this->orgType,true);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('fax',$this->fax);\n\t\t$criteria->compare('orgId',$this->orgId,true);\n\t\t$criteria->compare('validity',$this->validity);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n \n $criteria->with=array('c','b');\n\t\t$criteria->compare('pid',$this->pid,true);\n\t\t$criteria->compare('t.cid',$this->cid,true);\n\t\t$criteria->compare('t.bid',$this->bid,true);\n\n $criteria->compare('c.classify_name',$this->classify,true);\n\t\t$criteria->compare('b.brand_name',$this->brand,true);\n \n $criteria->addCondition('model LIKE :i and model REGEXP :j');\n $criteria->params[':i'] = \"%\".$this->index_search.\"%\";\n $criteria->params[':j'] = \"^\".$this->index_search;\n\n \n\t\t$criteria->compare('model',$this->model,true);\n\t\t$criteria->compare('package',$this->package,true);\n\t\t$criteria->compare('RoHS',$this->RoHS,true);\n\t\t$criteria->compare('datecode',$this->datecode,true);\n\t\t$criteria->compare('quantity',$this->quantity);\n\t\t$criteria->compare('direction',$this->direction,true);\n $criteria->compare('image_url',$this->image_url,true);\n\t\t$criteria->compare('create_time',$this->create_time,true);\n\t\t$criteria->compare('status',$this->status);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->id,true);\n\t\t$criteria->compare('category',$this->category,true);\n\t\t$criteria->compare('sortorder',$this->sortorder,true);\n\t\t$criteria->compare('fullname',$this->fullname,true);\n\t\t$criteria->compare('shortname',$this->shortname,true);\n\t\t$criteria->compare('idnumber',$this->idnumber,true);\n\t\t$criteria->compare('summary',$this->summary,true);\n\t\t$criteria->compare('summaryformat',$this->summaryformat);\n\t\t$criteria->compare('format',$this->format,true);\n\t\t$criteria->compare('showgrades',$this->showgrades);\n\t\t$criteria->compare('sectioncache',$this->sectioncache,true);\n\t\t$criteria->compare('modinfo',$this->modinfo,true);\n\t\t$criteria->compare('newsitems',$this->newsitems);\n\t\t$criteria->compare('startdate',$this->startdate,true);\n\t\t$criteria->compare('marker',$this->marker,true);\n\t\t$criteria->compare('maxbytes',$this->maxbytes,true);\n\t\t$criteria->compare('legacyfiles',$this->legacyfiles);\n\t\t$criteria->compare('showreports',$this->showreports);\n\t\t$criteria->compare('visible',$this->visible);\n\t\t$criteria->compare('visibleold',$this->visibleold);\n\t\t$criteria->compare('groupmode',$this->groupmode);\n\t\t$criteria->compare('groupmodeforce',$this->groupmodeforce);\n\t\t$criteria->compare('defaultgroupingid',$this->defaultgroupingid,true);\n\t\t$criteria->compare('lang',$this->lang,true);\n\t\t$criteria->compare('theme',$this->theme,true);\n\t\t$criteria->compare('timecreated',$this->timecreated,true);\n\t\t$criteria->compare('timemodified',$this->timemodified,true);\n\t\t$criteria->compare('requested',$this->requested);\n\t\t$criteria->compare('enablecompletion',$this->enablecompletion);\n\t\t$criteria->compare('completionnotify',$this->completionnotify);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('ID',$this->ID);\n\t\t$criteria->compare('name',$this->name,true);\n\t\t$criteria->compare('email',$this->email,true);\n\t\t$criteria->compare('password',$this->password,true);\n\t\t$criteria->compare('address',$this->address,true);\n\t\t$criteria->compare('zipcode',$this->zipcode,true);\n\t\t$criteria->compare('city',$this->city,true);\n\t\t$criteria->compare('phone',$this->phone,true);\n\t\t$criteria->compare('role',$this->role,true);\n\t\t$criteria->compare('active',$this->active);\n\t\t$criteria->compare('camaras',$this->camaras);\n\t\t$criteria->compare('freidoras',$this->freidoras);\n\t\t$criteria->compare('cebos',$this->cebos);\n\t\t$criteria->compare('trampas',$this->trampas);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('attribute',$this->attribute,true);\n\t\t$criteria->compare('displayName',$this->displayName,true);\n\t\t$criteria->compare('description',$this->description,true);\n\t\t$criteria->compare('value_type',$this->value_type,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('cod_venda',$this->cod_venda,true);\n\t\t$criteria->compare('filial_cod_filial',$this->filial_cod_filial,true);\n\t\t$criteria->compare('funcionario_cod_funcionario',$this->funcionario_cod_funcionario,true);\n\t\t$criteria->compare('cliente_cod_cliente',$this->cliente_cod_cliente,true);\n\t\t$criteria->compare('data_2',$this->data_2,true);\n\t\t$criteria->compare('valor_total',$this->valor_total);\n\t\t$criteria->compare('forma_pagamento',$this->forma_pagamento,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n {\n // should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('state', $this->state);\n $criteria->compare('type','0');\n return new ActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search() {\n // @todo Please modify the following code to remove attributes that should not be searched.\n\n $criteria = new CDbCriteria;\n\n $criteria->compare('id', $this->id);\n $criteria->compare('name', $this->name, true);\n $criteria->compare('sex', $this->sex);\n $criteria->compare('mobile', $this->mobile, true);\n $criteria->compare('idcard', $this->idcard, true);\n $criteria->compare('password', $this->password, true);\n $criteria->compare('place_ids', $this->place_ids, true);\n $criteria->compare('depart_id', $this->depart_id);\n $criteria->compare('bank', $this->bank, true);\n $criteria->compare('bank_card', $this->bank_card, true);\n $criteria->compare('address', $this->address, true);\n $criteria->compare('education', $this->education, true);\n $criteria->compare('created', $this->created);\n\n return new CActiveDataProvider($this, array(\n 'criteria' => $criteria,\n ));\n }", "public function search()\n\t{\n\t\t// Warning: Please modify the following code to remove attributes that\n\t\t// should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('id',$this->buscar,'OR');\n\t\t$criteria->compare('fecha',$this->buscar,true,'OR');\n\t\t$criteria->compare('fechaUpdate',$this->buscar,true,'OR');\n\t\t$criteria->compare('idProfesional',$this->buscar,'OR');\n\t\t$criteria->compare('importe',$this->buscar,'OR');\n\t\t$criteria->compare('idObraSocial',$this->buscar,'OR');\n\t\t$criteria->compare('estado',$this->buscar,true,'OR');\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t));\n\t}", "public function search()\n\t{\n\t\t// @todo Please modify the following code to remove attributes that should not be searched.\n\n\t\t$criteria=new CDbCriteria;\n\n\t\t$criteria->compare('codop',$this->codop,true);\n\t\t$criteria->compare('codcatval',$this->codcatval,true);\n\t\t$criteria->compare('cuentadebe',$this->cuentadebe,true);\n\t\t$criteria->compare('cuentahaber',$this->cuentahaber,true);\n\t\t$criteria->compare('desop',$this->desop,true);\n\t\t$criteria->compare('descat',$this->descat,true);\n\t\t$criteria->compare('debe',$this->debe,true);\n\t\t$criteria->compare('haber',$this->haber,true);\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria'=>$criteria,\n\t\t\t'pagination'=>array('pagesize'=>100),\n\t\t));\n\t}" ]
[ "0.72122115", "0.7135646", "0.70933557", "0.7093038", "0.69853544", "0.69601065", "0.69471765", "0.6941036", "0.69336957", "0.69234014", "0.69101834", "0.6902516", "0.68980986", "0.68976295", "0.68919283", "0.6881968", "0.6879198", "0.6873671", "0.6849069", "0.68485016", "0.68359107", "0.6825333", "0.6814869", "0.6806155", "0.6802932", "0.67969763", "0.67959327", "0.67950827", "0.6795069", "0.67936885", "0.67897666", "0.67851", "0.6784607", "0.67832357", "0.6780524", "0.67800134", "0.6778277", "0.6776813", "0.67762995", "0.6775539", "0.6774692", "0.6774692", "0.6774692", "0.6774692", "0.6774692", "0.6774692", "0.6774692", "0.6774692", "0.67723817", "0.67680556", "0.676652", "0.6765281", "0.67619765", "0.6761599", "0.6760308", "0.6759511", "0.6758487", "0.6758277", "0.6753351", "0.67525774", "0.6751319", "0.6747473", "0.6747065", "0.6745327", "0.67448926", "0.67445016", "0.674393", "0.6743794", "0.67431563", "0.6743147", "0.67415375", "0.6740314", "0.6739625", "0.6738686", "0.6736472", "0.6736202", "0.67338884", "0.673148", "0.6730556", "0.67247915", "0.6722427", "0.6721912", "0.67214644", "0.6712283", "0.6712211", "0.67104053", "0.6708274", "0.6705994", "0.6705235", "0.67051923", "0.6703427", "0.67018664", "0.66998273", "0.66974646", "0.6696", "0.66947436", "0.6694549", "0.6692817", "0.66926694", "0.669252", "0.66907203" ]
0.0
-1
Returns the static model of the specified AR class. Please note that you should have this exact method in all your CActiveRecord descendants!
public static function model($className=__CLASS__) { return parent::model($className); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function model() {\n return parent::model(get_called_class());\n }", "public function model()\r\n {\r\n return static::class;\r\n }", "public static function model($className=__CLASS__) { return parent::model($className); }", "public static function model($className=__CLASS__)\n {\n return CActiveRecord::model($className);\n }", "static public function model($className = __CLASS__)\r\n {\r\n return parent::model($className);\r\n }", "public static function model($class = __CLASS__)\n\t{\n\t\treturn parent::model(get_called_class());\n\t}", "public static function model($class = __CLASS__)\n {\n return parent::model($class);\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 {\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 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 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__) {\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__) {\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__) {\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__) {\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__) {\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__) {\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__) {\n return parent::model($className);\n }", "public static function model($className = __CLASS__) {\n return parent::model($className);\n }" ]
[ "0.75750446", "0.7528519", "0.7271581", "0.72703993", "0.72617143", "0.7213263", "0.72127366", "0.7131883", "0.71287453", "0.71287453", "0.7102495", "0.7102467", "0.7102467", "0.7074701", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163", "0.7064163" ]
0.0
-1
Enter description here ...
public function indexAction() { $page = intval($this->getInput('page')); $perpage = $this->perpage; $param = $this->getInput(array('status')); $search = array(); if ($param['status']) $search['status'] = $param['status']; list($total, $forums) = Gou_Service_ForumReply::getList($page, $perpage, $search, array('id'=>'DESC')); $this->assign('forums', $forums); $this->assign('status', $this->status); $this->assign('search', $search); $url = $this->actions['listUrl'].'/?' . http_build_query($search) . '&'; $this->assign('pager', Common::getPages($total, $page, $perpage, $url)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _i() {\n }", "private function __() {\n }", "private function __construct( )\n {\n\t}", "private function __construct()\t{}", "private function __construct () \n\t{\n\t}", "private function __construct () {}", "public function helper()\n\t{\n\t\n\t}", "private function __construct()\r\n {}", "private function __construct()\n\t{\n\t\t\n\t}", "function __construct()\r\n\t{\t\t//Yeah bro! Freaking PhP yo..\r\n\t}", "private function __construct() {;}", "public function main()\n\t{\n\t}", "public function main()\r\n {\r\n \r\n }", "private function __construct() {\r\n\t\t\r\n\t}", "function __construct() ;", "private function __construct()\r\r\n\t{\r\r\n\t}", "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() {}", "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()\r\n\t{\r\n\t\r\n\t}", "private function __construct() {}", "private function __construct() {}", "private function __construct()\n {}", "private function __construct()\n {}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}" ]
[ "0.6657408", "0.65589434", "0.64820397", "0.6460619", "0.6352262", "0.63471055", "0.6333378", "0.6295962", "0.62877053", "0.6264639", "0.6244913", "0.62399566", "0.6236184", "0.6226566", "0.62162316", "0.6206873", "0.6185354", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61814517", "0.61814517", "0.6164118", "0.61503685", "0.61503685", "0.6147242", "0.6147242", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854" ]
0.0
-1
Enter description here ...
public function editAction(){ $id = $this->getInput('id'); $info = Gou_Service_ForumReply::getForumReply(intval($id)); $this->assign('status', $this->status); $this->assign('info', $info); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _i() {\n }", "private function __() {\n }", "private function __construct( )\n {\n\t}", "private function __construct()\t{}", "private function __construct () \n\t{\n\t}", "private function __construct () {}", "public function helper()\n\t{\n\t\n\t}", "private function __construct()\r\n {}", "private function __construct()\n\t{\n\t\t\n\t}", "function __construct()\r\n\t{\t\t//Yeah bro! Freaking PhP yo..\r\n\t}", "private function __construct() {;}", "public function main()\n\t{\n\t}", "public function main()\r\n {\r\n \r\n }", "private function __construct() {\r\n\t\t\r\n\t}", "function __construct() ;", "private function __construct()\r\r\n\t{\r\r\n\t}", "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() {}", "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()\r\n\t{\r\n\t\r\n\t}", "private function __construct() {}", "private function __construct() {}", "private function __construct()\n {}", "private function __construct()\n {}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}" ]
[ "0.6657408", "0.65589434", "0.64820397", "0.6460619", "0.6352262", "0.63471055", "0.6333378", "0.6295962", "0.62877053", "0.6264639", "0.6244913", "0.62399566", "0.6236184", "0.6226566", "0.62162316", "0.6206873", "0.6185354", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61814517", "0.61814517", "0.6164118", "0.61503685", "0.61503685", "0.6147242", "0.6147242", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854" ]
0.0
-1
Enter description here ...
public function edit_postAction(){ $info = $this->getPost(array('id', 'content', 'status')); $info = $this->_cookData($info); $ret = Gou_Service_ForumReply::updateForumReply($info, $info['id']); if (!$ret) $this->output(-1, '操作失败.'); $this->output(0, '操作成功.'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _i() {\n }", "private function __() {\n }", "private function __construct( )\n {\n\t}", "private function __construct()\t{}", "private function __construct () \n\t{\n\t}", "private function __construct () {}", "public function helper()\n\t{\n\t\n\t}", "private function __construct()\r\n {}", "private function __construct()\n\t{\n\t\t\n\t}", "function __construct()\r\n\t{\t\t//Yeah bro! Freaking PhP yo..\r\n\t}", "private function __construct() {;}", "public function main()\n\t{\n\t}", "public function main()\r\n {\r\n \r\n }", "private function __construct() {\r\n\t\t\r\n\t}", "function __construct() ;", "private function __construct()\r\r\n\t{\r\r\n\t}", "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() {}", "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()\r\n\t{\r\n\t\r\n\t}", "private function __construct() {}", "private function __construct() {}", "private function __construct()\n {}", "private function __construct()\n {}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}" ]
[ "0.6657408", "0.65589434", "0.64820397", "0.6460619", "0.6352262", "0.63471055", "0.6333378", "0.6295962", "0.62877053", "0.6264639", "0.6244913", "0.62399566", "0.6236184", "0.6226566", "0.62162316", "0.6206873", "0.6185354", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61814517", "0.61814517", "0.6164118", "0.61503685", "0.61503685", "0.6147242", "0.6147242", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854" ]
0.0
-1
Enter description here ...
public function deleteAction() { $id = $this->getInput('id'); $info = Gou_Service_ForumReply::getForumReply($id); if ($info && $info['id'] == 0) $this->output(-1, '无法删除'); $ret = Gou_Service_ForumReply::deleteForumReply($id); if (!$ret) $this->output(-1, '操作失败'); $this->output(0, '操作成功'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _i() {\n }", "private function __() {\n }", "private function __construct( )\n {\n\t}", "private function __construct()\t{}", "private function __construct () \n\t{\n\t}", "private function __construct () {}", "public function helper()\n\t{\n\t\n\t}", "private function __construct()\r\n {}", "private function __construct()\n\t{\n\t\t\n\t}", "function __construct()\r\n\t{\t\t//Yeah bro! Freaking PhP yo..\r\n\t}", "private function __construct() {;}", "public function main()\n\t{\n\t}", "public function main()\r\n {\r\n \r\n }", "private function __construct() {\r\n\t\t\r\n\t}", "function __construct() ;", "private function __construct()\r\r\n\t{\r\r\n\t}", "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() {}", "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()\r\n\t{\r\n\t\r\n\t}", "private function __construct() {}", "private function __construct() {}", "private function __construct()\n {}", "private function __construct()\n {}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}" ]
[ "0.6657408", "0.65589434", "0.64820397", "0.6460619", "0.6352262", "0.63471055", "0.6333378", "0.6295962", "0.62877053", "0.6264639", "0.6244913", "0.62399566", "0.6236184", "0.6226566", "0.62162316", "0.6206873", "0.6185354", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61814517", "0.61814517", "0.6164118", "0.61503685", "0.61503685", "0.6147242", "0.6147242", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854" ]
0.0
-1
Enter description here ...
private function _cookData($info) { if(!$info['content']) $this->output(-1, '内容不能为空.'); return $info; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _i() {\n }", "private function __() {\n }", "private function __construct( )\n {\n\t}", "private function __construct()\t{}", "private function __construct () \n\t{\n\t}", "private function __construct () {}", "public function helper()\n\t{\n\t\n\t}", "private function __construct()\r\n {}", "private function __construct()\n\t{\n\t\t\n\t}", "function __construct()\r\n\t{\t\t//Yeah bro! Freaking PhP yo..\r\n\t}", "private function __construct() {;}", "public function main()\n\t{\n\t}", "public function main()\r\n {\r\n \r\n }", "private function __construct() {\r\n\t\t\r\n\t}", "function __construct() ;", "private function __construct()\r\r\n\t{\r\r\n\t}", "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() {}", "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()\r\n\t{\r\n\t\r\n\t}", "private function __construct() {}", "private function __construct() {}", "private function __construct()\n {}", "private function __construct()\n {}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}", "private function __construct()\n\t{\n\t}" ]
[ "0.6657408", "0.65589434", "0.64820397", "0.6460619", "0.6352262", "0.63471055", "0.6333378", "0.6295962", "0.62877053", "0.6264639", "0.6244913", "0.62399566", "0.6236184", "0.6226566", "0.62162316", "0.6206873", "0.6185354", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.6184391", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61841035", "0.61814517", "0.61814517", "0.6164118", "0.61503685", "0.61503685", "0.6147242", "0.6147242", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854", "0.61461854" ]
0.0
-1
retorna a lista dos alunos
public function listarTodos_get(){ $data = $this->Aluno->getAlunos(); $this->response($data, REST_Controller::HTTP_OK); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function busca_alunos(){\n\n\t\t\t$sql = \"SELECT * FROM aluno\";\n\n\t\t\t/*\n\t\t\t*isntrução que realiza a consulta de animes\n\t\t\t*PDO::FETCH_CLASS serve para perdir o retorno no modelo de uma classe\n\t\t\t*PDO::FETCH_PROPS_LATE serve para preencher os valores depois de executar o contrutor\n\t\t\t*/\n\n\t\t\t$resultado = $this->conexao->query($sql, PDO::FETCH_CLASS | PDO::FETCH_PROPS_LATE, 'Aluno');\n\n $alunos = [];\n\n foreach($resultado as $aluno){\n $alunos[] = $aluno;\n }\n\n \t\t\treturn $alunos;\n\t\t}", "public function lists();", "public function getList();", "public function getList();", "public function list();", "public function list();", "public function list();", "function getOrganismsList();", "public function liste()\n {\n return $this->createQueryBuilder('a')\n ->orderBy('a.pseudonyme', 'ASC')\n ;\n }", "public function getAutoposList(){\n return $this->_get(2);\n }", "public function obtenerTodosLosAlergenos(){\n $respuesta = $this->realizarPeticion('GET', $this->urlBase.'GetAlergenos');\n\n $datos = json_decode($respuesta);\n\n $alergenos = $datos->objeto;\n\n return $alergenos;\n }", "function getLista(){\n\n }", "function _find_list() {\n\t\treturn $this->Album->generatetreelist(null, null, null, '__');\n\t}", "abstract public function getList();", "public function listar(){\r\n }", "public function getList() {\n\t\t\tif (is_null($this->arList)) $this->load(); \n\t\t\treturn $this->arList; \n\t\t}", "public abstract function get_lists();", "public function listAll();", "public function listAll();", "public function getUl() {}", "public static function all()\n {\n $list = [];\n $db = Db::initDB();\n $req = $db->query('SELECT * FROM alcool');\n\n // on créer une list des objets Alcool depuis le résultat de la base de données\n foreach ($req->fetchAll() as $alcools) {\n $list[] = new Alcool($alcools['id'], $alcools['name'], $alcools['degree'], $alcools['dose']);\n }\n\n return $list;\n }", "public function listarUsuarios()\r\n\t{\r\n\t\t$administradores=array();\r\n\t\ttry{\r\n\t\t\t//realizamos la consulta de todos los items\r\n\t\t\t$consulta = $this->db->prepare(\"select * from administrador\");\r\n\t\t\t$consulta->execute();\r\n\t\t\tfor($i=0; $row = $consulta->fetch(); $i++)\r\n\t\t\t{\r\n\t\t $fila['admin_cedula']=$row['ADMIN_CEDULA'];\r\n\t\t\t$fila['admin_login']=$row['ADMIN_LOGIN'];\r\n\t\t\t$fila['admin_nombre']=$row['ADMIN_NOMBRE'];\r\n\t\t\t$fila['admin_apellido']=$row['ADMIN_APELLIDO'];\r\n\t\t\t$fila['admin_status']=$row['ADMIN_STATUS'];\r\n\t\t\t$administradores[]=$fila;\t\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\t\t\t\r\n\t\tcatch(PDOException $e)\r\n\t\t{\r\n\t\t\techo $e;\r\n\t\t}\r\n\t\treturn $administradores;\t\t\r\n\t}", "public static function listado() {\n $aulas = array();\n $resultset = DB::table('aulas')->get();\n foreach ($resultset as $var) {\n $aulas[$var->AULA] = $var->AULA;\n }\n return $aulas;\n }", "public function ListarUsuarios()\n{\n\tself::SetNames();\n\t$sql = \" select * from usuarios \";\n\tforeach ($this->dbh->query($sql) as $row)\n\t{\n\t\t$this->p[] = $row;\n\t}\n\treturn $this->p;\n\t$this->dbh=null;\n}", "function getAllLists()\n {\n $stmt = self::$_db->prepare(\"SELECT * FROM list\");\n $stmt->execute();\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\n }", "public function get_all ();", "function listaAll() {\n require ROOT . \"config/bootstrap.php\";\n return $em->getRepository('models\\Equipamentos')->findby(array(), array(\"id\" => \"DESC\"));\n $em->flush();\n }", "public function getAluno(){\n $result = $this->mysqli->query(\"SELECT * FROM alunos\");\n while($row = $result->fetch_array(MYSQLI_ASSOC)){\n $array[] = $row;\n }\n return $array;\n }", "protected function getGroupList() {}", "protected function getGroupList() {}", "public function getList() {\n \treturn array(\"id\" => $this->id,\n \"name\" => $this->name);\n\t}", "public function getList()\n {\n $categories = array();\n\n $q = $this->_db->query('SELECT * FROM categorie ORDER BY idCategorie');\n\n while ($donnees = $q->fetch(PDO::FETCH_ASSOC))\n {\n $categories[] = ($donnees);\n \n }\n }", "public function get_all()\n {\n\n $sql = \"SELECT * FROM `menu`\";\n $query = $this->db->prepare($sql);\n\n $query->execute();\n\n return $query->fetchAll();\n }", "public function getListaOcupaciones() {\n \n $listaOcupaciones = array();\n \n $dbAccess = new DBAccess();\n $result = $dbAccess->getSelect(\"SELECT * from ocupacion\");\n\n foreach($result as $row){\n \n $ocupacion = new Ocupacion($row['idocupacion'], $row['idempleado'], $row['fecha_ocupado']);\n array_push($listaOcupaciones, $ocupacion); \n }\n \n return $listaOcupaciones;\n }", "protected abstract function getIListar();", "public function readAll()\n {\n\n \t$list = $this->dao->readAll();\n\n if (!is_array($list) && $list != false){ // si no hay nada cargado, readall devuelve false\n $array[] = $list; \n $list = $array; // para que devuelva un arreglo en caso de haber solo 1 objeto // esto para cuando queremos hacer foreach al listar, ya que no se puede hacer foreach sobre un objeto ni sobre un false\n }\n\n return $list;\n }", "function rec_empresa_list(){\n\t\t}", "public function getAllItems() {\n\t\t$allItems = [];\n\t\t$res = $this->db->query(\"SELECT * FROM voorziening ORDER BY naam\");\n\t\twhile ($row = $res->fetch_assoc()) {\n\t\t\t$allItems[] = $row;\n\t\t}\n\t\treturn $allItems;\n\t}", "public function getLista() {\r\n\t\treturn $this->lista; \r\n\t}", "public static function all()\n {\n return self::$list;\n }", "function _find_list() {\n\t\treturn $this->Menu->generatetreelist(null, null, null, '__');\n\t}", "function lista()\r\n\t{\r\n\t\treturn mysql_fetch_array($this->get_consulta());\r\n\t}", "public function listaLibros() {\n $consultaListaLibros = $this->db->select(\"SELECT * FROM libro \"\n . \"ORDER BY titulo\");\n return $consultaListaLibros;\n }", "public function lista() {\n $sql = \"SELECT * FROM cliente\";\n $qry = $this->db->query($sql); // query do pdo com acesso ao bd\n\n //return $qry->fetchAll(); // retorna todos os registros\n return $qry->fetchAll(\\PDO::FETCH_OBJ); // retorna todos os registros a nível de objeto\n }", "public static function getAll();", "public static function getAll();", "public function selectAll() {\n $conn = $this->conex->connectDatabase();\n $sql = \"select * from tbl_menu\";\n $stm = $conn->prepare($sql);\n $success = $stm->execute();\n if ($success) {\n $listMenu = [];\n foreach ($stm->fetchAll(PDO::FETCH_ASSOC) as $result) {\n $Menu = new MenuFuncionario();\n $Menu->setId($result['id_menu']);\n $Menu->setPaginas($result['paginas']);\n array_push($listMenu, $Menu);\n }\n $this->conex -> closeDataBase();\n return $listMenu;\n } else {\n return \"Erro\";\n }\n }", "public static function getList(){\n return self::all();\n }", "function PListaGrupo() {\n\t\t$this->listas\t= array();\n\t}", "public function listar() {\n $conexion = new Conexion();\n $consulta = $conexion->prepare('SELECT * FROM facultad');\n $consulta->execute();\n $ces = null;\n\n $tabla_datos = $consulta->fetchAll(PDO::FETCH_ASSOC);\n\n $astraba = array();\n\n\n foreach ($tabla_datos as $con => $valor) {\n $ces = $tabla_datos[$con][\"nombre\"];\n\n array_push($astraba, $ces);\n }\n return $astraba;\n }", "public function getList()\n {\n }", "public function listarlapaz(){\n $persona=\"SELECT p.*,c.nombre as caja FROM persona as p\n LEFT JOIN cajalapaz as c ON c.id=p.id_caja where p.ciudad='lapaz' AND p.estado=1\";\n $bajas=\"SELECT p.*,c.nombre as caja FROM persona as p\n LEFT JOIN cajalapazretirado as c ON c.id=p.id_caja where p.ciudad='lapaz' AND p.estado=0\";\n $cajas=\"SELECT * FROM cajalapaz WHERE estado = 1\";\n $cajaretirados=\"SELECT * FROM cajalapazretirado WHERE estado = 1\";\n $result=[\n \"personal\"=> parent::consultaRetorno($persona),\n \"bajas\"=>parent::consultaRetorno($bajas),\n \"cajas\"=>parent::consultaRetorno($cajas),\n \"cajasretirados\"=>parent::consultaRetorno($cajaretirados)\n ];\n return $result;\n }", "public function Listar()\n\t{\n\t\ttry\n\t\t{\n\t\t\t$result = array();\n\n\t\t\t$stm = $this->pdo->prepare(\"SELECT usuario.`correo`, `usuario`.`clave`, `rol`.`nomRol`, `datospersonales`.`Documento`\nFROM `usuario`\nLEFT JOIN `rol` ON `rol`.`nomRol` = `usuario`.`nomRol` \nLEFT JOIN `datospersonales` ON `datospersonales`.`Documento` = `usuario`.`Documento`\n WHERE correo is not null \");\n\t\t\t$stm->execute();\n\n\t\t\tforeach($stm->fetchAll(PDO::FETCH_OBJ) as $r)\n\t\t\t{\n\t\t\t\t$usu = new Usuario();\n\n\t\t\t\t$usu->__SET('correo', $r->correo);\n\t\t\t\t$usu->__SET('clave', $r->clave);\n\t\t\t\t$usu->__SET('nomRol', $r->nomRol);\n\t\t\t\t$usu->__SET('Documento', $r->Documento);\n\t\t\t\t\n\t\t\t\t\n\n\t\t\t\t$result[] = $usu;\n\t\t\t}\n\n\t\t\treturn $result;\n\t\t}\n\t\tcatch(Exception $e)\n\t\t{\n\t\t\tdie($e->getMessage());\n\t\t}\n\t}", "public function ListarCategorias()\n{\n\tself::SetNames();\n\t$sql = \" select * from categorias\";\n\tforeach ($this->dbh->query($sql) as $row)\n\t{\n\t\t$this->p[] = $row;\n\t}\n\treturn $this->p;\n\t$this->dbh=null;\n}", "public function getSubdivisionList();", "public function getListArray(){\n static $list;\n if (isset($list)) {\n return $list;\n }\n $package = new Hosh_Manager_Db_Package_Hosh_Class();\n $listall = $package->getList();\n $list = array();\n foreach ($listall as $val){\n $list[strtolower($val['sname'])] = $val;\n }\n return $list;\n }", "public function ListarArqueoCaja()\n{\n\tself::SetNames();\n\t\n\tif($_SESSION[\"acceso\"] == \"cajero\") {\n\n\n $sql = \" select * FROM arqueocaja INNER JOIN cajas ON arqueocaja.codcaja = cajas.codcaja WHERE cajas.codigo = '\".$_SESSION[\"codigo\"].\"'\";\n\tforeach ($this->dbh->query($sql) as $row)\n\t{\n\t\t$this->p[] = $row;\n\t}\n\treturn $this->p;\n\t$this->dbh=null;\n\n\n\t} else {\n\n\t$sql = \" select * FROM arqueocaja INNER JOIN cajas ON arqueocaja.codcaja = cajas.codcaja\";\n\tforeach ($this->dbh->query($sql) as $row)\n\t{\n\t\t$this->p[] = $row;\n\t}\n\treturn $this->p;\n\t$this->dbh=null;\n\n\t}\n}", "function listar2(){\n\t\t\n\t\t$sql = \"SELECT c.id, c.codigo, c.nombre from prd_pasos_producto a\n\t\tinner join prd_pasos_acciones_producto b on b.id_paso=a.id\n\t\tinner join app_productos c on c.id=a.id_producto\n\t\tgroup by a.id_producto;\";\n\n\t\treturn $this->queryArray($sql);\n\t}", "public function getAll()\n {\n \tif(!$this->isEmpty()){\n \t\treturn $this->items;\n \t}\n }", "public function ListarCajasAbiertas()\n{\n\tself::SetNames();\n\t$sql = \" select * from cajas INNER JOIN arqueocaja ON cajas.codcaja = arqueocaja.codcaja LEFT JOIN usuarios ON cajas.codigo = usuarios.codigo WHERE arqueocaja.statusarqueo = '1'\";\n\tforeach ($this->dbh->query($sql) as $row)\n\t{\n\t\t$this->p[] = $row;\n\t}\n\treturn $this->p;\n\t$this->dbh=null;\n}", "public static function list(){\r\n\t\t$app = Aplicacion::getSingleton();\r\n\t\t$conn = $app->conexionBd();\r\n\t\t\r\n\t\t$query= sprintf(\"SELECT * FROM abono\");\r\n\t\t$resultado = $conn->query($query);\r\n\t\twhile($fila = mysqli_fetch_assoc($resultado)){\r\n\t\t\t$abono = new TOAbono();\r\n\t\t\t$abono->setTipoAbono($fila['tipo']);\r\n\t\t \t$abono->setCoste($fila['coste']);\r\n\t\t\t$abono->setDuracion($fila['duracion']);\r\n\t\t\t$abonos[] = $abono;\r\n\t\t}\r\n\t\treturn $abonos;\r\n\t}", "public function listarAerolineas() {\n//Se obtiene la conexion\n $conn = Conexion::singleton()->obtenerConexion();\n try {\n //Consulta para listar las aerolinas registradas\n $query = $conn->prepare(\"SELECT * FROM tbl_aerolinea\");\n $query->execute();\n return $query->fetchAll();\n }\n catch (Exception $ex) {\n\n echo 'ERROR' . $ex->getMessage();\n }\n\n $conn = null;\n }", "public function getListItems()\n {\n return $this->getAlbums();\n }", "private function listado_obras(){\n \treturn Sesion::where(\"inicio\",\">\",Carbon::now())->distinct()->get(['nombre_obra']);\n }", "public function list_all() {\n global $retailers;\t\t\n $this->names = array_column($retailers, 'name');\n }", "public function all(){\r\n return $this->items;\r\n }", "public function getApromenu() {\n $arr = ['36', '42', '18', '2', '20', '4', '11','5',];\n $theMenu = NULL;\n foreach ($arr as $v) {\n \n \n $theMenu[] = \\app\\modules\\whoarewe\\models\\Category::find()\n ->where(['depth'=>0])\n ->andWhere(['category_id' => $v])\n ->with(['photos']) \n // ->orderBy('category_id')\n ->one();\n }\n return $theMenu;\n }", "function listadeTodosLiderDao(){\r\n require_once (\"../conexao.php\");\r\n require_once (\"../modelo/objetoMembro.php\");\r\n \r\n $objDao = Connection::getInstance();\r\n \r\n $resultado = mysql_query(\"Select Matricula,Nome from membros where LiderCelula = 'S' order by Nome\") or die (\"Nao foi possivel realizar a busca\".mysql_error());\r\n $listaMembro = array();\r\n \r\n $i=0;\r\n \r\n \r\n while ($registro = mysql_fetch_assoc($resultado)){\r\n \r\n if($registro[\"Nome\"] != \"\"){\r\n \r\n\t $membro = new objetoMembro();\r\n \r\n $membro->setMatricula($registro['Matricula']);\r\n $membro->setNome($registro['Nome']);\r\n \r\n\t $listaMembro[$i] = $membro;\r\n\t}\r\n $i++;\r\n }\r\n\t\treturn $listaMembro;\r\n\t\tmysql_free_result($resultado);\r\n $objDao->freebanco();\r\n }", "public function getItemsList(){\n return $this->_get(4);\n }", "public function generateList() {}", "public function generateList() {}", "public function generateList() {}", "public function getList($perezoso = true){\n\t\t$select = $this->getListSelect();\n\t\t$stmt = $select->query();\n\t\t$objects = array();\n\t\t$this->setPerezoso($perezoso);\n\t\tforeach ($stmt->fetchAll() as $row){\n\t\t\t$objects[]= $this->_populate($row);\n\t\t}\n\t\treturn $objects;\n\t}", "public function obtenerViajesplusAbonados();", "public static function getAll() {}", "public function getObjectivesList() {\n return $this->_get(8);\n }", "public function Listar()\n\t{\n\t\ttry\n\t\t{\n\t\t\t$result = array();\n\n\t\t\t$stm = $this->pdo->prepare(\"SELECT * FROM properties order by id desc\");\n\t\t\t$stm->execute();\n\n\t\t\treturn $stm->fetchAll(PDO::FETCH_OBJ);\n\t\t}\n\t\tcatch(Exception $e)\n\t\t{\n\t\t\tdie($e->getMessage());\n\t\t}\n\t}", "function api_list_menus() {\n\t\t$menus = array();\n\t\tforeach ( get_nav_menu_locations() as $menu_slug => $menu_id ) {\n\n\t\t\t$menu = $menu_id?self::get_menu_object($menu_id):false;\n\t\t\t$menus[ $menu_slug ] = $menu;\n\t\t}\n\n\t\treturn $menus;\n\t}", "function listeGroupes(){\n $groupes = array();\n $connexion = new Connexion();\n $query = 'SELECT * FROM GROUPE';\n $result = $connexion->query($query);\n foreach($result as $row){\n $groupes[] = array('id'=>$row['id'],'libelle'=>$row['libelle'],'nombre'=>$row['nombre']);\n }\n return $groupes;\n}", "function fetchAnuncio() {\n\n $anuncios = array();\n\n $con = new DB();\n $sql = $con->prepare(\"SELECT * FROM anuncio\");\n $result = $con->executeQuery($sql);\n\n foreach ($result as $row) {\n $id = $row['id'];\n $titulo = $row['titulo'];\n $descripcion = $row['descripcion'];\n $imagen = $row['imagen'];\n $id_poi = $row['id_poi'];\n $id_usuario = $row['id_usuario'];\n $anuncio = new Anuncio($id, $titulo, $descripcion, $imagen, $id_poi, $id_usuario);\n array_push($anuncios, $anuncio);\n }\n\n return $anuncios;\n }", "function galerien_liste()\n\t{\n\t\t$sql = sprintf(\"SELECT * FROM %s\n\t\t\t\t\t\tORDER BY bgalg_order_id\",\n\t\t\t$this->db_praefix.\"ecard_galerien\"\n\t\t);\n\t\t$temp_return = $this->db->get_results($sql, ARRAY_A);\n\t\treturn $temp_return;\n\t}", "public function getList(){\r\n \r\n $sql = \"SELECT * FROM ESTADO_USUARIO\";\r\n $ests = array();\r\n if(!$resultado = pg_Exec($this->conexion, $sql));\r\n\r\n while($row = pg_fetch_array($resultado))\r\n { \r\n $est = New Status_User();\r\n $est->setCod_estado($row[0]);\r\n $est->setNom_estado($row[1]);\r\n $ests[] = $est;\r\n }\r\n return $ests;\r\n }", "public static function getOrtList() {\n $db = MDB2::singleton();\n $sql = 'SELECT * FROM orte;';\n $data = $db->extended->getAll($sql);\n IsDbError($data);\n $orte = ['-- unbekannt --'];\n foreach ($data as $val) {\n $st = $val['ort'] . '&nbsp;-&nbsp;' . $val['land'];\n $orte[$val['oid']] = $st;\n }\n return $orte;\n }", "public function avulsasLivres()\n\t{\n\t\t$stmt = $this->pdo->prepare(\"SELECT * FROM vagas where tipo = 'A' and status = 'L' order by vaga\");\n \t\t$stmt->execute();\n \t\t$vagas = $stmt->fetchall(PDO::FETCH_ASSOC);\n \t\treturn $vagas;\n\t}", "public function getObjectivesList() {\n return $this->_get(9);\n }", "public function getList(){\n $listeNom=array();\n\n $sql = 'SELECT per_num,per_nom,per_prenom from personne order by per_nom';\n $req=$this->db->prepare($sql);\n $req->execute();\n while ($nom = $req->fetch(PDO::FETCH_OBJ)){\n $listeNom[]=new Personne ($nom);\n }\n\n return $listeNom;\n $req->closeCursor();\n }", "public function getList()\r\n {\r\n return $this->setNuki(\r\n __FUNCTION__\r\n );\r\n }", "public function getAll() {\n $r = $this->db->query(\"SELECT * FROM autores\");\n $autores=array();\n foreach($r->result()as $autor){\n $autores[]=$autor;\n }\n return $autores; \n }", "public function obtenerLista() {\n $sql = \"SELECT * FROM HORARIO\";\n if(!$result = mysqli_query($this->con, $sql)) die();\n\t\t\t\t\t\t$horarios = array();\n\t\t\twhile ($row = mysqli_fetch_array($result)) {\n\t\t\t\t$horarios[] = new horario($row[0], $row[1]);\n\t\t\t}\n\t\t\treturn $horarios;\n }", "public function ListarSalas()\n{\n\tself::SetNames();\n\t$sql = \" select * from salas\";\n\tforeach ($this->dbh->query($sql) as $row)\n\t{\n\t\t$this->p[] = $row;\n\t}\n\treturn $this->p;\n\t$this->dbh=null;\n}", "public function items() {\n return $this->list;\n }", "public static function getList(){\n\t\t\t$sql = new sql();\n\n\t\t\treturn $sql->select(\"SELECT * FROM tb_usuarios ORDER BY deslogim\");\n\t\t}", "function listAll()\n{\n\tglobal $orderedIT;\n\n\t//to make sure this comes first\n\t//not so usefull anymore since they're not all open at start anyways..\n\tdispBatch('GENERIC', $orderedIT['GENERIC']);\n\n\tforeach($orderedIT as $name => $elem)\n\t{\n\t\tif ($name=='GENERIC') continue;\n\n\t\tdispBatch($name, $elem);\n\t}\n}", "public function loadAll() {\n $gerimu_masyvas = [];\n\n foreach ($this->db->getRows($this->table_name) as $gerimas) {\n $gerimu_masyvas[] = new \\App\\Item\\Gerimas($gerimas);\n }\n\n return $gerimu_masyvas;\n }", "public function listar() {\r\n $this->conexao->conect(\"host=localhost dbname=postgres user=postgres password=123\");\r\n $aLivro= Array();\r\n $sSql = \"SELECT livcodigo,livnome,tbgenero.gencodigo,tblocalizacao.loccodigo FROM atividade.tblivro \"\r\n . \"INNER JOIN atividade.tbgenero ON tblivro.gencodigo = tbgenero.gencodigo \"\r\n . \"INNER JOIN atividade.tblocalizacao ON tblocalizacao.loccodigo = tblivro.loccodigo \";\r\n $oRes = $this->conexao->query($sSql);\r\n while($oLivroBanco = pg_fetch_assoc($oRes)){\r\n $oLivro = new Livro();\r\n $oGenero = new Genero();\r\n $oLocalizacao = new Localizacao();\r\n $oLivro->setLivcodigo($oLivroBanco['livcodigo']);\r\n $oLivro->setLivnome($oLivroBanco['livnome']);\r\n $oGenero->setGencodigo($oLivroBanco['gencodigo']);\r\n $oLocalizacao->setLoccodigo($oLivroBanco['loccodigo']);\r\n $oLivro->setGenero($oGenero);\r\n $oLivro->setLocalizacao($oLocalizacao);\r\n $aLivro[] = $oLivro;\r\n }\r\n $this->conexao->close();\r\n return $aLivro;\r\n }", "public function getList()\n {\n \treturn $this->model->where('is_base', '=', 0)->get();\n }", "public function all() {\r\n\t\t$objects = []\r\n\t\twhile($this->hasNext()) {\r\n\t\t\t$next = $this->next();\r\n\t\t\tif($next == FALSE) break;\r\n\t\t\t$objects->push($next);\r\n\t\t}", "function get_list($table,$language_not_default)\n\t\t{\n\t\t\tglobal $db;\n\t\t\t$query = $this->setQuery($table,$language_not_default);\n\t\t\t$sql = $db->query_limit($query,$this->limit,$this->page);\n\t\t\t$result = $db->getObjectList();\n\t\t\t\n\t\t\treturn $result;\n\t\t}", "public function list(): array\n {\n \n }", "public function listAll()\n {\n }", "function listarUsuarios(){\n\t$usuarios = getKeys(BUCKET_USUARIOS);\n\tforeach ($usuarios as $usuario) {\n\t\t//echo $usuario.'<br>';\n\t\t//$rwits = getNumberOfValues($usuario);\n\t\t//echo $rwits.'<br>';\n\t\t$resul[] = new KValue($usuario, getNumberOfValues($usuario));\n\t}\n\tusort($resul, \"compararUsuarios\");\n\treturn $resul;\n}" ]
[ "0.68425834", "0.6780507", "0.6712386", "0.6712386", "0.6643916", "0.6643916", "0.6643916", "0.6643325", "0.6511888", "0.65090877", "0.64966524", "0.6488871", "0.64787596", "0.64664525", "0.645927", "0.64551955", "0.64499515", "0.64411783", "0.64411783", "0.642564", "0.6424444", "0.64043343", "0.6402434", "0.63125634", "0.6305868", "0.62962353", "0.62438816", "0.62345725", "0.6202876", "0.6202876", "0.61371106", "0.6132066", "0.61267686", "0.6122482", "0.61007744", "0.60980827", "0.60920084", "0.6080569", "0.6070139", "0.6069093", "0.6067074", "0.6065446", "0.606229", "0.6056048", "0.6046206", "0.6046206", "0.60422844", "0.60366136", "0.60353184", "0.60325056", "0.60312253", "0.6023641", "0.60172796", "0.6015641", "0.60092735", "0.6005101", "0.6000798", "0.5997977", "0.599392", "0.5990571", "0.59896225", "0.59781146", "0.5974202", "0.5973185", "0.5967139", "0.59652454", "0.595642", "0.5952631", "0.59506696", "0.5939036", "0.5939036", "0.59387535", "0.5937793", "0.5928205", "0.5924541", "0.5909723", "0.59095806", "0.58979285", "0.58975834", "0.5888081", "0.5887994", "0.5884634", "0.58840615", "0.5870934", "0.58708453", "0.5868415", "0.5867882", "0.58663094", "0.5858677", "0.5857455", "0.58563393", "0.584948", "0.58430773", "0.5840153", "0.5837034", "0.58292955", "0.58289057", "0.5821772", "0.58168083", "0.5815838", "0.5815351" ]
0.0
-1
Run the database seeds.
public function run() { DB::table('tm_module')->insert([ 'name' => 'Administrator', 'description' => 'Module', 'icon' => 'fa fa-users', 'order' => '1', 'segment' => 'Administrator' ]); DB::table('tm_module')->insert([ 'name' => 'Master Data', 'description' => 'Module', 'icon' => 'fa fa-tasks', 'order' => '2', 'segment' => 'MasterData' ]); DB::table('tm_module')->insert([ 'name' => 'Transaksi', 'description' => 'Module', 'icon' => 'fa fa-file', 'order' => '3', 'segment' => 'Report' ]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function run()\n {\n // $this->call(UserTableSeeder::class);\n // $this->call(PostTableSeeder::class);\n // $this->call(TagTableSeeder::class);\n // $this->call(PostTagTableSeeder::class);\n\n /*AB - use faker to populate table see file ModelFactory.php */\n factory(App\\Editeur::class, 40) ->create();\n factory(App\\Auteur::class, 40) ->create();\n factory(App\\Livre::class, 80) ->create();\n\n for ($i = 1; $i < 41; $i++) {\n $number = rand(2, 8);\n for ($j = 1; $j <= $number; $j++) {\n DB::table('auteur_livre')->insert([\n 'livre_id' => rand(1, 40),\n 'auteur_id' => $i\n ]);\n }\n }\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n \t$faker = Faker::create();\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$post = new Post;\n \t\t$post->title = $faker->sentence();\n \t\t$post->body = $faker->paragraph();\n \t\t$post->category_id = rand(1, 5);\n \t\t$post->save();\n \t}\n\n \t$list = ['General', 'Technology', 'News', 'Internet', 'Mobile'];\n \tforeach($list as $name) {\n \t\t$category = new Category;\n \t\t$category->name = $name;\n \t\t$category->save();\n \t}\n\n \tfor($i=0; $i<20; $i++) {\n \t\t$comment = new Comment;\n \t\t$comment->comment = $faker->paragraph();\n \t\t$comment->post_id = rand(1,20);\n \t\t$comment->save();\n \t}\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(UserTableSeeder::class);\n \n factory('App\\Cat', 5)->create();\n $tags = factory('App\\Tag', 8)->create();\n\n factory(Post::class, 15)->create()->each(function($post) use ($tags){\n $post->comments()->save(factory(Comment::class)->make());\n $post->tags()->attach( $tags->random(mt_rand(1,4))->pluck('id')->toArray() );\n });\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('post')->insert(\n [\n 'title' => 'Test Post1',\n 'desc' => str_random(100).\" post1\",\n 'alias' => 'test1',\n 'keywords' => 'test1',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post2',\n 'desc' => str_random(100).\" post2\",\n 'alias' => 'test2',\n 'keywords' => 'test2',\n ]\n );\n DB::table('post')->insert(\n [\n 'title' => 'Test Post3',\n 'desc' => str_random(100).\" post3\",\n 'alias' => 'test3',\n 'keywords' => 'test3',\n ]\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n \t$faker = Factory::create();\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\tDepartment::create([\n \t\t\t'name' => $department\n \t\t]);\n \t}\n \tforeach ($this->collections as $key => $collection) {\n \t\tCollection::create([\n \t\t\t'name' => $collection\n \t\t]);\n \t}\n \t\n \t\n \tfor ($i=0; $i < 40; $i++) {\n \t\tUser::create([\n \t\t\t'name' \t=>\t$faker->name,\n \t\t\t'email' \t=>\t$faker->email,\n \t\t\t'password' \t=>\tbcrypt('123456'),\n \t\t]);\n \t} \n \t\n \t\n \tforeach ($this->departments as $key => $department) {\n \t\t//echo ($key + 1) . PHP_EOL;\n \t\t\n \t\tfor ($i=0; $i < 10; $i++) { \n \t\t\techo $faker->name . PHP_EOL;\n\n \t\t\tArt::create([\n \t\t\t\t'name'\t\t\t=> $faker->sentence(2),\n \t\t\t\t'img'\t\t\t=> $this->filenames[$i],\n \t\t\t\t'medium'\t\t=> 'canvas',\n \t\t\t\t'department_id'\t=> $key + 1,\n \t\t\t\t'user_id'\t\t=> $this->userIndex,\n \t\t\t\t'dimension'\t\t=> '18.0 x 24.0',\n\t\t\t\t]);\n \t\t\t\t\n \t\t\t\t$this->userIndex ++;\n \t\t}\n \t}\n \t\n \tdd(\"END\");\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->dataCategory();\n factory(App\\Model\\Category::class, 70)->create();\n factory(App\\Model\\Producer::class, rand(5,10))->create();\n factory(App\\Model\\Provider::class, rand(5,10))->create();\n factory(App\\Model\\Product::class, 100)->create();\n factory(App\\Model\\Album::class, 300)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n\n factory('App\\User', 10 )->create();\n\n $users= \\App\\User::all();\n $users->each(function($user){ factory('App\\Category', 1)->create(['user_id'=>$user->id]); });\n $users->each(function($user){ factory('App\\Tag', 3)->create(['user_id'=>$user->id]); });\n\n\n $users->each(function($user){\n factory('App\\Post', 10)->create([\n 'user_id'=>$user->id,\n 'category_id'=>rand(1,20)\n ]\n );\n });\n\n $posts= \\App\\Post::all();\n $posts->each(function ($post){\n\n $post->tags()->attach(array_unique([rand(1,20),rand(1,20),rand(1,20)]));\n });\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $types = factory(\\App\\Models\\Type::class, 5)->create();\n\n $cities = factory(\\App\\Models\\City::class, 10)->create();\n\n $cities->each(function ($city) {\n $districts = factory(\\App\\Models\\District::class, rand(2, 5))->create([\n 'city_id' => $city->id,\n ]);\n\n $districts->each(function ($district) {\n $properties = factory(\\App\\Models\\Property::class, rand(2, 5))->create([\n 'type_id' => rand(1, 5),\n 'district_id' => $district->id\n ]);\n\n $properties->each(function ($property) {\n $galleries = factory(\\App\\Models\\Gallery::class, rand(3, 10))->create([\n 'property_id' => $property->id\n ]);\n });\n });\n });\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "public function run()\n {\n $this->call(CategoriesTableSeeder::class);\n\n $users = factory(App\\User::class, 5)->create();\n $recipes = factory(App\\Recipe::class, 30)->create();\n $preparations = factory(App\\Preparation::class, 70)->create();\n $photos = factory(App\\Photo::class, 90)->create();\n $comments = factory(App\\Comment::class, 200)->create();\n $flavours = factory(App\\Flavour::class, 25)->create();\n $flavour_recipe = factory(App\\FlavourRecipe::class, 50)->create();\n $tags = factory(App\\Tag::class, 25)->create();\n $recipe_tag = factory(App\\RecipeTag::class, 50)->create();\n $ingredients = factory(App\\Ingredient::class, 25)->create();\n $ingredient_preparation = factory(App\\IngredientPreparation::class, 300)->create();\n \n \n \n DB::table('users')->insert(['name' => 'SimpleUtilisateur', 'email' => '[email protected]', 'password' => bcrypt('SimpleMotDePasse')]);\n \n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n UsersLevel::create([\n 'name' => 'Administrator'\n ]);\n\n UsersLevel::create([\n 'name' => 'User'\n ]);\n\n User::create([\n 'username' => 'admin',\n 'password' => bcrypt('admin123'),\n 'level_id' => 1,\n 'fullname' => \"Super Admin\",\n 'email'=> \"[email protected]\"\n ]);\n\n\n \\App\\CategoryPosts::create([\n 'name' =>'Paket Trip'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' =>'Destinasi Kuliner'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Event'\n ]);\n\n \\App\\CategoryPosts::create([\n 'name' => 'Profil'\n ]);\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'avatar' => \"avatar\",\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',\n ]);\n $this->call(CategorySeeder::class);\n // \\App\\Models\\Admin::factory(1)->create();\n \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(50)->create();\n \\App\\Models\\PetComment::factory(50)->create();\n $pets = \\App\\Models\\Pet::factory(50)->create();\n foreach ($pets as $pet) {\n \\App\\Models\\PetTag::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\PetPhotoUrl::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\Order::factory(1)->create(['pet_id' => $pet->id]);\n };\n }", "public function run()\n { \n\n $this->call(RoleSeeder::class);\n \n $this->call(UserSeeder::class);\n\n Storage::deleteDirectory('socials-icon');\n Storage::makeDirectory('socials-icon');\n $socials = Social::factory(7)->create();\n\n Storage::deleteDirectory('countries-flag');\n Storage::deleteDirectory('countries-firm');\n Storage::makeDirectory('countries-flag');\n Storage::makeDirectory('countries-firm');\n $countries = Country::factory(18)->create();\n\n // Se llenan datos de la tabla muchos a muchos - social_country\n foreach ($countries as $country) {\n foreach ($socials as $social) {\n\n $country->socials()->attach($social->id, [\n 'link' => 'https://www.facebook.com/ministeriopalabrayespiritu/'\n ]);\n }\n }\n\n Person::factory(50)->create();\n\n Category::factory(7)->create();\n\n Video::factory(25)->create(); \n\n $this->call(PostSeeder::class);\n\n Storage::deleteDirectory('documents');\n Storage::makeDirectory('documents');\n Document::factory(25)->create();\n\n }", "public function run()\n {\n $faker = Faker::create('id_ID');\n /**\n * Generate fake author data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('author')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Generate fake publisher data\n */\n for ($i=1; $i<=50; $i++) { \n DB::table('publisher')->insert([\n 'name' => $faker->name\n ]);\n }\n /**\n * Seeding payment method\n */\n DB::table('payment')->insert([\n ['name' => 'Mandiri'],\n ['name' => 'BCA'],\n ['name' => 'BRI'],\n ['name' => 'BNI'],\n ['name' => 'Pos Indonesia'],\n ['name' => 'BTN'],\n ['name' => 'Indomaret'],\n ['name' => 'Alfamart'],\n ['name' => 'OVO'],\n ['name' => 'Cash On Delivery']\n ]);\n }", "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n // MyList::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 3; $i++) {\n MyList::create([\n 'title' => 'List-'.($i+1),\n 'color' => $faker->sentence,\n 'icon' => $faker->randomDigitNotNull,\n 'index' => $faker->randomDigitNotNull,\n 'user_id' => 1,\n ]);\n }\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Products::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few products in our database:\n for ($i = 0; $i < 50; $i++) {\n Products::create([\n 'name' => $faker->word,\n 'sku' => $faker->randomNumber(7, false),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n User::create([\n 'name' => 'Pablo Rosales',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'status' => 1,\n 'role_id' => 1,\n 'movil' => 0\n ]);\n\n User::create([\n 'name' => 'Usuario Movil',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'status' => 1,\n 'role_id' => 3,\n 'movil' => 1\n ]);\n\n Roles::create([\n 'name' => 'Administrador'\n ]);\n Roles::create([\n 'name' => 'Operaciones'\n ]);\n Roles::create([\n 'name' => 'Comercial'\n ]);\n Roles::create([\n 'name' => 'Aseguramiento'\n ]);\n Roles::create([\n 'name' => 'Facturación'\n ]);\n Roles::create([\n 'name' => 'Creditos y Cobros'\n ]);\n\n factory(App\\Customers::class, 100)->create();\n }", "public function run()\n {\n // php artisan db:seed --class=StoreTableSeeder\n\n foreach(range(1,20) as $i){\n $faker = Faker::create();\n Store::create([\n 'name' => $faker->name,\n 'desc' => $faker->text,\n 'tags' => $faker->word,\n 'address' => $faker->address,\n 'longitude' => $faker->longitude($min = -180, $max = 180),\n 'latitude' => $faker->latitude($min = -90, $max = 90),\n 'created_by' => '1'\n ]);\n }\n\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name'=>\"test\",\n 'password' => Hash::make('123'),\n 'email'=>'[email protected]'\n ]);\n DB::table('tags')->insert(['name'=>'tags']);\n $this->call(UserSeed::class);\n $this->call(CategoriesSeed::class);\n $this->call(TopicsSeed::class);\n $this->call(CommentariesSeed::class);\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n echo 'seeding permission...', PHP_EOL;\n $permissions = [\n 'role-list',\n 'role-create',\n 'role-edit',\n 'role-delete',\n 'formation-list',\n 'formation-create',\n 'formation-edit',\n 'formation-delete',\n 'user-list',\n 'user-create',\n 'user-edit',\n 'user-delete'\n ];\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n echo 'seeding users...', PHP_EOL;\n\n $user= User::create(\n [\n 'name' => 'Mr. admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'remember_token' => null,\n ]\n );\n echo 'Create Roles...', PHP_EOL;\n Role::create(['name' => 'former']);\n Role::create(['name' => 'learner']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'manager']);\n Role::create(['name' => 'user']);\n\n echo 'seeding Role User...', PHP_EOL;\n $user->assignRole('admin');\n $role = $user->assignRole('admin');\n $role->givepermissionTo(Permission::all());\n\n \\DB::table('languages')->insert(['name' => 'English', 'code' => 'en']);\n \\DB::table('languages')->insert(['name' => 'Français', 'code' => 'fr']);\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "public function run()\n {\n $this->call([\n UserSeeder::class,\n ]);\n\n User::factory(20)->create();\n Author::factory(20)->create();\n Book::factory(60)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UserSeeder::class);\n $this->call(RolePermissionSeeder::class);\n $this->call(AppmodeSeeder::class);\n\n // \\App\\Models\\Appmode::factory(3)->create();\n \\App\\Models\\Doctor::factory(100)->create();\n \\App\\Models\\Unit::factory(50)->create();\n \\App\\Models\\Broker::factory(100)->create();\n \\App\\Models\\Patient::factory(100)->create();\n \\App\\Models\\Expence::factory(100)->create();\n \\App\\Models\\Testcategory::factory(100)->create();\n \\App\\Models\\Test::factory(50)->create();\n \\App\\Models\\Parameter::factory(50)->create();\n \\App\\Models\\Sale::factory(50)->create();\n \\App\\Models\\SaleItem::factory(100)->create();\n \\App\\Models\\Goption::factory(1)->create();\n \\App\\Models\\Pararesult::factory(50)->create();\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // DB::table('roles')->insert(\n // [\n // ['name' => 'admin', 'description' => 'Administrator'],\n // ['name' => 'student', 'description' => 'Student'],\n // ['name' => 'lab_tech', 'description' => 'Lab Tech'],\n // ['name' => 'it_staff', 'description' => 'IT Staff Member'],\n // ['name' => 'it_manager', 'description' => 'IT Manager'],\n // ['name' => 'lab_manager', 'description' => 'Lab Manager'],\n // ]\n // );\n\n // DB::table('users')->insert(\n // [\n // 'username' => 'admin', \n // 'password' => Hash::make('password'), \n // 'active' => 1,\n // 'name' => 'Administrator',\n // 'email' => '[email protected]',\n // 'role_id' => \\App\\Role::where('name', 'admin')->first()->id\n // ]\n // );\n\n DB::table('status')->insert([\n // ['name' => 'Active'],\n // ['name' => 'Cancel'],\n // ['name' => 'Disable'],\n // ['name' => 'Open'],\n // ['name' => 'Closed'],\n // ['name' => 'Resolved'],\n ['name' => 'Used'],\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create([\n 'name' => 'Qwerty',\n 'email' => '[email protected]',\n 'password' => bcrypt('secretpassw'),\n ]);\n\n factory(User::class, 59)->create([\n 'password' => bcrypt('secretpassw'),\n ]);\n\n for ($i = 1; $i < 11; $i++) {\n factory(Category::class)->create([\n 'name' => 'Category ' . $i,\n ]);\n }\n\n for ($i = 1; $i < 101; $i++) {\n factory(Product::class)->create([\n 'name' => 'Product ' . $i,\n ]);\n }\n }", "public function run()\n {\n\n \t// Making main admin role\n \tDB::table('roles')->insert([\n 'name' => 'Admin',\n ]);\n\n // Making main category\n \tDB::table('categories')->insert([\n 'name' => 'Other',\n ]);\n\n \t// Making main admin account for testing\n \tDB::table('users')->insert([\n 'name' \t\t=> 'Admin',\n 'email' \t=> '[email protected]',\n 'password' => bcrypt('12345'),\n 'role_id' => 1,\n 'created_at' => date('Y-m-d H:i:s' ,time()),\n 'updated_at' => date('Y-m-d H:i:s' ,time())\n ]);\n\n \t// Making random users and posts\n factory(App\\User::class, 10)->create();\n factory(App\\Post::class, 35)->create();\n }", "public function run()\n {\n $faker = Faker::create();\n\n \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Chef',\n 'salario' => '15000.00'\n ));\n\n\t\t \\DB::table('positions')->insert(array (\n 'codigo' => strtoupper($faker->randomLetter).$faker->postcode,\n 'nombre' => 'Mesonero',\n 'salario' => '12000.00'\n ));\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = \\Faker\\Factory::create();\n\n foreach (range(1,5) as $index) {\n Lista::create([\n 'name' => $faker->sentence(2),\n 'description' => $faker->sentence(10), \n ]);\n } \n\n foreach (range(1,20) as $index) {\n $n = $faker->sentence(2);\n \tTarea::create([\n \t\t'name' => $n,\n \t\t'description' => $faker->sentence(10),\n 'lista_id' => $faker->numberBetween(1,5),\n 'slug' => Str::slug($n),\n \t\t]);\n } \n }", "public function run()\n {\n $faker = Faker::create('lt_LT');\n\n DB::table('users')->insert([\n 'name' => 'user',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n DB::table('users')->insert([\n 'name' => 'user2',\n 'email' => '[email protected]',\n 'password' => Hash::make('123')\n ]);\n\n foreach (range(1,100) as $val)\n DB::table('authors')->insert([\n 'name' => $faker->firstName(),\n 'surname' => $faker->lastName(),\n \n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(UsersTableSeeder::class);\n\n // DB::table('users')->insert([\n // 'name' => 'User1',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('password'),\n // ]);\n\n\n $faker = Faker::create();\n \n foreach (range(1,10) as $index){\n DB::table('companies')->insert([\n 'name' => $faker->company(),\n 'email' => $faker->email(10).'@gmail.com',\n 'logo' => $faker->image($dir = '/tmp', $width = 640, $height = 480),\n 'webiste' => $faker->domainName(),\n \n ]);\n }\n \n \n foreach (range(1,10) as $index){\n DB::table('employees')->insert([\n 'first_name' => $faker->firstName(),\n 'last_name' => $faker->lastName(),\n 'company' => $faker->company(),\n 'email' => $faker->str_random(10).'@gmail.com',\n 'phone' => $faker->e164PhoneNumber(),\n \n ]);\n }\n\n\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n Flight::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 100; $i++) {\n\n\n Flight::create([\n 'flightNumber' => $faker->randomNumber(5),\n 'depAirport' => $faker->city,\n 'destAirport' => $faker->city,\n 'reservedWeight' => $faker->numberBetween(1000 - 10000),\n 'deptTime' => $faker->dateTime('now'),\n 'arrivalTime' => $faker->dateTime('now'),\n 'reservedVolume' => $faker->numberBetween(1000 - 10000),\n 'airlineName' => $faker->colorName,\n ]);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->truncteTables([\n 'users',\n 'products'\n ]);\n\n $this->call(UsersSeeder::class);\n $this->call(ProductsSeeder::class);\n\n }", "public function run()\n {\n /**\n * Dummy seeds\n */\n DB::table('metas')->truncate();\n $faker = Faker::create();\n\n for ($i=0; $i < 10; $i++) { \n DB::table('metas')->insert([\n 'id_rel' => $faker->randomNumber(),\n 'titulo' => $faker->sentence,\n 'descricao' => $faker->paragraph,\n 'justificativa' => $faker->paragraph,\n 'valor_inicial' => $faker->numberBetween(0,100),\n 'valor_atual' => $faker->numberBetween(0,100),\n 'valor_final' => $faker->numberBetween(0,10),\n 'regras' => json_encode([$i => [\"values\" => $faker->words(3)]]),\n 'types' => json_encode([$i => [\"values\" => $faker->words(2)]]),\n 'categorias' => json_encode([$i => [\"values\" => $faker->words(4)]]),\n 'tags' => json_encode([$i => [\"values\" => $faker->words(5)]]),\n 'active' => true,\n ]);\n }\n\n\n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n\n $faker = Faker::create();\n\n $lessonIds = Lesson::lists('id')->all(); // An array of ID's in that table [1, 2, 3, 4, 5, 7]\n $tagIds = Tag::lists('id')->all();\n\n foreach(range(1, 30) as $index)\n {\n // a real lesson id\n // a real tag id\n DB::table('lesson_tag')->insert([\n 'lesson_id' => $faker->randomElement($lessonIds),\n 'tag_id' => $faker->randomElement($tagIds),\n ]);\n }\n }", "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "public function run()\n {\n // \\DB::statement('SET_FOREIGN_KEY_CHECKS=0');\n \\DB::table('users')->truncate();\n \\DB::table('posts')->truncate();\n // \\DB::table('category')->truncate();\n \\DB::table('photos')->truncate();\n \\DB::table('comments')->truncate();\n \\DB::table('comment_replies')->truncate();\n\n \\App\\Models\\User::factory()->times(10)->hasPosts(1)->create();\n \\App\\Models\\Role::factory()->times(10)->create();\n \\App\\Models\\Category::factory()->times(10)->create();\n \\App\\Models\\Comment::factory()->times(10)->hasReplies(1)->create();\n \\App\\Models\\Photo::factory()->times(10)->create();\n\n \n // \\App\\Models\\User::factory(10)->create([\n // 'role_id'=>2,\n // 'is_active'=>1\n // ]);\n\n // factory(App\\Models\\Post::class, 10)->create();\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $this->call([\n ArticleSeeder::class, \n TagSeeder::class,\n Arttagrel::class\n ]);\n // \\App\\Models\\User::factory(10)->create();\n \\App\\Models\\Article::factory()->count(7)->create();\n \\App\\Models\\Tag::factory()->count(15)->create(); \n \\App\\Models\\Arttagrel::factory()->count(15)->create(); \n }", "public function run()\n {\n $this->call(ArticulosTableSeeder::class);\n /*DB::table('articulos')->insert([\n 'titulo' => str_random(50),\n 'cuerpo' => str_random(200),\n ]);*/\n }", "public function run()\n {\n $this->call(CategoryTableSeeder::class);\n $this->call(ProductTableSeeder::class);\n\n \t\t\n\t\t\tDB::table('users')->insert([\n 'first_name' => 'Ignacio',\n 'last_name' => 'Garcia',\n 'email' => '[email protected]',\n 'password' => bcrypt('123456'),\n 'role' => '1',\n 'avatar' => 'CGnABxNYYn8N23RWlvTTP6C2nRjOLTf8IJcbLqRP.jpeg',\n ]);\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n $this->call(RoleSeeder::class);\n $this->call(UserSeeder::class);\n\n Medicamento::factory(50)->create();\n Reporte::factory(5)->create();\n Cliente::factory(200)->create();\n Asigna_valor::factory(200)->create();\n Carga::factory(200)->create();\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n TicketSeeder::class\n ]);\n\n DB::table('departments')->insert([\n 'abbr' => 'IT',\n 'name' => 'Information Technologies',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'email_verified_at' => Carbon::now(),\n 'password' => Hash::make('admin'),\n 'department_id' => 1,\n 'avatar' => 'default.png',\n 'created_at' => Carbon::now(),\n 'updated_at' => Carbon::now(),\n ]);\n\n DB::table('role_user')->insert([\n 'role_id' => 1,\n 'user_id' => 1\n ]);\n }", "public function run()\n {\n \\App\\Models\\Article::factory(20)->create();\n \\App\\Models\\Category::factory(5)->create();\n \\App\\Models\\Comment::factory(40)->create();\n\n \\App\\Models\\User::create([\n \"name\"=>\"Alice\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n \\App\\Models\\User::create([\n \"name\"=>\"Bob\",\n \"email\"=>'[email protected]',\n 'password' => Hash::make('password'),\n ]);\n }", "public function run()\n {\n /** \n * Note: You must add these lines to your .env file for this Seeder to work (replace the values, obviously):\n SEEDER_USER_FIRST_NAME = 'Firstname'\n SEEDER_USER_LAST_NAME = 'Lastname'\n\t\tSEEDER_USER_DISPLAY_NAME = 'Firstname Lastname'\n\t\tSEEDER_USER_EMAIL = [email protected]\n SEEDER_USER_PASSWORD = yourpassword\n */\n\t\tDB::table('users')->insert([\n 'user_first_name' => env('SEEDER_USER_FIRST_NAME'),\n 'user_last_name' => env('SEEDER_USER_LAST_NAME'),\n 'user_name' => env('SEEDER_USER_DISPLAY_NAME'),\n\t\t\t'user_email' => env('SEEDER_USER_EMAIL'),\n 'user_status' => 1,\n \t'password' => Hash::make((env('SEEDER_USER_PASSWORD'))),\n 'permission_fk' => 1,\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s')\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class,3)->create()->each(\n \tfunction($user)\n \t{\n \t\t$user->questions()\n \t\t->saveMany(\n \t\t\tfactory(App\\Question::class, rand(2,6))->make()\n \t\t)\n ->each(function ($q) {\n $q->answers()->saveMany(factory(App\\Answer::class, rand(1,5))->make());\n })\n \t}\n );\n }\n}", "public function run()\n {\n $faker = Faker::create();\n\n // $this->call(UsersTableSeeder::class);\n\n DB::table('posts')->insert([\n 'id'=>str_random(1),\n 'user_id'=> str_random(1),\n 'title' => $faker->name,\n 'body' => $faker->safeEmail,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s'),\n ]);\n }", "public function run()\n\t{\n\t\tDB::table(self::TABLE_NAME)->delete();\n\n\t\tforeach (seed(self::TABLE_NAME) as $row)\n\t\t\t$records[] = [\n\t\t\t\t'id'\t\t\t\t=> $row->id,\n\t\t\t\t'created_at'\t\t=> $row->created_at ?? Carbon::now(),\n\t\t\t\t'updated_at'\t\t=> $row->updated_at ?? Carbon::now(),\n\n\t\t\t\t'sport_id'\t\t\t=> $row->sport_id,\n\t\t\t\t'gender_id'\t\t\t=> $row->gender_id,\n\t\t\t\t'tournamenttype_id'\t=> $row->tournamenttype_id ?? null,\n\n\t\t\t\t'name'\t\t\t\t=> $row->name,\n\t\t\t\t'external_id'\t\t=> $row->external_id ?? null,\n\t\t\t\t'is_top'\t\t\t=> $row->is_top ?? null,\n\t\t\t\t'logo'\t\t\t\t=> $row->logo ?? null,\n\t\t\t\t'position'\t\t\t=> $row->position ?? null,\n\t\t\t];\n\n\t\tinsert(self::TABLE_NAME, $records ?? []);\n\t}", "public function run()\n\t{\n\t\tDB::table('libros')->truncate();\n\n\t\t$faker = Faker\\Factory::create();\n\n\t\tfor ($i=0; $i < 10; $i++) { \n\t\t\tLibro::create([\n\n\t\t\t\t'titulo'\t\t=> $faker->text(40),\n\t\t\t\t'isbn'\t\t\t=> $faker->numberBetween(100,999),\n\t\t\t\t'precio'\t\t=> $faker->randomFloat(2,3,150),\n\t\t\t\t'publicado'\t\t=> $faker->numberBetween(0,1),\n\t\t\t\t'descripcion'\t=> $faker->text(400),\n\t\t\t\t'autor_id'\t\t=> $faker->numberBetween(1,3),\n\t\t\t\t'categoria_id'\t=> $faker->numberBetween(1,3)\n\n\t\t\t]);\n\t\t}\n\n\t\t// Uncomment the below to run the seeder\n\t\t// DB::table('libros')->insert($libros);\n\t}", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 10)->create()->each(function ($user) {\n // Seed the relation with 5 purchases\n // $videos = factory(App\\Video::class, 5)->make();\n // $user->videos()->saveMany($videos);\n // $user->videos()->each(function ($video){\n // \t$video->videometa()->save(factory(App\\VideoMeta::class)->make());\n // \t// :( \n // });\n factory(App\\User::class, 10)->create()->each(function ($user) {\n\t\t\t factory(App\\Video::class, 5)->create(['user_id' => $user->id])->each(function ($video) {\n\t\t\t \tfactory(App\\VideoMeta::class, 1)->create(['video_id' => $video->id]);\n\t\t\t // $video->videometa()->save(factory(App\\VideoMeta::class)->create(['video_id' => $video->id]));\n\t\t\t });\n\t\t\t});\n\n });\n }", "public function run()\n {\n // for($i=1;$i<11;$i++){\n // DB::table('post')->insert(\n // ['title' => 'Title'.$i,\n // 'post' => 'Post'.$i,\n // 'slug' => 'Slug'.$i]\n // );\n // }\n $faker = Faker\\Factory::create();\n \n for($i=1;$i<20;$i++){\n $dname = $faker->name;\n DB::table('post')->insert(\n ['title' => $dname,\n 'post' => $faker->text($maxNbChars = 200),\n 'slug' => str_slug($dname)]\n );\n }\n }", "public function run()\n {\n $this->call([\n CountryTableSeeder::class,\n ProvinceTableSeeder::class,\n TagTableSeeder::class\n ]);\n\n User::factory()->count(10)->create();\n Category::factory()->count(5)->create();\n Product::factory()->count(20)->create();\n Section::factory()->count(5)->create();\n Bundle::factory()->count(20)->create();\n\n $bundles = Bundle::all();\n // populate bundle-product table (morph many-to-many)\n Product::all()->each(function ($product) use ($bundles) {\n $product->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray(),\n ['default_quantity' => rand(1, 10)]\n );\n });\n // populate bundle-tags table (morph many-to-many)\n Tag::all()->each(function ($tag) use ($bundles) {\n $tag->bundles()->attach(\n $bundles->random(2)->pluck('id')->toArray()\n );\n });\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n Contract::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Contract::create([\n 'serialnumbers' => $faker->numberBetween($min = 1000000, $max = 2000000),\n 'address' => $faker->address,\n 'landholder' => $faker->lastName,\n 'renter' => $faker->lastName,\n 'price' => $faker->numberBetween($min = 10000, $max = 50000),\n 'rent_start' => $faker->date($format = 'Y-m-d', $max = 'now'),\n 'rent_end' => $faker->date($format = 'Y-m-d', $max = 'now'),\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker=Faker\\Factory::create();\n\n for($i=0;$i<100;$i++){\n \tApp\\Blog::create([\n \t\t'title' => $faker->catchPhrase,\n 'description' => $faker->text,\n 'showns' =>true\n \t\t]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // TO PREVENT CHECKS FOR foreien key in seeding\n\n User::truncate();\n Category::truncate();\n Product::truncate();\n Transaction::truncate();\n\n DB::table('category_product')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Product::flushEventListeners();\n Transaction::flushEventListeners();\n\n $usersQuantities = 1000;\n $categoriesQuantities = 30;\n $productsQuantities = 1000;\n $transactionsQuantities = 1000;\n\n factory(User::class, $usersQuantities)->create();\n factory(Category::class, $categoriesQuantities)->create();\n\n factory(Product::class, $productsQuantities)->create()->each(\n function ($product) {\n $categories = Category::all()->random(mt_rand(1, 5))->pluck('id');\n $product->categories()->attach($categories);\n });\n\n factory(Transaction::class, $transactionsQuantities)->create();\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n $this->call(PermissionsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n\n $this->call(BusinessTableSeeder::class);\n $this->call(PrinterTableSeeder::class);\n factory(App\\Tag::class,10)->create();\n factory(App\\Category::class,10)->create();\n factory(App\\Subcategory::class,50)->create();\n factory(App\\Provider::class,10)->create();\n factory(App\\Product::class,24)->create()->each(function($product){\n\n $product->images()->saveMany(factory(App\\Image::class, 4)->make());\n\n });\n\n\n factory(App\\Client::class,10)->create();\n }", "public function run()\n {\n Article::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 50; $i++) {\n Article::create([\n 'name' => $faker->sentence,\n 'sku' => $faker->paragraph,\n 'price' => $faker->number,\n ]);\n }\n }", "public function run()\n {\n Storage::deleteDirectory('public/products');\n Storage::makeDirectory('public/products');\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n $this->call(ProductSeeder::class);\n Order::factory(4)->create();\n Order_Detail::factory(4)->create();\n Size::factory(100)->create();\n }", "public function run()\n {\n $this->call(RolSeeder::class);\n\n $this->call(UserSeeder::class);\n Category::factory(4)->create();\n Doctor::factory(25)->create();\n Patient::factory(50)->create();\n Status::factory(3)->create();\n Appointment::factory(100)->create();\n }", "public function run()\n\t{\n\t\t\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n\t\t$faker = \\Faker\\Factory::create();\n\n\t\tTodolist::truncate();\n\n\t\tforeach(range(1, 50) as $index)\n\t\t{\n\n\t\t\t$user = User::create([\n\t\t\t\t'name' => $faker->name,\n\t\t\t\t'email' => $faker->email,\n\t\t\t\t'password' => 'password',\n\t\t\t\t'confirmation_code' => mt_rand(0, 9),\n\t\t\t\t'confirmation' => rand(0,1) == 1\n\t\t\t]);\n\n\t\t\t$list = Todolist::create([\n\t\t\t\t'name' => $faker->sentence(2),\n\t\t\t\t'description' => $faker->sentence(4),\n\t\t\t]);\n\n\t\t\t// BUILD SOME TASKS FOR EACH LIST ITEM\n\t\t\tforeach(range(1, 10) as $index) \n\t\t\t{\n\t\t\t\t$task = new Task;\n\t\t\t\t$task->name = $faker->sentence(2);\n\t\t\t\t$task->description = $faker->sentence(4);\n\t\t\t\t$list->tasks()->save($task);\n\t\t\t}\n\n\t\t}\n\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS = 1'); \n\n\t}", "public function run()\n {\n Campus::truncate();\n Canteen::truncate();\n Dorm::truncate();\n\n $faker = Faker\\Factory::create();\n $schools = School::all();\n foreach ($schools as $school) {\n \tforeach (range(1, 2) as $index) {\n\t \t$campus = Campus::create([\n\t \t\t'school_id' => $school->id,\n\t \t\t'name' => $faker->word . '校区',\n\t \t\t]);\n\n \t$campus->canteens()->saveMany(factory(Canteen::class, mt_rand(2,3))->make());\n $campus->dorms()->saveMany(factory(Dorm::class, mt_rand(2,3))->make());\n\n }\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::table('users')->insert([\n 'name' => 'admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'seq_q'=>'1',\n 'seq_a'=>'admin'\n ]);\n\n // DB::table('bloods')->insert([\n // ['name' => 'A+'],\n // ['name' => 'A-'],\n // ['name' => 'B+'],\n // ['name' => 'B-'],\n // ['name' => 'AB+'],\n // ['name' => 'AB-'],\n // ['name' => 'O+'],\n // ['name' => 'O-'],\n // ]);\n\n \n }", "public function run()\n {\n // $this->call(UserTableSeeder::class);\n \\App\\User::create([\n 'name'=>'PAPE SAMBA NDOUR',\n 'email'=>'[email protected]',\n 'password'=>bcrypt('Admin1122'),\n ]);\n\n $faker = Faker::create();\n\n for ($i = 0; $i < 100 ; $i++)\n {\n $firstName = $faker->firstName;\n $lastName = $faker->lastName;\n $niveau = \\App\\Niveau::inRandomOrder()->first();\n \\App\\Etudiant::create([\n 'prenom'=>$firstName,\n 'nom'=>$lastName,\n 'niveau_id'=>$niveau->id\n ]);\n }\n\n\n }", "public function run()\n {\n //\n DB::table('foods')->delete();\n\n Foods::create(array(\n 'name' => 'Chicken Wing',\n 'author' => 'Bambang',\n 'overview' => 'a deep-fried chicken wing, not in spicy sauce'\n ));\n\n Foods::create(array(\n 'name' => 'Beef ribs',\n 'author' => 'Frank',\n 'overview' => 'Slow baked beef ribs rubbed in spices'\n ));\n\n Foods::create(array(\n 'name' => 'Ice cream',\n 'author' => 'Lou',\n 'overview' => ' A sweetened frozen food typically eaten as a snack or dessert.'\n ));\n\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n News::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 10; $i++) {\n News::create([\n 'title' => $faker->sentence,\n 'summary' => $faker->sentence,\n 'content' => $faker->paragraph,\n 'imagePath' => '/img/exclamation_mark.png'\n ]);\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(App\\User::class, 3)->create();\n factory(App\\Models\\Category::class, 3)\n ->create()\n ->each(function ($u) {\n $u->courses()->saveMany(factory(App\\Models\\Course::class,3)->make())->each(function ($c){\n $c->exams()->saveMany(factory(\\App\\Models\\Exam::class,3)->make())->each(function ($e){\n $e->questions()->saveMany(factory(\\App\\Models\\Question::class,4)->make())->each(function ($q){\n $q->answers()->saveMany(factory(\\App\\Models\\Answer::class,4)->make())->each(function ($a){\n $a->correctAnswer()->save(factory(\\App\\Models\\Correct_answer::class)->make());\n });\n });\n });\n });\n\n });\n\n }", "public function run()\n {\n \\DB::table('employees')->delete();\n\n $faker = \\Faker\\Factory::create('ja_JP');\n\n $role_id = ['1','2','3'];\n\n for ($i = 0; $i < 10; $i++) {\n \\App\\Models\\Employee::create([\n 'last_name' =>$faker->lastName() ,\n 'first_name' => $faker->firstName(),\n 'mail' => $faker->email(),\n 'password' => Hash::make( \"password.$i\"),\n 'birthday' => $faker->date($format='Y-m-d',$max='now'),\n 'role_id' => $faker->randomElement($role_id)\n ]);\n }\n }", "public function run()\n {\n\n DB::table('clients')->delete();\n DB::table('trips')->delete();\n error_log('empty tables done.');\n\n $random_cities = City::inRandomOrder()->select('ar_name')->limit(5)->get();\n $GLOBALS[\"random_cities\"] = $random_cities->pluck('ar_name')->toArray();\n\n $random_airlines = Airline::inRandomOrder()->select('code')->limit(5)->get();\n $GLOBALS[\"random_airlines\"] = $random_airlines->pluck('code')->toArray();\n\n factory(App\\Client::class, 5)->create();\n error_log('Client seed done.');\n\n\n factory(App\\Trip::class, 50)->create();\n error_log('Trip seed done.');\n\n\n factory(App\\Quicksearch::class, 10)->create();\n error_log('Quicksearch seed done.');\n }", "public function run()\n {\n // Admins\n User::factory()->create([\n 'name' => 'Zaiman Noris',\n 'username' => 'rognales',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n User::factory()->create([\n 'name' => 'Affiq Rashid',\n 'username' => 'affiqr',\n 'email' => '[email protected]',\n 'active' => true,\n ]);\n\n // Only seed test data in non-prod\n if (! app()->isProduction()) {\n Member::factory()->count(1000)->create();\n Staff::factory()->count(1000)->create();\n\n Participant::factory()\n ->addSpouse()\n ->addChildren()\n ->addInfant()\n ->addOthers()\n ->count(500)\n ->hasUploads(2)\n ->create();\n }\n }", "public function run()\n {\n $this->call([\n RoleSeeder::class,\n UserSeeder::class,\n ]);\n\n \\App\\Models\\Category::factory(4)->create();\n \\App\\Models\\View::factory(6)->create();\n \\App\\Models\\Room::factory(8)->create();\n \n $rooms = \\App\\Models\\Room::all();\n // \\App\\Models\\User::all()->each(function ($user) use ($rooms) { \n // $user->rooms()->attach(\n // $rooms->random(rand(1, \\App\\Models\\Room::max('id')))->pluck('id')->toArray()\n // ); \n // });\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n Employee::factory()->create(['email' => '[email protected]']);\n Brand::factory()->count(3)->create();\n $this->call([\n TagSeeder::class,\n AttributeSeeder::class,\n AttributeValueSeeder::class,\n ProductSeeder::class,\n ]);\n }", "public function run()\n {\n $this->call(RolesTableSeeder::class); // crée les rôles\n $this->call(PermissionsTableSeeder::class); // crée les permissions\n\n factory(Employee::class,3)->create();\n factory(Provider::class,1)->create();\n\n $user = User::create([\n 'name'=>'Alioune Bada Ndoye',\n 'email'=>'[email protected]',\n 'phone'=>'773012470',\n 'password'=>bcrypt('123'),\n ]);\n Employee::create([\n 'job'=>'Informaticien',\n 'user_id'=>User::where('email','[email protected]')->first()->id,\n 'point_id'=>Point::find(1)->id,\n ]);\n $user->assignRole('admin');\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(User::class, 1)\n \t->create(['email' => '[email protected]']);\n\n factory(Category::class, 5)->create();\n }", "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "public function run()\n {\n \n User::factory(1)->create([\n 'rol'=>'EPS'\n ]);\n Person::factory(10)->create();\n $this->call(EPSSeeder::class);\n $this->call(OfficialSeeder::class);\n $this->call(VVCSeeder::class);\n $this->call(VaccineSeeder::class);\n }", "public function run()\n {\n // $faker=Faker::create();\n // foreach(range(1,100) as $index)\n // {\n // DB::table('products')->insert([\n // 'name' => $faker->name,\n // 'price' => rand(10,100000)/100\n // ]);\n // }\n }", "public function run()\n {\n $this->call([\n LanguagesTableSeeder::class,\n ListingAvailabilitiesTableSeeder::class,\n ListingTypesTableSeeder::class,\n RoomTypesTableSeeder::class,\n AmenitiesTableSeeder::class,\n UsersTableSeeder::class,\n UserLanguagesTableSeeder::class,\n ListingsTableSeeder::class,\n WishlistsTableSeeder::class,\n StaysTableSeeder::class,\n GuestsTableSeeder::class,\n TripsTableSeeder::class,\n ReviewsTableSeeder::class,\n RatingsTableSeeder::class,\n PopularDestinationsTableSeeder::class,\n ImagesTableSeeder::class,\n ]);\n\n // factory(App\\User::class, 5)->states('host')->create();\n // factory(App\\User::class, 10)->states('hostee')->create();\n\n // factory(App\\User::class, 10)->create();\n // factory(App\\Models\\Listing::class, 30)->create();\n }", "public function run()\n {\n Schema::disableForeignKeyConstraints();\n Grade::truncate();\n Schema::enableForeignKeyConstraints();\n\n $faker = \\Faker\\Factory::create();\n\n for ($i = 0; $i < 10; $i++) {\n Grade::create([\n 'letter' => $faker->randomElement(['а', 'б', 'в']),\n 'school_id' => $faker->unique()->numberBetween(1, School::count()),\n 'level' => 1\n ]);\n }\n }", "public function run()\n {\n // $this->call(UserSeeder::class);\n factory(App\\User::class,5)->create();//5 User created\n factory(App\\Model\\Genre::class,5)->create();//5 genres\n factory(App\\Model\\Film::class,6)->create();//6 films\n factory(App\\Model\\Comment::class, 20)->create();// 20 comments\n }", "public function run()\n {\n\n $this->call(UserSeeder::class);\n factory(Empresa::class,10)->create();\n factory(Empleado::class,50)->create();\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n User::create([\n 'name' => 'jose luis',\n 'email' => '[email protected]',\n 'password' => bcrypt('xxxxxx'),\n 'role' => 'admin',\n ]);\n\n Category::create([\n 'name' => 'inpods',\n 'description' => 'auriculares inalambricos que funcionan con blouthue genial'\n ]);\n\n Category::create([\n 'name' => 'other',\n 'description' => 'otra cosa diferente a un inpods'\n ]);\n\n\n /* Create 10 products */\n Product::factory(10)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Russell'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Bitfumes'\n ]);\n\n factory(User::class)->create([\n 'email' => '[email protected]',\n 'name' => 'Paul'\n ]);\n }", "public function run()\n {\n $user_ids = [1,2,3];\n $faker = app(\\Faker\\Generator::class);\n $posts = factory(\\App\\Post::class)->times(50)->make()->each(function($post) use ($user_ids,$faker){\n $post->user_id = $faker->randomElement($user_ids);\n });\n \\App\\Post::insert($posts->toArray());\n }", "public function run()\n {\n // Vaciar la tabla.\n Favorite::truncate();\n $faker = \\Faker\\Factory::create();\n // Crear artículos ficticios en la tabla\n\n // factory(App\\Models\\User::class, 2)->create()->each(function ($user) {\n // $user->users()->saveMany(factory(App\\Models\\User::class, 25)->make());\n //});\n }", "public function run()\n\t{\n\t\t$this->call(ProductsTableSeeder::class);\n\t\t$this->call(CategoriesTableSeeder::class);\n\t\t$this->call(BrandsTableSeeder::class);\n\t\t$this->call(ColorsTableSeeder::class);\n\n\t\t$products = \\App\\Product::all();\n \t$categories = \\App\\Category::all();\n \t$brands = \\App\\Brand::all();\n \t$colors = \\App\\Color::all();\n\n\t\tforeach ($products as $product) {\n\t\t\t$product->colors()->sync($colors->random(3));\n\n\t\t\t$product->category()->associate($categories->random(1)->first());\n\t\t\t$product->brand()->associate($brands->random(1)->first());\n\n\t\t\t$product->save();\n\t\t}\n\n\t\t// for ($i = 0; $i < count($products); $i++) {\n\t\t// \t$cat = $categories[rand(0,5)];\n\t\t// \t$bra = $brands[rand(0,7)];\n\t\t// \t$cat->products()->save($products[$i]);\n\t\t// \t$bra->products()->save($products[$i]);\n\t\t// }\n\n\t\t// $products = factory(App\\Product::class)->times(20)->create();\n\t\t// $categories = factory(App\\Category::class)->times(6)->create();\n\t\t// $brands = factory(App\\Brand::class)->times(8)->create();\n\t\t// $colors = factory(App\\Color::class)->times(15)->create();\n\t}", "public function run()\n {\n /*$this->call(UsersTableSeeder::class);\n $this->call(GroupsTableSeeder::class);\n $this->call(TopicsTableSeeder::class);\n $this->call(CommentsTableSeeder::class);*/\n DB::table('users')->insert([\n 'name' => 'pkw',\n 'email' => '[email protected]',\n 'password' => bcrypt('secret'),\n 'type' => '1'\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n $faker = Faker::create();\n foreach (range(1,200) as $index) {\n DB::table('users')->insert([\n 'name' => $faker->name,\n 'email' => $faker->email,\n 'phone' => $faker->randomDigitNotNull,\n 'address'=> $faker->streetAddress,\n 'password' => bcrypt('secret'),\n ]);\n }\n }", "public function run()\n {\n $this->call(UsersSeeder::class);\n User::factory(2)->create();\n Company::factory(2)->create();\n\n }", "public function run()\n {\n echo PHP_EOL , 'seeding roles...';\n\n Role::create(\n [\n 'name' => 'Admin',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Principal',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Teacher',\n 'deletable' => false,\n ]\n );\n\n Role::create(\n [\n 'name' => 'Student',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Parents',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Accountant',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Librarian',\n 'deletable' => false,\n ]\n );\n Role::create(\n [\n 'name' => 'Receptionist',\n 'deletable' => false,\n ]\n );\n\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(QuestionTableSeed::class);\n\n $this->call([\n QuestionTableSeed::class,\n AlternativeTableSeed::class,\n ScheduleActionTableSeeder::class,\n UserTableSeeder::class,\n CompanyClassificationTableSeed::class,\n ]);\n // DB::table('clients')->insert([\n // 'name' => 'Empresa-02',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('07.052.477/0001-60'),\n // ]);\n }", "public function run()\n {\n $faker = \\Faker\\Factory::create();\n\n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 5; $i++) {\n Runner::create([\n 'external_id' => $faker->uuid,\n 'name' => $faker->name,\n 'race_id' =>rand(1,5),\n 'age' => rand(30, 45),\n 'sex' => $faker->randomElement(['male', 'female']),\n 'color' => $faker->randomElement(['#ecbcb4', '#d1a3a4']),\n ]);\n }\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n User::factory()->create([\n 'name' => 'Carlos',\n 'email' => '[email protected]',\n 'email_verified_at' => now(),\n 'password' => bcrypt('123456'), // password\n 'remember_token' => Str::random(10),\n ]);\n \n $this->call([PostsTableSeeder::class]);\n $this->call([TagTableSeeder::class]);\n\n }", "public function run()\n {\n $this->call(AlumnoSeeder::class);\n //Alumnos::factory()->count(30)->create();\n //DB::table('alumnos')->insert([\n // 'dni_al' => '13189079',\n // 'nom_al' => 'Jose',\n // 'ape_al' => 'Araujo',\n // 'rep_al' => 'Principal',\n // 'esp_al' => 'Tecnologia',\n // 'lnac_al' => 'Valencia'\n //]);\n }", "public function run()\n {\n Eloquent::unguard();\n\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // $this->call([\n // CountriesTableSeeder::class,\n // ]);\n\n factory(App\\User::class, 100)->create();\n factory(App\\Type::class, 10)->create();\n factory(App\\Item::class, 100)->create();\n factory(App\\Order::class, 1000)->create();\n\n $items = App\\Item::all();\n\n App\\Order::all()->each(function($order) use ($items) {\n\n $n = rand(1, 10);\n\n $order->items()->attach(\n $items->random($n)->pluck('id')->toArray()\n , ['quantity' => $n]);\n\n $order->total = $order->items->sum(function($item) {\n return $item->price * $item->pivot->quantity;\n });\n\n $order->save();\n\n });\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'izzanni',\n \n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'aina',\n\n ]\n );\n factory(User::class)->create(\n [\n 'email'=>'[email protected]',\n 'name'=>'sab',\n\n ]\n );\n }", "public function run()\n {\n\n factory('App\\Models\\Pessoa', 60)->create();\n factory('App\\Models\\Profissional', 10)->create();\n factory('App\\Models\\Paciente', 50)->create();\n $this->call(UsersTableSeeder::class);\n $this->call(ProcedimentoTableSeeder::class);\n // $this->call(PessoaTableSeeder::class);\n // $this->call(ProfissionalTableSeeder::class);\n // $this->call(PacienteTableSeeder::class);\n // $this->call(AgendaProfissionalTableSeeder::class);\n }", "public function run()\n {\n //Acá se define lo que el seeder va a hacer.\n //insert() para insertar datos.\n //Array asociativo. La llave es el nombre de la columna.\n// DB::table('users')->insert([\n// //Para un solo usuario.\n// 'name' => 'Pedrito Perez',\n// 'email' => '[email protected]',\n// 'password' => bcrypt('123456')\n// ]);//Se indica el nombre de la tabla.\n\n //Crea 50 usuarios (sin probar)\n// factory(App\\User::class, 50)->create()->each(function($u) {\n// $u->posts()->save(factory(App\\Post::class)->make());\n// });\n\n factory(App\\User::class, 10)->create(); //Así se ejecuta el model factory creado en ModelFactory.php\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n //nhập liệu mẫu cho bảng users\n DB::table('users')->insert([\n \t['id'=>'1001', 'name'=>'Phan Thị Hiền', 'email'=>'[email protected]', 'password'=>'123456', 'isadmin'=>1],\n \t['id'=>'1002', 'name'=>'Phan Thị Hà', 'email'=>'[email protected]', 'password'=>'111111', 'isadmin'=>0]\n ]);\n\n\n //nhập liệu mẫu cho bảng suppliers\n DB::table('suppliers')->insert([\n \t['name'=>'FPT', 'address'=>'151 Hùng Vương, TP. Đà Nẵng', 'phonenum'=>'0971455395'],\n \t['name'=>'Điện Máy Xanh', 'address'=>'169 Phan Châu Trinh, TP. Đà Nẵng', 'phonenum'=>'0379456011']\n ]);\n\n\n //Bảng phiếu bảo hành\n }", "public function run()\n {\n \t// DB::table('categories')->truncate();\n // factory(App\\Models\\Category::class, 10)->create();\n Schema::disableForeignKeyConstraints();\n Category::truncate();\n $faker = Faker\\Factory::create();\n\n $categories = ['SAMSUNG','NOKIA','APPLE','BLACK BERRY'];\n foreach ($categories as $key => $value) {\n Category::create([\n 'name'=>$value,\n 'description'=> 'This is '.$value,\n 'markup'=> rand(10,100),\n 'category_id'=> null,\n 'UUID' => $faker->uuid,\n ]);\n }\n }" ]
[ "0.8013876", "0.79804534", "0.7976992", "0.79542726", "0.79511505", "0.7949612", "0.794459", "0.7942486", "0.7938189", "0.79368967", "0.79337025", "0.78924936", "0.78811055", "0.78790957", "0.78787595", "0.787547", "0.7871811", "0.78701615", "0.7851422", "0.7850352", "0.7841468", "0.7834583", "0.7827792", "0.7819104", "0.78088796", "0.7802872", "0.7802348", "0.78006834", "0.77989215", "0.7795819", "0.77903426", "0.77884805", "0.77862066", "0.7778816", "0.7777486", "0.7765202", "0.7762492", "0.77623445", "0.77621746", "0.7761383", "0.77606887", "0.77596676", "0.7757001", "0.7753607", "0.7749522", "0.7749292", "0.77466977", "0.7729947", "0.77289546", "0.772796", "0.77167094", "0.7714503", "0.77140456", "0.77132195", "0.771243", "0.77122366", "0.7711113", "0.77109736", "0.7710777", "0.7710086", "0.7705484", "0.770464", "0.7704354", "0.7704061", "0.77027386", "0.77020216", "0.77008796", "0.7698617", "0.76985973", "0.76973504", "0.7696405", "0.7694293", "0.7692694", "0.7691264", "0.7690576", "0.76882726", "0.7687433", "0.7686844", "0.7686498", "0.7685065", "0.7683827", "0.7679184", "0.7678287", "0.76776296", "0.76767945", "0.76726556", "0.76708084", "0.76690495", "0.766872", "0.76686716", "0.7666299", "0.76625943", "0.7662227", "0.76613766", "0.7659881", "0.7656644", "0.76539344", "0.76535016", "0.7652375", "0.7652313", "0.7652022" ]
0.0
-1
get data by id
function get_by_id($id) { $this->db->join('tbl_ijin','tbl_out.id_ijin=tbl_ijin.id_ijin'); $this->db->join('tbl_perusahaan','tbl_out.id_perusahaan=tbl_perusahaan.id_perusahaan'); $this->db->where($this->id, $id); return $this->db->get($this->table)->row(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function get( $id ){}", "public function get( $id );", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get($id);", "public function get(string $id);", "public function getById( $id );", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "public function getById($id);", "abstract public function get($id);", "abstract public function get($id);", "abstract public function get($id);", "public function read($id);", "public function get($id) {\n\t}", "public function get_data_by_id()\n {\n $token = $this->getAuthHeader();\n $data = $this->request->getJSON();\n $ret_data = [];\n\n //init data\n $id = isset( $data->id ) ? $data->id : -1;\n\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 $db_data = $this->_getCurrentData($id);\n\n if ( $this->db->error()['message'] !== '' ) {\n $dataDB['status'] = \"error\";\n $dataDB['message'] = $this->db->error()['message'];\n $dataDB['data'] = \"\";\n\n return $this->respond( $dataDB, 200 );\n }\n\n if ( !empty($db_data) ) {\n $ret_data[] = $this->_mappingData($db_data);\n $ret_data[] = $this->_mappingData($db_data);\n }\n \n\n $dataDB['status'] = \"success\";\n $dataDB['message'] = \"\";\n $dataDB['data'] = $ret_data;\n\n return $this->respond( $dataDB, 200 );\n }", "function get(string $id);", "public abstract function get($id);", "public function retrieve(int $id);", "abstract public function getById($id);", "abstract public function getById($id);", "public function getById(int $id);", "function getData($id){\n // ineed to be more clear about where to get this data because i need to nkow where i should pick up this data from?\n return $this->db->get_where(\"mahasiswa\",array('nim' => $id))->row();\n }", "public function getById(string $id);", "public static function get($id) {\n\t\tself::load();\n\t\treturn self::$data[$id];\n\t}", "public abstract function getById($id);", "abstract public function retrieve($id);", "public function retrieveById($id);", "public function get($id)\n {\n }", "public function get($id)\n {\n }", "public function get($id){\n }", "public function getDataById($id)\n {\n $this->getData($id);\n return $this->data;\n }", "public function getDataById($id) {\n\t\treturn $this->simu !== null ? $this->simu->getDataById($id) : null;\n\t}", "public function fetch($id);", "public function fetch($id);", "function get_by_id($id)\n {\n $this->db2->where($this->id, $id);\n return $this->db2->get($this->table)->row();\n }", "public function index_get($id = 0)\n\t{\n if(!empty($id)){\n $data = $this->db->get_where($_table, [$_id => $id])->row_array();\n }else{\n $data = $this->db->get($_table)->result();\n }\n \n $this->response($data, REST_Controller::HTTP_OK);\n\t}", "public function getById($id)\n {\n }", "public function getById($id)\n {\n }", "function get_by_id($id) {\r\n $this->db->where('id', $id);\r\n return $this->db->get($this->tbl);\r\n }", "public function getById($id)\n {\n return $this->prepareData($this->model->find($id));\n }", "function get_by_id($id)\n {\n $db2 = $this->load->database('database_kedua', TRUE);\n\n $db2->where($this->id, $id);\n return $db2->get($this->table)->row();\n }", "public function GetById($id);", "public function GetById($id);", "function getdatait( $id = 0 )\n\t{\n\t\tif ($id === 0 ){\n\t\t\t$id = $this->datasis->dameval(\"SELECT MAX(id) FROM prdo\");\n\t\t}\n\t\tif(empty($id)) return \"\";\n\t\t$numero = $this->datasis->dameval(\"SELECT numero FROM prdo WHERE id=$id\");\n\t\t$grid = $this->jqdatagrid;\n\t\t$mSQL = \"SELECT * FROM itprdo WHERE numero='${numero}' \";\n\t\t$response = $grid->getDataSimple($mSQL);\n\t\t$rs = $grid->jsonresult( $response);\n\t\techo $rs;\n\t}", "public function getById() {}", "public function getById($id) {\r\n\r\n $data = $this->adapter->request('GET', \"{$this->url}/{$id}\");\r\n\r\n return $this->_makeEntry($data, $id, \"{$this->url}/{$id}\");\r\n\r\n }", "public function byId($id);", "public function byId($id);", "public function byId($id);", "public function byId($id);", "public function read($id)\n {\n }", "public function read($id)\n {\n }", "function getdatait( $id = 0 ){\n\t\tif($id === 0){\n\t\t\t$id = intval($this->datasis->dameval(\"SELECT MAX(id) FROM rcobro\"));\n\t\t}\n\t\tif(empty($id)) return '';\n\t\t$grid = $this->jqdatagrid;\n\t\t$mSQL = \"SELECT * FROM smov WHERE rcobro=${id}\";\n\t\t$response = $grid->getDataSimple($mSQL);\n\t\t$rs = $grid->jsonresult( $response);\n\t\techo $rs;\n\t}", "public function getDataByID($id){\n $query = $this->db->query('select from books where ID');\n }", "public function getRecord($id = null);", "public function get( $iId );", "function getDataFromId($id)\n {\n return $this->db->get_where('users', ['id' => $id])->row_array();\n }", "public function getLazyData($id);", "function get_data_by_id(){\n\t\tglobal $db;\n\t\t$data=array();\n\t\tif($this->id!=''){\n\t\t\t$sql=\"SELECT * FROM $this->table where id = ? \";\n\t\t\t$db->query($sql, array($this->id));\n\t\t\t$data=$db->fetch_assoc();\n\t\t\t}else{\n\t\t\t $data['id']='0'; $data['email']='';\n\t }\n return $data;\n\t}", "public function get_by_id($id)\r\n\t{\r\n\t\treturn $this->findByPoperty(array($this->id_field => $id));\r\n\t}", "public function getItem ($id);", "function get_by_id($id)\r\n {\r\n $this->db->where($this->id, $id);\r\n return $this->db->get($this->table)->row();\r\n }", "function get($id){ \t\n \tif(isset($id)){\n \t\t$result = $this->model->selectWhere('*',\"id = \".\"'$id'\");\n \t\techo json_encode($result);\n \t}else{\n \t\techo json_encode('failed');\n \t} \t\n }", "public function get($id)\n {\n return $this->where('id = ?' , $id)->fetch($this->table);\n }", "function getdatait( $id = 0 ){\n\t\tif ($id === 0 ){\n\t\t\t$id = $this->datasis->dameval(\"SELECT MAX(id) FROM scon\");\n\t\t}\n\t\tif(empty($id)) return '';\n\t\t$grid = $this->jqdatagrid;\n\t\t$mSQL = \"SELECT * FROM itscon WHERE id_scon=${id}\";\n\t\t$response = $grid->getDataSimple($mSQL);\n\t\t$rs = $grid->jsonresult( $response);\n\t\techo $rs;\n\t}", "public function getDataId($id)\n {\n $galeri = ModelGaleriNews::find($id);\n return $galeri;\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 }", "function get_by_id($id)\n {\n $this->db->where($this->id, $id);\n return $this->db->get($this->table)->row();\n }", "function get_by_id($id)\n {\n $this->db->where($this->id, $id);\n return $this->db->get($this->table)->row();\n }" ]
[ "0.8208614", "0.8159501", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.81502706", "0.8022783", "0.79464656", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7894407", "0.7885043", "0.7885043", "0.7885043", "0.7857593", "0.78207403", "0.78024656", "0.77872723", "0.77842647", "0.7731199", "0.7729477", "0.7729477", "0.77185345", "0.77147686", "0.7705486", "0.76490134", "0.7640524", "0.7623572", "0.76048446", "0.7596778", "0.7596778", "0.75576967", "0.75517493", "0.7539116", "0.7537681", "0.7537681", "0.75313103", "0.7509218", "0.7504324", "0.7504324", "0.75024885", "0.7496187", "0.74949837", "0.74883795", "0.74883795", "0.74829894", "0.7469419", "0.7448974", "0.74469024", "0.74469024", "0.74469024", "0.74469024", "0.7444703", "0.7444703", "0.7436167", "0.742298", "0.7418674", "0.74169576", "0.74035937", "0.7400527", "0.73972684", "0.7392388", "0.7379283", "0.7378448", "0.73648703", "0.7364657", "0.73640096", "0.73522335", "0.7351253", "0.7351253", "0.7351253", "0.73381656", "0.73381656" ]
0.0
-1
get data with limit
function index_limit($limit, $start = 0) { $this->db->join('tbl_perusahaan','tbl_out.id_perusahaan=tbl_perusahaan.id_perusahaan'); $this->db->group_by('nomor_permohonan'); $this->db->order_by($this->id, $this->order); $this->db->limit($limit, $start); return $this->db->get($this->table)->result(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function get( $limit = 10 );", "public function apiFetch( $limit, $offset );", "public function getLimit();", "public function getLimit();", "public function getLimit();", "public function getLimit();", "public function getLimit();", "public function get_limit();", "public function take($limit = 20);", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $db2 = $this->load->database('database_kedua', TRUE);\n\n $db2->order_by($this->id, $this->order);\n $db2->like('id', $q);\n\t$db2->or_like('kelas', $q);\n\t$db2->limit($limit, $start);\n return $db2->get($this->table)->result();\n }", "function getLimit() ;", "public function getLimit() {}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n\t$this->db->or_like('id_barang', $q);\n\t$this->db->or_like('nama_barang', $q);\n\t$this->db->or_like('harga_beli', $q);\n\t$this->db->or_like('harga_jual', $q);\n $this->db->or_like('satuan', $q);\n\t$this->db->or_like('wp_suplier_id', $q);\n\t$this->db->or_like('created_at', $q);\n\t$this->db->or_like('updated_at', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_indikator_ta', $q);\n $this->db->or_like('id_ta', $q);\n $this->db->or_like('id_indikator', $q);\n $this->db->or_like('tgl_isi', $q);\n $this->db->or_like('tgl_update', $q);\n $this->db->or_like('file', $q);\n $this->db->or_like('nilai', $q);\n $this->db->or_like('status', $q);\n $this->db->or_like('isian', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function limit($limit);", "public function limit($limit);", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_jadwal', $q);\n\t$this->db->or_like('id_semester', $q);\n\t$this->db->or_like('id_makul', $q);\n\t$this->db->or_like('id_kelas', $q);\n\t$this->db->or_like('id_dosen', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function getAll($limit = 20){\n $query = $this->db->get($this->table, $limit);\n if($query->num_rows() > 0 ){\n foreach ($query->result() as $row){\n $data[] = $row;\n }\n return $data;\n }\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_waktu', $q);\n\t$this->db->or_like('id_hari', $q);\n\t$this->db->or_like('id_jam', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n\t$this->db->or_like('id_proyek', $q);\n\t$this->db->or_like('id_sumber', $q);\n\t$this->db->or_like('likelihood', $q);\n\t$this->db->or_like('severity', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "private function query($cursor, $limit) {\n // here. Since this is an example, we just use a premade dataset.\n\n return array_slice($this->data, $cursor, $limit);\n }", "public function getData($limit = -1, $offset = -1){ \n $returnValue = [];\n //TODO: Implement get records.\n return $returnValue;\n }", "public function getDatas($data,$limit,$start)\n{\n\t$this->db->select('*');\n\t$this->db->where('sample_field', $data['value']);\n\n\t$this->db->limit($limit, $start);\n\t$query = $this->db->get('sample_table');\n\treturn $query->result();\n}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('makId', $q);\n\t$this->db->or_like('makKode', $q);\n\t$this->db->or_like('makNama', $q);\n\t// $this->db->or_like('makBiayaSbuId', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function limit($limit,$offset);", "public function all_data($limit = null) {\n global $wpdb;\n\n $limit_string = \"\";\n if ($limit != null) {\n $limit_string = \"limit \" . mysql_real_escape_string((int) $limit);\n }\n\n return $wpdb->get_results(\n 'select * from `' . mysql_real_escape_string($this->table_name()) . '`' .\n ' order by recipecan_id desc ' . $limit_string,\n ARRAY_A\n );\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_siswa', $q);\n\t$this->db->or_like('kode_siswa', $q);\n\t$this->db->or_like('nama_siswa', $q);\n\t$this->db->or_like('tgl_lahir', $q);\n\t$this->db->or_like('jkel', $q);\n\t$this->db->or_like('alamat', $q);\n\t$this->db->or_like('no_hp', $q);\n\t$this->db->or_like('tgl_ins', $q);\n\t$this->db->or_like('tgl_updt', $q);\n\t$this->db->or_like('user_updt', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function allWithLimit() {\n\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_barang', $q);\n\t$this->db->or_like('nama_barang', $q);\n\t$this->db->or_like('id_kategori', $q);\n\t$this->db->or_like('tgl_masuk', $q);\n\t$this->db->or_like('pengirim', $q);\n\t$this->db->or_like('id_lokasi', $q);\n\t$this->db->or_like('barcode', $q);\n\t$this->db->or_like('qr', $q);\n $this->db->or_like('stok', $q);\n $this->db->or_like('satuan', $q);\n $this->db->or_like('fungsi', $q);\n $this->db->or_like('pengambil', $q);\n $this->db->or_like('kirim', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function getRecords($limit = false)\n\t{\n\t\tif ($limit !== false)\n\t\t\t$this->setParam(\"limit\", $limit);\n\n\t\t$this->table->getRecords();\n\t}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_supplier', $q);\n\t$this->db->or_like('kode_supplier', $q);\n\t$this->db->or_like('nama_supplier', $q);\n\n $this->db->or_like('alamat', $q);\n $this->db->or_like('no_telp', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('user_id', $q);\n\t$this->db->or_like('name', $q);\n\t$this->db->or_like('mobile', $q);\n\t$this->db->or_like('email', $q);\n\t$this->db->or_like('type', $q);\n\t$this->db->or_like('teamName', $q);\n\t$this->db->or_like('favriteTeam', $q);\n\t$this->db->or_like('dob', $q);\n\t$this->db->or_like('gender', $q);\n\t$this->db->or_like('address', $q);\n\t$this->db->or_like('city', $q);\n\t$this->db->or_like('pincode', $q);\n\t$this->db->or_like('state', $q);\n\t$this->db->or_like('country', $q);\n\t//$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n //$this->db->like('id', $q);\n \t$this->db->like('judul', $q);\n \t/*\n \t$this->db->or_like('isi', $q);\n \t$this->db->or_like('created', $q);\n \t$this->db->or_like('updated', $q);\n \t$this->db->or_like('slug', $q);\n \t$this->db->or_like('featured_image', $q);\n \t*/\n \t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->desc);\n $this->db->group_start();\n $this->db->like('id_item', $q);\n $this->db->or_like('item_type_id', $q);\n $this->db->or_like('id_disciplines', $q);\n $this->db->or_like('item_type_id', $q);\n $this->db->or_like('item_type_name', $q);\n $this->db->group_end();\n $this->db->where('project_status', 0);\n $this->db->where('discipline_status', 0);\n // MODIF BY FAZRI\n $this->db->join('tbl_disciplines', 'tbl_items.id_disciplines = tbl_disciplines.id_discipline');\n $this->db->join('tbl_projects', 'tbl_items.id_projects = tbl_projects.id_project');\n \t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_pembayaran', $q);\n $this->db->or_like('id_kategori', $q);\n $this->db->or_like('id_jurusan', $q);\n $this->db->or_like('tahun_ajaran', $q);\n $this->db->or_like('nominal', $q);\n $this->db->or_like('keterangan', $q);\n $this->db->limit($limit, $start);\n $this->db->join('tahun_ajaran', 'id_tahun_ajaran');\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('a.id_users', $q);\n $this->db->or_like('a.nik', $q);\n $this->db->or_like('a.full_name', $q);\n $this->db->or_like('a.email', $q);\n $this->db->or_like('a.images', $q);\n $this->db->or_like('b.nama_level', $q);\n $this->db->or_like('a.no_hp', $q);\n $this->db->or_like('a.is_aktif', $q);\n $this->db->join('tbl_user_level b', 'a.id_user_level = b.id_user_level');\n \t$this->db->limit($limit, $start);\n return $this->db->get($this->table.' a')->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_langage', $q);\n\t$this->db->or_like('nom_langage', $q);\n\t$this->db->or_like('description', $q);\n\t$this->db->or_like('connaissances_linguistiques_id_langue_parler', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('username', $q);\n $this->db->like('email', $q);\n $this->db->or_like('password', $q);\n $this->db->like('role', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function getData($limit = 10, $page = 1) { // set default arguments values\n $results = array();\n $this->limit = $limit;\n $this->page = $page;\n\n // no limiting necessary, use query as it is\n if ($this->limit == 'all') {\n $query = $this->query;\n } else {\n // echo (($this->page - 1) * $this->limit); die;\n // create the query, limiting records from page, to limit\n $this->rowstart = (($this->page - 1) * $this->limit);\n // add to original query: (minus one because of the way SQL works)\n $query = $this->query . \" LIMIT {$this->rowstart}, $this->limit\";\n }\n\n try {\n $stmt = $this->conn->query($query);\n\n if ($stmt->execute()):\n $results = $stmt->fetchAll(PDO::FETCH_ASSOC);\n endif;\n } catch (PDOException $e) {\n echo \"Error: \" . $e->getMessage();\n die;\n }\n\n return $results; // object\n }", "function get_limit_data($limit, $start = 0, $q = NULL,$fil_1 = Null, $kri_1 = Null) {\n $id_patner = $this->session->userdata('DX_id_patner');\n\t\tif($id_patner > 0){\n\t\t\t$this->db->where('id_patner', $id_patner);\n\t\t}\n $this->db->like('id_pelanggan', $q);\n\t$this->db->or_like('kode', $q);\n\t$this->db->or_like('nama', $q);\n\t$this->db->or_like('alamat', $q);\n\t$this->db->or_like('telp', $q);\n\t$this->db->or_like('id_layanan', $q);\n\t$this->db->or_like('id_patner', $q);\n\t$this->db->or_like('in_pajak', $q);\n\t$this->db->or_like('tanggal_pasang', $q);\n\t$this->db->or_like('status', $q);\n\t\n\t$this->db->order_by($this->id, $this->order);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public static function limit($limit);", "function fetch_data($limit, $start)\n\t{\n\t\t// \t\t\t\t\t->from(\"joblist\")\n\t\t// \t\t\t\t\t->where(\"status = '<span class=\\\"label label-success\\\">Telah tayang</span>'\")\n\t\t// \t\t\t\t\t->order_by(\"id_joblist\", \"DESC\")\n\t\t// \t\t\t\t\t->limit($limit, $start)\n\t\t// \t\t\t\t\t->get();\n\n\t\t//\n\t\t// $query = $this->db->query(\"SELECT *\n\t\t// FROM joblist\n\t\t// NATURAL JOIN industri\n\t\t// WHERE status = '<span class=\\\"label label-success\\\">Telah tayang</span>'\n\t\t// ORDER BY id_joblist DESC\n\t\t// LIMIT $limit OFFSET $start \");\n\n\t\t$query = $this->db->query(\"SELECT Nama_joblist, id_joblist, nama_perusahaan, logo_perusahaan, nama, perusahaan\n\t\tFROM joblist\n\t\tNATURAL JOIN company\n\t\tNATURAL JOIN provinsi\n WHERE id_perusahaan = perusahaan\n\t\tAND status = '<span class=\\\"label label-success\\\">Telah tayang</span>'\n\t\tAND id_provinsi = id\n\t\tAND deadline >= current_date()\n\t\tORDER BY id_joblist DESC\n\t\tLIMIT $limit OFFSET $start \");\n\n\t\treturn $query;\n\t}", "function fetchList($limit, $offset);", "function loadPending($startpoint=null,$limit=null){\r\n$sql=\"SELECT DISTINCT birth_info.*, general_info.surname, general_info.othernames FROM birth_info, general_info WHERE birth_info.status='pending' AND general_info.c_id=birth_info.c_id \";\r\nreturn array_slice($this->query($sql),$startpoint,$limit);\r\n}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n\n $this->db->order_by($this->id, $this->order);\n\n $this->db->like('id', $q);\n\n\t$this->db->or_like('date', $q);\n\n\t$this->db->or_like('transaction_id', $q);\n\n\t$this->db->or_like('category', $q);\n\n\t$this->db->or_like('subcategory', $q);\n\n\t$this->db->or_like('Item_detail', $q);\n\n\t$this->db->or_like('paying_employee', $q);\n\n\t$this->db->or_like('amount_paid', $q);\n\n\t$this->db->or_like('payment_mode', $q);\n\n\t$this->db->or_like('building_id', $q);\n\n\t$this->db->or_like('room_id', $q);\n\n\t$this->db->or_like('room_type', $q);\n\n\t$this->db->or_like('sic_bill', $q);\n\n\t$this->db->or_like('comment', $q);\n\n\t$this->db->or_like('vendor_bill', $q);\n\n\t$this->db->or_like('shop_name', $q);\n\n\t$this->db->or_like('vendor_type', $q);\n\n\t$this->db->or_like('location', $q);\n\n\t$this->db->or_like('mobile', $q);\n\n\t$this->db->or_like('asset_id', $q);\n\n\t$this->db->or_like('model', $q);\n\n\t$this->db->or_like('manufacturing_company', $q);\n\n\t$this->db->or_like('warranty', $q);\n\n\t$this->db->or_like('stayinclass_asset_id', $q);\n\n\t$this->db->limit($limit, $start);\n\n return $this->db->get($this->table)->result();\n\n }", "function get_limit_data($limit, $start = 0, $q = NULL)\n {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_rincian', $q);\n $this->db->or_like('id_satker', $q);\n $this->db->or_like('id_dak_alokasi', $q);\n $this->db->or_like('tahun_anggaran', $q);\n $this->db->or_like('id_dak_bidang', $q);\n $this->db->or_like('id_dak_sub_bidang', $q);\n $this->db->or_like('id_dak_komponen', $q);\n $this->db->or_like('id_dak_komponen_sub', $q);\n $this->db->or_like('menu_kegiatan', $q);\n $this->db->or_like('kegiatan', $q);\n $this->db->or_like('id_dak_rincian', $q);\n $this->db->or_like('id_alkes', $q);\n $this->db->or_like('id_jenis_output', $q);\n $this->db->or_like('harga_satuan', $q);\n $this->db->or_like('volume', $q);\n $this->db->or_like('volume_perubahan', $q);\n $this->db->or_like('satuan', $q);\n $this->db->or_like('total', $q);\n $this->db->or_like('sarana', $q);\n $this->db->or_like('created_by', $q);\n $this->db->or_like('created_date', $q);\n $this->db->or_like('updated_by', $q);\n $this->db->or_like('updated_date', $q);\n $this->db->or_like('isdeleted', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL)\n {\n $this->db->order_by('a.kdtarif', $this->order);\n $this->db->like('a.kdtarif', $q);\n $this->db->or_like('a.nmtarif', $q);\n $this->db->or_like('b.poli', $q);\n $this->db->or_like('a.paket', $q);\n $this->db->or_like('a.aktif', $q);\n $this->db->or_like('a.tglinput', $q);\n $this->db->or_like('a.id_users', $q);\n $this->db->limit($limit, $start);\n $this->db->from('m_tarif a');\n $this->db->join('m_poli b', 'a.kdpoli = b.kdpoli', 'left');\n return $this->db->get()->result();\n }", "public function get_limit_data($limit, $start = 0, $q = null)\n {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n $this->db->or_like('notrans', $q);\n $this->db->or_like('id_karyawan', $q);\n $this->db->or_like('tanggal', $q);\n $this->db->or_like('pengikut', $q);\n $this->db->or_like('tujuan', $q);\n $this->db->or_like('keterangan', $q);\n $this->db->or_like('bbm', $q);\n $this->db->or_like('kupon_bbm', $q);\n $this->db->or_like('id_mobil', $q);\n $this->db->or_like('id_driver', $q);\n $this->db->or_like('keluar_jam', $q);\n $this->db->or_like('masuk_jam', $q);\n $this->db->or_like('status', $q);\n $this->db->or_like('datetime', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function find_limit($limit = 100, $offset = 0 )\n {\n $query= $this->db->query(\"\n SELECT *\n FROM punti_spesi\n LIMIT $offset , $limit \"); \n return $query->result();\n }", "function showLatestDespachos_SI($limit)\n\t {\n\t\t $sql=\"select despacho_id, nombre_despacho,fecha_despacho\n\t\t from despacho order by despacho_id desc limit 0,$limit\";\n\t\t\n\t\t $result=mysql_query($sql,$this->link);\n\t\t $data=null;\n\t\t $i=0;\n\t while($row=mysql_fetch_array($result))\n\t\t {\n\t\t\t $data[$i]['iddespacho']=$row['despacho_id'];\n\t\t\t $data[$i]['fecha_ref']=$row['fecha_despacho'];\n\t\t\t $data[$i]['nombre_despacho']=$row['nombre_despacho'];\n\t\t\t $i++;\n\t\t }\n\t\t return $data;\n\t }", "function getAllModelByID($id, $limit){\n $data = http_build_query([\n 'mark_id' => $id,\n 'limit' => $limit,\n ]);//build query\n $ch = curl_init();//init Curl\n curl_setopt_array($ch, [\n CURLOPT_URL => 'https://apistaging.el-market.org/v1/osago/lists/models/?' . $data,\n CURLOPT_RETURNTRANSFER => 1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => [\n 'Accept: application/json',\n 'Authorization: Token Test2019',\n ],\n ]);\n $res=json_decode(curl_exec($ch),true);\n curl_close($ch);\n if (curl_errno($ch)) { echo 'Error:' . curl_error($ch);}\n return $res['results'];\n}", "public function limit($limit, $offset = null);", "function getAllMarks($limit){\n $data = http_build_query([\n 'limit' => $limit,\n ]);//build query\n $ch = curl_init();//init Curl\n curl_setopt_array($ch, [\n CURLOPT_URL => 'https://apistaging.el-market.org/v1/osago/lists/marks/?' . $data,\n CURLOPT_RETURNTRANSFER => 1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => [\n 'Accept: application/json',\n 'Authorization: Token Test2019'\n ]\n ]);\n $res=json_decode(curl_exec($ch),true);\n curl_close($ch);\n if (curl_errno($ch)) { echo 'Error:' . curl_error($ch);}\n return $res['results'];\n}", "public function getLimit()\n {\n //a little different than normal gets...\n return array (\n $this->_count, $this->_offset,\n );\n }", "abstract protected function _getData($organism, $timestart, $timeend, $limit = 0);", "public function limit($limit)\n {\n }", "private function selectLimit(){\n $result=parent::selectSomething('*', 'config');\n $row=mysqli_fetch_object($result);\n $this->limit=$row->answersperpage;\n }", "function get_all($limit=10000, $offset=0)\n\t{\n\t\t$this->db->from('giftcards');\n\t\t$this->db->where('deleted',0);\n\t\t$this->db->order_by(\"giftcard_number\", \"asc\");\n\t\t$this->db->limit($limit);\n\t\t$this->db->offset($offset);\n\t\treturn $this->db->get();\n\t}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->select('id_persediaan, persediaan.id_puskesmas, persediaan.kode, nama_obat, SUM(persediaan.stok_awal) AS stok_awal');\n $this->db->group_by('persediaan.kode');\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_persediaan', $q);\n $this->db->or_like('persediaan.id_puskesmas', $q);\n $this->db->or_like('persediaan.kode', $q);\n $this->db->or_like('stok_awal', $q);\n $this->db->limit($limit, $start);\n $this->db->join('puskesmas', 'puskesmas.id_puskesmas=persediaan.id_puskesmas');\n $this->db->join('obat', 'obat.kode=persediaan.kode');\n return $this->db->get($this->table)->result();\n }", "public function list_limit($var,$page){\n if($page>1){\n $page=$page*6-6;\n }else{\n $page=0;\n }\n $sql=\"SELECT a.identificador, a.nombre_inmueble ,e.nombre_t_inmueble ,d.nombre_distrito ,a.direccion ,a.numero ,a.superficie ,\n a.habitaciones ,a.baño ,a.cochera ,a.descripcion ,a.precio ,a.from_url ,a.fecha ,a.tipo ,b.id_operacion ,b.id_people ,\n c.nombre_t_operacion,f.id_contrato,f.identificador as id_contrato,g.tiempo ,f.contrato \n from inmueble as a inner join operacion as b on a.id_inmuebe=b.id_inmueble \n inner join tipo_operacion as c on b.tipo_operacion=c.id_t_operacion inner join distrito as d on a.id_distrito =d.id_distrito\n inner join tipo_inmueble as e on a.tipo_inmueble=e.id_tipo_inmueble inner join contrato as f on b.id_operacion=f.id_operacion\n inner join tipo_contrato as g on f.id_t_contrato=g.id_t_contrato where a.tipo =? limit $page,6\";\n $rs=$this->con->prepare($sql);\n $rs->execute(array($var));\n return $rs->fetchAll(PDO::FETCH_OBJ);\n\t\t}", "function index_limit($limit, $start = 0) {\n $this->db->order_by($this->id, $this->order);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function index_limit($limit, $start = 0) {\n $this->db->order_by($this->id, $this->order);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function doCustomRestGetLimit($var) {\n\t\t$criteria = new CDbCriteria();\n\t\t\n\t\tif(is_array($var)){\n\t \t $criteria->limit = $var[0];\n\t \t $criteria->offset = $var[1];\n\t\t}\n\t\telse {\n\t \t $criteria->limit = $var;\n\t\t}\n\n //$this->renderJson(array('success'=>true, 'message'=>'Records Retrieved Successfully', 'data'=>$this->getModel()->findAll($criteria)));\n $this->outputHelper( \n 'Records Retrieved Successfully', \n $this->getModel()->with($this->nestedRelations)->findAll($criteria),\n $this->getModel()->with($this->nestedRelations)->count()\n );\n\t}", "function get($count = 500, $orderby = null, $order = null, $from = null, $to = null) {\r\n\t\t//Query\r\n\t\t$sql = new DataBase;\r\n\t\t$sql->connect();\r\n\t\t$query = \"\r\n\t\t\tSELECT DISTINCT tag.*\r\n\t\t\tFROM tags tag\r\n\t\t\tWHERE tag.profile_id = \".CurrentUser::getId();\r\n\t\tif($orderby == 'name') $query .= \" ORDER BY tag.name\";\r\n\t\tif($order == 'ASC') $query .= \" ASC\";\r\n\t\tif($order == 'DESC') $query .= \" DESC\";\r\n\t\tif($count && $orderby == 'name') $query .= \" LIMIT \".$count;\r\n\t\t\r\n\t\t$sql->query($query);\r\n\t\t\r\n\t\t//Objects\r\n\t\t$json = array();\r\n\t\t\r\n\t\t//Data\r\n\t\twhile($data = mysql_fetch_array($sql->result)):\r\n\t\t\t$sql2 = new DataBase;\r\n\t\t\t$sql2->connect();\r\n\t\t\t$query = \"\r\n\t\t\t\tSELECT DISTINCT transaction.id, transaction.amount\r\n\t\t\t\tFROM transactions_has_tags tht, transactions transaction\r\n\t\t\t\tWHERE tht.tag_id = \".$data[\"id\"].\" AND transaction.id = tht.transaction_id AND transaction.profile_id = \".CurrentUser::getId();\r\n\t\t\tif($from) $query .= \" AND transaction.date >= '\".$from.\"'\";\r\n\t\t\tif($to) $query .= \" AND transaction.date <= '\".$to.\"'\";\r\n\r\n\t\t\t\t\r\n\t\t\t$sql2->query($query);\r\n\t\t\t$json2 = array();\r\n\t\t\t$totalSpend = 0;\r\n\t\t\t\r\n\t\t\twhile($data2 = mysql_fetch_array($sql2->result)):\r\n\t\t\t\tarray_push($json2, $data2[\"id\"]);\r\n\t\t\t\t$totalSpend += $data2['amount'];\r\n\t\t\tendwhile;\r\n\t\t\t\r\n\t\t\t$array = array(\r\n\t\t\t\t\"id\"\t\t\t=>\t$data[\"id\"],\r\n\t\t\t\t\"name\"\t\t\t=>\t$data[\"name\"],\r\n\t\t\t\t\"transactions\"\t=> $json2,\r\n\t\t\t\t\"total_spend\"\t=> $totalSpend\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\tarray_push($json, $array);\r\n\t\tendwhile;\r\n\t\t\r\n\t\t//Close connection\r\n\t\t$sql->close();\r\n\t\t\r\n\t\t//Order By\r\n\t\tswitch($orderby):\r\n\t\t\tcase \"most_expensive\":\r\n\t\t\t\t($order == \"asc\" || $order == \"ASC\") ? $json = array_sort($json, 'total_spend') : $json = array_sort($json, 'total_spend', SORT_DESC);\r\n\t\t\tbreak;\r\n\t\t\tcase \"most_valuable\":\r\n\t\t\t\t($order == \"asc\" || $order == \"ASC\") ? $json = array_sort($json, 'total_spend') : $json = array_sort($json, 'total_spend', SORT_DESC);\r\n\t\t\tbreak;\r\n\t\t\t\r\n\t\tendswitch;\r\n\t\t\r\n\t\t//Finally\r\n\t\t$t = array();\r\n\t\tforeach ($json as $a): array_push($t, $a); endforeach;\r\n\t\t$t = array_slice($t,0,$count);\r\n\t\t\r\n\t\t//Return\r\n\t\treturn $t;\r\n\t}", "public function get($limit = 0)\n {\n if ($limit) {\n $this->setLimit($limit);\n }\n return $this->getResults();\n }", "protected function actionGetByLimit($start=0,$limit=0) {\n $model = new News();\n \n $result= $model->getItemsByLimit($start, $limit);\n return $result;\n }", "function getLimitedPost($userId, $limitStart, $limit)\n{\n\n $sqlPost = \"SELECT * FROM `post` WHERE `userId` = '$userId' AND `deleted` = 0 ORDER BY `creationTime` DESC LIMIT $limitStart,$limit \";\n $resultPost = mysqli_query($GLOBALS[\"conn\"], $sqlPost);\n return $resultPost;\n}", "public function latest($limit);", "function getResult($limit, $idField, $dateField = null);", "public function get_data_blok($limit,$start)\n\t{\n\t\t$this->db->select('k.nama_kawasan, b.nama_blok, b.gambar, b.add_time, b.jumlah_unit, k.alamat, b.id_blok, b.keterangan as ket');\n\t\t$this->db->from('blok as b');\n\t\t$this->db->join('kawasan as k', 'k.id_kawasan = b.id_kawasan', 'inner');\n\t\t$this->db->limit($limit,$start);\n\t\t$this->db->order_by('b.keterangan', 'asc');\n\t\treturn $this->db->get();\n }", "protected function _getData($limit) {\n $helper = Mage::helper('unityreports');\n\n try {\n $campaignsTable = Intelivemetrics_Unityreports_Model_Utils::getTableName('unityreports/campaigns');\n $ordersTable = Intelivemetrics_Unityreports_Model_Utils::getTableName('unityreports/orders');\n $now = date('Y-m-d H:i:s');\n $collection = Mage::getModel('sales/order')->getCollection()\n ->addAttributeToSelect('*')\n ->addAttributeToSort('updated_at', 'ASC');\n $collection->getSelect()\n ->joinLeft(\n array('campaigns' => $campaignsTable), \"main_table.entity_id=campaigns.id AND campaigns.type='order'\", array('source', 'medium', 'content', 'campaign')\n )\n ->where(\"main_table.increment_id NOT IN (SELECT increment_id FROM $ordersTable WHERE synced=1 OR sents>={$this->getMaxSents()} OR TIMESTAMPDIFF(MINUTE,last_sent_at,'{$now}')<60)\")\n ->limit($limit)\n ;\n //$helper->debug($collection->getSelectSql()->__toString());\n // nothing to sync get out\n if (count($collection) == 0) {\n $helper->debug('No order data found to sync', Zend_Log::INFO);\n return null;\n }\n\n //get additional produc attributes list\n $attribs = Intelivemetrics_Unityreports_Model_Utils::getProductAttributesToSync();\n\n // pack order data\n $data = array();\n $order_count = 0;\n $category = Mage::getModel('catalog/category');\n foreach ($collection as $order) {\n $attributes = $order->getData();\n\n try {\n $currency = $attributes['order_currency_code'];\n\n $order_fields = array(\n 'entity_name' => self::ENTITY_TYPE,\n 'id' => $order->getId(),\n 'increment_id' => $order->getIncrementId(),\n 'coupon_code' => $attributes['coupon_code'],\n 'store_id' => $attributes['store_id'],\n 'customer_id' => $attributes['customer_id'],\n 'customer_email' => $attributes['customer_email'],\n 'customer_name' => $attributes['customer_firstname'] . ' ' . $attributes['customer_lastname'],\n 'customer_group' => $this->_getGroupCode($attributes['group_id']),\n 'grand_total' => $attributes['grand_total'],\n 'shipping_amount' => $attributes['shipping_amount'],\n 'shipping_tax_amount' => $attributes['shipping_tax_amount'],\n 'subtotal' => $attributes['subtotal'],\n 'discount_amount' => $attributes['discount_amount'],\n 'tax_amount' => $attributes['tax_amount'],\n 'currency_code' => $currency,\n 'total_qty_ordered' => $attributes['total_qty_ordered'],\n 'created_at' => $attributes['created_at'],\n 'total_item_count' => $attributes['total_item_count'],\n 'status' => $attributes['status'],\n 'state' => $attributes['state'],\n 'shipping_description' => $attributes['shipping_description'],\n 'source' => (empty($attributes['source']) ? self::CHANNEL_UNTRACKED : $attributes['source']),\n 'medium' => (empty($attributes['medium']) ? self::CHANNEL_UNTRACKED : $attributes['medium']),\n 'content' => (empty($attributes['content']) ? self::CHANNEL_UNTRACKED : $attributes['content']),\n 'campaign' => (empty($attributes['campaign']) ? self::CHANNEL_UNTRACKED : $attributes['campaign']),\n 'payment_method' => (is_object($order->getPayment()) ? $order->getPayment()->getMethod() : 'unknown')\n );\n\n // indirizzo di spedizione\n $orderShippingAddress = $order->getShippingAddress();\n if (!is_null($orderShippingAddress) && is_object($orderShippingAddress)) {\n $shipping_arr = array();\n $shipping_arr['postcode'] = $orderShippingAddress->getPostcode();\n $shipping_arr['city'] = $orderShippingAddress->getCity();\n $shipping_arr['region'] = $orderShippingAddress->getRegion();\n $shipping_arr['country'] = $orderShippingAddress->getCountry();\n $order_fields['shipping_address'] = $shipping_arr;\n }\n\n // indirizzo di fatturazione\n $orderBillingAddress = $order->getBillingAddress();\n if (!is_null($orderBillingAddress) && is_object($orderBillingAddress)) {\n $billing_arr = array();\n $billing_arr['postcode'] = $orderBillingAddress->getPostcode();\n $billing_arr['city'] = $orderBillingAddress->getCity();\n $billing_arr['region'] = $orderBillingAddress->getRegion();\n $billing_arr['country'] = $orderBillingAddress->getCountry();\n $order_fields['billing_address'] = $billing_arr;\n }\n\n // processa le righe dell'ordine\n $items_arr = array();\n foreach ($order->getAllItems() as $item) {\n $_categories = array();\n\n //export only simple products\n if ($item->getParentItem()) {\n continue;\n }\n\n $item_attribs = $item->getData();\n $item_arr = array();\n $item_arr['item_id'] = $item_attribs['product_id'];\n $item_arr['order_id'] = $order->getId();\n $item_arr['sku'] = $item_attribs['sku'];\n $item_arr['name'] = $item_attribs['name'];\n $item_arr['qty'] = $item_attribs['qty_ordered'];\n $item_arr['price'] = $item_attribs['price'];\n $item_arr['tax_amount'] = $item_attribs['tax_amount'];\n $item_arr['product_type'] = $item_attribs['product_type'];\n $item_arr['creation_date'] = $item_attribs['created_at'];\n $item_arr['update_date'] = $item_attribs['updated_at'];\n\n //recupera path categorie, solo della prima categoria associata\n //TODO: what if no category info is available? put some fake cateogry like UNKNOWN\n if (($product = $item->getProduct()) || ($product = Mage::getModel('catalog/product')->load($item->getProductId()))) {\n $mainCategory = $product->getCategoryCollection()->getFirstItem();\n $ids = array_reverse($mainCategory->getPathIds());\n $counter = 1;\n foreach ($ids as $categoryId) {\n //massimo 5 livelli di profondità\n if ($counter > 5) {\n break;\n }\n if ($category->load($categoryId)) {\n $_categories[] = array(\n 'id' => $category->getId(),\n 'name' => $category->getName(),\n );\n }\n $counter++;\n }\n $item_arr['categories'] = $_categories;\n }\n\n //add configurable options \n if ($item_attribs['product_type'] == 'configurable') {\n $productOptions = $item->getProductOptions();\n $superAttributeIds = array();\n foreach ($productOptions['info_buyRequest']['super_attribute'] as $superId => $superValue) {\n $superAttributeIds[] = $superId;\n }\n $option = array();\n foreach ($productOptions['attributes_info'] as $index => $attribute) {\n $attributeId = $superAttributeIds[$index];\n $option = array(\n 'attribute_id' => $attributeId,\n 'label' => $attribute['label'],\n 'value' => $attribute['value'],\n );\n }\n $item_arr['options'][] = $option;\n }\n\n //add custom prod attributes\n if (is_array($attribs) && count($attribs) > 0) {\n foreach ($attribs as $_code => $_id) {\n $_value = ($product->getAttributeText($_code) ? $product->getAttributeText($_code) : $product->getData($_code));\n if (!$_value)\n continue;\n\n $item_arr['options'][] = array(\n 'attribute_id' => $_id,\n 'label' => $_code,\n 'value' => $_value,\n );\n }\n }\n\n $items_arr['item_' . $item_attribs['item_id']] = $item_arr;\n }\n $order_fields['items'] = $items_arr;\n\n $data[\"order_\" . $order->getIncrementId()] = $order_fields;\n $order_count++;\n } catch (Exception $ex) {\n $helper->debug($ex->getMessage(), Zend_Log::ERR);\n $helper->debug('FILE: ' . __FILE__ . 'LINE: ' . __LINE__);\n }\n }//end order loop\n\n return $data;\n } catch (Exception $ex) {\n $helper->debug($ex->getMessage(), Zend_Log::ERR);\n $helper->debug('FILE: ' . __FILE__ . 'LINE: ' . __LINE__);\n return null;\n }\n }", "public function readCollectionWithLimit($limit) {\n\n $recordCollection = [];\n\n do {\n $recordArr = $this->readNextOne();\n\n if ($recordArr) {\n $recordCollection[] = $this->prepareRecord($recordArr);\n }\n } while (!empty($recordArr) && count($recordCollection) < $limit);\n\n return $recordCollection;\n }", "public function get_limit(){\r\n return $this->limit;\r\n }", "function getPopular()\n\t{\n\t\t$interval = $this->input->post('interval');\n\t\tif($interval == '') {\n\t\t\t$interval = 1;\n\t\t}\n\n\t\t$limit = $this->input->post('limit');\n\t\tif($limit == '') {\n\t\t\t$limit = 30;\n\t\t}\n\n\t\t$response = $this->mapi->getPopular($interval,$limit);\n\n\t\theader('Content-Type: application/json');\n\t\techo json_encode($response);\n\t}", "public function getLimit() {\n return $this->limit;\n }", "public function getCountriesData10($limitStart) {\n $db = database::getDB();\n $query = \"SELECT * FROM countries ORDER BY id ASC LIMIT $limitStart , 10\";\n $data = $db->query($query);\n return $data;\n }", "public function limit($count, $offset);", "public function all($limit, $offset);", "function array_product_limit($lim) {\n\n include \"../db/setting.php\";\n $sql = mysqli_connect($servername, $username, $password, $database);\n echo mysqli_error($sql) . \"<br>\";\n\n $s = \"SELECT id, title, spec, price FROM produit LIMIT\".$lim;\n $res = mysqli_query($sql, $s);\n echo mysqli_error($sql) . \"<br>\";\n\n $arr = array();\n for ($i = 0; $i < mysqli_num_rows($res); $i = $i + 1) {\n $arr[] = mysqli_fetch_row($res);\n }\n return ($arr);\n}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n\t$this->db->or_like('title', $q);\n\t$this->db->or_like('meta_keyword', $q);\n\t$this->db->or_like('meta_description', $q);\n\t$this->db->or_like('home_welcome_title', $q);\n\t$this->db->or_like('home_welcome_subtitle', $q);\n\t$this->db->or_like('home_welcome_text', $q);\n\t$this->db->or_like('home_welcome_video', $q);\n\t$this->db->or_like('home_welcome_pbar1_text', $q);\n\t$this->db->or_like('home_welcome_pbar1_value', $q);\n\t$this->db->or_like('home_welcome_pbar2_text', $q);\n\t$this->db->or_like('home_welcome_pbar2_value', $q);\n\t$this->db->or_like('home_welcome_pbar3_text', $q);\n\t$this->db->or_like('home_welcome_pbar3_value', $q);\n\t$this->db->or_like('home_welcome_pbar4_text', $q);\n\t$this->db->or_like('home_welcome_pbar4_value', $q);\n\t$this->db->or_like('home_welcome_pbar5_text', $q);\n\t$this->db->or_like('home_welcome_pbar5_value', $q);\n\t$this->db->or_like('home_welcome_status', $q);\n\t$this->db->or_like('home_welcome_video_bg', $q);\n\t$this->db->or_like('home_why_choose_title', $q);\n\t$this->db->or_like('home_why_choose_subtitle', $q);\n\t$this->db->or_like('home_why_choose_status', $q);\n\t$this->db->or_like('home_feature_title', $q);\n\t$this->db->or_like('home_feature_subtitle', $q);\n\t$this->db->or_like('home_feature_status', $q);\n\t$this->db->or_like('home_service_title', $q);\n\t$this->db->or_like('home_service_subtitle', $q);\n\t$this->db->or_like('home_service_status', $q);\n\t$this->db->or_like('counter_1_title', $q);\n\t$this->db->or_like('counter_1_value', $q);\n\t$this->db->or_like('counter_1_icon', $q);\n\t$this->db->or_like('counter_2_title', $q);\n\t$this->db->or_like('counter_2_value', $q);\n\t$this->db->or_like('counter_2_icon', $q);\n\t$this->db->or_like('counter_3_title', $q);\n\t$this->db->or_like('counter_3_value', $q);\n\t$this->db->or_like('counter_3_icon', $q);\n\t$this->db->or_like('counter_4_title', $q);\n\t$this->db->or_like('counter_4_value', $q);\n\t$this->db->or_like('counter_4_icon', $q);\n\t$this->db->or_like('counter_photo', $q);\n\t$this->db->or_like('counter_status', $q);\n\t$this->db->or_like('home_portfolio_title', $q);\n\t$this->db->or_like('home_portfolio_subtitle', $q);\n\t$this->db->or_like('home_portfolio_status', $q);\n\t$this->db->or_like('home_booking_form_title', $q);\n\t$this->db->or_like('home_booking_faq_title', $q);\n\t$this->db->or_like('home_booking_status', $q);\n\t$this->db->or_like('home_booking_photo', $q);\n\t$this->db->or_like('home_team_title', $q);\n\t$this->db->or_like('home_team_subtitle', $q);\n\t$this->db->or_like('home_team_status', $q);\n\t$this->db->or_like('home_ptable_title', $q);\n\t$this->db->or_like('home_ptable_subtitle', $q);\n\t$this->db->or_like('home_ptable_status', $q);\n\t$this->db->or_like('home_testimonial_title', $q);\n\t$this->db->or_like('home_testimonial_subtitle', $q);\n\t$this->db->or_like('home_testimonial_photo', $q);\n\t$this->db->or_like('home_testimonial_status', $q);\n\t$this->db->or_like('home_blog_title', $q);\n\t$this->db->or_like('home_blog_subtitle', $q);\n\t$this->db->or_like('home_blog_item', $q);\n\t$this->db->or_like('home_blog_status', $q);\n\t$this->db->or_like('home_cta_text', $q);\n\t$this->db->or_like('home_cta_button_text', $q);\n\t$this->db->or_like('home_cta_button_url', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function getData($limit = 10000) {\r\n\t\t$req_dump = print_r($_REQUEST, true);\r\n\t\t$fp = file_put_contents('request.log', $req_dump, FILE_APPEND);\r\n\r\n\t\ttry {\r\n \t\t $pdo = $this->db->generatePDO();\r\n\r\n \t\t $t_sql = \"SELECT * FROM temperature ORDER BY id DESC LIMIT $limit\";\r\n \t\t $h_sql = \"SELECT * FROM humidity ORDER BY id DESC LIMIT $limit\";\r\n\r\n \t\t $getTemp = $pdo->prepare($t_sql);\r\n \t\t $getTemp->execute();\r\n \t\t $getHum = $pdo->prepare($h_sql);\r\n \t\t $getHum->execute();\r\n\r\n \t\t $temp = $getTemp->fetchAll(PDO::FETCH_ASSOC);\r\n \t\t $hum = $getHum->fetchAll(PDO::FETCH_ASSOC);\r\n\r\n\r\n \t\t if (!empty($temp)) {\r\n \t\t\t $host = '';\r\n \t\t\t $dataset = [];\r\n \t\t\t $dataset_t = [];\r\n \t\t\t $dataset_h = [];\r\n \t\t\t $data_obj = [];\r\n \t\t\t $host_list = $this->getHosts();\r\n\r\n\r\n \t\t\t foreach ($host_list as $key => $host) {\r\n \t\t\t\t $data_obj['client_addr'] = $host;\r\n \t\t\t\t $sql = \"SELECT * FROM temperature WHERE client_addr = '$host' ORDER BY id DESC LIMIT $limit\";\r\n \t\t\t\t $q = $pdo->prepare($sql);\r\n \t\t\t\t $q->execute();\r\n \t\t\t\t $data = $q->fetchAll(PDO::FETCH_ASSOC);\r\n \t\t\t\t $data_obj['data'] = [];\r\n\r\n \t\t\t\t foreach($data as $key => $value) {\r\n \t\t\t\t\t array_push($data_obj['data'], $value['value']);\r\n \t\t\t\t }\r\n \t\t\t\t array_push($dataset_t, $data_obj);\r\n\r\n \t\t\t }\r\n \t\t\t foreach ($host_list as $key => $host) {\r\n \t\t\t\t $data_obj['client_addr'] = $host;\r\n \t\t\t\t $sql = \"SELECT * FROM humidity WHERE client_addr = '$host' ORDER BY id DESC LIMIT $limit\";\r\n \t\t\t\t $q = $pdo->prepare($sql);\r\n \t\t\t\t $q->execute();\r\n \t\t\t\t $data = $q->fetchAll(PDO::FETCH_ASSOC);\r\n \t\t\t\t $data_obj['data'] = [];\r\n\r\n \t\t\t\t foreach($data as $key => $value) {\r\n \t\t\t\t\t array_push($data_obj['data'], $value['value']);\r\n \t\t\t\t }\r\n \t\t\t\t array_push($dataset_h, $data_obj);\r\n\r\n \t\t\t }\r\n\r\n \t\t\t $dataset['temperature'] = $dataset_t;\r\n \t\t\t $dataset['humidity'] = $dataset_h;\r\n\r\n \t\t\t return $dataset;\r\n \t\t }\r\n\r\n \t } catch (PDOException $e) {\r\n \t\t $this->throwError($e->getMessage());\r\n \t }\r\n }", "function GetData($_start=0,$_count=9999999)\r\n\t{\r\n\t\t\r\n\t\t$_tpl_select_command = \"SELECT {limit} * FROM ({SelectCommand}) AS _TMP {where} {orderby} {groupby}\";\r\n\t\t\r\n\t\t//Filters\r\n\t\t$_where = \"\";\r\n\t\t$_filters = $this->Filters;\r\n\t\tfor($i=0;$i<sizeof($_filters);$i++)\r\n\t\t{\r\n\t\t\t$_where.=\" and \".$this->GetFilterExpression($_filters[$i]);\r\n\t\t}\r\n\t\tif ($_where!=\"\")\r\n\t\t{\r\n\t\t\t$_where = \"WHERE \".substr($_where,5);\r\n\t\t}\r\n\t\t//Order\r\n\t\t$_orderby = \"\";\r\n\t\t$_orders = $this->Sorts;\r\n\t\tfor($i=0;$i<sizeof($_orders);$i++)\r\n\t\t{\r\n\t\t\t$_orderby.=\", \".$_orders[$i]->Field.\" \".$_orders[$i]->Order;\r\n\t\t}\r\n\t\tif ($_orderby!=\"\")\r\n\t\t{\r\n\t\t\t$_orderby = \"ORDER BY \".substr($_orderby,2);\r\n\t\t}\r\n\t\t//Group\r\n\t\t$_groupby = \"\";\r\n\t\t$_groups = $this->Groups;\r\n\t\tfor($i=0;$i<sizeof($_groups);$i++)\r\n\t\t{\r\n\t\t\t$_groupby.=\", \".$_groups[$i]->Field;\r\n\t\t}\r\n\t\tif ($_groupby!=\"\")\r\n\t\t{\r\n\t\t\t$_groupby = \"GROUP BY \".substr($_groupby,2);\r\n\t\t}\r\n\t\t//Limit\r\n\t\t$_limit = \"TOP \".($_start+$_count); \t\t\r\n\t\t\r\n\t\t$_select_command = str_replace(\"{SelectCommand}\",$this->SelectCommand,$_tpl_select_command);\r\n\t\t$_select_command = str_replace(\"{where}\",$_where,$_select_command);\r\n\t\t$_select_command = str_replace(\"{orderby}\",$_orderby,$_select_command);\r\n\t\t$_select_command = str_replace(\"{groupby}\",$_groupby,$_select_command);\r\n\t\t$_select_command = str_replace(\"{limit}\",$_limit,$_select_command);\r\n\t\t\r\n\t\t//echo $_select_command;\r\n\t\t$_result = mssql_query($_select_command,$this->_Link);\r\n\t\t$_rows = array();\r\n\t\t$_i=0;\r\n\t\twhile ($_row = mssql_fetch_assoc($_result)) \r\n\t\t{\r\n\t\t\tif($_i>=$_start)\r\n\t\t\t{\r\n\t\t\t\tarray_push($_rows,$_row);\t\t\t\t\r\n\t\t\t}\r\n\t\t\t$_i++;\r\n\t\t}\r\n\r\n\t\treturn $_rows;\r\n\t}", "function ratelimit(array $data);", "function listar_boletines_limit($inicial,$cantidad) {\n\t\t$query = \"SELECT newsletters.*\n\t\tFROM newsletters\n\t\tORDER BY fecha_publicacion desc\n\t\tLIMIT $inicial,$cantidad\";\n\n $connection = mysql_connect($this->HOST, $this->USERNAME, $this->PASSWORD);\n\t\t\n\t\t$SelectedDB = mysql_select_db($this->DBNAME);\n\t\t$result = mysql_query($query); \n\t\t\n\t\t$numrows = mysql_num_rows($result);\n\t\tmysql_close($connection);\n\t\t// COMPROBAMOS QUE HAYA RESULTADOS\n\t\t// SI EL NUMERO DE RESULTADOS ES 0 SIGNIFICA QUE NO HAY REGISTROS CON ESOS DATOS\n\t\tif ($numrows == 0) {\n\t\t\treturn $result;\n\t\t}\n\t\telse {\n\t\t\treturn $result;\n\t\t}\n\t}", "function get_test_page(){\r\n\t\t\t\t$limit=10;\r\n\t\t$sql = \"select * from test_bag where tid!='offer' and nstatus!='pending' and nstatus!='process' and status=2\";\r\n\t\t//echo $sql;\r\n\t\t$pagination_qatar = new pagination_qatar();\r\n\t\t$pagination_qatar->createPaging($sql,$limit);\r\n\t\twhile($row=mysql_fetch_object($pagination_qatar->resultpage)){\r\n\t\t$rowdc[]=$row;\r\n\t\t}\r\n\t\t $rowdc['total_rec']=$pagination_qatar->totalrecords();\r\n\t\t $rowdc['dis_page']=$pagination_qatar->displayPaging();\r\n\t\t \r\n\t\treturn $rowdc;\r\n\t}", "public function all($limit = 5, $offset = 0);", "public function all($limit = 5, $offset = 0);", "function simple_select($_connection, $_uid, $_limit){\n $result = pg_query(\"\n SELECT id, uid, freq, ta, pa, momento\n FROM elo_dados\n WHERE uid = '$_uid'\n ORDER BY id DESC\n LIMIT '$_limit';\n \");\n $data = array();\n while ($row = pg_fetch_assoc($result)){\n $data[] = $row;\n }\n return $data;\n}", "function readNouvelles($first,$RSS_id,$limit) {\n $sql = \"SELECT * FROM Nouvelle WHERE id >= ? AND idRSS = ? ORDER BY idRSS, id LIMIT ?\";\n $req = $this->db->prepare($sql);\n $params = array($first,$RSS_id,$limit);\n $res = $req->execute($params);\n debug($this->db,$sql,$params);\n if ($res === FALSE) {\n die(\"readNouvelle error: no Nouvelle finded\\n\");\n }\n return $req->fetchAll(PDO::FETCH_CLASS, \"Nouvelle\",array($RSS_id));\n }", "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 limit($limit)\n {\n return $this->query->limit($limit);\n }", "public function getData($to, $from) {\n\t\t$this->db->from ( self::TABLE_NAME );\n\t\t$this->db->limit ( $to, $from );\n\t\t$result = $this->db->get (); // \n\t\treturn $result->result_array ();\n\t}", "function getData() {\n\t\tif (empty($this->_data)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_data = $this->_getList($query, $this->getState('limitstart'), $this->getState('limit'));\n\t\t}\n\t\treturn $this->_data;\n\t}", "function &getLastTen( $limit, $offset )\n {\n $this->dbInit();\n $link_array = 0;\n \n $this->Database->array_query( $link_array, \"SELECT * FROM eZLink_Link WHERE Accepted='Y' ORDER BY Title DESC LIMIT $offset, $limit\" );\n\n return $link_array;\n }", "function getData()\n\t{\n\t\tif (empty($this->_data)) {\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_data = $this->_getList($query, $this->getState('limitstart'), $this->getState('limit'));\n\t\t}\n\t\treturn $this->_data;\n\t}", "private function getData(){\n\t\tdb::getAdapter();\n\t\t\n\t\t$counter=0;\n\t\t$arrayFieldQuery=array();\n\t\tforeach($this->fields as $field){\n\t\t\t$arrayFieldQuery[$field]=$this->types[$counter];\n\t\t\t$counter++;\n\t\t}\n\t\t\n\t\t$counter=0;\n\t\t$arrayFilters=array();\n\t\tforeach($this->filters as $filter){\n\t\t\t$arrayFilters[$this->fields[$filter[0]]]=array(\"type\"=>$this->types[$filter[0]],\"value\"=>$filter[1]);\n\t\t}\n\t\t\n\t\tif(db::getFields($this->table,$arrayFieldQuery,$arrayFilters,$this->orderQuery,$this->limit,true)){\n\t\t\t$this->pages=ceil(((int)db::getCalculatedRows())/((int)$this->maxRowsPerPage));\n\t\t\t$this->maxRows=(int)db::getCalculatedRows();\n\t\t\twhile($row=db::fetch(db::$FETCH_TYPE_ASSOC)){\n\t\t\t\t$this->addRow($row);\n\t\t\t}\n\t\t}\n\t}", "public function GetByPaginated($offset, $limit);", "function findStartGet($limit) { // limit diisi 10\n\t\tif ((!isset($_GET['page'])) || ($_GET['page'] == \"1\")) \n\t\t { \n\t\t $start = 0; \n\t\t $_GET['page'] = 1; \n\t\t } \n\t\t else \n\t\t { // jika $page= 3 \n\t\t $start = ($_GET['page']-1) * $limit; // maka $start= 20\n\t\t }\n\t\t\t\n\t\t return $start; \n }", "function KM_getDataList($limit,$offset,$sort_by,$sort_order)\n\t {\n\t \t//result query\n\t\t$sort_order=($sort_order=='desc')?'desc':'asc';\n\t\t$sort_columns=array('id','name'); \n\t\t//table columns\n\t\t$sort_by=(in_array($sort_by,$sort_columns))?$sort_by:'id';\n\t $sql=\"SELECT * from $table order by $sort_by $sort_order limit $offset, $limit \"; \t \n\t \t$query = $this->db->query($sql);\t \n\t \t$result['rows']= $query->result();\t \n\t\t \n\t \t//count query\n\t \t$this-> db -> select(\"COUNT(*) AS count\",FALSE);\n\t \t$this-> db -> from($table);\n\t \t$query = $this -> db -> get();\t\t \t \n\t \t$tmp = $query->result();\t \n\t \n\t \t$result['num_rows'] = $tmp[0] -> count;\t\t\n\t \treturn $result;\t \n\t }", "public function find_limit($limit = 100, $offset = 0 )\n {\n $query= $this->db->query(\"\n SELECT *\n FROM app_ip\n LIMIT $offset , $limit \"); \n return $query->result();\n }" ]
[ "0.8316894", "0.73177034", "0.72137046", "0.72137046", "0.72137046", "0.72137046", "0.72137046", "0.7210758", "0.7180552", "0.7179508", "0.7122921", "0.706634", "0.70655155", "0.70564723", "0.7033684", "0.7033684", "0.70288414", "0.70138544", "0.6966351", "0.6957874", "0.6917318", "0.6912296", "0.69058305", "0.6891439", "0.6891156", "0.68761003", "0.6871194", "0.68572205", "0.6843375", "0.684207", "0.68419224", "0.6823429", "0.6821363", "0.6813471", "0.68134063", "0.680468", "0.68034893", "0.6781499", "0.6780228", "0.6760175", "0.6727853", "0.66632056", "0.6658603", "0.6630821", "0.6623466", "0.66085756", "0.6597304", "0.65893793", "0.6543177", "0.6529353", "0.65011567", "0.64972967", "0.6486668", "0.6485595", "0.6473099", "0.6459039", "0.6451067", "0.6440377", "0.64377004", "0.6414173", "0.6387827", "0.6387827", "0.63867235", "0.6377152", "0.6371507", "0.636166", "0.6356624", "0.63536316", "0.6352748", "0.6346535", "0.6343906", "0.6333172", "0.63288766", "0.6316138", "0.6306405", "0.6295254", "0.62863225", "0.6275581", "0.6263223", "0.6262675", "0.625807", "0.62542444", "0.6253633", "0.6230293", "0.62196004", "0.6214223", "0.6214223", "0.6213463", "0.62091833", "0.6201767", "0.6200084", "0.6180343", "0.61783487", "0.6174493", "0.6174364", "0.61688983", "0.61494315", "0.6140418", "0.6139605", "0.61365485" ]
0.6601096
46
get search total rows
function search_total_rows($keyword = NULL) { $this->db->like('id_out', $keyword); $this->db->or_like('nomor_permohonan', $keyword); $this->db->or_like('tanggal_permohonan', $keyword); $this->db->or_like('id_ijin', $keyword); $this->db->or_like('barang', $keyword); $this->db->or_like('jumlah', $keyword); $this->db->or_like('satuan', $keyword); $this->db->from($this->table); return $this->db->count_all_results(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function total_rows();", "public function totalNumRows()\n {\n try {\n\n $sql = 'SELECT DISTINCT gil.id_item\n FROM geocontexter.gc_item AS gil\n '.$this->_sql_tables.'\n WHERE gil.title ILIKE ?\n '.$this->_sql_in_id_list;\n\n $res = $this->query($sql, array($this->search . '%'));\n return (int)count($res);\n\n } catch(\\Exception $e) {\n throw $e;\n }\n }", "function search_total_rows($keyword = NULL) {\n $this->db->like('id_nilai', $keyword);\n\t\t$this->db->or_like('id_infeksi', $keyword);\n\t\t$this->db->or_like('nilai', $keyword);\n\t$this->db->from($this->table);\n return $this->db->count_all_results();\n }", "public function getTotalNumberOfResults();", "public function getTotalResults();", "public static function searchTotal()\n\t{\n\t\t$total = self::all()->total();\n\t\treturn $total;\n\t}", "public function FetchTotalRowsSearch($qSearch) {\n\t\n\t\t$encTxt = Encryption::Encrypt($qSearch);\n\t\n\t\t$query = \"SELECT Count(*) AS total FROM \" . $this->mTableName .\n\t\t\" WHERE username LIKE '%$qSearch%' OR date_create LIKE '%$qSearch%' OR email = '$encTxt' ;\";\n\t\t$objects = $this->SelectWithQuery($query);\n\t\treturn $objects[0]->total;\n\t}", "public function getFoundRows();", "public function totalCount();", "public function totalCount();", "public function getNumTotalQueryResults() : int{\n return $this->numTotalQueryResults;\n }", "public function countquery(){ \n\t\treturn $this->query_total; \n\t}", "public function numOfRows();", "public function get_found_rows() {\n\t\treturn (int) $this->found_rows;\n\t}", "function RowCount() {}", "public function getTotalCount();", "public function getTotalCount();", "public function getTotalCount();", "public function getNbResults()\n {\n $this->sphinxQL->execute();\n\n $helper = Helper::create($this->sphinxQL->getConnection());\n $meta = $helper->showMeta()->execute()->fetchAllAssoc();\n\n foreach ($meta as $item) {\n if ('total_found' === $item['Variable_name']) {\n return (int) $item['Value'];\n }\n }\n\n return 0;\n }", "public function numRows(){\n $val = $this->numResults;\n $this->numResults = array();\n return $val;\n }", "function search_total_rows($keyword = NULL) {\n $this->db->like('id_penanaman', $keyword);\n\t$this->db->or_like('nama_penanam', $keyword);\n\t$this->db->or_like('tgl_tanam', $keyword);\n\t$this->db->or_like('id_user', $keyword);\n\t$this->db->or_like('id_pohon', $keyword);\n\t$this->db->or_like('id_petak', $keyword);\n\t$this->db->or_like('status', $keyword);\n\t$this->db->or_like('jumlah', $keyword);\n\t$this->db->from($this->table);\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 getNumRows();", "function total_rowskhusus($q = NULL) {\n $this->db->like('id_persediaan', $q);\n $this->db->or_like('id_puskesmas', $q);\n $this->db->or_like('kode', $q);\n $this->db->or_like('stok_awal', $q);\n $this->db->from($this->table);\n return $this->db->count_all_results();\n }", "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 numRows() {\n\t\t$val = $this->numResults;\n\t\t$this->numResults = array();\n\t\treturn $val;\n\t}", "function numResults() {\n\t\treturn $this->num_rows();\n\t}", "protected abstract function getRowsTotal(Result $result);", "function total_rowskhusus2($q = NULL) {\n $this->db->like('id_persediaan', $q);\n $this->db->or_like('id_puskesmas', $q);\n $this->db->from($this->table);\n return $this->db->count_all_results();\n }", "public function getRowCount();", "public function numberOfRows();", "public function found_rows() {\n\t\t$this->FoundRows();\n\t}", "function fetch_total_restaurant_rows($query)\n {\n $search = $query['search'];\n $this->db->select('*')->from($this->table);\n if(!empty($search)) {\n\t\t\t$this->db->like('restaurant_name', $search);\n\t\t}\n return $this->db->get()->num_rows();\n }", "public function FoundRows() {\n\t\treturn $this->found_rows;\n\t}", "public function getRecordsTotal(): int;", "public function count() {\n return count($this->__rows__);\n }", "public abstract function row_count();", "public function getNumberOfRows();", "public function getTotal($search){\n $repository = App_Doctrine_Repository::repository(\"Photos\");\n $query = $repository->listAll(array(\"file_name\" => $search));\n return $query->resetDQLParts(array('select', \"orderBy\"))\n ->select('COUNT(p)')\n ->getQuery()\n ->getSingleScalarResult();\n \n }", "public function get_foundrows() \n {\n return $this->foundrows;\n }", "public function rowTotalCount() {\n if (is_null($this->response)) {\n throw new Exception('Response in NULL');\n }\n return $this->response->found;\n }", "public function count_filtered(){\n $this->datatables_query();\n $query = $this->db->get();\n return $query->num_rows();\n }", "public function getTotalResults() {\n return $this->totalResults;\n }", "function gettotalpageno(){\n\t $qry = \"SELECT * FROM countries\";\n\t return $result = $this->modelObj->numRows($qry);\n\t}", "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 getTotalItemCount();", "public function totalResults()\n {\n\t\treturn (int) $this->totalResultsReturned;\n }", "public function total_results()\n\t{\n\t\t$results = $this->get_results();\n\t\t$total = 0;\n\n\t\tforeach\t( $results as $set ) {\n\t\t\t$total = $total + count( $set );\n\t\t}\n\n\t\treturn $total;\n\t}", "public function nbRows();", "public function getTotalResults(): int\n {\n return $this->totalResults;\n }", "public abstract function GetNumRows();", "public static function getTotalSearchResultsCount() {\n\n $category_dress_type_id = isset($_POST['product_type']) ? $_POST['product_type'] : '';\n $search_term = $_POST['search_term'];\n\n if (isset($_POST['model_type'])) {\n $model_type = $_POST['model_type'];\n switch ($model_type) {\n case \"girl\":\n Db_Actions::DbSelect(\"SELECT DISTINCT COUNT(product_id) AS totalprds FROM cscart_products_categories WHERE category_id=260\");\n Db_Actions::DbSelect(\"SELECT product_id FROM cscart_product_descriptions WHERE product LIKE '%\" . $search_term . \"%'\");\n break;\n case \"boy\":\n Db_Actions::DbSelect(\"SELECT DISTINCT COUNT(product_id) AS totalprds FROM cscart_products_categories WHERE category_id=261\");\n\n break;\n }\n }\n $products_count = Db_Actions::DbGetResults();\n if (!isset($products_count->empty_result)) {\n foreach ($products_count as $count) {\n echo ceil($count->totalprds / 9);\n }\n }\n else {\n echo 0;\n }\n }", "public function count_rows() {\r\n return $this->db->count_all_results($this->table_name);\r\n }", "public function numRows($where=false) {\n\t\t$sql = 'SELECT COUNT(*) as total from cbt_nomor_peserta';\n\t\t\n\t\tif ($where !== false){\n\t\t\t$sql.=' where ';\n\t\t\t$whereArr = array();\n\t\t\tforeach($where as $clause => $val) {\n\t\t\t\t$whereArr[] = $clause.'=\\''.$val.'\\'';\n\t\t\t}\n\t\t\t$sql.=' where '.implode(',',$whereArr);\n\t\t}\n\t\t$sqlQuery = new SqlQuery($sql);\n\t\treturn $this->querySingleResult($sqlQuery);\n\t }", "abstract public function getNumRows();", "abstract public function getNumRows();", "public function getTotalResults() : int\n {\n return $this->totalResults;\n }", "function getTotal() {\r\n\t\tif (empty ( $this->_total )) {\r\n\t\t\t$query = $this->_buildQuery ();\r\n\t\t\t$this->_total = $this->_getListCount ( $query );\r\n\t\t}\r\n\t\treturn $this->_total;\r\n\t}", "function count_filtered()\n {\n $this->_get_datatables_query();\n $query = $this->db->get();\n return $query->num_rows();\n }", "public function count(){\n $query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n $row = $stmt->fetch(PDO::FETCH_ASSOC);\n \n return $row['total_rows'];\n }", "public function getNumResultsStored() : int{\n return $this->numResults;\n }", "public function count(){\n\t\t\t$query = \"SELECT COUNT(*) as total_rows FROM \" . $this->table_name . \"\";\n\t\t\n\t\t\t$stmt = $this->conn->prepare( $query );\n\t\t\t$stmt->execute();\n\t\t\t$row = $stmt->fetch(PDO::FETCH_ASSOC);\n\t\t\n\t\t\treturn $row['total_rows'];\n\t\t}", "function f_total($sql)\n\t{\n return $sql->num_rows;\n }", "public function numRows($where=false) {\n\t\t$sql = 'SELECT COUNT(*) as total from cbt_soal_siswa';\n\t\t\n\t\tif ($where !== false){\n\t\t\t$sql.=' where ';\n\t\t\t$whereArr = array();\n\t\t\tforeach($where as $clause => $val) {\n\t\t\t\t$whereArr[] = $clause.'=\\''.$val.'\\'';\n\t\t\t}\n\t\t\t$sql.=' where '.implode(',',$whereArr);\n\t\t}\n\t\t$sqlQuery = new SqlQuery($sql);\n\t\treturn $this->querySingleResult($sqlQuery);\n\t }", "public function getFoundRows()\n\t{\n\t\treturn (int) $this->value('SELECT FOUND_ROWS()', [], null);\n\t}", "public function getNumRows(){\n\t\treturn $this->instance->getNumRows();\n\t}", "public function getNbResults(): int\n {\n return $this->adapter->getTotalHits();\n }", "public function get_cantidad_resultados(){\n \treturn $this->db->query('select FOUND_ROWS() as found_rows')->row()->found_rows;\n }", "public function getTotalRows( $query_id=null );", "public function getTotalResults()\n {\n return $this->totalResults;\n }", "public function getTotalResults()\n {\n return $this->totalResults;\n }", "function numRows()\n {\n $this->getRows();\n return $this->row_counter;\n }", "public function get_rows_count()\n\t{\n\t\treturn count($this->get_rows());\n\t}", "function &getNumRows($filter = null, $content = null, $date_ini = '2009-01-01 00:00:00', $date_fin = NOW){\n global $db;\n global $user;\n\n $sql = \"SELECT COUNT(*) AS numRows FROM products\";\n\n if(($filter != null) and ($content != null)){\n $sql = \t\"SELECT COUNT(*) AS numRows \"\n .\"FROM products \"\n .\"WHERE \".$filter.\" like '%$content%'\";\n }\n //Basic::EventLog(\"products->getNumRows: \".$sql);\n $res =& $db->queryOne($sql);\n return $res;\t\t\n }", "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 getRowCount() {\n\t\t$saleData = $this->getProducts();\n\t\t$saleSize = sizeof($saleData);\n\t\treturn $saleSize -=1;\n\t}", "public function numRows($where=false) {\n\t\t$sql = 'SELECT COUNT(*) as total from cbt_jadwal_ujian';\n\t\t\n\t\tif ($where !== false){\n\t\t\t$sql.=' where ';\n\t\t\t$whereArr = array();\n\t\t\tforeach($where as $clause => $val) {\n\t\t\t\t$whereArr[] = $clause.'=\\''.$val.'\\'';\n\t\t\t}\n\t\t\t$sql.=' where '.implode(',',$whereArr);\n\t\t}\n\t\t$sqlQuery = new SqlQuery($sql);\n\t\treturn $this->querySingleResult($sqlQuery);\n\t }", "public function countData($qr){\n\t\t$totalRow = mysql_num_rows($qr);\n\t\treturn $totalRow;\n\t}", "function getTotalRows()\n {\n $query = \"SELECT * FROM \" . $this->table_name;\n $result = mysqli_query($this->conn, $query);\n return mysqli_num_rows($result);\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 getNumRows(){\n return $this->numrows;\n }", "public function countRows()\n {\n return count($this->rows);\n }", "public function getQueryCount();", "public function getAllRows()\n\t{\n\t\treturn $this->foundRows;\n\t}", "abstract public function countTotal();", "public function count()\n {\n return $this->rows;\n }", "function getTotal($fieldName='', $searchKeyword='')\r\n\t\t{\r\n\t\t\t$sqlCount = $this->getTableCount($this->table, $fieldName , $searchKeyword );\r\n\t\t\treturn $sqlCount;\r\n\t\t\t\r\n\t\t}", "abstract public function NumRows();", "function NumRows() {}", "public function getTotal()\n\t{\n\t\t// Lets load the 'pending' records of the view instead of the existing records list\n\t\tif ($this->_pending)\n\t\t{\n\t\t\tif ($this->_total_pending === null)\n\t\t\t{\n\t\t\t\t$query = $this->_buildQuery();\n\n\t\t\t\tif ($query === false)\n\t\t\t\t{\n\t\t\t\t\treturn $this->_total_pending = 0;\n\t\t\t\t}\n\n\t\t\t\t$this->_getList($query, 0, 1);\n\t\t\t\t$this->_db->setQuery(\"SELECT FOUND_ROWS()\");\n\t\t\t\t$this->_total_pending = $this->_db->loadResult();\n\t\t\t}\n\n\t\t\treturn $this->_total_pending;\n\t\t}\n\n\t\t// Lets load the records if it doesn't already exist\n\t\telseif ($this->_total === null)\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\n\t\t\tif ($query === false)\n\t\t\t{\n\t\t\t\treturn $this->_total = 0;\n\t\t\t}\n\n\t\t\t$this->_getList($query, 0, 1);\n\t\t\t$this->_db->setQuery(\"SELECT FOUND_ROWS()\");\n\t\t\t$this->_total = $this->_db->loadResult();\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "function total_rows($table, $where = array())\n{\n $CI =& get_instance();\n if (is_array($where)) {\n if (sizeof($where) > 0) {\n $CI->db->where($where);\n }\n } elseif (strlen($where) > 0) {\n $CI->db->where($where);\n }\n\n return $CI->db->count_all_results($table);\n}", "function get_filtered_data(){\n $this->make_query();\n $query = $this->db->get();\n return $query->num_rows();\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 getNbResults()\n {\n return $this->select->count();\n }", "function get_num_records()\n\t{\n\t\t$this->sql = 'SELECT COUNT(*) FROM ' . $this->table;\n\t\t$this->apply_filters();\n\t\treturn db_getOne($this->sql, $this->use_db);\n\t}", "function getTotal()\n\t{\n\t\t// Lets load the content if it doesn't already exist\n\t\tif (empty($this->_total))\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "function getTotal()\n\t{\n\t\t// Lets load the content if it doesn't already exist\n\t\tif (empty($this->_total))\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "function getTotal()\n\t{\n\t\t// Lets load the content if it doesn't already exist\n\t\tif (empty($this->_total))\n\t\t{\n\t\t\t$query = $this->_buildQuery();\n\t\t\t$this->_total = $this->_getListCount($query);\n\t\t}\n\n\t\treturn $this->_total;\n\t}", "public function getNumRows()\n {\n \treturn $this->previouslyExecuted->num_rows;\n }", "public function qTotal(){\n return Manager::getManager($this)->select()->count();\n }" ]
[ "0.7851448", "0.7801934", "0.76779526", "0.7615219", "0.76020944", "0.7520296", "0.73480135", "0.7193201", "0.71745765", "0.71745765", "0.71392417", "0.7137954", "0.7129139", "0.7126313", "0.7115173", "0.710867", "0.710867", "0.710867", "0.7046272", "0.7044577", "0.7043402", "0.70308256", "0.7029848", "0.7017473", "0.70166063", "0.7000709", "0.70005643", "0.6991974", "0.69812053", "0.6976582", "0.69694054", "0.6934335", "0.6921916", "0.69203585", "0.69145614", "0.6905297", "0.68971217", "0.6877581", "0.6875248", "0.6864667", "0.686253", "0.6844368", "0.6843917", "0.6842383", "0.68343353", "0.6833091", "0.68192005", "0.6818078", "0.6811821", "0.68054605", "0.6804722", "0.6803098", "0.6795773", "0.67948705", "0.6793729", "0.6793729", "0.6791349", "0.67906064", "0.6784459", "0.6771571", "0.67656857", "0.67648834", "0.6762233", "0.6738977", "0.67295927", "0.67289275", "0.67281073", "0.6726739", "0.67256534", "0.67196697", "0.67196697", "0.67129785", "0.67127806", "0.6711461", "0.67107797", "0.67099935", "0.6702731", "0.66990066", "0.66918147", "0.6690655", "0.669039", "0.6690016", "0.66869354", "0.66867244", "0.6682498", "0.66726387", "0.6667788", "0.66612595", "0.6658438", "0.6653659", "0.6649146", "0.66470164", "0.6643044", "0.6640535", "0.6640478", "0.66378176", "0.66378176", "0.66378176", "0.6637649", "0.66344875" ]
0.7374584
6
get search data with limit
function search_index_limit($limit, $start = 0, $keyword = NULL) { $this->db->order_by($this->id, $this->order); $this->db->like('id_out', $keyword); $this->db->or_like('nomor_permohonan', $keyword); $this->db->or_like('tanggal_permohonan', $keyword); $this->db->or_like('id_ijin', $keyword); $this->db->or_like('barang', $keyword); $this->db->or_like('jumlah', $keyword); $this->db->or_like('satuan', $keyword); $this->db->limit($limit, $start); return $this->db->get($this->table)->result(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 get( $limit = 10 );", "public function getSearchResults($data,$limit,$start)\n{\n\t$this->db->select('*');\n\t$this->db->where('sample_field', $data['search_key']);\n\t$this->db->limit($limit, $start);\n\t$query = $this->db->get('sample_table');\n\treturn $query->result();\n}", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('user_id', $q);\n\t$this->db->or_like('name', $q);\n\t$this->db->or_like('mobile', $q);\n\t$this->db->or_like('email', $q);\n\t$this->db->or_like('type', $q);\n\t$this->db->or_like('teamName', $q);\n\t$this->db->or_like('favriteTeam', $q);\n\t$this->db->or_like('dob', $q);\n\t$this->db->or_like('gender', $q);\n\t$this->db->or_like('address', $q);\n\t$this->db->or_like('city', $q);\n\t$this->db->or_like('pincode', $q);\n\t$this->db->or_like('state', $q);\n\t$this->db->or_like('country', $q);\n\t//$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_indikator_ta', $q);\n $this->db->or_like('id_ta', $q);\n $this->db->or_like('id_indikator', $q);\n $this->db->or_like('tgl_isi', $q);\n $this->db->or_like('tgl_update', $q);\n $this->db->or_like('file', $q);\n $this->db->or_like('nilai', $q);\n $this->db->or_like('status', $q);\n $this->db->or_like('isian', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $db2 = $this->load->database('database_kedua', TRUE);\n\n $db2->order_by($this->id, $this->order);\n $db2->like('id', $q);\n\t$db2->or_like('kelas', $q);\n\t$db2->limit($limit, $start);\n return $db2->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n //$this->db->like('id', $q);\n \t$this->db->like('judul', $q);\n \t/*\n \t$this->db->or_like('isi', $q);\n \t$this->db->or_like('created', $q);\n \t$this->db->or_like('updated', $q);\n \t$this->db->or_like('slug', $q);\n \t$this->db->or_like('featured_image', $q);\n \t*/\n \t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_jadwal', $q);\n\t$this->db->or_like('id_semester', $q);\n\t$this->db->or_like('id_makul', $q);\n\t$this->db->or_like('id_kelas', $q);\n\t$this->db->or_like('id_dosen', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n\t$this->db->or_like('id_barang', $q);\n\t$this->db->or_like('nama_barang', $q);\n\t$this->db->or_like('harga_beli', $q);\n\t$this->db->or_like('harga_jual', $q);\n $this->db->or_like('satuan', $q);\n\t$this->db->or_like('wp_suplier_id', $q);\n\t$this->db->or_like('created_at', $q);\n\t$this->db->or_like('updated_at', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('makId', $q);\n\t$this->db->or_like('makKode', $q);\n\t$this->db->or_like('makNama', $q);\n\t// $this->db->or_like('makBiayaSbuId', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_siswa', $q);\n\t$this->db->or_like('kode_siswa', $q);\n\t$this->db->or_like('nama_siswa', $q);\n\t$this->db->or_like('tgl_lahir', $q);\n\t$this->db->or_like('jkel', $q);\n\t$this->db->or_like('alamat', $q);\n\t$this->db->or_like('no_hp', $q);\n\t$this->db->or_like('tgl_ins', $q);\n\t$this->db->or_like('tgl_updt', $q);\n\t$this->db->or_like('user_updt', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_supplier', $q);\n\t$this->db->or_like('kode_supplier', $q);\n\t$this->db->or_like('nama_supplier', $q);\n\n $this->db->or_like('alamat', $q);\n $this->db->or_like('no_telp', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_barang', $q);\n\t$this->db->or_like('nama_barang', $q);\n\t$this->db->or_like('id_kategori', $q);\n\t$this->db->or_like('tgl_masuk', $q);\n\t$this->db->or_like('pengirim', $q);\n\t$this->db->or_like('id_lokasi', $q);\n\t$this->db->or_like('barcode', $q);\n\t$this->db->or_like('qr', $q);\n $this->db->or_like('stok', $q);\n $this->db->or_like('satuan', $q);\n $this->db->or_like('fungsi', $q);\n $this->db->or_like('pengambil', $q);\n $this->db->or_like('kirim', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_waktu', $q);\n\t$this->db->or_like('id_hari', $q);\n\t$this->db->or_like('id_jam', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n\t$this->db->or_like('id_proyek', $q);\n\t$this->db->or_like('id_sumber', $q);\n\t$this->db->or_like('likelihood', $q);\n\t$this->db->or_like('severity', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('username', $q);\n $this->db->like('email', $q);\n $this->db->or_like('password', $q);\n $this->db->like('role', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_pembayaran', $q);\n $this->db->or_like('id_kategori', $q);\n $this->db->or_like('id_jurusan', $q);\n $this->db->or_like('tahun_ajaran', $q);\n $this->db->or_like('nominal', $q);\n $this->db->or_like('keterangan', $q);\n $this->db->limit($limit, $start);\n $this->db->join('tahun_ajaran', 'id_tahun_ajaran');\n return $this->db->get($this->table)->result();\n }", "function search_index_limit($limit, $start = 0, $keyword = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_penanaman', $keyword);\n\t$this->db->or_like('nama_penanam', $keyword);\n\t$this->db->or_like('tgl_tanam', $keyword);\n\t$this->db->or_like('id_user', $keyword);\n\t$this->db->or_like('id_pohon', $keyword);\n\t$this->db->or_like('id_petak', $keyword);\n\t$this->db->or_like('status', $keyword);\n\t$this->db->or_like('jumlah', $keyword);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n\t$this->db->or_like('title', $q);\n\t$this->db->or_like('meta_keyword', $q);\n\t$this->db->or_like('meta_description', $q);\n\t$this->db->or_like('home_welcome_title', $q);\n\t$this->db->or_like('home_welcome_subtitle', $q);\n\t$this->db->or_like('home_welcome_text', $q);\n\t$this->db->or_like('home_welcome_video', $q);\n\t$this->db->or_like('home_welcome_pbar1_text', $q);\n\t$this->db->or_like('home_welcome_pbar1_value', $q);\n\t$this->db->or_like('home_welcome_pbar2_text', $q);\n\t$this->db->or_like('home_welcome_pbar2_value', $q);\n\t$this->db->or_like('home_welcome_pbar3_text', $q);\n\t$this->db->or_like('home_welcome_pbar3_value', $q);\n\t$this->db->or_like('home_welcome_pbar4_text', $q);\n\t$this->db->or_like('home_welcome_pbar4_value', $q);\n\t$this->db->or_like('home_welcome_pbar5_text', $q);\n\t$this->db->or_like('home_welcome_pbar5_value', $q);\n\t$this->db->or_like('home_welcome_status', $q);\n\t$this->db->or_like('home_welcome_video_bg', $q);\n\t$this->db->or_like('home_why_choose_title', $q);\n\t$this->db->or_like('home_why_choose_subtitle', $q);\n\t$this->db->or_like('home_why_choose_status', $q);\n\t$this->db->or_like('home_feature_title', $q);\n\t$this->db->or_like('home_feature_subtitle', $q);\n\t$this->db->or_like('home_feature_status', $q);\n\t$this->db->or_like('home_service_title', $q);\n\t$this->db->or_like('home_service_subtitle', $q);\n\t$this->db->or_like('home_service_status', $q);\n\t$this->db->or_like('counter_1_title', $q);\n\t$this->db->or_like('counter_1_value', $q);\n\t$this->db->or_like('counter_1_icon', $q);\n\t$this->db->or_like('counter_2_title', $q);\n\t$this->db->or_like('counter_2_value', $q);\n\t$this->db->or_like('counter_2_icon', $q);\n\t$this->db->or_like('counter_3_title', $q);\n\t$this->db->or_like('counter_3_value', $q);\n\t$this->db->or_like('counter_3_icon', $q);\n\t$this->db->or_like('counter_4_title', $q);\n\t$this->db->or_like('counter_4_value', $q);\n\t$this->db->or_like('counter_4_icon', $q);\n\t$this->db->or_like('counter_photo', $q);\n\t$this->db->or_like('counter_status', $q);\n\t$this->db->or_like('home_portfolio_title', $q);\n\t$this->db->or_like('home_portfolio_subtitle', $q);\n\t$this->db->or_like('home_portfolio_status', $q);\n\t$this->db->or_like('home_booking_form_title', $q);\n\t$this->db->or_like('home_booking_faq_title', $q);\n\t$this->db->or_like('home_booking_status', $q);\n\t$this->db->or_like('home_booking_photo', $q);\n\t$this->db->or_like('home_team_title', $q);\n\t$this->db->or_like('home_team_subtitle', $q);\n\t$this->db->or_like('home_team_status', $q);\n\t$this->db->or_like('home_ptable_title', $q);\n\t$this->db->or_like('home_ptable_subtitle', $q);\n\t$this->db->or_like('home_ptable_status', $q);\n\t$this->db->or_like('home_testimonial_title', $q);\n\t$this->db->or_like('home_testimonial_subtitle', $q);\n\t$this->db->or_like('home_testimonial_photo', $q);\n\t$this->db->or_like('home_testimonial_status', $q);\n\t$this->db->or_like('home_blog_title', $q);\n\t$this->db->or_like('home_blog_subtitle', $q);\n\t$this->db->or_like('home_blog_item', $q);\n\t$this->db->or_like('home_blog_status', $q);\n\t$this->db->or_like('home_cta_text', $q);\n\t$this->db->or_like('home_cta_button_text', $q);\n\t$this->db->or_like('home_cta_button_url', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_langage', $q);\n\t$this->db->or_like('nom_langage', $q);\n\t$this->db->or_like('description', $q);\n\t$this->db->or_like('connaissances_linguistiques_id_langue_parler', $q);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function search_index_limit($limit, $start = 0, $keyword = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_nilai', $keyword);\n\t\t$this->db->or_like('id_infeksi', $keyword);\n\t\t$this->db->or_like('nilai', $keyword);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('a.id_users', $q);\n $this->db->or_like('a.nik', $q);\n $this->db->or_like('a.full_name', $q);\n $this->db->or_like('a.email', $q);\n $this->db->or_like('a.images', $q);\n $this->db->or_like('b.nama_level', $q);\n $this->db->or_like('a.no_hp', $q);\n $this->db->or_like('a.is_aktif', $q);\n $this->db->join('tbl_user_level b', 'a.id_user_level = b.id_user_level');\n \t$this->db->limit($limit, $start);\n return $this->db->get($this->table.' a')->result();\n }", "function get_limit_data_hotels($limit, $start = 0, $q = NULL) {\n $this->db->order_by('hotels_name', 'ASC');\n $this->db->like('idhotels', $q);\n $this->db->or_like('hotels_name', $q);\n $this->db->from('career_hotels');\n $this->db->limit($limit, $start);\n return $this->db->get()->result();\n }", "public function testFindByQWithLimit()\n {\n $dataLoader = $this->getDataLoader();\n $all = $dataLoader->getAll();\n $filters = ['q' => $all[0]['name'], 'limit' => 1];\n $this->filterTest($filters, [$all[0]]);\n $filters = ['q' => 'desc', 'limit' => 2];\n $this->filterTest($filters, [$all[0], $all[1]]);\n }", "function get_limit_data($limit, $start = 0, $q = NULL,$fil_1 = Null, $kri_1 = Null) {\n $id_patner = $this->session->userdata('DX_id_patner');\n\t\tif($id_patner > 0){\n\t\t\t$this->db->where('id_patner', $id_patner);\n\t\t}\n $this->db->like('id_pelanggan', $q);\n\t$this->db->or_like('kode', $q);\n\t$this->db->or_like('nama', $q);\n\t$this->db->or_like('alamat', $q);\n\t$this->db->or_like('telp', $q);\n\t$this->db->or_like('id_layanan', $q);\n\t$this->db->or_like('id_patner', $q);\n\t$this->db->or_like('in_pajak', $q);\n\t$this->db->or_like('tanggal_pasang', $q);\n\t$this->db->or_like('status', $q);\n\t\n\t$this->db->order_by($this->id, $this->order);\n\t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n\n $this->db->order_by($this->id, $this->order);\n\n $this->db->like('id', $q);\n\n\t$this->db->or_like('date', $q);\n\n\t$this->db->or_like('transaction_id', $q);\n\n\t$this->db->or_like('category', $q);\n\n\t$this->db->or_like('subcategory', $q);\n\n\t$this->db->or_like('Item_detail', $q);\n\n\t$this->db->or_like('paying_employee', $q);\n\n\t$this->db->or_like('amount_paid', $q);\n\n\t$this->db->or_like('payment_mode', $q);\n\n\t$this->db->or_like('building_id', $q);\n\n\t$this->db->or_like('room_id', $q);\n\n\t$this->db->or_like('room_type', $q);\n\n\t$this->db->or_like('sic_bill', $q);\n\n\t$this->db->or_like('comment', $q);\n\n\t$this->db->or_like('vendor_bill', $q);\n\n\t$this->db->or_like('shop_name', $q);\n\n\t$this->db->or_like('vendor_type', $q);\n\n\t$this->db->or_like('location', $q);\n\n\t$this->db->or_like('mobile', $q);\n\n\t$this->db->or_like('asset_id', $q);\n\n\t$this->db->or_like('model', $q);\n\n\t$this->db->or_like('manufacturing_company', $q);\n\n\t$this->db->or_like('warranty', $q);\n\n\t$this->db->or_like('stayinclass_asset_id', $q);\n\n\t$this->db->limit($limit, $start);\n\n return $this->db->get($this->table)->result();\n\n }", "function get_limit_data($limit, $start = 0, $q = NULL)\n {\n $this->db->order_by('a.kdtarif', $this->order);\n $this->db->like('a.kdtarif', $q);\n $this->db->or_like('a.nmtarif', $q);\n $this->db->or_like('b.poli', $q);\n $this->db->or_like('a.paket', $q);\n $this->db->or_like('a.aktif', $q);\n $this->db->or_like('a.tglinput', $q);\n $this->db->or_like('a.id_users', $q);\n $this->db->limit($limit, $start);\n $this->db->from('m_tarif a');\n $this->db->join('m_poli b', 'a.kdpoli = b.kdpoli', 'left');\n return $this->db->get()->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL)\n {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_rincian', $q);\n $this->db->or_like('id_satker', $q);\n $this->db->or_like('id_dak_alokasi', $q);\n $this->db->or_like('tahun_anggaran', $q);\n $this->db->or_like('id_dak_bidang', $q);\n $this->db->or_like('id_dak_sub_bidang', $q);\n $this->db->or_like('id_dak_komponen', $q);\n $this->db->or_like('id_dak_komponen_sub', $q);\n $this->db->or_like('menu_kegiatan', $q);\n $this->db->or_like('kegiatan', $q);\n $this->db->or_like('id_dak_rincian', $q);\n $this->db->or_like('id_alkes', $q);\n $this->db->or_like('id_jenis_output', $q);\n $this->db->or_like('harga_satuan', $q);\n $this->db->or_like('volume', $q);\n $this->db->or_like('volume_perubahan', $q);\n $this->db->or_like('satuan', $q);\n $this->db->or_like('total', $q);\n $this->db->or_like('sarana', $q);\n $this->db->or_like('created_by', $q);\n $this->db->or_like('created_date', $q);\n $this->db->or_like('updated_by', $q);\n $this->db->or_like('updated_date', $q);\n $this->db->or_like('isdeleted', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function getSearch();", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->order_by($this->id, $this->desc);\n $this->db->group_start();\n $this->db->like('id_item', $q);\n $this->db->or_like('item_type_id', $q);\n $this->db->or_like('id_disciplines', $q);\n $this->db->or_like('item_type_id', $q);\n $this->db->or_like('item_type_name', $q);\n $this->db->group_end();\n $this->db->where('project_status', 0);\n $this->db->where('discipline_status', 0);\n // MODIF BY FAZRI\n $this->db->join('tbl_disciplines', 'tbl_items.id_disciplines = tbl_disciplines.id_discipline');\n $this->db->join('tbl_projects', 'tbl_items.id_projects = tbl_projects.id_project');\n \t$this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "public function getDatas($data,$limit,$start)\n{\n\t$this->db->select('*');\n\t$this->db->where('sample_field', $data['value']);\n\n\t$this->db->limit($limit, $start);\n\t$query = $this->db->get('sample_table');\n\treturn $query->result();\n}", "function index_limit($limit, $start = 0) {\n $this->db->join('tbl_perusahaan','tbl_out.id_perusahaan=tbl_perusahaan.id_perusahaan');\n $this->db->group_by('nomor_permohonan');\n $this->db->order_by($this->id, $this->order);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function get_limit_data($limit, $start = 0, $q = NULL) {\n $this->db->select('id_persediaan, persediaan.id_puskesmas, persediaan.kode, nama_obat, SUM(persediaan.stok_awal) AS stok_awal');\n $this->db->group_by('persediaan.kode');\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id_persediaan', $q);\n $this->db->or_like('persediaan.id_puskesmas', $q);\n $this->db->or_like('persediaan.kode', $q);\n $this->db->or_like('stok_awal', $q);\n $this->db->limit($limit, $start);\n $this->db->join('puskesmas', 'puskesmas.id_puskesmas=persediaan.id_puskesmas');\n $this->db->join('obat', 'obat.kode=persediaan.kode');\n return $this->db->get($this->table)->result();\n }", "public function take($limit = 20);", "public static function getAll($limit,$offset,$search){\n \n $where = \" WHERE a.status=1\";\n $where .= ($search!=\"\")?\" AND CONCAT(a.idArea,' ',a.nombre,' ',DATE_FORMAT(a.updatedAt, '%d/%m/%Y')) LIKE '%$search%'\":\"\";\n \n $sql = \"SELECT a.idArea AS areaId,a.nombre AS areaNombre,DATE_FORMAT(a.updatedAt, '%d/%m/%Y') as createdAt\n FROM area AS a\n $where\n ORDER BY a.updatedAt DESC\";\n\n $general = DB::records($sql);\n $sql.=\" LIMIT \".$offset.\",\".$limit;\n $filter = DB::records($sql);\n \n return array(\"general\"=>$general,\"filter\"=>$filter);\t\n }", "function v_quick_search($surveyid=NULL,$limit=50,$offset=0)\n\t{\n\t\t//get a select query instance\n\t\t$query = $this->solr_client->createSelect();\n\n\t\t//set Edismax\n\t\t$edismax = $query->getEDisMax();\n\n\n\t\t$query->setFields(array(\n\t\t\t\t'vid',\n\t\t\t\t'labl',\n\t\t\t\t'name'\n\t\t\t));\n\n\t\t//set a query (all prices starting from 12)\n\t\t$query->setQuery(sprintf('doctype:2 AND labl:(%s) AND sid:(%s)',$this->study_keywords, $surveyid ) );\n\t\t$query->setStart(0)->setRows(100); //get 0-100 rows\n\n\t\tif($this->debug){\n\t\t\t$request = $this->solr_client->createRequest($query);\n\t\t\techo 'Request URI: ' . $request->getUri() . '<br/>';\n\t\t}\n\n\t\t//execute search\n\t\t$resultset = $this->solr_client->select($query);\n\n\t\t//get the total number of documents found by solr\n\t\t$this->search_found_rows=$resultset->getNumFound();\n\n\t\t//get search result as array\n\t\t$this->search_result=$resultset->getData();\n\t\treturn $this->search_result['response']['docs'];\n\t}", "public function paginate_search($take = 10, $search = null, $status = null);", "function search(Request $request)\n\t{\n\t\t//$limit = $request->limit | 20;\n\t\t$data = $request->get('data');\n\t\t$indicateurs = Indicateur::where('name', 'like', \"%{$data}%\")\n\t\t\t->take(8)\n\t\t\t->get();\n\n\t\treturn new JsonResponse([\n\t\t\t'message' => 'Success get all',\n\t\t\t'data' => $indicateurs !== NULL ? $indicateurs : []\n\t\t], Response::HTTP_OK);\n\t}", "public function searchGet($opt=array()){\n\n\t# Gérer les options\n\t#\n\t$limit\t\t= isset($opt['limit']) \t\t? $opt['limit']\t\t\t: 30;\n\t$offset\t\t= isset($opt['offet']) \t\t? $opt['offset']\t\t: 0;\n\n\tif($opt['id_search'] > 0){\n\t\t$dbMode = 'dbOne';\n\t\t$cond[] = \"k_search.id_search=\".$opt['id_search'];\n\t}else{\n\t\t$dbMode = 'dbMulti';\n\t}\n\n\tif($opt['searchType'] != '') $cond[] = \"searchType='\".$opt['searchType'].\"'\";\n\n\t# Former les conditions\n\t#\n\tif($opt['type'] == 'user') \t\t$cond[] = \"searchType ='user'\";\n\tif($opt['type'] == 'content')\t$cond[] = \"searchType!='user'\";\n\tif(sizeof($cond) > 0) $where = \"WHERE \".implode(\" AND \", $cond);\n\n\t# SEARCH\n\t#\n\t$search = $this->$dbMode(\"SELECT * FROM k_search\\n\". $where);\n\n\t# PARAM\n\t#\n\tif($dbMode == 'dbMulti'){\n\t\tforeach($search as $idx => $c){\n\t\t\t$search[$idx]['searchParam'] = unserialize($search[$idx]['searchParam']);\n\t\t\tif(!is_array($search[$idx]['searchParam'])) $search[$idx]['searchParam'] = array();\n\t\t}\n\t}else\n\tif($dbMode == 'dbOne'){\n\t\t$search['searchParam'] = unserialize($search['searchParam']);\n\t\tif(!is_array($search['searchParam'])) $search['searchParam'] = array();\n\t}\n\n\tif($opt['debug']) $this->pre($this->db_query, $this->db_error, $search);\n\n\treturn $search;\n}", "public function get_limit_data($limit, $start = 0, $q = null)\n {\n $this->db->order_by($this->id, $this->order);\n $this->db->like('id', $q);\n $this->db->or_like('notrans', $q);\n $this->db->or_like('id_karyawan', $q);\n $this->db->or_like('tanggal', $q);\n $this->db->or_like('pengikut', $q);\n $this->db->or_like('tujuan', $q);\n $this->db->or_like('keterangan', $q);\n $this->db->or_like('bbm', $q);\n $this->db->or_like('kupon_bbm', $q);\n $this->db->or_like('id_mobil', $q);\n $this->db->or_like('id_driver', $q);\n $this->db->or_like('keluar_jam', $q);\n $this->db->or_like('masuk_jam', $q);\n $this->db->or_like('status', $q);\n $this->db->or_like('datetime', $q);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function index_limit($limit, $start = 0) {\n $this->db->order_by($this->id, $this->order);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function index_limit($limit, $start = 0) {\n $this->db->order_by($this->id, $this->order);\n $this->db->limit($limit, $start);\n return $this->db->get($this->table)->result();\n }", "function fetch_data($limit, $start)\n\t{\n\t\t// \t\t\t\t\t->from(\"joblist\")\n\t\t// \t\t\t\t\t->where(\"status = '<span class=\\\"label label-success\\\">Telah tayang</span>'\")\n\t\t// \t\t\t\t\t->order_by(\"id_joblist\", \"DESC\")\n\t\t// \t\t\t\t\t->limit($limit, $start)\n\t\t// \t\t\t\t\t->get();\n\n\t\t//\n\t\t// $query = $this->db->query(\"SELECT *\n\t\t// FROM joblist\n\t\t// NATURAL JOIN industri\n\t\t// WHERE status = '<span class=\\\"label label-success\\\">Telah tayang</span>'\n\t\t// ORDER BY id_joblist DESC\n\t\t// LIMIT $limit OFFSET $start \");\n\n\t\t$query = $this->db->query(\"SELECT Nama_joblist, id_joblist, nama_perusahaan, logo_perusahaan, nama, perusahaan\n\t\tFROM joblist\n\t\tNATURAL JOIN company\n\t\tNATURAL JOIN provinsi\n WHERE id_perusahaan = perusahaan\n\t\tAND status = '<span class=\\\"label label-success\\\">Telah tayang</span>'\n\t\tAND id_provinsi = id\n\t\tAND deadline >= current_date()\n\t\tORDER BY id_joblist DESC\n\t\tLIMIT $limit OFFSET $start \");\n\n\t\treturn $query;\n\t}", "function get_search_suggestions($search,$limit=5)\n\t{\n\t\t$suggestions = array();\n\t\t\n\t\t$this->db->from('designation');\n\t\t\n\t\t$this->db->where(\"(designation_name LIKE '%\".$this->db->escape_like_str($search).\"%') AND is_status = 0\");\n\t\t\n\t\t$this->db->limit($limit);\t\n\t\t$by_name = $this->db->get();\n\t\t$temp_suggestions = array();\n\t\tforeach($by_name->result() as $row)\n\t\t{\n\t\t\t$temp_suggestions[] = $row->designation_name;\n\t\t}\n\t\t\n\t\tsort($temp_suggestions);\n\t\tforeach($temp_suggestions as $temp_suggestion)\n\t\t{\n\t\t\t$suggestions[]=array('label'=> $temp_suggestion);\t\t\n\t\t}\n\t\t\n\t\t//only return $limit suggestions\n\t\tif(count($suggestions > $limit))\n\t\t{\n\t\t\t$suggestions = array_slice($suggestions, 0,$limit);\n\t\t}\n\t\treturn $suggestions;\n\t\n\t}", "public function search();", "public function search();", "public function get_limit();", "function kas_list($filter,$start,$end){\r\n\t\t\t$query = \"SELECT * FROM bs \";\r\n\t\t\t\r\n\t\t\t// For simple search\r\n\t\t\tif ($filter<>\"\"){\r\n\t\t\t\t$query .=eregi(\"WHERE\",$query)? \" AND \":\" WHERE \";\r\n\t\t\t\t$query .= \" (bs_tanggal LIKE '%\".addslashes($filter).\"%' OR bs_keterangan LIKE '%\".addslashes($filter).\"%' OR bs_kode LIKE '%\".addslashes($filter).\"%' OR bs_tipe LIKE '%\".addslashes($filter).\"%')\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$result = $this->db->query($query);\r\n\t\t\t$nbrows = $result->num_rows();\r\n\t\t\t$limit = $query.\" LIMIT \".$start.\",\".$end;\t\t\r\n\t\t\t$result = $this->db->query($limit); \r\n\t\t\t\r\n\t\t\tif($nbrows>0){\r\n\t\t\t\tforeach($result->result() as $row){\r\n\t\t\t\t\t$arr[] = $row;\r\n\t\t\t\t}\r\n\t\t\t\t$jsonresult = json_encode($arr);\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}", "function search()\n\t{\n\t\t$search = $this->input->post('search') != '' ? $this->input->post('search') : null;\n\t\t$limit_from = $this->input->post('limit_from');\n\t\t$lines_per_page = $this->Appconfig->get('lines_per_page');\n\n\t\t$suppliers = $this->Supplier->search($search, $lines_per_page, $limit_from);\n\t\t$total_rows = $this->Supplier->get_found_rows($search);\n\t\t$links = $this->_initialize_pagination($this->Supplier, $lines_per_page, $limit_from, $total_rows);\n\t\t$data_rows = get_supplier_manage_table_data_rows($suppliers, $this);\n\n\t\techo json_encode(array('total_rows' => $total_rows, 'rows' => $data_rows, 'pagination' => $links));\n\t}", "function getSearchInfo()\n\t{\n\t\t//Global allows variables outside the function scope to be used here\n\t\tglobal $conn;\n\t\tglobal $myObj;\n\t\tglobal $params_arr;\n\t\t\n\t\t\n\t\t$keyword = $params_arr[0];\n\t\t$order = $params_arr[1];\n\t\t\n\t\t$sql = \"SET @SEARCH_TERM = '%$keyword%';\";\n\t\t\n\t\tif ($conn->query($sql) === TRUE) \n\t\t{\n\t\t\t//echo \"New record created successfully\";\n\t\t} \n\t\telse \n\t\t{\n\t\t\techo \"Error: \" . $sql . \"<br>\" . $conn->error;\n\t\t}\n\n\n\t\t$sql = \"SELECT books.COVER, books.TITLE, books.GENRE, books.PUBLISHER, authors.FIRST_NAME, authors.LAST_NAME, books.PUB_DATE,\n\t\t\t \t\t books.DESCRIPTION, authors.BIO, books.ISBN, books.ID\n\t\t\t\t FROM books \n\t\t\t\t JOIN authors ON books.AUTHOR = authors.ID\n\t\t\t\t WHERE authors.FIRST_NAME LIKE @SEARCH_TERM OR\n\t\t\t authors.LAST_NAME LIKE @SEARCH_TERM OR \n\t\t\t\t\t\tbooks.TITLE LIKE @SEARCH_TERM OR\n\t\t\t\t\t\tbooks.GENRE LIKE @SEARCH_TERM\n\t\t\t\tORDER BY books.TITLE $order\n\t\t\t\t\n\t\t\t\t\";\n\t\t\t\t//Limit $offset; \n\t\t\t\t//@Julian then here I have LIMIT of per page here $offset so if 10 or 20 placed here just like ASC/DESC\n\n\t\t//Executes query string\n\t\t$result = $conn->query($sql);\n\t\t//Im making the page number between 10 and 20\n\t\tif ($result->num_rows > 0) \n\t\t{\n\t\t\t$json = array();\n\t \t// convert the data into json object\n\t \twhile($row = $result->fetch_assoc()) \n\t \t{\n\t\t\t\t$bus = array(\n\t\t\t\t\t\"cover\" => $row[\"COVER\"],\n\t\t\t\t\t\"title\" => $row[\"TITLE\"],\n\t\t\t\t\t\"author\" => $row[\"FIRST_NAME\"]. \" \" .$row[\"LAST_NAME\"],\n\t\t\t\t\t\"genre\" => $row[\"GENRE\"],\n\t\t\t\t\t\"publisher\" => $row[\"PUBLISHER\"],\n\t\t\t\t\t\"pub_date\" => $row[\"PUB_DATE\"],\n\t\t\t\t\t\"description\" => $row[\"DESCRIPTION\"],\n\t\t\t\t\t\"bio\" => $row[\"BIO\"],\n\t\t\t\t\t\"isbn\" => $row[\"ISBN\"],\n\t\t\t\t\t\"id\" => $row[\"ID\"]\n\t\t\t\t);\n\n\t\t\t\tarray_push($json, $bus);\n\t\t\t\t\n\t\t\t}\n\n\t\t\t$jsonstring = json_encode($json);\n\t\t\techo $jsonstring;\n\t\t}\n\t\telse\n\t\t{\n\t\t echo \"0 results\";\n\t\t}\n\n\n\n\t\t$conn->close();\n\t}", "public function getSearchRange() {}", "public function getSearchRange() {}", "function getAll($limit = 20){\n $query = $this->db->get($this->table, $limit);\n if($query->num_rows() > 0 ){\n foreach ($query->result() as $row){\n $data[] = $row;\n }\n return $data;\n }\n }", "private function queryProducts($query,$limit = NULL)\n {\n if($limit != NULL){\n $products = ProductModel::where('product_name','LIKE','%'.$query.'%')->take($limit)->get();\n }\n else{\n $products = ProductModel::where('product_name','LIKE','%'.$query.'%')->get();\n }\n\n if(!$products->isEmpty())\n {\n $searchData = $this->prepareProductsData($products);\n }\n else\n {\n $searchData=[];\n }\n \n // Log::info('SearchController >> Returning Search Results For Query '. \"$query\"); \n return $searchData;\n }", "public function find_limit($limit = 100, $offset = 0 )\n {\n $query= $this->db->query(\"\n SELECT *\n FROM punti_spesi\n LIMIT $offset , $limit \"); \n return $query->result();\n }", "public function paging(){\n\t\t$sql = \"SELECT * FROM berita\";\n\t\t$query = $this->db->query($sql) or die ($this->db->error);\n\t\treturn $query;\n\t}", "function list_rechazo($data_search, $limit = 10, $offset = 0)\n {\n $sql=\"\n SELECT\n tbl_rechazo.*,\n\t\t \t\ttbl_cliente.id_cliente,\n \t \tIF (tbl_cliente.tipo_cliente = 'natural', CONCAT(tbl_cliente.nombre,' ',tbl_cliente.apellidos,' ',tbl_cliente.rut_doc), CONCAT(tbl_cliente.razon_social,' ',tbl_cliente.rut_doc)) AS cliente_nom\n FROM tbl_rechazo, tbl_cliente\n WHERE tbl_rechazo.id_cliente = tbl_cliente.id_cliente\";\n if ($data_search['id_cliente'] != ''){\n \t$sql=$sql.\"\n AND tbl_rechazo.id_cliente = \".$this->db->escape($data_search['id_cliente']);\n }\n if ($data_search['st_rechazo'] != ''){\n $sql=$sql.\"\n AND tbl_rechazo.st_rechazo = \".$this->db->escape($data_search['st_rechazo']);\n }\n if ($data_search['tipo_rechazo'] != ''){\n \t$sql=$sql.\"\n AND tbl_rechazo.tipo_rechazo = \".$this->db->escape($data_search['tipo_rechazo']);\n }\n $sql=$sql.'\n ORDER BY id_rechazo ASC\n LIMIT ' . $offset . ', ' . $limit;\n $result = $this->db->query($sql);\n return $result->result_array();\n }", "function get_search_suggestions($search,$limit=25)\n\t{\n\t\t$suggestions = array();\n\n\t\t$this->db->from('department_type');\n\t\t$this->db->like('dept_title', $search);\n\t\t$this->db->where('is_status',0);\n\t\t$this->db->limit($limit);\n\t\t$by_name = $this->db->get();\n\t\t$temp_suggestions = array();\n\t\tforeach($by_name->result() as $row)\n\t\t{\n\t\t\t$temp_suggestions[] = $row->dept_title;\n\t\t}\n\n\t\tsort($temp_suggestions);\n\t\tforeach($temp_suggestions as $temp_suggestion)\n\t\t{\n\t\t\t$suggestions[]=array('label'=> $temp_suggestion);\n\t\t}\n\n\t\t$this->db->from('university');\n\t\t$this->db->where('is_status',0);\n\t\t$this->db->like('dept_title_kh', $search);\n\t\t$this->db->limit($limit);\n\t\t$by_name_kh = $this->db->get();\n\n\t\t$temp_suggestions = array();\n\t\tforeach($by_name_kh->result() as $row)\n\t\t{\n\t\t\t$temp_suggestions[] = $row->dept_title_kh;\n\t\t}\n\n\t\tsort($temp_suggestions);\n\t\tforeach($temp_suggestions as $temp_suggestion)\n\t\t{\n\t\t\t$suggestions[]=array('label'=> $temp_suggestion);\n\t\t}\n\n\t\t//only return $limit suggestions\n\t\tif(count($suggestions > $limit))\n\t\t{\n\t\t\t$suggestions = array_slice($suggestions, 0,$limit);\n\t\t}\n\n\t\treturn $suggestions;\n\t}", "function getAllModelByID($id, $limit){\n $data = http_build_query([\n 'mark_id' => $id,\n 'limit' => $limit,\n ]);//build query\n $ch = curl_init();//init Curl\n curl_setopt_array($ch, [\n CURLOPT_URL => 'https://apistaging.el-market.org/v1/osago/lists/models/?' . $data,\n CURLOPT_RETURNTRANSFER => 1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => [\n 'Accept: application/json',\n 'Authorization: Token Test2019',\n ],\n ]);\n $res=json_decode(curl_exec($ch),true);\n curl_close($ch);\n if (curl_errno($ch)) { echo 'Error:' . curl_error($ch);}\n return $res['results'];\n}", "public function limit($limit,$offset);", "function newskomentar_searchdata_all_bypage( $tbl_newskomentar, $cari, $offset, $dataperPage ){\n\t\t$sql = mysql_query(\"SELECT * FROM $tbl_newskomentar WHERE \n\t\t\tjudul LIKE '$cari' OR\n\t\t\tpesan LIKE '$cari' \n\t\t\t\tORDER BY id ASC LIMIT $offset, $dataperPage\n\t\t\"); \n \t\treturn $sql;\n}", "public function search(){}", "private function rest_search() {\n\t\t// return json elements here\n\t}", "function getResult($limit, $idField, $dateField = null);", "public function getLimit();", "public function getLimit();", "public function getLimit();", "public function getLimit();", "public function getLimit();", "function getRecords($limit = false)\n\t{\n\t\tif ($limit !== false)\n\t\t\t$this->setParam(\"limit\", $limit);\n\n\t\t$this->table->getRecords();\n\t}", "public function limit($limit);", "public function limit($limit);", "function get_item_kit_search_suggestions($search, $limit=25)\n\t{\n\t\t$suggestions = array();\n\n\t\t$by_name = $this->db->like('name', $search, $this->config->item('speed_up_search_queries') ? 'after' : 'both')\n\t\t\t\t\t->where('deleted',0)\n\t\t\t\t\t->where('category',\"tickets\")\n\t\t\t\t\t->order_by(\"name\", \"asc\")\n\t\t\t\t\t->get(\"item_kits\");\n\t\tforeach($by_name->result() as $row)\n\t\t{\n\t\t\t$suggestions[]=array('value' => 'KIT '.$row->item_kit_id, 'label' => $row->name);\n\t\t}\n\t\t\n\t\t$by_item_kit_number = $this->db->like('item_kit_number', $search, $this->config->item('speed_up_search_queries') ? 'after' : 'both')\n\t\t\t\t\t->where('deleted',0)\n\t\t\t\t\t->where('category',\"tickets\")\n\t\t\t\t\t->order_by(\"item_kit_number\", \"asc\")\n\t\t\t\t\t->get(\"item_kits\");\n\t\tforeach($by_item_kit_number->result() as $row)\n\t\t{\n\t\t\t$suggestions[]=array('value' => 'KIT '.$row->item_kit_id, 'label' => $row->item_kit_number);\n\t\t}\n\t\t\n\t\t//only return $limit suggestions\n\t\tif(count($suggestions > $limit))\n\t\t{\n\t\t\t$suggestions = array_slice($suggestions, 0,$limit);\n\t\t}\n\t\treturn $suggestions;\n\t\t\n\t}", "function getSearch()\n\t{\n\t\t//init variable\n\t\t$app = JFactory::getApplication();\n\t\t$log_user = JFactory::getUser($this->plugin->get('user')->id);\n\t\n\t\t$search = $app->input->get('search','','STRING');\n\t\t$nxt_lim = $app->input->get('next_limit',0,'INT');\n\n\t\t$limitstart = $app->input->get('limitstart',0,'INT');\n\t\t$limit = $app->input->get('limit',10,'INT');\n\t\t$list = array();\n\t\t$list['data_status'] = true;\n\t\tif($limitstart)\n\t\t{\n\t\t\t$limit = $limit + $limitstart;\n\t\t}\n\t\t\n\t\t$mapp = new EasySocialApiMappingHelper();\n\t\t$res = new stdClass;\n\t\t\n\t\tif(empty($search))\n\t\t{\n\t\t\t$res->status = 0;\n\t\t\t$res->message = JText::_( 'PLG_API_EASYSOCIAL_EMPTY_SEARCHTEXT_MESSAGE' );\n\t\t\treturn $res;\n\t\t}\n\t\t\n\t\t$userid = $log_user->id;\n\t\n\t\t$serch_obj = new EasySocialModelSearch();\n\t\t\t\n\t\t$db = JFactory::getDbo();\n\t\t$query = $db->getQuery(true);\n\t\t$frnd_obj = new EasySocialModelFriends();\n\t\t\n\t\t$query->select($db->quoteName(array('su.user_id')));\n\t\t$query->from($db->quoteName('#__social_users','su'));\n\t\t$query->join('LEFT', $db->quoteName('#__users', 'u') . ' ON (' . $db->quoteName('su.user_id') . ' = ' . $db->quoteName('u.id') . ')');\n\t\t\n\t\tif(!empty($search))\n\t\t{\n\t\t\t$query->where(\"(u.username LIKE '%\".$search.\"%' ) OR ( u.name LIKE '%\".$search.\"%')\");\n\t\t}\n\t\t\n\t\t$query->order($db->quoteName('u.id') .'ASC');\n\n\t\t$db->setQuery($query);\n\t\t$tdata = $db->loadObjectList();\n\t\t$block_model = FD::model('Blocks');\t\n\t\t$susers = array();\n\t\tforeach($tdata as $ky=>$val)\n\t\t{\n\t\t\t$block = $block_model->isBlocked($val->user_id,$userid);\n\t\t\tif(!$block)\n\t\t\t{\t\t\n\t\t\t\t$susers[] = FD::user($val->user_id);\t\t\t\t\n\t\t\t}\n\t\t}\n\t\t\t\t\n\t\t//manual pagination code\n\t\t$susers = array_slice( $susers, $limitstart, $limit );\t\t\n\t\t$base_obj = $mapp->mapItem($susers,'user',$log_user->id);\n\t\t$list['user'] = $this->createSearchObj( $base_obj );\n\n\t\tif(empty($list['user']))\n\t\t{\n\t\t\t$ret_arr = new stdClass;\n\t\t\t$ret_arr->status = false;\n\t\t\t$ret_arr->message = JText::_( 'PLG_API_EASYSOCIAL_USER_NOT_FOUND' );\n\t\t\t$list['user']= $ret_arr;\n\t\t}\n\t\t\n\t\t//for group\n\t\t$query1 = $db->getQuery(true);\n\t\t$query1->select($db->quoteName(array('cl.id')));\n\t\t$query1->from($db->quoteName('#__social_clusters','cl'));\n\t\t\n\t\tif(!empty($search))\n\t\t{\n\t\t\t$query1->where(\"(cl.title LIKE '%\".$search.\"%' )\");\n\t\t}\n\t\t$query1->where('cl.state = 1');\n\t\t\n\t\t$query1->order($db->quoteName('cl.id') .'ASC');\n\n\t\t$db->setQuery($query1);\n\t\t$gdata = $db->loadObjectList();\n\t\t\n\t\t$grp_model = FD::model('Groups');\n\t\t$group = array();\n\t\tforeach($gdata as $grp)\n\t\t{\n\t\t\t$group_load = FD::group($grp->id); \n\t\t\t$is_inviteonly = $group_load->isInviteOnly();\n\t\t\t$is_member = $group_load->isMember($log_user->id);\n\t\t\tif($is_inviteonly && !$is_member)\n\t\t\t{\n\t\t\t\tif($group_load->creator_uid == $log_user->id)\n\t\t\t\t{\n\t\t\t\t\t$group[] = FD::group($grp->id);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{ \n\t\t\t\t\tcontinue;\n\t\t\t\t} \n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$group[] = FD::group($grp->id); \n\t\t\t}\n\t\t}\n\t\t\n\t\t//manual pagination code\n\t\t$group = array_slice( $group, $limitstart, $limit );\n\t\t$list['group'] = $mapp->mapItem($group,'group',$log_user->id);\n\t\t\n\t\tif(empty($list['group']))\n\t\t{\n\t\t\t$ret_arr = new stdClass;\n\t\t\t$ret_arr->status = false;\n\t\t\t$ret_arr->message = JText::_( 'PLG_API_EASYSOCIAL_GROUP_NOT_FOUND' );\n\t\t\t$list['group']= $ret_arr;\n\t\t}\n\t\t\t\n\t\t//give status as per front end requirement\n\t\tif(empty($list['group']) && empty($list['user']))\t\n\t\t{\n\t\t\t$list['data_status'] = false;\n\t\t}\n\t\treturn( $list );\n\t}", "private function _findInIndex($keywords, $filter=null, $sortBy=null, $limit=10)\n {\n $ret = array();\n $query = $this->client->createSelect();\n // create a filterquery\n if (!empty($keywords))\n {\n // if isbn\n if (preg_match('/^\\d{10,13}$/', $keywords)) {\n $query->addFilterQuery(array(\n 'key' => 'fq1',\n // 'tag' => array('populationLimit'),\n 'query' => 'ISBN:'.$keywords,\n ));\n } else {\n $query->addFilterQuery(array(\n 'key' => 'fq1',\n // 'tag' => array('populationLimit'),\n 'query' => '\"'.$keywords.'\"'.'~0.5',\n ));\n }\n }\n if (!empty($filter))\n {\n if (!empty($filter['categoryNames']))\n {\n $query->addFilterQuery(array(\n 'key' => 'fq4',\n // 'tag' => array('populationLimit'),\n 'query' => 'categories:'.implode(' ',$filter['categoryNames']),\n ));\n }\n \n if(!empty($filter['min']) && !empty($filter['max'])) {\n $query->addFilterQuery(array(\n 'key'=> 'fq2',\n 'query' => 'min_investment: ['.($filter['min']*10000).' TO *]'\n ));\n $query->addFilterQuery(array(\n 'key'=> 'fq3',\n 'query' => 'max_investment: [* TO '.($filter['max']*10000).']'\n ));\n } elseif(!empty($filter['min']) && empty($filter['max'])) {\n $query->addFilterQuery(array(\n 'key'=> 'fq2',\n 'query' => 'min_investment: ['.($filter['min']*10000).' TO *]'\n ));\n } elseif(empty($filter['min']) && !empty($filter['max'])) {\n $query->addFilterQuery(array(\n 'key'=> 'fq3',\n 'query' => 'max_investment: [* TO '.($filter['max']*10000).']'\n ));\n }\n }\n $query->setRows($limit);\n //:['' TO *]\n //\n // *:* is equivalent to telling solr to return all docs\n $resultSet = $this->client->select($query);\n $index = 0;\n foreach ($resultSet as $result) {\n $klass = new \\StdClass;\n $klass->id = $result->id;\n $klass->name = $result->name;\n $klass->description = $result->description;\n $klass->min_investment = $result->min_investment;\n $klass->max_investment = $result->max_investment;\n $klass->address = $result->address;\n $klass->tags = $this->_getTagsOrCategories($result->tags);\n $klass->categories = $this->_getTagsOrCategories($result->categories);\n $klass->url = $result->url;\n $klass->contact_name = $result->contact_name;\n $klass->contact_email = $result->contact_email;\n $klass->contact_phone = $result->contact_phone;\n if (isset($result->big_image_url)) {\n $klass->big_image_url = $this->base_url.\\Config::get('core::core.defaults.image_base_url.item').$result->big_image_url;\n } else {\n $klass->big_image_url = $this->base_url.\\Config::get('core::core.defaults.image_base_url.item').\\Config::get('core::core.defaults.image.item');\n }\n if (isset($result->medium_image_url)) {\n $klass->medium_image_url = $this->base_url.\\Config::get('core::core.defaults.image_base_url.item').$result->medium_image_url;\n } else {\n $klass->medium_image_url = $this->base_url.\\Config::get('core::core.defaults.image_base_url.item').\\Config::get('core::core.defaults.image.item');\n }\n if (isset($result->small_image_url)) {\n $klass->small_image_url = $this->base_url.\\Config::get('core::core.defaults.image_base_url.item').$result->small_image_url;\n } else {\n $klass->small_image_url = $this->base_url.\\Config::get('core::core.defaults.image_base_url.item').\\Config::get('core::core.defaults.image.item');\n }\n $klass->company = $this->_getCompany($result->companyId, $result->companyName, $result->companyBigImageUrl, $result->companyMediumImageUrl, $result->companySmallImageUrl);\n $klass->territory = $this->_getTerritory($result->territoryId, $result->territoryName, $result->countryId, $result->countryName);\n $ret[$index++] = $klass;\n }\n\n return $this->_mapSearchResult($ret, $filter);\n }", "function gets(Sale_model $sale)\n {\n $display = isset($sale->display)? $sale->display:10;\n $page = isset($sale->page)?$sale->page:1;\n $offset = ($page-1) * $display;\n\n $search = isset($sale->search)? $sale->search: \"\";\n $search_by = isset($sale->search_by)? $sale->search_by: \"journal_no\";\n $search_option = isset($sale->search_option)? $sale->search_option : 'like';\n\n $room_id = isset($sale->room_id)? $sale->room_id : 0;\n\n $all_date = isset($sale->all_date) && $sale->all_date==1? 1 : 0;\n $date_of = isset($sale->date_of)? $sale->date_of : \"journal_date\";\n $from_date = isset($sale->from_date)? $sale->from_date : Date('Y-m-d');\n $to_date = isset($sale->to_date)? $sale->to_date : Date('Y-m-d');\n\n $sql = \"SELECT j.*, r.room_name, \".\n \"(select count(*) \".\n \"from journal j \".\n \"left join room r on r.room_id=j.room_id \".\n \"where $room_id in (0, j.room_id) \".\n \"and ('$search'='' || \".\n \"('$search_option'='exact' && $search_by='$search') || \".\n \"('$search_option'='start_with' && $search_by LIKE '$search%' ESCAPE '!') || \".\n \"('$search_option'='like' && $search_by LIKE '%$search%' ESCAPE '!')) \".\n \"AND (($all_date=1 && j.$date_of is not null) || j.$date_of BETWEEN '$from_date 00:00:00' and '$to_date 23:59:59') \".\n \") records \".\n \"from journal j \".\n \"left join room r on r.room_id=j.room_id \".\n \"where $room_id in (0, j.room_id) \".\n \"and ('$search'='' || \".\n \"('$search_option'='exact' && $search_by='$search') || \".\n \"('$search_option'='start_with' && $search_by LIKE '$search%' ESCAPE '!') || \".\n \"('$search_option'='like' && $search_by LIKE '%$search%' ESCAPE '!')) \".\n \"AND (($all_date=1 && j.$date_of is not null) || j.$date_of BETWEEN '$from_date 00:00:00' and '$to_date 23:59:59') \".\n \"LIMIT $offset, $display\"\n ;\n\n $query = $this->db->query($sql);\n\n //echo $this->db->last_query();\n\n if(!$query || $query->num_rows()== 0)\n {\n return Message_result::error_message('Search not found');\n }\n else\n {\n return Message_result::success_message('', null, $query->result('Sale_model'));\n }\n\n\n }", "public function apiFetch( $limit, $offset );", "function allWithLimit() {\n\n }", "function search()\n\t{\n\t\t$search=$this->input->post('search');\n\t\t\t$data_rows=get_temp_manage_table_data_rows1($this->Giftcard->search($search),$this);\n\t\t\techo $data_rows;\n\t}", "function findStartGet($limit) { // limit diisi 10\n\t\tif ((!isset($_GET['page'])) || ($_GET['page'] == \"1\")) \n\t\t { \n\t\t $start = 0; \n\t\t $_GET['page'] = 1; \n\t\t } \n\t\t else \n\t\t { // jika $page= 3 \n\t\t $start = ($_GET['page']-1) * $limit; // maka $start= 20\n\t\t }\n\t\t\t\n\t\t return $start; \n }", "function getAllMarks($limit){\n $data = http_build_query([\n 'limit' => $limit,\n ]);//build query\n $ch = curl_init();//init Curl\n curl_setopt_array($ch, [\n CURLOPT_URL => 'https://apistaging.el-market.org/v1/osago/lists/marks/?' . $data,\n CURLOPT_RETURNTRANSFER => 1,\n CURLOPT_CUSTOMREQUEST => \"GET\",\n CURLOPT_HTTPHEADER => [\n 'Accept: application/json',\n 'Authorization: Token Test2019'\n ]\n ]);\n $res=json_decode(curl_exec($ch),true);\n curl_close($ch);\n if (curl_errno($ch)) { echo 'Error:' . curl_error($ch);}\n return $res['results'];\n}", "public function all_data($limit = null) {\n global $wpdb;\n\n $limit_string = \"\";\n if ($limit != null) {\n $limit_string = \"limit \" . mysql_real_escape_string((int) $limit);\n }\n\n return $wpdb->get_results(\n 'select * from `' . mysql_real_escape_string($this->table_name()) . '`' .\n ' order by recipecan_id desc ' . $limit_string,\n ARRAY_A\n );\n }", "function getsearch_get(){\n $keyword = $this->get('keyword');\n $result = $this->lecturers_model->getsearch_all($keyword);\n $this->response($result); \n\n }", "function allNewsDB($search_by='', $limit='', $offset=0) {\n\t\t$this->db->select('N.*');\n\t\t$this->db->from('dipp_news N');\n\t\t$this->db->limit($limit, $offset);\n\t\t$this->db->order_by('N.id','DESC');\n\t\tif($search_by <> ''){\n\t\t\t$this->db->like('N.title',$search_by);\n\t\t}\n\t\t$query= $this->db->get();\n\t\t//echo $this->db->last_query();\n\t\treturn $query->result_array();\n\t}", "function gets(Currency_model $model)\n {\n\n $display = isset($model->display)? $model->display:10;\n $page = isset($model->page)?$model->page:1;\n $offset = ($page-1) * $display;\n\n $search = isset($model->search)? $model->search:'';\n $field = isset($model->search_by)? $model->search_by: 'currency_name';\n\n $this->db->select(\"currency.*, \".\n \"(select count(*) from currency where $field like '%$search%') 'records' \"\n );\n $this->db->like(\"$field\", \"$search\");\n $this->db->limit($display, $offset);\n $query = $this->db->get('currency');\n\n //echo $this->db->last_query();\n\n if(!$query || $query->num_rows()== 0)\n {\n return Message_result::error_message('Search not found');\n }\n else\n {\n return Message_result::success_message('', null, $query->result('Currency_model'));\n }\n }", "public function get($limit = 0)\n {\n if ($limit) {\n $this->setLimit($limit);\n }\n return $this->getResults();\n }", "public function getResults()\n {\n if($this->search) {\n foreach ($this->filters as $field) {\n $field = array_filter(explode('.', $field));\n if(count($field) == 2) {\n $this->query->whereHas($field[0], function ($q) use ($field) {\n $q->where($field[1], 'ilike', \"%{$this->search}%\");\n });\n }\n if(count($field) == 1) {\n $this->query->orWhere($field[0], 'ilike', \"%{$this->search}%\");\n }\n }\n }\n\n if($this->where) {\n foreach ($this->where as $field => $value) {\n $this->query->where($field, $value);\n }\n }\n\n if ($this->whereBetween) {\n foreach ($this->whereBetween as $field => $value)\n $this->query->whereBetween($field, $value);\n }\n// dd($this->query->toSql());\n return $this->query->paginate($this->per_page);\n }", "public function find($page, $limit, $term);", "public function find($page, $limit, $term);", "public function getAllBy ($search = [[]], $limit=null, $offset=null)\r\n\t\t{\r\n\t\t\t$i = 1;\r\n\t\t\t$req =\"\";\r\n\r\n\t\t\tforeach ($search as $key=>$array2)\r\n\t\t\t{\r\n\t\t\t\tif($key === \"OR\")\r\n\t\t\t\t{\r\n\t\t\t\t\t$req = \"SELECT * FROM \" .$this->table. \" WHERE \";\r\n\t\t\t\t\t$count = count($array2);\r\n\t\t\t\t\tforeach($array2 as $key2=>$value2)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$req .= $key2. \" = '\" .$value2. \"'\";\r\n\t\t\t\t\t\tif ($count > 1 && $i < $count) {\r\n\t\t\t\t\t\t\t\t$req .= \" OR \";\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t$i = $i + 1;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\telse if($key === \"AND\") {\r\n\t\t\t\t\t$req = \"SELECT * FROM \" .$this->table. \" WHERE \";\r\n\t\t\t\t\t$count = count($array2);\r\n\t\t\t\t\tforeach($array2 as $key2=>$value2)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$req .= $key2. \" = '\" .$value2. \"'\";\r\n\t\t\t\t\t\tif ($count > 1 && $i < $count) {\r\n\t\t\t\t\t\t\t\t$req .= \" AND \";\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t$i = $i + 1;\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$req = \"SELECT * FROM \" .$this->table;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t// On ajoute limite et offset si ils sont passés en paramètres\r\n\t\t\tif($limit != null && is_int($limit)) {\r\n\t\t\t $req .= \" LIMIT :limit\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif($offset != null && is_int($offset)) {\r\n\t\t\t $req .= \" OFFSET :offset\";\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t// Prépare la requête\r\n\t\t\t$query = $this->db->prepare($req);\r\n\t\t\t\r\n\t\t\t\r\n\t\t\tif($limit != null && is_int($limit)) {\r\n\t\t\t\t$query->bindParam(':limit', $limit, PDO::PARAM_INT);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tif($offset != null && is_int($offset)) {\r\n\t\t\t\t$query->bindParam(':offset', $offset, PDO::PARAM_INT);\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$query->execute();\r\n\t\t\t/* $results is the results table from the query executed */\r\n\t\t\t$results = $query->fetchAll(PDO::FETCH_ASSOC);\r\n\r\n\t\t\tif (count($results) < 1) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\r\n\t\t\t// TODO: A adapter suite au fetch -> fetchAll ?\r\n\t\t\t/*foreach($results as $key => $val) {\r\n\t\t\t\t$this->{$key} = $val;\r\n\t\t\t}*/\r\n\t\t\t\r\n\t\t\treturn $results;\r\n\t\t}", "public function getData($limit = 10, $page = 1) { // set default arguments values\n $results = array();\n $this->limit = $limit;\n $this->page = $page;\n\n // no limiting necessary, use query as it is\n if ($this->limit == 'all') {\n $query = $this->query;\n } else {\n // echo (($this->page - 1) * $this->limit); die;\n // create the query, limiting records from page, to limit\n $this->rowstart = (($this->page - 1) * $this->limit);\n // add to original query: (minus one because of the way SQL works)\n $query = $this->query . \" LIMIT {$this->rowstart}, $this->limit\";\n }\n\n try {\n $stmt = $this->conn->query($query);\n\n if ($stmt->execute()):\n $results = $stmt->fetchAll(PDO::FETCH_ASSOC);\n endif;\n } catch (PDOException $e) {\n echo \"Error: \" . $e->getMessage();\n die;\n }\n\n return $results; // object\n }", "private function query($cursor, $limit) {\n // here. Since this is an example, we just use a premade dataset.\n\n return array_slice($this->data, $cursor, $limit);\n }", "function GetAll($limit, $offset)\n {\n\t\t$this->db->select('employer_job_post.*');\n\t\t$this->db->from('employer_job_post');\n\t\t$filterData = $this->session->userdata('job_search');\n\t\t$where = \"(\ttitle like '%$filterData%' )\";\n\t\t$this->db->where($where);\n\t\tif($this->session->userdata('job_industry')!='')\n\t\t$this->db->where('industry',$this->session->userdata('job_industry'));\n\t\tif($this->session->userdata('job_location')!='')\n\t\t$this->db->where('country',$this->session->userdata('job_location'));\n\t\tif($this->session->userdata('job_role')!='')\n\t\t$this->db->where('role',$this->session->userdata('job_role'));\n\t\t\n\t\t$this->db->limit($limit, $offset);\n\t\t$this->db->order_by(\"employer_job_post.job_id\", \"DESC\");\n\t\t$query = $this->db->get();\n $module = array();\n if ($query->num_rows() > 0) \n {\n $module = $query->result_array();\n }\n return $module;\n }", "public function admin_get_users(){\n $limit = $this->input->get('length');\n $offset = $this->input->get('start');\n $search = $this->input->get('search')['value'];\n echo $this->usm->get_users($limit, $offset, $search);\n }", "public function findOrdered($limit = 10, $search = null) {\n $results = $this->createQueryBuilder()\n ->hydrate(true)\n ->limit($limit)\n\t\t\t\t\t\t\t\t\t\t->sort(\"u\", \"desc\");\n \n\t\tif ($search) {\n\t\t\t$regexp = new \\MongoRegex('/'.$search.'/i');\n\t\t\t$results->field('domain')->equals($regexp);\n\t\t}\n\t\t\n return $results->getQuery()->execute();\n\t}", "public function getMaxResults();", "protected function actionGetByLimit($start=0,$limit=0) {\n $model = new News();\n \n $result= $model->getItemsByLimit($start, $limit);\n return $result;\n }", "function getLimit() ;", "function fetchList($limit, $offset);", "public function search($limit = 5)\n\t{\n\t\t$criteria = $this->getSearchCriteria();\n\n\t\treturn new CActiveDataProvider($this, array(\n\t\t\t'criteria' => $criteria,\n\t\t\t'pagination'=>array(\n\t\t\t\t'pageSize' => $limit,\n\t\t\t),\n\t\t));\n\t}" ]
[ "0.736385", "0.7351141", "0.73325604", "0.7150403", "0.7140918", "0.7117208", "0.71165836", "0.7114456", "0.7099251", "0.70849854", "0.7059615", "0.7040838", "0.7019689", "0.7011828", "0.6997974", "0.69627774", "0.6928679", "0.69104755", "0.6861577", "0.6847491", "0.684027", "0.68245834", "0.6764349", "0.67582434", "0.6751349", "0.6746285", "0.67216235", "0.669673", "0.6634494", "0.660914", "0.65956956", "0.65927124", "0.6549899", "0.65012795", "0.6492517", "0.6485632", "0.6475378", "0.6434931", "0.6416965", "0.64108515", "0.64032644", "0.64032644", "0.6393262", "0.63861185", "0.6375018", "0.6375018", "0.6369796", "0.6369718", "0.63671046", "0.6361536", "0.63384795", "0.6335603", "0.63332003", "0.6327506", "0.63185346", "0.62840664", "0.6269762", "0.6261096", "0.6256336", "0.62463564", "0.6245504", "0.6235611", "0.6226791", "0.6224792", "0.62229437", "0.62229437", "0.62229437", "0.62229437", "0.62229437", "0.62213", "0.6218063", "0.6218063", "0.6216907", "0.6216115", "0.62065196", "0.62064534", "0.6188203", "0.6187513", "0.618363", "0.6153147", "0.61467975", "0.6138933", "0.6137412", "0.6134506", "0.6132725", "0.6114306", "0.610403", "0.6101574", "0.6101574", "0.60967225", "0.6094314", "0.6090947", "0.6074105", "0.60679924", "0.6061391", "0.6060958", "0.6054581", "0.6047557", "0.6039627", "0.6039231" ]
0.69826734
15
ambil data dari db
function dropdown_ijin() { $result = $this->db->get('tbl_ijin'); // bikin array // please select berikut ini merupakan tambahan saja agar saat pertama // diload akan ditampilkan text please select. $dd[''] = 'Please Select'; if ($result->num_rows() > 0) { foreach ($result->result() as $row) { // tentukan value (sebelah kiri) dan labelnya (sebelah kanan) $dd[$row->id_ijin] = $row->nomor . "/KODE KANTOR/" . $row->id_seksi . "/" . $row->tahun; } } return $dd; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ambil_data(){\n\t\t$this->db->order_by($this->id_admin,$this->order);\n\t\treturn $this->db->get($this->nama_table)->result();\n\t}", "function ambil_data()\n \t{\n \t\t$this->db->distinct();\n \t\t$this->db->select('bk.id_buku, s.nama_supplier, bk.judul, bk.tema, bk.penulis, bk.harga');\n \t\t$this->db->from('buku bk');\n \t\t$this->db->join('supplier s', 's.id_supplier = bk.id_supplier');\n \t\treturn $this->db->get($this->nama_table)->result();\n\n \t\t$data['buku'] = $this->db->order_by($this->id, $this->order);\n \t\treturn $this->db->get($this->nama_table)->result();\n \t}", "public function ambildata_perusahaan(){\n\t\t$query=$this->db->query(\"SELECT * FROM tb_perusahaan\");\n\t\treturn $query->result_array();\n\t}", "function ambil_data(){ //fungsi yang akan mengambil data pada table user\n\t\treturn $this->db->get('user'); //mengambil data dari database, mengembalikan data yang ditangkap pada controller yang memanggil function ambil_data\n\t}", "function allinea_db(){\n\t\tif ($this->attributes['BYTB']!='' ) $this->fields_value_bytb($this->attributes['BYTB']);\n\t\tif ($this->attributes['TB']!='no'){\n\t\t\t$i=0;\n\t\t\tforeach ($this->values as $key => $val){\n\t\t\t\t$ret[$i]=\"{$key} NUMBER\";\n\t\t\t\t$i++;\n\t\t\t\t$ret[$i]=\"D_{$key} VARCHAR2(200 CHAR)\";\n\t\t\t\t$i++;\n\t\t\t}\n\t\t\treturn $ret;\n\t\t}\n\t\telse return ;\n\t}", "public function readDataPerbaikanBelum(){\n $sql = \"SELECT c.tanggal,c.nomor,c.no_inventaris,c.nama_user,b.cost_center,c.no_ex,GROUP_CONCAT(e.pekerjaan SEPARATOR '<br>') as pekerjaan FROM entri c,perbaikan e,kendaraan a,user b WHERE c.nomor = e.id_entri AND a.no_inventaris = c.no_inventaris AND c.id_status = 1 AND b.id_user = a.id_user GROUP BY c.nomor ORDER BY c.tanggal DESC\";\n $query = $this->db->query($sql);\n return $query;\n }", "function tampil_data($tabel)\n {\n $row = $this->db->prepare(\"SELECT * FROM sms\");\n $row->execute();\n return $hasil = $row->fetchAll();\n }", "public function ambilDataBarang($id)\n {\n return Yii::app()->db->createCommand(\"\n\t\t\t\t\t\t\tselect\n\t\t\t\t\t\t\t\tb.nama,\n\t\t\t\t\t\t\t\tb.barcode,\n\t\t\t\t\t\t\t\tsb.nama satuan,\n\t\t\t\t\t\t\t\t(select harga_beli from pembelian_detail where barang_id=:barangId\n\t\t\t\t\t\t\t\torder by id desc limit 1) harga_beli,\n\t\t\t\t\t\t\t\t(select harga\n\t\t\t\t\t\t\t\tfrom barang_harga_jual\n\t\t\t\t\t\t\t\twhere barang_id =:barangId\n\t\t\t\t\t\t\t\torder by id desc limit 1) harga_jual,\n\t\t\t\t\t\t\t\t(select harga\n\t\t\t\t\t\t\t\tfrom barang_harga_jual_rekomendasi\n\t\t\t\t\t\t\t\twhere barang_id =:barangId\n\t\t\t\t\t\t\t\torder by id desc limit 1) rrp\n\t\t\t\t\t\t\tfrom barang b\n\t\t\t\t\t\t\tleft join barang_satuan sb on sb.id = b.satuan_id\n\t\t\t\t\t\t\twhere b.id=:barangId\n\t\t\t\t\t\t\t\")\n ->bindParam(':barangId', $id)\n ->queryRow();\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 }", "function ambilSemuaDataHasilHitung() {\n\tglobal $conn;\n\n\t$data = [];\n\t$query = \"SELECT * FROM `hasil_hitung`\";\n\t$hasil = $conn->query($query);\n\n\tif ($hasil->num_rows > 0) {\n\t\twhile ($barisData = $hasil->fetch_assoc()) {\n\t\t\t$data[] = $barisData;\n\t\t}\n\t}\n\n\treturn $data;\n}", "function tampil_jadwal(){\n\t\t\tglobal $con;\n\n\t\t\t$query=mysqli_query($con, \"select * from tb_jadwal\");\n\t\t\twhile($row=mysqli_fetch_array($query))\n\t\t\t\t$data[] = $row;\n\n\t\t\t\treturn $data;\n\t\t}", "public function modelFetchAll(){\n\t\t\t//lay bien ket noi de thao tac csdl\n\t\t\t$conn = Connection::getInstance();\n\t\t\t//thuc hien truy van, tra ket qua ve mot object\n\t\t\t$query = $conn->query(\"select * from phongban\");\n\t\t\t//tra ve tat ca cac ban ghi\n\t\t\treturn $query->fetchAll();\n\t\t}", "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 tabel_data()\n {\n $tampil = $this->koneksi()->prepare(\"SELECT id FROM tb_users\");\n $tampil->execute();\n $tampil->setFetchMode(PDO::FETCH_ASSOC);\n if (count($tampil)>0){\n while ($data=$tampil->fetch(PDO::FETCH_ORI_NEXT)){\n $user_id_array [] = $data['id'];\n }\n }\n\n $tampil = $this->koneksi()->prepare(\"SELECT id FROM tb_lbb\");\n $tampil->execute();\n $tampil->setFetchMode(PDO::FETCH_ASSOC);\n if (count($tampil)>0){\n while ($data=$tampil->fetch(PDO::FETCH_ORI_NEXT)){\n $lbb_id_array [] = $data['id'];\n }\n }\n\n foreach ($user_id_array as $user_id){\n foreach ($lbb_id_array as $lbb_id){\n $rating = \"0\";\n $tampil = $this->koneksi()->prepare(\"SELECT rating FROM tb_rating WHERE user_id=:user_id AND lbb_id=:lbb_id\");\n $tampil->bindParam(':user_id', $user_id);\n $tampil->bindParam(':lbb_id', $lbb_id);\n $tampil->execute();\n $tampil->setFetchMode(PDO::FETCH_ASSOC);\n if (count($tampil)>0){\n while ($data=$tampil->fetch(PDO::FETCH_ORI_NEXT)){\n $rating = $data['rating'];\n }\n }\n $tabel_data [$user_id] [$lbb_id] = $rating;\n }\n }\n\n return $tabel_data;\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 fetchDataBencana(){\n\n try {\n return Pemohon::find();\n } catch (\\Exception $e) {\n return [];\n }\n \n }", "public function ObtenerAvionesBD(){\n $aviones=DB::table('avion')\n ->get();\n return $aviones;\n }", "function datagolongan() {\n\t\t\t\t$koneksi = $this->koneksi;\n\t\t\t\t// SQL\n\t\t\t\t$query\t\t\t= \"SELECT * FROM golongan\";\n\t\t\t\t\n\t\t\t\t$sql\t\t\t= mysqli_query($koneksi,$query);\n\t\t\t\t\n\t\t\t\treturn $sql;\n\t\t\t}", "public function getDataToIza(){\n\n $criteria=new CDbCriteria;\n $criteria->select='AVG(result) as result, koef, name_post, name_vesh, id_posti, PDK_ss, id_vechestva';\n $criteria->group='name_vesh';\n $res=Allresult::model()->findAll($criteria);\n $restoret=\"\";\n // var_dump($res);\n foreach($res as $oneres){\n $restoret.='[\"'.$oneres->name_vesh.'\", '.pow(($oneres->result/$oneres->PDK_ss),$oneres->koef).'],';\n }\n //\n return substr($restoret, 0, strlen($restoret)-1);\n }", "public function ambildata_admin(){\n\t\t$query=$this->db->query(\"SELECT * FROM tb_admin\");\n\t\treturn $query->result_array();\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 }", "public function fullDataBase()\n {\n print \"<table cellpadding='10' border=solid bordercolor=black>\";\n print\"<tr>\n <td>ROW</td> <td>EXCHANGE</td>\n <td>NAME</td> <td>IPO</td>\n <td>SYMBOL</td> <td>PRICE</td>\n <td>CAP</td> <td>UPDATED</td>\n <td>SECTOR</td> <td>INDUSTRY</td>\n </tr>\";\n $sql = \"SELECT * FROM companies ORDER BY ipodate DESC, cap DESC\";\n\n foreach ($this->conn->query($sql) as $row) {\n print \"<tr> <td nowrap>\";\n print $row['id'] . \"</td><td nowrap>\";\n print $row['stockexchange'] . \"</td><td nowrap>\";\n print $row['name'] . \"</td><td nowrap>\";\n print $row['ipodate'] . \"</td><td nowrap>\";\n print $row['symbol'] . \"</td><td nowrap>\";\n print $row['price'] . \"</td><td nowrap>\";\n print $row['cap'] . \"</td><td nowrap>\";\n print $row['created_at'] . \"</td><td nowrap>\";\n print $row['sector'] . \"</td><td nowrap>\";\n print $row['industry'] . \"</td></tr>\";\n }\n print \"</table>\";\n }", "function tampil_data(){\n\t\t//query select user\n\t\t$data = mysqli_query($this->conn, \"SELECT * FROM table_1\");\n\t\twhile($d = mysqli_fetch_array($data)){\n\t\t\t$hasil[] = $d;\n\t\t}\n\t\treturn $hasil;\n\n\t}", "public function tampil_data(){\n $sql= \"Select * From penjualan Order By id_penjualan DESC\";\n $data=$this->konek->query($sql);\n while ($row=mysqli_fetch_array($data)) {\n $hasil[]=$row;\n }\n return $hasil;\n }", "public function dataMahasiswa()\n\t{\n\t\t$this->db->select('*');\n\t\t$this->db->from('tb_mahasiswa');\n\t\t$this->db->order_by('nim', 'asc');\n\t\t$data = $this->db->get('');\n\t\treturn $data;\n\t}", "function recuperer_bsm_entier(){\n global $db;\n $sql = \"SELECT * FROM bsm \";\n $req = $db->prepare($sql);\n $req-> execute();\n $results = array();\n while($rows = $req->fetchObject()){\n $results[] = $rows;\n }\n return $results;\n}", "function ambil_data_on_going()\n\t{\n\t\t\n\t\t$sql=\"SELECT * FROM irena_view_sbsn_on_going\";\n\t\treturn $this->db->query($sql);\n\t}", "public function readAll(){\n //select all data\n $query = \"SELECT\n id, num_compte, cle_rib, num_agence, duree_epargne, frais, solde, created\n FROM\n \" . $this->table_name . \"\n ORDER BY\n num_compte\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n \n return $stmt;\n }", "function tampil_data()\n\t{\n\t\t# perintah join digunakan untuk menggabungkan 2 table, yaitu penduduk dan kematian, agar data yang tampil lebih detail, karena pada tabel kematian hanya terdapat sedikit kolom, sehingga dengan menambah kolom nik, maka data yang ada di tabel penduduk juga otomatis terdeteksi karena perintah join, dengan aturan, nik harus sama antara tabel kematian dan nik yang ada di penduduk.\n\t\treturn $this->db->query(\"SELECT*FROM `kematian` left join penduduk on kematian.nik = penduduk.nik\")->result();\n\t}", "public function getAllMahasiswa(){\n // melakukan prepare query\n $this->db->query('SELECT * FROM '. $this->tabel);\n // eksekusi query dan mengambil semua data mahasiswa\n return $this->db->resultAll();\n }", "function ambil_data(){\n\t\treturn $this->db->get('user'); //digunakan untuk mengambil data yang ditangkap pada controller yang memanggil function ambil_data(controller belelajar pada function user())\n\t}", "public function load()\n {\n $pdo = $this->getDbConnection();\n $query = \"SELECT * FROM {$this->dbTable}\";\n $data = $pdo->query($query)->fetchAll(\\PDO::FETCH_ASSOC);\n\n foreach ($data as ['key' => $key, 'value' => $value]) {\n $this->setData($key, $value);\n }\n }", "public function data($id = null)\n\t{\n if($id != null)\n {\n return $this->db->get($this->table, \"*\", [$this->primaryKey => $id]);\n }\n else\n {\n // return $this->db->query(\"SELECT bidang.*, pegawai.nama FROM bidang JOIN pegawai ON bidang.nip = pegawai.nip\")->fetchAll(PDO::FETCH_ASSOC);\n return $this->db->query(\"SELECT * from bidang\")->fetchAll(PDO::FETCH_ASSOC);\n }\n\t}", "private function getData(){\n\t\tdb::getAdapter();\n\t\t\n\t\t$counter=0;\n\t\t$arrayFieldQuery=array();\n\t\tforeach($this->fields as $field){\n\t\t\t$arrayFieldQuery[$field]=$this->types[$counter];\n\t\t\t$counter++;\n\t\t}\n\t\t\n\t\t$counter=0;\n\t\t$arrayFilters=array();\n\t\tforeach($this->filters as $filter){\n\t\t\t$arrayFilters[$this->fields[$filter[0]]]=array(\"type\"=>$this->types[$filter[0]],\"value\"=>$filter[1]);\n\t\t}\n\t\t\n\t\tif(db::getFields($this->table,$arrayFieldQuery,$arrayFilters,$this->orderQuery,$this->limit,true)){\n\t\t\t$this->pages=ceil(((int)db::getCalculatedRows())/((int)$this->maxRowsPerPage));\n\t\t\t$this->maxRows=(int)db::getCalculatedRows();\n\t\t\twhile($row=db::fetch(db::$FETCH_TYPE_ASSOC)){\n\t\t\t\t$this->addRow($row);\n\t\t\t}\n\t\t}\n\t}", "public function get_Banco(){\r\n $conectar=parent::conexion();\r\n parent::set_names();\r\n $sql=\"select * from banco;\";\r\n $sql=$conectar->prepare($sql);\r\n $sql->execute();\r\n return $resultado=$sql->fetchAll(PDO::FETCH_ASSOC);\r\n }", "public function tampilDataGalang(){\n\t\t\n\t}", "function einstellungen_data ()\n\t{\n\t\t$sql = sprintf(\"SELECT * FROM %s WHERE bgalset_id='1'\",\n\t\t\t$this->db_praefix.\"ecard_einstellungen\"\n\t\t);\n\t\t$temp_return = $this->db->get_row($sql, ARRAY_A);\n\t\treturn $temp_return;\n\t}", "protected function importDatabaseData() {}", "function getInfosBanque($id_bqe=NULL,$id_ag=NULL) {\n\n global $dbHandler;\n\n $db = $dbHandler->openConnection();\n $sql = \"SELECT * FROM adsys_banque\";\n if ($id_bqe != NULL) {\n if ($id_ag == NULL)\n $sql .=\" WHERE id_banque = $id_bqe\";\n else\n $sql .=\" WHERE id_banque = $id_bqe and id_ag = $id_ag \";\n }\n elseif ($id_ag != NULL) $sql .=\" WHERE id_ag = $id_ag\";\n $sql.= \";\";\n\n $result=$db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__,__LINE__,__FUNCTION__);\n }\n\n $dbHandler->closeConnection(true);\n\n if ($result->numRows() == 0) return NULL;\n\n while ( $row = $result->fetchRow(DB_FETCHMODE_ASSOC) )\n $DATAS[$row[\"id_banque\"]] = $row;\n\n return $DATAS;\n\n}", "public function getAllData($table){\n $sql = \"select * from $table\";\n $this->execute($sql);\n if($this->num_rows() == 0){\n $data = 0;\n }\n else {\n while($datas = $this->getData()){\n $data[] = $datas;\n }\n }\n return $data;\n }", "public function getCommondata()\n {\n $select = $this->select()\n // ->setIntegrityCheck(false)\n ->from(array('album' => 'album'),array('Id','name_n'))\n ->join('album_det','album_det.Id = album.Id',array('album_det.Id'));\n // $result=$this->fetchAll($hhh);\n $result = $this->fetchAll($select);\n \n echo \"<pre>\";\n print_r($result);exit;\n return $result;\n\n }", "function ambil_data(){\n\t\treturn $this->db->get('user');\n\t}", "public function run()\n {\n DB::table('harga_obats')->truncate();\n $data =[\n ['id'=>1, 'id_obat'=>'konimexsanbe', 'harga'=>10000, 'tgl_awal'=>new DateTime, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=>2, 'id_obat'=>'IBUPKIMITABLOBAT', 'harga'=>5000, 'tgl_awal'=>new DateTime, 'created_at' => new DateTime, 'updated_at' => new DateTime]\n ];\n DB::table('harga_obats')->insert($data);\n }", "function data_banco($databr) {\n\tif (!empty($databr)){\n\t$p_dt = explode('/',$databr);\n\t$data_sql = $p_dt[2].'-'.$p_dt[1].'-'.$p_dt[0];\n\treturn $data_sql;\n\t}\n}", "function all(){\n\t\t\t$query = \"SELECT * FROM khach_hang\";\n\t\t\t$data = array();\n\t\t\t$result = $this->conn->query($query);\n\t\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t\t$data[] =$row;\n\t\t\t}\n\t\t\treturn $data;\n\n\t\t}", "public function getAllAMt() {\n $data = $this->db->query(\"select * from pegawai where (jabatan='SUPIR' or jabatan='KERNET')\");\n return $data;\n }", "public function get_makanan_buahs()\n\t{\n\t\t$database = $this->db->select('*')\n\t\t\t\t\t->from('makanan_buah')\n\t\t\t\t\t->get()->result();\n\n\t\treturn $database;\n\t\t// Result in Object\n\t}", "public function get_all_alamat(){\n \n\t$query = $this->db->query(\"select *,case when gender = '1' then 'Pria' else 'Wanita' end as genderstatus,date_format(start_date,'%d %M %Y') as tanggalmasuknya from human_pa_md_emp_personal order by personnel_id asc\");\n\n \treturn $query;\n\t}", "function readAll(){\n \n $query = \"SELECT * FROM \".$this->table_name.\" ORDER BY id_alternatif ASC\";\n $stmt = $this->conn->prepare($query);\n $stmt->execute();\n\n return $stmt;\n }", "public function allData()\n {\n return DB::table('tbl_laporankeluar')\n ->leftJoin('tbl_sales', 'tbl_sales.id_sales', '=', 'tbl_laporankeluar.id_sales')\n ->leftJoin('tbl_produk', 'tbl_produk.id_produk', '=', 'tbl_laporankeluar.id_produk')\n ->orderBy('id_laporan', 'desc')\n ->get();\n }", "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 getAll()\n\t{\n\t\treturn $this->db->get('data_b')->result();\n\t}", "public function run()\n {\n DB::table(\"produk\")->insert([\n \t[\n \t\t\"nama\" => \"banner\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat banner\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"nota\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat nota\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"undangan\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat undangan\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"sticker print\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat sticker print\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"kartu nama\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat kartu nama\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"brosur\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat brosur\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"sticker sablon\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat sticker sablon\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"buku yaasin\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat buku yaasin\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"umbul-umbul kain\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat umbul-umbul kain\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"id card\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat id card\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"kalender\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat kalender\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"nama dada\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat nama dada\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"sablon plastik/tas/kaos\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat sablon plastik/tas/kaos\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"stempel\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat stempel\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"neon box (papan nama)\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat neon box (papan nama)\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t\n ]);\n }", "function all2($cod_programa) {\n \n $sql = \"SELECT * FROM inasistencia_grupo_motivos\";\n \n return DB::query($sql);\n }", "private function list_data_sql()\n\t{\n\t\t$this->db\n\t\t\t->from('tweb_penduduk u')\n\t\t\t->join('tweb_keluarga d', 'u.id_kk = d.id', 'left')\n\t\t\t->join('tweb_wil_clusterdesa a', 'd.id_cluster = a.id', 'left')\n\t\t\t->join('tweb_penduduk_sex x', 'u.sex = x.id', 'left')\n\t\t\t->join('tweb_penduduk_agama g', 'u.agama_id = g.id', 'left')\n\t\t\t->join('tweb_status_dasar sd', 'u.status_dasar = sd.id', 'left')\n\t\t\t->join('log_penduduk log', 'u.id = log.id_pend', 'left')\n\t\t\t->join('ref_pindah rp', 'rp.id = log.ref_pindah', 'left')\n\t\t\t->where('u.status_dasar >', 1)\n\t\t\t->where_in('log.id_detail', array(2, 3, 4));\n\n\t\t$this->search_sql();\n\t\t$this->status_dasar_sql();\n\t\t$this->sex_sql();\n\t\t$this->agama_sql();\n\t\t$this->dusun_sql();\n\t\t$this->rw_sql();\n\t\t$this->rt_sql();\n\t}", "public function getAll(){\n $sqlQuery = \"SELECT * FROM \".$this->t_name.\"\";\n //prepate stamt;\n $stmt = $this->conn->prepare($sqlQuery);\n $stmt->execute();\n //kembalikan nilai stmt\n return $stmt;\n }", "protected function loadData(){\n\t\t//SELECT from \".self::TABLE_NAME.\"_data WHERE \".self::TABLE_NAME.\"_id=\".$this->id.\"\n\t\t\n\t\t//return the data\n\t\treturn array();\n\t}", "public function ambildata_psikolog(){\n\t\t$query=$this->db->query(\"SELECT * FROM tb_psikolog\");\n\t\treturn $query->result_array();\n\t}", "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 getDatabaseData()\n {\n $data = array();\n $sql = 'SELECT * FROM `' . $this->table . '`';\n $db_success = mysql_query($sql)\n or die('Laden der Daten fehlgeschlagen: ' . mysql_error());\n while ($row = mysql_fetch_array($db_success, MYSQL_ASSOC))\n {\n $data[] = $row;\n }\n return $data;\n }", "private function ajustarDataReporte()\r\n\t\t{\r\n\t\t\tself::setConexion();\r\n\t\t\t$this->_conn->open();\r\n\t\t\t$this->_transaccion = $this->_conn->beginTransaction();\r\n\r\n\t\t\t$tabla = $this->tableName();\r\n\r\n\t\t\t//lapso=2 and ano_impositivo<year(fecha_pago) and impuesto=9 and fecha_pago>='2014-06-01\r\n\t\t\t$sql = \"UPDATE {$tabla} SET codigo=301035900, nombre_impuesto='Deuda Morosa Por Tasas'\r\n\t\t\t WHERE lapso=2 AND ano_impositivo<year(fecha_pago) AND impuesto=9 AND fecha_pago>='2014-06-01'\";\r\n\r\n\t\t\t$result = $this->_conn->createCommand($sql)->execute();\r\n\t\t\tif ( $result ) {\r\n\t\t\t\t$this->_transaccion->commit();\r\n\t\t\t} else {\r\n\t\t\t\t$this->_transaccion->rollBack();\r\n\t\t\t}\r\n\t\t\t$this->_conn->close();\r\n\t\t\treturn $result;\r\n\t\t}", "public function run()\n {\n DB::table('alumno')->insert([\n 'alum_id' => '1',\n 'alum_dni' => '75406456',\n 'alum_ape' => 'CAVERO AVILA',\n 'alum_nom' => 'MARIA CARMEN',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2006-02-05',\n 'alum_grad' => '3',\n 'alum_apod' => '1',\n 'alum_user' => '75406456'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '2',\n 'alum_dni' => '75200134',\n 'alum_ape' => 'ALVAREZ AGUILAR',\n 'alum_nom' => 'JUAN DIEGO',\n 'alum_sexo' => '1',\n 'alum_fnac' => '2006-08-20',\n 'alum_grad' => '3',\n 'alum_apod' => '2',\n 'alum_user' => '75200134'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '3',\n 'alum_dni' => '75246604',\n 'alum_ape' => 'SALAZAR AVILA',\n 'alum_nom' => 'CARLA',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2006-07-11',\n 'alum_grad' => '3',\n 'alum_apod' => '3',\n 'alum_user' => '75246604'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '4',\n 'alum_dni' => '75650012',\n 'alum_ape' => 'ROBLES LACHI',\n 'alum_nom' => 'DIANA',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2005-01-06',\n 'alum_grad' => '4',\n 'alum_apod' => '4',\n 'alum_user' => '75650012'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '5',\n 'alum_dni' => '79520105',\n 'alum_ape' => 'CHUMPITAZ TACSA',\n 'alum_nom' => 'ELSA',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2005-10-12',\n 'alum_grad' => '4',\n 'alum_apod' => '5',\n 'alum_user' => '79520105'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '6',\n 'alum_dni' => '78415200',\n 'alum_ape' => 'ARROYO HUAMAN',\n 'alum_nom' => 'DAVID',\n 'alum_sexo' => '1',\n 'alum_fnac' => '2005-08-28',\n 'alum_grad' => '4',\n 'alum_apod' => '6',\n 'alum_user' => '78415200'\n ]);\n\n\n }", "public function run()\n {\n $data=[];\n for($i=0;$i<100;$i++){\n \t$temp['typeid']=rand(1,11);\n \t$temp['goods']=str_random(10);\n \t$temp['price']=rand(1,10000);\n \t$temp['picname']='/upload/14869794804653.jpg';\n \t$temp['descr']='<p><img src=\"/upload/baidu/1486979474670564.jpg\" title=\"1486979474670564.jpg\"/></p><p><img src=\"/upload/baidu/1486922430402045.jpg\" title=\"1486922430402045.jpg\"/></p>';\n \t$temp['num']=rand(1,1000);\n \t$temp['created_at']=date('Y-m-d H:i:s');\n \t$temp['updated_at']=date('Y-m-d H:i:s');\n $temp['szie']=rand(0,2);\n \t$temp['state']=1;\n $data[]=$temp;\n }\n \\DB::table('goods')->insert($data);\n }", "public function fillDataBase(){\n $conn = $this->connectdb();\n $tweets_total = $this->getTweets();\n foreach ($tweets_total as $page){\n foreach($page as $key){\n $title = $this->stripTitle($key->text);\n $prepared_title = mysqli_real_escape_string($conn,$title);\n if(!empty($key->entities->urls)){\n $url_source = $key->entities->urls[0]->url; \n $url_dispaly_source = $key->entities->urls[0]->display_url;\n }\n else{\n $url_source=\".\";\n $url_dispaly_source = \".\";\n }\n $tweet_url = $key->id;\n $tweet_date = $this->customDate($key->created_at);\n $user_name = $key->user->name;\n $user_screen_name= $key->user->screen_name;\n $user_image_src= $key->user->profile_image_url;\n $sql=\"INSERT INTO tweets (title, url_source, tweet_url_id, created_date, url_display_source, user_name, user_screen_name, user_logo) \"\n . \"VALUES('$prepared_title','$url_source','$tweet_url','$tweet_date','$url_dispaly_source','$user_name','$user_screen_name','$user_image_src')\";\n mysqli_query($conn, $sql);\n }\n }\n }", "private function userDataFromDB($all) {\n\n foreach ($all as $value) {\n\n $user_data = $this->users->find($value->userId);\n $value->name = $user_data->name;\n $value->mail = $user_data->email;\n $value->gravatar = $user_data->gravatar;\n }\n return $all;\n }", "function dataSelect() {\n\t\t\t\t$koneksi = $this->koneksi;\n\t\t\t\t// SQL\n\t\t\t\t$query\t\t\t= \"SELECT * FROM pegawai ORDER BY id ASC\";\n\t\t\t\t\n\t\t\t\t$sql\t\t\t= mysqli_query($koneksi,$query);\n\t\t\t\t\n\t\t\t\treturn $sql;\n\t\t\t}", "public function queryAll(){\n\t\t$sql = 'SELECT * FROM cbt_jadwal_ujian';\n\t\t$sqlQuery = new SqlQuery($sql);\n\t\treturn $this->getList($sqlQuery);\n\t}", "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 function getData(){\n\n //Connetto al database\n $conn = $this->connection->sqlConnection();\n\n $sql = $conn->prepare(\"SELECT * FROM compra\");\n\n //Eseguo la query\n $sql->execute();\n\n $dataArray = array();\n //Se ci sono dei valori\n if($sql->rowCount() > 1) {\n\n // Ciclo tutti i valori\n while ($row = $sql->fetch()) {\n array_push($dataArray, $row);\n }\n //Se c'è un solo valore lo inserisco\n }else if($sql->rowCount() == 1) {\n $dataArray = $sql->fetch();\n }\n $conn = null;\n return $dataArray;\n }", "static function get_data($table) {\r\n $rekete = \"SELECT * FROM \" . $table . \" ORDER BY created DESC\";\r\n $result = Functions::commit_sql($rekete, \"\");\r\n if (Functions::is_void($result))\r\n return false;\r\n else\r\n return $result;\r\n }", "function get_records_bahan(){\n\t\t$output=array();\n\t\t/*data request dari client*/\n\t\t$request = $this->m_master->request_datatable();\n\t\t/*Token yang dikrimkan client, akan dikirim balik ke client*/\n\t\t$output['draw'] = $request['draw'];\n\t\n\t\t/*\n\t\t $output['recordsTotal'] adalah total data sebelum difilter\n\t\t$output['recordsFiltered'] adalah total data ketika difilter\n\t\tBiasanya kedua duanya bernilai sama pada saat load default(Tanpa filter), maka kita assignment\n\t\tkeduaduanya dengan nilai dari $total\n\t\t*/\n\t\t/*Menghitung total desa didalam database*/\n\t\t$total = count($this->m_master->get_jenis_bahan());\n\t\t$output['recordsTotal']= $output['recordsFiltered'] = $total;\n\t\n\t\t/*disini nantinya akan memuat data yang akan kita tampilkan\n\t\t pada table client*/\n\t\t$output['data'] = array();\n\t\n\t\n\t\t/*\n\t\t * jika keyword tidak kosong, maka menjalankan fungsi search\n\t\t* untuk ditampilkan di datable\n\t\t* */\n\t\tif($request['keyword'] !=\"\"){\n\t\t\t/*menjalankan fungsi filter or_like*/\n\t\t\t$this->m_master->search_like($request['keyword'],$this->column_bahan());\n\t\t}\n\t\t/*Pencarian ke database*/\n\t\t$query = $this->m_master->get_jenis_bahan('',$this->column_bahan()[$request['column']],$request['sorting'],$request['length'],$request['start']);\n\t\n\t\n\t\t/*Ketika dalam mode pencarian, berarti kita harus\n\t\t 'recordsTotal' dan 'recordsFiltered' sesuai dengan jumlah baris\n\t\tyang mengandung keyword tertentu\n\t\t*/\n\t\tif($request['keyword'] !=\"\"){\n\t\t\t$this->m_master->search_like($request['keyword'],$this->column_bahan());\n\t\t\t$total = count($this->m_master->get_jenis_bahan());\n\t\t\t/*total record yg difilter*/\n\t\t\t$output['recordsFiltered'] = $total;\n\t\t}\n\t\n\t\n\t\t$nomor_urut=$request['start']+1;\n\t\tforeach ($query as $row) {\n\t\t\t//show in html\n\t\t\t$output['data'][]=array($nomor_urut,\n\t\t\t\t\t$row->nama_product,\n\t\t\t\t\t$row->nama_kategori,\n\t\t\t\t\t$row->nama_supplier,\n\t\t\t\t\t'<button type=\"button\" class=\"btn btn-success btn-circle\" title=\"Pilih Bahan\" onclick=\"ajaxcall(\\''.base_url('bo/'.$this->class.'/pilih_bahan').'\\',\\''.$row->id_product.'#'.$row->nama_product.'#'.$row->nama_kategori.'#'.$row->id_form_order.'\\',\\'splcart\\')\"><i class=\"icon-download-alt\"></i></button>'\n\t\t\t);\n\t\t\t$nomor_urut++;\n\t\t}\n\t\techo json_encode($output);\n\t}", "public function getAllData()\n\t{\n\t\treturn $this->db\n\t\t\t->where('row_status', 'A')\n\t\t\t->where('jabatan_karyawan', 'Admin')\n\t\t\t->get($this->_karyawan)\n\t\t\t->result();\n\t}", "public function run()\n {\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '1',\n 'merk_barang' => 'Single, AMP Single',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '2',\n 'merk_barang' => 'Media Stand HP Designjet 110/500 series 24',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '3',\n 'merk_barang' => 'Royal R775-18',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-03-01',\n 'idbarang_fk' => '4',\n 'merk_barang' => 'Mesin Ketik Brother GX6750',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-11-03',\n 'idbarang_fk' => '5',\n 'merk_barang' => 'Newmark NM - 03C',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '7',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP C13LG-7',\n 'nup' => '8',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP C13LG-7',\n 'nup' => '9',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP LTC 22',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP C13LG-7',\n 'nup' => '11',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B204',\n 'nup' => '12',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Cupboard datascrip CBRG/LF05',\n 'nup' => '13',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Cupboard datascrip CBRG/LF05',\n 'nup' => '14',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Cupboard datascrip CBRG/ET C22',\n 'nup' => '15',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Lemari Arsip Brother B-20',\n 'nup' => '16',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Lemari Arsip Brother B-20',\n 'nup' => '17',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother cardek',\n 'nup' => '18',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother Cardek',\n 'nup' => '19',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '20',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-304',\n 'nup' => '21',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-304',\n 'nup' => '22',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-304',\n 'nup' => '23',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'lemari Sliding door Brother B-304',\n 'nup' => '24',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'lemari Arsip Brother B-203',\n 'nup' => '25',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-28',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-203',\n 'nup' => '26',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-28',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-203',\n 'nup' => '27',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '3',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '4',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '6',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '7',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '8',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '9',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '11',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'DATASCRIP FCD4-7',\n 'nup' => '12',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'DATASCRIP FCD4-7',\n 'nup' => '13',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B104',\n 'nup' => '14',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet B-104',\n 'nup' => '15',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet B-104',\n 'nup' => '16',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet B-104',\n 'nup' => '17',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-104',\n 'nup' => '18',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-104',\n 'nup' => '19',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-104',\n 'nup' => '20',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2019-04-05',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-103',\n 'nup' => '21',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2019-04-05',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-103',\n 'nup' => '22',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2019-04-05',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-103',\n 'nup' => '23',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // brangkas\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '8',\n 'merk_barang' => 'Dragon DR-A1',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // locker\n\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '1',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '2',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '3',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '4',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '5',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '6',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '7',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'Alba LC-506',\n 'nup' => '8',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'Alba LC-506',\n 'nup' => '9',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // lemari display\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '10',\n 'merk_barang' => 'BROTHER B-304',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '10',\n 'merk_barang' => 'BROTHER B-304',\n 'nup' => '2',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '10',\n 'merk_barang' => 'BROTHER B-304',\n 'nup' => '3',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // CCTV\n 'tanggal' => '2017-10-05',\n 'idbarang_fk' => '11',\n 'merk_barang' => 'Paket CCTV ANALOG 1 MP 720P, 1 DVR BCH',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '11',\n 'merk_barang' => 'CCTV 9 Kamera',\n 'nup' => '2',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // white board\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '12',\n 'merk_barang' => '120X240',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '120X240',\n 'nup' => '2',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '120X240',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '90X120',\n 'nup' => '4',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '90X120',\n 'nup' => '5',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '90X120',\n 'nup' => '6',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'GM Economi DF',\n 'nup' => '7',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'GM Economi DF',\n 'nup' => '8',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '9',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '10',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '11',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '12',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat penghancur Kertas\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '13',\n 'merk_barang' => 'Secure Maxi 24SC',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat penghancur Kertas\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '13',\n 'merk_barang' => 'Secure Maxi 24SC',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '1',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '2',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '3',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '4',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '5',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '6',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '7',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // lASER POINTER\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '15',\n 'merk_barang' => 'Logitech Wireless Presenter R400',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // lASER POINTER\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '15',\n 'merk_barang' => 'Logitech Wireless Presenter R400',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '19',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '20',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '21',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '22',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '23',\n 'idruang_fk' => '26'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP575',\n 'nup' => '24',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-12-1',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP575',\n 'nup' => '25',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP515',\n 'nup' => '26',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP670',\n 'nup' => '27',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MX810 ST',\n 'nup' => '28',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP660',\n 'nup' => '29',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP660',\n 'nup' => '30',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ans',\n 'nup' => '31',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'DELL 161011D',\n 'nup' => '32',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'DELL 161011D',\n 'nup' => '33',\n 'idruang_fk' => '6'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'DELL 161011D',\n 'nup' => '34',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '35',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '36',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '37',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '38',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '39',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '40',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '41',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '42',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '43',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '44',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '45',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '46',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '47',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 70\" Size 180x180',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 70\" Size 180x180',\n 'nup' => '2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 84\" Size 213x213',\n 'nup' => '3',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 84\" Size 213x213',\n 'nup' => '4',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // papan pengumuman\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '18',\n 'merk_barang' => 'GM Announcement Board',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // papan pengumuman\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '18',\n 'merk_barang' => 'GM Announcement Board',\n 'nup' => '2',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '33',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '34',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '35',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '36',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '37',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '38',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '39',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '40',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '41',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '42',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '43',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '44',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '45',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '46',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '47',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '48',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '49',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '50',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '51',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '52',\n 'idruang_fk' => '4'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '53',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n //meja kayu sekretaris\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '54',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '55',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '56',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '57',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '58',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '59',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '60',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil 180x90x75',\n 'nup' => '61',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Credenza',\n 'nup' => '62',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '63',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '64',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '65',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Espana 1275',\n 'nup' => '66',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Espana 1275',\n 'nup' => '67',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Fatoni',\n 'nup' => '68',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Fatoni',\n 'nup' => '69',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Kerja Active Galant MTO 120',\n 'nup' => '70',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Kerja Active Galant MTO 120',\n 'nup' => '71',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Kerja Active Galant MTO 120',\n 'nup' => '72',\n 'idruang_fk' => '15'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '1',\n 'idruang_fk' => '5'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '4',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '5',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '7',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '8',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '9',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '10',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Ushinto 9035',\n 'nup' => '11',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel 147',\n 'nup' => '12',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel 147',\n 'nup' => '13',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '14',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '15',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '16',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '17',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '18',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '19',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '20',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '21',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '22',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '23',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '24',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '25',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '26',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '27',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '28',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '29',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '30',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '31',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '32',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '33',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '34',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '35',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '36',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '37',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '38',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '39',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '40',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '41',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '42',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '43',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '44',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '45',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '46',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '47',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '48',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '49',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '50',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '51',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '52',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '53',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '54',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '55',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '56',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '57',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '58',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '59',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '60',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '61',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '62',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '63',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '64',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '65',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '66',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '67',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '68',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '69',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '70',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '71',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '72',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '73',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '74',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '75',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '76',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '77',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '78',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '79',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '80',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '81',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '82',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '83',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '84',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '85',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '86',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '87',\n 'idruang_fk' => '26'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '88',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '89',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '90',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '91',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '92',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '93',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '94',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '95',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '96',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '97',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '98',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '99',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '100',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '101',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '102',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '103',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '104',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '105',\n 'idruang_fk' => '26'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '106',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '107',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '108',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '109',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '110',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '111',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '112',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '113',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '114',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '115',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '116',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '117',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '118',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '119',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '120',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '121',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '122',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '123',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '124',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '125',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '126',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '127',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '128',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '129',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '130',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '131',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '132',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '133',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '134',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '135',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '136',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '137',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '138',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '139',\n 'idruang_fk' => '8'\n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '140',\n 'idruang_fk' => '8'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '141',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '142',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '143',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '144',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '145',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '146',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '147',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '148',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '149',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '150',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '151',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '152',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '153',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '154',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '155',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'OSCAR FHANTASI VH ',\n 'nup' => '156',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO 608T OSCAR HITAM ',\n 'nup' => '157',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO 608T OSCAR HITAM ',\n 'nup' => '158',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO OSCAR ',\n 'nup' => '159',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO OSCAR ',\n 'nup' => '160',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO OSCAR ',\n 'nup' => '161',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '162',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '163',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '164',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '165',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '166',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '167',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '168',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '169',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '170',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '171',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '172',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '173',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '174',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '175',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '176',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '177',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '178',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '179',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '180',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '181',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '182',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '183',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '184',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '185',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '186',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '187',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '188',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '189',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '190',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '191',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '192',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '193',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '194',\n 'idruang_fk' => '8'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '195',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '196',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal gudang\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '197',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal gudang\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '198',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal gudang\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '199',\n 'idruang_fk' => '18'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '200',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '201',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '202',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '203',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '204',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '205',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '206',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '207',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '208',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '209',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '210',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '211',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '212',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '213',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '214',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '215',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '216',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '217',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '218',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '219',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '220',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '221',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '222',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '223',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '224',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '225',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '226',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '227',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '228',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '229',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '230',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '231',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '232',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '233',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '234',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '235',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '236',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '237',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '238',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '239',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '240',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '241',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '242',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '243',\n 'idruang_fk' => '5'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '244',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '245',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '246',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '247',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '248',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '249',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '250',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '251',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '252',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '253',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '254',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '255',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '256',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '257',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '258',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '259',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL MR 357TLPM',\n 'nup' => '260',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL MR 357TLPM',\n 'nup' => '261',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '262',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '263',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '264',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '265',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'CISEBEL 311 TLLPP',\n 'nup' => '266',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '67',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '268',\n 'idruang_fk' => '13'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '269',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '270',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '270',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '271',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '272',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '273',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '274',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '275',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '276',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '277',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '278',\n 'idruang_fk' => '20'\n \n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '278',\n 'idruang_fk' => '20'\n \n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '279',\n 'idruang_fk' => '20'\n \n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '280',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '281',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '282',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '283',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '284',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '285',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '286',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '287',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '288',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '289',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '290',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '291',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '292',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '293',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '294',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '295',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '296',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '297',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '298',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '299',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '300',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '301',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '302',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '303',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '304',\n 'idruang_fk' => '21'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '305',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '306',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '307',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '308',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '309',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '310',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '311',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '312',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '313',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '314',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '315',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '316',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '317',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '318',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '319',\n 'idruang_fk' => '22'\n \n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '320',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '321',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '322',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '323',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '324',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '325',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '326',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '327',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '328',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '329',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '329',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '330',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '331',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '332',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '333',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '334',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '335',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '336',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '337',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '338',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '339',\n 'idruang_fk' => '1'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '340',\n 'idruang_fk' => '12'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '341',\n 'idruang_fk' => '12'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '342',\n 'idruang_fk' => '12'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '343',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '344',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '345',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '363',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '347',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '348',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '349',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '350',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '351',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '352',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '353',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '354',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '355',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '356',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '357',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '358',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '360',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '361',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '362',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T906',\n 'nup' => '363',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '364',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '365',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '366',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '367',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '368',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '369',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '370',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '371',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '372',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '373',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '374',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '375',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '376',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '377',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '378',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '379',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '380',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '381',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '382',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '383',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '384',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '385',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '386',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '387',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '388',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '389',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '400',\n 'idruang_fk' => '18'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '401',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '402',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '403',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '404',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '405',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '406',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '407',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '408',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '409',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '410',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '411',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '412',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '413',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '414',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '415',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '416',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '417',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '418',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '419',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '420',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '421',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '422',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '423',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '424',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '425',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '426',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '427',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '428',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '429',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '430',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '431',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '432',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '433',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '434',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '435',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '436',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '437',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '438',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '439',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '440',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '441',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '442',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '443',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '444',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '445',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '446',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '447',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '448',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '449',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '450',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '451',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '452',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '453',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '454',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '455',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '456',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '457',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '458',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '459',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '460',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '461',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '462',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '463',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '464',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '465',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '466',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '467',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '468',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '469',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '470',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '471',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '472',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '473',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '474',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '475',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '476',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '477',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '478',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '479',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '480',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '481',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '482',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '483',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '484',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '485',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '486',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '487',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '488',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '489',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '490',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '491',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '492',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '493',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '494',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '495',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '496',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '497',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '498',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '499',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '500',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '501',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '502',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '503',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '504',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '505',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '506',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '507',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chairman VC 1055',\n 'nup' => '508',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chairman VC 1055',\n 'nup' => '509',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '510',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '511',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '512',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '513',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '514',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '515',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '516',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '517',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '518',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '519',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '520',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '521',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '522',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '523',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '524',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '525',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '526',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '527',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '528',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '529',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '530',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '531',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '532',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '533',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '534',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '535',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '536',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '537',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '538',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '539',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '540',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '541',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '542',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '543',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '544',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '545',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '546',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '547',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '548',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '549',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '550',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '551',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '552',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '553',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '554',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '555',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '556',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '557',\n 'idruang_fk' => '19'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '558',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '559',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '560',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '561',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '562',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '563',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '564',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '565',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '566',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '567',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '568',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '569',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '570',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '571',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '572',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '573',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '574',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '575',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '576',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '577',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '576',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '577',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '578',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '578',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '579',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '580',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '581',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '582',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '583',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '584',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '585',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '586',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '587',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '588',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '589',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '590',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '591',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '592',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '593',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '594',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '595',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '596',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '597',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '598',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '599',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '600',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '601',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '602',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '603',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '604',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '605',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '606',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '607',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '608',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '609',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '610',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '611',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '612',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '613',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '614',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '615',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '616',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '617',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '618',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '619',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '620',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '621',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '622',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '623',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '624',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '625',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '626',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '627',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '628',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '629',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '630',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '631',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '632',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '634',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '635',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '636',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '637',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '638',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '639',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '640',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '641',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '642',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '643',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '644',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '645',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '646',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '647',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '648',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '649',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '627',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '628',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '629',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '630',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '631',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '632',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '633',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '634',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '635',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '636',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '637',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '638',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '639',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '640',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '641',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '642',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '643',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '644',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '645',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '646',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '647',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '648',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '649',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '650',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '651',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '652',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '653',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '654',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '655',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '656',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '657',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '658',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '659',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '660',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '661',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '662',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '663',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '664',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '665',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '666',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '667',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '668',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '669',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '670',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '671',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '672',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang RPL\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '673',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang RPL\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '674',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang RPL\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '675',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '676',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '677',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '678',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '679',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '680',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '681',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '682',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '683',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '684',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '685',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '686',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '687',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '689',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '690',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '691',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '692',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '693',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '694',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '695',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '696',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '697',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '698',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '699',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '700',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '701',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '702',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '703',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '704',\n 'idruang_fk' => '9'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '705',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '706',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '707',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '708',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '709',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '710',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '711',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '712',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '713',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '714',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '715',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '716',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '717',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '718',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '719',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '720',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '721',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '722',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '723',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '724',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '725',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Yamato HAA',\n 'nup' => '726',\n 'idruang_fk' => '15'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi Tunggu HighPoint Monterey AY405K',\n 'nup' => '727',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi Tunggu HighPoint Monterey AY405K',\n 'nup' => '728',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi Tunggu HighPoint Monterey AY405K',\n 'nup' => '729',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '730',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '731',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '732',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '732',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '733',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '734',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '735',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '736',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '737',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '738',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '739',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '740',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '741',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '742',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '743',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '744',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '745',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '746',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '747',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '748',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '749',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '750',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '751',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '752',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '753',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '754',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '755',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '756',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '759',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '760',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '761',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '762',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '763',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '764',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'MINIMALIS',\n 'nup' => '1',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Sofa 211 Minimalis+Meja',\n 'nup' => '2',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Sofa 211 Minimalis+Meja',\n 'nup' => '3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Kursi Taman 2 set untuk Taman Fasilkom',\n 'nup' => '4',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Kursi Taman 2 set untuk Taman Fasilkom',\n 'nup' => '5',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '1',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '2',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '3',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '4',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '5',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '6',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '7',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '8',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '9',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '10',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '11',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '12',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '13',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '14',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '6',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '6',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '7',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '7',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '8',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '9',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '10',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '11',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '12',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '13',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '14',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '15',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '16',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '17',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '18',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '19',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '20',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '21',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '22',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '23',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '24',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '25',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '26',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '27',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '28',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '29',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '30',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '31',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '32',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '33',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '34',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '35',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '36',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '37',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '38',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '39',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '40',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '41',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '42',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '43',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '44',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '45',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '46',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '47',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '48',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '49',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '50',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '51',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '52',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '53',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '54',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '55',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '56',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '57',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '58',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '59',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '60',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '61',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '62',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '63',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '64',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '65',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '66',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '67',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '68',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '69',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '70',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '71',\n 'idruang_fk' => '8'\n )); DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '72',\n 'idruang_fk' => '8'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '73',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '74',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '75',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '76',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '77',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '78',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '79',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '80',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '81',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '82',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '83',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '84',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '85',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '86',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '87',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '88',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '89',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '90',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '91',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '92',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '93',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '94',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '95',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '96',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '97',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '98',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '99',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '100',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '101',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '102',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '103',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '104',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '105',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '106',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '107',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '108',\n 'idruang_fk' => '6'\n )); DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '109',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '110',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '111',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '112',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '113',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '114',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '115',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '116',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '117',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '118',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '119',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '120',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '121',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '122',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '123',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '124',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '125',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '126',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '127',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '128',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '129',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '130',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '131',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '132',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '133',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '134',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '135',\n 'idruang_fk' => '15'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '136',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '137',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '138',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '139',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '140',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '141',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '142',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '143',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '145',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '146',\n 'idruang_fk' => '6'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Instruktur High Point CD-301',\n 'nup' => '147',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Instruktur High Point CD-301',\n 'nup' => '148',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Meja Komputer AZTEK',\n 'nup' => '149',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Meja Komputer AZTEK',\n 'nup' => '150',\n 'idruang_fk' => '3'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Meja Komputer AZTEK',\n 'nup' => '151',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Lemari es\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '24',\n 'merk_barang' => 'PANASONIC A191D',\n 'nup' => '1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C CENTRAL\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '25',\n 'merk_barang' => 'pOLITRON 3PK',\n 'nup' => '1',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C CENTRAL\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '25',\n 'merk_barang' => 'pOLITRON 3PK',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2016-05-11',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIKAC',\n 'nup' => '35',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2016-05-11',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIKAC',\n 'nup' => '36',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2016-05-11',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIKAC',\n 'nup' => '37',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK 2PK',\n 'nup' => '38',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK 2PK',\n 'nup' => '39',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '40',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '41',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '42',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '43',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '44',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '45',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '46',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '47',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '48',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '49',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '50',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '51',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '52',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '53',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '54',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '55',\n 'idruang_fk' => '4'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '56',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '57',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 18KKP',\n 'nup' => '58',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '59',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC',\n 'nup' => '60',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC',\n 'nup' => '61',\n 'idruang_fk' => '20'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG',\n 'nup' => '62',\n 'idruang_fk' => '26'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG',\n 'nup' => '63',\n 'idruang_fk' => '26'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC',\n 'nup' => '64',\n 'idruang_fk' => '21'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 2PK',\n 'nup' => '65',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 2PK',\n 'nup' => '66',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 2PK',\n 'nup' => '67',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 1,5PK',\n 'nup' => '68',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 1,5PK',\n 'nup' => '69',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC 2PK',\n 'nup' => '70',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC 2PK',\n 'nup' => '71',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC R32 2PK',\n 'nup' => '72',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK Inverter CS-s18rkp I n/CU-S18RKP out 2pk',\n 'nup' => '73',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK CU-PN18SKP Outdoor/CS-PN18SKP/Indoee 2PK',\n 'nup' => '74',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK CU-PN18SKP Outdoor/CS-PN18SKP/Indoee 2PK',\n 'nup' => '75',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-05-31',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'AC PANASONIK 2PK',\n 'nup' => '76',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-05-31',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'AC PANASONIK 2PK',\n 'nup' => '77',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-09-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => '2 PK CS-YN18TKP',\n 'nup' => '78',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-09-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => '2 PK CS-YN18TKP',\n 'nup' => '79',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '4',\n 'idruang_fk' => '3'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '5',\n 'idruang_fk' => '5'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '6',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2014-11-19',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Kipas Angin Berdiri MIYAKO',\n 'nup' => '7',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2014-11-19',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Kipas Angin Berdiri MIYAKO',\n 'nup' => '8',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Hexos Van',\n 'nup' => '9',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Treng/Tandon air\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '27',\n 'merk_barang' => 'STANLESS 1000L',\n 'nup' => '1',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'PANASONIC VIERA TH-L32C20X',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'LG 42LK450',\n 'nup' => '2',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'LG 42LK450',\n 'nup' => '3',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'SHARP LED TV 60 INCH FHD+ BRACKET',\n 'nup'=>'4',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2019-04-29',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'Televisi SHARP 60\"',\n 'nup'=>'4',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // amplifier\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '29',\n 'merk_barang' => 'TOA',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LOADSPEAKER\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '30',\n 'merk_barang' => 'SPEAKER TOA',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LOADSPEAKER\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '30',\n 'merk_barang' => 'SPEAKER TOA',\n 'nup'=>'2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // SOUNDSYSTEM\n 'tanggal' => '2016-08-19',\n 'idbarang_fk' => '31',\n 'merk_barang' => 'LEXUS KM 500',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'AIRLIVE AIR VIDEO 2000',\n 'nup'=>'1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A1',\n 'nup'=>'2',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A1',\n 'nup'=>'3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A2',\n 'nup'=>'4',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A2',\n 'nup'=>'5',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TANGGA ALUM\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '33',\n 'merk_barang' => 'CALTEX DOUBLE TINGGI',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TANGGA ALUM\n 'tanggal' => '2014-03-26',\n 'idbarang_fk' => '33',\n 'merk_barang' => 'TANPA MERK',\n 'nup'=>'2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'2',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'5',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MIMBAR\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '35',\n 'merk_barang' => 'PODIUM KAYU',\n 'nup'=>'1',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'1',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'2',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'3',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'4',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'5',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'6',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'7',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'8',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'9',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'10',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'11',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'12',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'13',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'14',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'15',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'16',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'17',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'18',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'19',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'20',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'21',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'22',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'23',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'24',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'25',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2016-07-26',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Shure',\n 'nup'=>'2',\n 'idruang_fk' => '10'\n )); \n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA ZW-3200',\n 'nup'=>'3',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA Wireless Michrophone ZW-G810CU + 2 Mic',\n 'nup'=>'4',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA Wireless Michrophone ZW-G810CU + 2 Mic',\n 'nup'=>'5',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA Wireless Michrophone ZW-G810CU + 2 Mic',\n 'nup'=>'6',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Shure ULX 4 BETA 58',\n 'nup'=>'7',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2018-04-30',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Sound cress 801',\n 'nup'=>'8',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2018-04-30',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Sound cress 801',\n 'nup'=>'9',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SUA3000I',\n 'nup'=>'1',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SUA3000I',\n 'nup'=>'2',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SUA1500I',\n 'nup'=>'3',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'KENIKA',\n 'nup'=>'4',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'DELL UPS RACK 3750W/5000VA',\n 'nup'=>'5',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'DELL UPS RACK 3750W/5000VA',\n 'nup'=>'6',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'7',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'8',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'9',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'10',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 4200W/6000VA',\n 'nup'=>'11',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 4200W/6000VA',\n 'nup'=>'12',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'13',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'14',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'15',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'16',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'17',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2018-12-26',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SURT15KRMXLI',\n 'nup'=>'18',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // video presenter\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '39',\n 'merk_barang' => 'PROLINK PWP301',\n 'nup'=>'1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n //video conference\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '40',\n 'merk_barang' => 'Fancil D800',\n 'nup'=>'1',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Image View 118326',\n 'nup'=>'1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Image View 118326',\n 'nup'=>'2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Night Vision 260400',\n 'nup'=>'3',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Night Vision 260400',\n 'nup'=>'4',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Telephone\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '42',\n 'merk_barang' => 'Favorite TC416 PABX-16 Unit',\n 'nup'=>'1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Facsimile\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '43',\n 'merk_barang' => 'PANASONIC C KXFP 362 CX',\n 'nup'=>'1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'3',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'4',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'5',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'6',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'7',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'8',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'9',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'10',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'11',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'12',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'13',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'14',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'15',\n 'idruang_fk' => '1'\n ));DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'16',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'17',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'18',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'19',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Finger Printer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '45',\n 'merk_barang' => 'Fingerspot Enterprise 2000C',\n 'nup'=>'1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Finger Printer\n 'tanggal' => '2018-04-30',\n 'idbarang_fk' => '45',\n 'merk_barang' => 'Fingerprint New Premier Series',\n 'nup'=>'2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Peralatan Antena\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '46',\n 'merk_barang' => 'Trimble Tornado Antena for Mapping & GIS',\n 'nup'=>'1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Peralatan Antena\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '46',\n 'merk_barang' => 'Trimble Tornado Antena for Mapping & GIS',\n 'nup'=>'2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1900',\n 'nup'=>'1',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'2',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'3',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'4',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'5',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'7',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'8',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'9',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'10',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'11',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'12',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'13',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'14',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'15',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'16',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'17',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'18',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'19',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'20',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'21',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'22',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'23',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'24',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'25',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'26',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'27',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'28',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'29',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'30',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'31',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'32',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'33',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'34',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'35',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'36',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'37',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'38',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'39',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'40',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'41',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'42',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'43',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'44',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'45',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'46',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'47',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'48',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'49',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'50',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'51',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'52',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'53',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'54',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'55',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'56',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'57',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'58',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'59',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'60',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'61',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'62',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'63',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'64',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'65',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'66',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'67',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'68',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'69',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'70',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'71',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'72',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'73',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'74',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'75',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'76',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'77',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'78',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'79',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'80',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'81',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'82',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'83',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'84',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'85',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'86',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'87',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'88',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'89',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'90',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'91',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'92',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'93',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'94',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'95',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '96',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '97',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '98',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '99',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '100',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER Aspire M1900JM',\n 'nup' => '101',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER Aspire M1900JM',\n 'nup' => '102',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '103',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '104',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '105',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '106',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '107',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '108',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '109',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '110',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '111',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '112',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '113',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '114',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '115',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '116',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '117',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '118',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '120',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '121',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '122',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '123',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '124',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '125',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '126',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '127',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '128',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '129',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '130',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '131',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '132',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '133',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '134',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '135',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '136',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '137',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '138',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '139',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '140',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '141',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '142',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '143',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Power edge R730',\n 'nup' => '144',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Power edge R730',\n 'nup' => '145',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '146',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '147',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '148',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '149',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '150',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '151',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '152',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '153',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '154',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '155',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '156',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '157',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '158',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '159',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '160',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '161',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '162',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '163',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '164',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '165',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '166',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '167',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '168',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '169',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '170',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '171',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '172',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '173',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '174',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '175',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '176',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '177',\n 'idruang_fk' => '8'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '178',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '179',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '180',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '181',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '182',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '183',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '184',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '185',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '186',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '187',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '188',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '189',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '190',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '191',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '192',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '193',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '194',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '195',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '196',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '197',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '198',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '199',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '200',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '201',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '202',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '203',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '204',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '205',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '206',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '207',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '208',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '209',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '210',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Electronic Robot\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '48',\n 'merk_barang' => 'Wow Wee Rovio',\n 'nup' => '1',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Electronic Robot\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '48',\n 'merk_barang' => 'Arm MR-999E',\n 'nup' => '2',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kamera Digital\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '49',\n 'merk_barang' => 'Nikon D5 100 Kit TO',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kamera Digital\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '49',\n 'merk_barang' => 'Canon Digital EOS 77D With Lens18-55mm+Memory 32G',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Handheld GPS System Trimble Juno',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Handheld GPS System Trimble Juno',\n 'nup' => '2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Trimble geo explorer 6000',\n 'nup' => '3',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Trimble Recon Hendheld',\n 'nup' => '4',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Trimble Recon Hendheld',\n 'nup' => '5',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Omni\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '51',\n 'merk_barang' => 'Omni Mikrotik ANT APF24-20',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Omni\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '51',\n 'merk_barang' => 'Omni Mikrotik ANT APF24-20',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Omni\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '51',\n 'merk_barang' => 'Omni Mikrotik ANT APF24-20',\n 'nup' => '3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '3',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '4',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '5',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '6',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '7',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '8',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '9',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '10',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '11',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '12',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '13',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '14',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '15',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '16',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '17',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '18',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '19',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '20',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '21',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '22',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '23',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '24',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '25',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '26',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '27',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '28',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '29',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '30',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '31',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '32',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '33',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '34',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '35',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '36',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '37',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '38',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '39',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '40',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '41',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '42',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '43',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '44',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '45',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '46',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '47',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '48',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '49',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '50',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '51',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '52',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '53',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '54',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '55',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '56',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '57',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '58',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '59',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '60',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Mini Komputer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '53',\n 'merk_barang' => 'Tablet with GPS Pathfinder ProXH receiver',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'Dell Precision T1600',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'Precision T1600',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'Dell Precision T15500',\n 'nup' => '3',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '4',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '5',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '6',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '7',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '1',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '3',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '4',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '5',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '6',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '7',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Fujitsu Lifebook TH700',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Toshiba Portege T210-1029 U',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'ASUS A42F-VX085D',\n 'nup' => '3',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Toshiba Satellite L635-1064',\n 'nup' => '4',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Toshiba Portege T210-1018R',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2019-03-27',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Asus Ultra Slim 14 inch',\n 'nup' => '6',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Asus Eee PC 1005PX-Black',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Asus Eee PC 1005PX-Black',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Asus Eee PC 1005PX',\n 'nup' => '3',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Dell Latitude E6420',\n 'nup' => '4',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Dell Latitude E6420',\n 'nup' => '5',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Latitude E6420',\n 'nup' => '6',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Latitude E6420',\n 'nup' => '7',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Latitude E6420',\n 'nup' => '8',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'DELL Latitude E6230',\n 'nup' => '9',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'DELL Latitude E6230',\n 'nup' => '10',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Dell Precision M6700',\n 'nup' => '11',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2015-04-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Apple Mac Book Air (MD7121D/B)',\n 'nup' => '12',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '13',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '14',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '15',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '16',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'DELL Ultra Sharp U2410',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'DELL Ultra Sharp U2410',\n 'nup' => '2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'Interactive pen Display Wacom DTU-2231 A',\n 'nup' => '3',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'Interactive pen Display Wacom DTU-2231 A',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'LASERJET P1005 HP',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP LASERJET PRO P1 102',\n 'nup' => '2',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP LASERJET PRO P1 102',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'CANON PIXMA MP276',\n 'nup' => '4',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'CANON PIXMA MP276',\n 'nup' => '5',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Pro P1 102',\n 'nup' => '6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Epson L100',\n 'nup' => '7',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Canon pixma MGR 170',\n 'nup' => '8',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Canon pixma MGR 170',\n 'nup' => '9',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Lip CP3525dn',\n 'nup' => '10',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet Pro MI 212',\n 'nup' => '11',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'CANON PIXMA IP4870',\n 'nup' => '12',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP LAser Jet Pro MO 212',\n 'nup' => '13',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'EPSON LQ 2190',\n 'nup' => '14',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '15',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '16',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'INK Jet EPSON L110',\n 'nup' => '17',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '18',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '19',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '20',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '21',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '22',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP DESIGNjet 510 AO 42\" (AO+) CH337A',\n 'nup' => '23',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'EPSON L360',\n 'nup' => '24',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'EPSON L360',\n 'nup' => '25',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1102',\n 'nup' => '26',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1102',\n 'nup' => '27',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1102',\n 'nup' => '28',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '29',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '30',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '31',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '32',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer HP Laser Jet Pro M102a (G3Q34A)',\n 'nup' => '33',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer HP Laser Jet Pro M102a (G3Q34A)',\n 'nup' => '34',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer HP Laser Jet Pro M102a (G3Q34A)',\n 'nup' => '35',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Scanner\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '60',\n 'merk_barang' => 'EPSON GT-2900',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Scanner\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'EPSON GT-2900',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '3',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'QNAP TS 559 Pro+',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '3',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '4',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '5',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '6',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'SUPERMI CRO Super Server 1029P-WTR',\n 'nup' => '7',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'SUPERMI CRO Super Server 1029P-WTR',\n 'nup' => '8',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'ATEN 8-Port PS/2-USB VGA LCD KVM Switch with daisy',\n 'nup' => '9',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Rackmount, Nikrotik RB110',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Rackmount, Nikrotik RB110',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '3',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '6',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '7',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '8',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '9',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Mikrotik Core Router',\n 'nup' => '11',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // HUb\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '64',\n 'merk_barang' => 'D-LINK DGS-1024D',\n 'nup' => '1',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Rak Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '65',\n 'merk_barang' => 'Dell PowerEdge Rack 4220',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Rak Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '65',\n 'merk_barang' => 'Dell PowerEdge Rack 4220',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Swiitch Rak\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '66',\n 'merk_barang' => 'Fortuna 8u double door',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '1',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '2',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '3',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '4',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 UTP Cable',\n 'nup' => '7',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 UTP Cable',\n 'nup' => '8',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'Belden Cat 6',\n 'nup' => '9',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'TP Link Switch HUB',\n 'nup' => '14',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'TP Link Switch HUB',\n 'nup' => '15',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '16',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '17',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '18',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '19',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '20',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '21',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '22',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '23',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '24',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '25',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '26',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'LINK TL-SG 1024',\n 'nup' => '27',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'LINK TL-SG 1024',\n 'nup' => '28',\n 'idruang_fk' => '18'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-02-23',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'SWITCH MANAGE Cisco SLM2008T-EU',\n 'nup' => '29',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-02-23',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'SWITCH MANAGE Cisco SLM2008T-EU',\n 'nup' => '30',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'CISCO SG95D-08/-Port Gigabit Dekstop Switch',\n 'nup' => '31',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'CISCO SG95D-08/-Port Gigabit Dekstop Switch',\n 'nup' => '32',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'JUNIPER Switch Manage EX2200-24T-4G',\n 'nup' => '33',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'TP-LINK AC1200 Dual-Band Wifi Gigabit Router',\n 'nup' => '34',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Acces Point\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '69',\n 'merk_barang' => 'D-Link DAP-1360',\n 'nup' => '1',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Acces Point\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '69',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '3',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '4',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '5',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '6',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '7',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Jet Pump\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '71',\n 'merk_barang' => 'LAKONI 505',\n 'nup' => '1',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '3',\n 'idruang_fk' => '25'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '4',\n 'idruang_fk' => '25'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'WD Sentinel DX4000 WDBLGTO 1 20KBK',\n 'nup' => '5',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'WD Sentinel DX4000 WDBLGTO 1 20KBK',\n 'nup' => '6',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat tenis meja\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '73',\n 'merk_barang' => 'Meja Pingpong Lokal',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat tenis meja\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '73',\n 'merk_barang' => 'Tanis Meja Nittaku 2003B',\n 'nup' => '2',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat Music Modern\n 'tanggal' => '2016-07-26',\n 'idbarang_fk' => '74',\n 'merk_barang' => 'Keyboard Roland E 09',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat music \n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '74',\n 'merk_barang' => 'Korg PA50 RU',\n 'nup' => '2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB 7',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Parallel computing',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Opsfullzation Toolbox',\n 'nup' => '3',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '74',\n 'merk_barang' => 'MATLAB Symbolic Math Toolbox',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Partial Differential',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Global Optimization',\n 'nup' => '6',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Statistics rootbox',\n 'nup' => '7',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Neural Network Toolbox',\n 'nup' => '8',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Curve Fitting Toolbox',\n 'nup' => '9',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Image Proces Toolbox',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Vision System Toolbox',\n 'nup' => '11',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Mapping toolbox',\n 'nup' => '12',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Bioinformatics Toolbox',\n 'nup' => '13',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Simbiology',\n 'nup' => '14',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Compiler',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Spreadsheet link EX',\n 'nup' => '16',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Builder NE',\n 'nup' => '17',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Builder EX',\n 'nup' => '18',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Huilder JA',\n 'nup' => '19',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Database Toolbox',\n 'nup' => '20',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Report Generator',\n 'nup' => '21',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Trimble Trim Pix Pro',\n 'nup' => '22',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Trimble Trim Pix pro',\n 'nup' => '23',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Software Trimble Terrasync Pro 45955-VG',\n 'nup' => '24',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GPS Correct Extention For esri ArPad 46837-VG',\n 'nup' => '25',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GPS Analyst Extention For esri ArcGis 52726-VG',\n 'nup' => '26',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GPS pathfinder Office Software 34191-VG',\n 'nup' => '27',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Dekstop GIS ESRI Advanced (Arcinfo)',\n 'nup' => '28',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GIS Analysis Extention ESRi ArcGis Schematcs',\n 'nup' => '29',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Extention Esri ArcGis Analyst Schematics',\n 'nup' => '30',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Produktivity ArcGis Data Interoperability',\n 'nup' => '31',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'ArcGis Geostatistical Analyst',\n 'nup' => '32',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => ' Extention ESRI ArcGIS Network Analyst',\n 'nup' => '33',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Extention ESRI ArcGIS Spatial Analyst',\n 'nup' => '34',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Extention ESRI ArcGIS Tracking Analyst',\n 'nup' => '35',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Mobile GIS ESRI ArcPad 10',\n 'nup' => '36',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GIS for Server ESRi ArcGis',\n 'nup' => '37',\n 'idruang_fk' => '1'\n ));\n }", "public function run()\n {\n \n\n \\DB::table('halamanstatis')->delete();\n \n \\DB::table('halamanstatis')->insert(array (\n 0 => \n array (\n 'id_halaman' => 1,\n 'judul' => 'Profil',\n 'isi_halaman' => '<p>\n<strong>Bukulokomedia.com</strong> merupakan website resmi dari penerbit\nLokomedia yang bermarkas di Jl. Jambon. Perum. Pesona Alam Hijau 2 Blok B-4 Kricak, Jatimulyo, Yogyakarta\n55242. Dirintis pertama kali oleh Lukmanul Hakim pada tanggal 14 Maret\n2008.<br />\n<br />\nProduk unggulan dari penerbit Lokomedia adalah buku-buku serta aksesoris bertema Web, terutama PHP (<span style=\"font-weight: bold; font-style: italic\">PHP: Hypertext Preprocessor</span>) yang merupakan pemrograman Internet paling handal saat ini.\n</p>\n',\n 'tgl_posting' => '2010-05-31',\n 'gambar' => 'gedungku.jpg',\n ),\n 1 => \n array (\n 'id_halaman' => 2,\n 'judul' => 'Visi dan Misi',\n 'isi_halaman' => '<p>\nVisi :\n</p>\n<p>\n&nbsp;\n</p>\n<p>\n&nbsp;\n</p>\n<p>\nMisi :\n</p>\n<p>\n&nbsp;\n</p>\n',\n 'tgl_posting' => '2010-05-31',\n 'gambar' => '',\n ),\n 2 => \n array (\n 'id_halaman' => 3,\n 'judul' => 'Struktur Organisasi',\n 'isi_halaman' => 'Isikan struktur organisasi di bagian ini\n',\n 'tgl_posting' => '2010-05-31',\n 'gambar' => '',\n ),\n ));\n \n \n }", "public function simpan_data_penerima_bansos()\n {\n $noKK = $this->request->getVar('noKK');\n $kepalaKeluarga = $this->request->getVar('kepalaKeluarga');\n $idBansos = $this->request->getVar('idBansos');\n $namaBansos = $this->request->getVar('namaBansos');\n $kategori = $this->request->getVar('kategori');\n $pendamping = $this->request->getVar('pendamping');\n $nominal = $this->request->getVar('nominal');\n $jumlahData = count($noKK);\n $jumlahBerhasil = 0;\n $jumlahGagal = 0;\n $jumlahTerdaftar = 0;\n $jumlahDataKKTidakDitemukan = 0;\n $jumlahDataBansosTidakDitemukan = 0;\n $jumlahBelumDisetujui = 0;\n for ($i = 0; $i < $jumlahData; $i++) {\n // cek apakah fieldnya kosong\n if ($noKK[$i] == 0 || $idBansos[$i] == 0) {\n $jumlahGagal++;\n } else {\n // cek pada database apakah data KK tersebut ada\n $dataKeluarga = $this->KeluargaModel->where('noKK', $noKK[$i])->first();\n if ($dataKeluarga) {\n // cek pada database apakah data bansos ada\n $dataBansos = $this->DataBansosModel->where('idBansos', $idBansos[$i])->first();\n if ($dataBansos) {\n // cek apakah data keluarga sudah\n $status = 'Disetujui';\n $disetujui = $this->KeluargaModel->where('noKK', $noKK[$i])->where('status', $status)->first();\n if ($disetujui) {\n // cek data peserta apakah sudah terdaftar\n $pesertaBansos = $this->BansosModel->where('noKK', $noKK[$i])->where('idBansos', $idBansos[$i])->first();\n if ($pesertaBansos) {\n $jumlahTerdaftar++;\n } else {\n\n $this->BansosModel->save([\n 'noKK' => $noKK[$i],\n 'kepalaKeluarga' => $kepalaKeluarga[$i],\n 'idBansos' => $idBansos[$i],\n 'namaBansos' => $namaBansos[$i],\n 'kategori' => $kategori[$i],\n 'pendamping' => $pendamping[$i],\n 'nominal' => $nominal[$i],\n 'statusAnggota' => 'Aktif'\n ]);\n $jumlahBerhasil++;\n }\n } else {\n $jumlahBelumDisetujui++;\n }\n } else {\n $jumlahDataBansosTidakDitemukan++;\n }\n } else {\n $jumlahDataKKTidakDitemukan++;\n }\n }\n }\n session()->setFlashdata('pesan', '' . $jumlahBerhasil . ' Berhasil Disimpan, ' . $jumlahTerdaftar . ' Telah Terdaftar, ' . $jumlahDataKKTidakDitemukan . ' Data KK Tidak Ditemukan, ' . $jumlahDataBansosTidakDitemukan . ' Data Bansos Tidak Ditemukan dan ' . $jumlahBelumDisetujui . ' Belum Disetujui');\n return redirect()->to('/Admin/penerima_bansos');\n }", "function newskomentar_listdata($tbl_newskomentar){\n\t\t$sql = mysql_query(\"SELECT * FROM $tbl_newskomentar\");\n\t\treturn $sql;\n}", "public function buscarDatosDeCodigo($lote, $suc){\n $db = new My();\n $my = new My();\n $datos = array();\n $query = \"SELECT a.codigo AS Codigo,l.lote,CONCAT( a.descrip, '-', p.nombre_color) AS Descrip , s.suc, s.cantidad AS Stock, s.estado_venta,a.um AS UM,l.ancho AS Ancho,l.gramaje AS Gramaje,l.tara AS Tara,l.padre AS Padre,s.ubicacion AS U_ubic,\n l.img AS Img, l.kg_desc AS U_kg_desc,h.fecha_hora AS entDate\n\n FROM articulos a INNER JOIN lotes l ON a.codigo = l.codigo INNER JOIN stock s ON l.codigo = s.codigo AND l.lote = s.lote \n INNER JOIN pantone p ON l.pantone = p.pantone INNER JOIN historial h ON l.codigo = h.codigo AND l.lote = h.lote\n WHERE s.cantidad > 0 AND s.suc = '$suc' AND l.lote ='$lote' GROUP BY lote ORDER BY h.fecha_hora ASC LIMIT 1\";\n \n $my->Query($query);\n if($my->NextRecord()){\n $datos = $my->Record;\n if(count($datos)){\n $datos = array_map(\"utf8_encode\",$datos);\n // print_r($datos);\n \n $rem = \"SELECT CONCAT(fecha_cierre,' ',hora_cierre) AS fecha_ingreso FROM nota_remision n, nota_rem_det d WHERE n.n_nro = d.n_nro AND lote = '$lote' AND n.estado = 'Cerrada' AND n.suc_d = '$suc'\";\n \n $db->Query($rem);\n if($db->NumRows() > 0){ \n $db->NextRecord();\n $fecha_ingreso = $db->Record['fecha_ingreso'];\n $datos['entDate'] = $fecha_ingreso;\n }\n // Buscar si esta en una Remision Abierta o En Proceso\n $rem2 = \"SELECT n.n_nro, n.suc_d FROM nota_remision n, nota_rem_det d WHERE n.n_nro = d.n_nro AND lote = '$lote' AND n.estado != 'Cerrada' AND n.suc = '$suc'\";\n \n $db->Query($rem2);\n if($db->NumRows() > 0){ \n $db->NextRecord();\n $n_nro = $db->Record['n_nro'];\n $destino = $db->Record['suc_d'];\n $datos['NroRemision'] = $n_nro;\n $datos['Destino'] = $destino;\n $datos['Mensaje']=\"En Remision\";\n }else{\n $datos['Mensaje']=\"Ok\"; \n }\n \n }\n echo json_encode($datos);\n }else{\n echo '{\"Mensaje\":\"Error: Codigo no encontrado!\"}';\n } \n $my->Close();\n }", "public function run()\n {\n DB::table('obat_masuk')->insert(array(\n \tarray('id_jenis_obat'=>1, 'id_stok_obat'=>1, 'waktu_masuk'=>'2017-01-07 09:12:00', 'jumlah'=>170, 'harga_beli_satuan'=>9100.00),\n\t\t\tarray('id_jenis_obat'=>2, 'id_stok_obat'=>2, 'waktu_masuk'=>'2017-01-15 09:16:00', 'jumlah'=>110, 'harga_beli_satuan'=>11000.00),\n\t\t\tarray('id_jenis_obat'=>3, 'id_stok_obat'=>3, 'waktu_masuk'=>'2017-01-22 09:26:00', 'jumlah'=>380, 'harga_beli_satuan'=>49000.00),\n\t\t\tarray('id_jenis_obat'=>4, 'id_stok_obat'=>4, 'waktu_masuk'=>'2017-02-06 09:32:00', 'jumlah'=>480, 'harga_beli_satuan'=>1300.00),\n\t\t\tarray('id_jenis_obat'=>5, 'id_stok_obat'=>5, 'waktu_masuk'=>'2017-02-07 09:42:00', 'jumlah'=>380, 'harga_beli_satuan'=>1400.00),\n\t\t\tarray('id_jenis_obat'=>6, 'id_stok_obat'=>6, 'waktu_masuk'=>'2017-02-21 09:46:00', 'jumlah'=>310, 'harga_beli_satuan'=>1600.00),\n\t\t\tarray('id_jenis_obat'=>7, 'id_stok_obat'=>7, 'waktu_masuk'=>'2017-03-15 10:02:00', 'jumlah'=>450, 'harga_beli_satuan'=>900.00),\n\t\t\tarray('id_jenis_obat'=>8, 'id_stok_obat'=>8, 'waktu_masuk'=>'2017-03-28 10:08:00', 'jumlah'=>90, 'harga_beli_satuan'=>2700.00),\n\t\t\tarray('id_jenis_obat'=>9, 'id_stok_obat'=>9, 'waktu_masuk'=>'2017-04-05 10:10:00', 'jumlah'=>230, 'harga_beli_satuan'=>470),\n\t\t\tarray('id_jenis_obat'=>10, 'id_stok_obat'=>10, 'waktu_masuk'=>'2017-04-16 10:16:00', 'jumlah'=>320, 'harga_beli_satuan'=>450),\n\t\t\tarray('id_jenis_obat'=>11, 'id_stok_obat'=>11, 'waktu_masuk'=>'2017-04-19 10:22:00', 'jumlah'=>30, 'harga_beli_satuan'=>6800.00),\n\t\t\tarray('id_jenis_obat'=>12, 'id_stok_obat'=>12, 'waktu_masuk'=>'2017-04-29 10:36:00', 'jumlah'=>330, 'harga_beli_satuan'=>7400.00),\n\t\t\tarray('id_jenis_obat'=>13, 'id_stok_obat'=>13, 'waktu_masuk'=>'2017-05-05 10:38:00', 'jumlah'=>20, 'harga_beli_satuan'=>6300.00),\n\t\t\tarray('id_jenis_obat'=>14, 'id_stok_obat'=>14, 'waktu_masuk'=>'2017-05-23 10:44:00', 'jumlah'=>320, 'harga_beli_satuan'=>6300.00),\n\t\t\tarray('id_jenis_obat'=>15, 'id_stok_obat'=>15, 'waktu_masuk'=>'2017-06-05 10:48:00', 'jumlah'=>180, 'harga_beli_satuan'=>9700.00),\n\t\t\tarray('id_jenis_obat'=>16, 'id_stok_obat'=>16, 'waktu_masuk'=>'2017-06-18 10:56:00', 'jumlah'=>190, 'harga_beli_satuan'=>12200.00),\n\t\t\tarray('id_jenis_obat'=>17, 'id_stok_obat'=>17, 'waktu_masuk'=>'2017-06-20 10:58:00', 'jumlah'=>420, 'harga_beli_satuan'=>700.00),\n\t\t\tarray('id_jenis_obat'=>18, 'id_stok_obat'=>18, 'waktu_masuk'=>'2017-06-25 11:00:00', 'jumlah'=>280, 'harga_beli_satuan'=>1500.00),\n\t\t\tarray('id_jenis_obat'=>19, 'id_stok_obat'=>19, 'waktu_masuk'=>'2017-06-27 11:02:00', 'jumlah'=>340, 'harga_beli_satuan'=>630),\n\t\t\tarray('id_jenis_obat'=>20, 'id_stok_obat'=>20, 'waktu_masuk'=>'2017-07-02 11:06:00', 'jumlah'=>50, 'harga_beli_satuan'=>8000.00),\n\t\t\tarray('id_jenis_obat'=>21, 'id_stok_obat'=>21, 'waktu_masuk'=>'2017-08-06 11:08:00', 'jumlah'=>150, 'harga_beli_satuan'=>5100.00),\n\t\t\tarray('id_jenis_obat'=>22, 'id_stok_obat'=>22, 'waktu_masuk'=>'2017-08-23 11:20:00', 'jumlah'=>210, 'harga_beli_satuan'=>500.00),\n\t\t\tarray('id_jenis_obat'=>23, 'id_stok_obat'=>23, 'waktu_masuk'=>'2017-08-24 11:22:00', 'jumlah'=>250, 'harga_beli_satuan'=>900.00),\n\t\t\tarray('id_jenis_obat'=>24, 'id_stok_obat'=>24, 'waktu_masuk'=>'2017-08-30 11:24:00', 'jumlah'=>440, 'harga_beli_satuan'=>600.00),\n\t\t\tarray('id_jenis_obat'=>25, 'id_stok_obat'=>25, 'waktu_masuk'=>'2017-09-10 11:26:00', 'jumlah'=>420, 'harga_beli_satuan'=>2100.00),\n\t\t\tarray('id_jenis_obat'=>26, 'id_stok_obat'=>26, 'waktu_masuk'=>'2017-01-05 11:28:00', 'jumlah'=>270, 'harga_beli_satuan'=>4400.00),\n\t\t\tarray('id_jenis_obat'=>27, 'id_stok_obat'=>27, 'waktu_masuk'=>'2017-01-17 11:30:00', 'jumlah'=>500, 'harga_beli_satuan'=>15500.00),\n\t\t\tarray('id_jenis_obat'=>28, 'id_stok_obat'=>28, 'waktu_masuk'=>'2017-01-24 11:34:00', 'jumlah'=>310, 'harga_beli_satuan'=>39200.00),\n\t\t\tarray('id_jenis_obat'=>29, 'id_stok_obat'=>29, 'waktu_masuk'=>'2017-02-15 11:38:00', 'jumlah'=>260, 'harga_beli_satuan'=>400.00),\n\t\t\tarray('id_jenis_obat'=>30, 'id_stok_obat'=>30, 'waktu_masuk'=>'2017-02-19 11:40:00', 'jumlah'=>500, 'harga_beli_satuan'=>3100.00),\n\t\t\tarray('id_jenis_obat'=>31, 'id_stok_obat'=>31, 'waktu_masuk'=>'2017-03-05 11:50:00', 'jumlah'=>160, 'harga_beli_satuan'=>350),\n\t\t\tarray('id_jenis_obat'=>32, 'id_stok_obat'=>32, 'waktu_masuk'=>'2017-03-16 11:54:00', 'jumlah'=>180, 'harga_beli_satuan'=>370),\n\t\t\tarray('id_jenis_obat'=>33, 'id_stok_obat'=>33, 'waktu_masuk'=>'2017-03-18 11:56:00', 'jumlah'=>380, 'harga_beli_satuan'=>200.00),\n\t\t\tarray('id_jenis_obat'=>34, 'id_stok_obat'=>34, 'waktu_masuk'=>'2017-03-20 12:02:00', 'jumlah'=>390, 'harga_beli_satuan'=>500.00),\n\t\t\tarray('id_jenis_obat'=>35, 'id_stok_obat'=>35, 'waktu_masuk'=>'2017-03-22 12:12:00', 'jumlah'=>440, 'harga_beli_satuan'=>1100.00),\n\t\t\tarray('id_jenis_obat'=>36, 'id_stok_obat'=>36, 'waktu_masuk'=>'2017-03-24 12:28:00', 'jumlah'=>210, 'harga_beli_satuan'=>220),\n\t\t\tarray('id_jenis_obat'=>37, 'id_stok_obat'=>37, 'waktu_masuk'=>'2017-03-31 12:30:00', 'jumlah'=>280, 'harga_beli_satuan'=>3300.00),\n\t\t\tarray('id_jenis_obat'=>38, 'id_stok_obat'=>38, 'waktu_masuk'=>'2017-04-08 12:42:00', 'jumlah'=>460, 'harga_beli_satuan'=>7100.00),\n\t\t\tarray('id_jenis_obat'=>39, 'id_stok_obat'=>39, 'waktu_masuk'=>'2017-04-10 12:52:00', 'jumlah'=>250, 'harga_beli_satuan'=>8800.00),\n\t\t\tarray('id_jenis_obat'=>40, 'id_stok_obat'=>40, 'waktu_masuk'=>'2017-04-11 13:02:00', 'jumlah'=>230, 'harga_beli_satuan'=>16400.00),\n\t\t\tarray('id_jenis_obat'=>41, 'id_stok_obat'=>41, 'waktu_masuk'=>'2017-05-14 13:16:00', 'jumlah'=>270, 'harga_beli_satuan'=>2400.00),\n\t\t\tarray('id_jenis_obat'=>42, 'id_stok_obat'=>42, 'waktu_masuk'=>'2017-05-30 13:28:00', 'jumlah'=>360, 'harga_beli_satuan'=>520),\n\t\t\tarray('id_jenis_obat'=>43, 'id_stok_obat'=>43, 'waktu_masuk'=>'2017-06-03 13:30:00', 'jumlah'=>470, 'harga_beli_satuan'=>360),\n\t\t\tarray('id_jenis_obat'=>44, 'id_stok_obat'=>44, 'waktu_masuk'=>'2017-06-04 13:48:00', 'jumlah'=>120, 'harga_beli_satuan'=>660),\n\t\t\tarray('id_jenis_obat'=>45, 'id_stok_obat'=>45, 'waktu_masuk'=>'2017-06-10 14:00:00', 'jumlah'=>30, 'harga_beli_satuan'=>720),\n\t\t\tarray('id_jenis_obat'=>46, 'id_stok_obat'=>46, 'waktu_masuk'=>'2017-06-19 14:10:00', 'jumlah'=>250, 'harga_beli_satuan'=>410),\n\t\t\tarray('id_jenis_obat'=>47, 'id_stok_obat'=>47, 'waktu_masuk'=>'2017-06-20 14:12:00', 'jumlah'=>420, 'harga_beli_satuan'=>4300.00),\n\t\t\tarray('id_jenis_obat'=>48, 'id_stok_obat'=>48, 'waktu_masuk'=>'2017-06-27 14:14:00', 'jumlah'=>470, 'harga_beli_satuan'=>5000.00),\n\t\t\tarray('id_jenis_obat'=>49, 'id_stok_obat'=>49, 'waktu_masuk'=>'2017-07-15 14:16:00', 'jumlah'=>60, 'harga_beli_satuan'=>7900.00),\n\t\t\tarray('id_jenis_obat'=>50, 'id_stok_obat'=>50, 'waktu_masuk'=>'2017-07-28 14:18:00', 'jumlah'=>100, 'harga_beli_satuan'=>9200.00),\n\t\t\tarray('id_jenis_obat'=>51, 'id_stok_obat'=>51, 'waktu_masuk'=>'2017-01-08 14:24:00', 'jumlah'=>260, 'harga_beli_satuan'=>7500.00),\n\t\t\tarray('id_jenis_obat'=>52, 'id_stok_obat'=>52, 'waktu_masuk'=>'2017-01-11 14:32:00', 'jumlah'=>20, 'harga_beli_satuan'=>7800.00),\n\t\t\tarray('id_jenis_obat'=>53, 'id_stok_obat'=>53, 'waktu_masuk'=>'2017-02-11 14:40:00', 'jumlah'=>170, 'harga_beli_satuan'=>8800.00),\n\t\t\tarray('id_jenis_obat'=>54, 'id_stok_obat'=>54, 'waktu_masuk'=>'2017-02-13 14:42:00', 'jumlah'=>100, 'harga_beli_satuan'=>100.00),\n\t\t\tarray('id_jenis_obat'=>55, 'id_stok_obat'=>55, 'waktu_masuk'=>'2017-03-02 14:46:00', 'jumlah'=>380, 'harga_beli_satuan'=>9400.00),\n\t\t\tarray('id_jenis_obat'=>56, 'id_stok_obat'=>56, 'waktu_masuk'=>'2017-03-03 14:52:00', 'jumlah'=>410, 'harga_beli_satuan'=>3600.00),\n\t\t\tarray('id_jenis_obat'=>57, 'id_stok_obat'=>57, 'waktu_masuk'=>'2017-03-20 15:04:00', 'jumlah'=>490, 'harga_beli_satuan'=>8100.00),\n\t\t\tarray('id_jenis_obat'=>58, 'id_stok_obat'=>58, 'waktu_masuk'=>'2017-03-21 15:14:00', 'jumlah'=>380, 'harga_beli_satuan'=>8500.00),\n\t\t\tarray('id_jenis_obat'=>59, 'id_stok_obat'=>59, 'waktu_masuk'=>'2017-03-23 15:18:00', 'jumlah'=>270, 'harga_beli_satuan'=>14200.00),\n\t\t\tarray('id_jenis_obat'=>60, 'id_stok_obat'=>60, 'waktu_masuk'=>'2017-03-29 15:36:00', 'jumlah'=>10, 'harga_beli_satuan'=>22100.00),\n\t\t\tarray('id_jenis_obat'=>61, 'id_stok_obat'=>61, 'waktu_masuk'=>'2017-04-03 15:46:00', 'jumlah'=>100, 'harga_beli_satuan'=>7300.00),\n\t\t\tarray('id_jenis_obat'=>62, 'id_stok_obat'=>62, 'waktu_masuk'=>'2017-04-06 15:54:00', 'jumlah'=>260, 'harga_beli_satuan'=>19000.00),\n\t\t\tarray('id_jenis_obat'=>63, 'id_stok_obat'=>63, 'waktu_masuk'=>'2017-04-07 15:56:00', 'jumlah'=>450, 'harga_beli_satuan'=>24300.00),\n\t\t\tarray('id_jenis_obat'=>64, 'id_stok_obat'=>64, 'waktu_masuk'=>'2017-05-02 16:06:00', 'jumlah'=>490, 'harga_beli_satuan'=>17200.00),\n\t\t\tarray('id_jenis_obat'=>65, 'id_stok_obat'=>65, 'waktu_masuk'=>'2017-05-09 16:08:00', 'jumlah'=>400, 'harga_beli_satuan'=>35000.00),\n\t\t\tarray('id_jenis_obat'=>66, 'id_stok_obat'=>66, 'waktu_masuk'=>'2017-05-16 16:10:00', 'jumlah'=>290, 'harga_beli_satuan'=>37000.00),\n\t\t\tarray('id_jenis_obat'=>67, 'id_stok_obat'=>67, 'waktu_masuk'=>'2017-05-26 16:18:00', 'jumlah'=>450, 'harga_beli_satuan'=>1600.00),\n\t\t\tarray('id_jenis_obat'=>68, 'id_stok_obat'=>68, 'waktu_masuk'=>'2017-05-27 16:38:00', 'jumlah'=>90, 'harga_beli_satuan'=>3200.00),\n\t\t\tarray('id_jenis_obat'=>69, 'id_stok_obat'=>69, 'waktu_masuk'=>'2017-06-22 16:42:00', 'jumlah'=>140, 'harga_beli_satuan'=>5600.00),\n\t\t\tarray('id_jenis_obat'=>70, 'id_stok_obat'=>70, 'waktu_masuk'=>'2017-06-28 16:44:00', 'jumlah'=>300, 'harga_beli_satuan'=>700.00),\n\t\t\tarray('id_jenis_obat'=>71, 'id_stok_obat'=>71, 'waktu_masuk'=>'2017-07-06 16:48:00', 'jumlah'=>210, 'harga_beli_satuan'=>800.00),\n\t\t\tarray('id_jenis_obat'=>72, 'id_stok_obat'=>72, 'waktu_masuk'=>'2017-07-17 16:52:00', 'jumlah'=>500, 'harga_beli_satuan'=>1200.00)\n ));\n }", "function input_data($data,$table){\n\t\t$this->db->insert($table,$data);//menginputkan data ke database dengan function input_data\n }", "public function run()\n {\n \n\n \\DB::table('bahan')->delete();\n \n \\DB::table('bahan')->insert(array (\n 0 => \n array (\n 'ID_BAHAN' => 'B001',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Kertas saring',\n ),\n 1 => \n array (\n 'ID_BAHAN' => 'B002',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Lakmus merah',\n ),\n 2 => \n array (\n 'ID_BAHAN' => 'B003',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Lakmus biru',\n ),\n 3 => \n array (\n 'ID_BAHAN' => 'B004',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Indicator universal',\n ),\n 4 => \n array (\n 'ID_BAHAN' => 'B005',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Gula pasir',\n ),\n 5 => \n array (\n 'ID_BAHAN' => 'B006',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Urea',\n ),\n 6 => \n array (\n 'ID_BAHAN' => 'L1/B001',\n 'ID_LEMARI' => 11,\n 'NAMA_BAHAN' => 'Kertas grafik/millimeter',\n ),\n 7 => \n array (\n 'ID_BAHAN' => 'L1/B002',\n 'ID_LEMARI' => 11,\n 'NAMA_BAHAN' => 'Kertas grafik/millimeter 2cm',\n ),\n ));\n \n \n }", "function all(){\n try{\n $link= connecter_db();\n $rp=$link->prepare(\"select * from etudiant order by id desc\");\n $rp->execute();\n $resultat= $rp->fetchAll(); \n\n return $resultat;\n }catch(PDOException $e ){\n die (\"erreur de recuperation des etudiants dans la base de donnees \".$e->getMessage());\n }\n\n}", "public function selectdata(){\n$this->autoRender=false;\n$data=$this->connection->execute(\"select * from users\")->fetchAll();\nprint_r($data);\n}", "public function busca_alunos(){\n\n\t\t\t$sql = \"SELECT * FROM aluno\";\n\n\t\t\t/*\n\t\t\t*isntrução que realiza a consulta de animes\n\t\t\t*PDO::FETCH_CLASS serve para perdir o retorno no modelo de uma classe\n\t\t\t*PDO::FETCH_PROPS_LATE serve para preencher os valores depois de executar o contrutor\n\t\t\t*/\n\n\t\t\t$resultado = $this->conexao->query($sql, PDO::FETCH_CLASS | PDO::FETCH_PROPS_LATE, 'Aluno');\n\n $alunos = [];\n\n foreach($resultado as $aluno){\n $alunos[] = $aluno;\n }\n\n \t\t\treturn $alunos;\n\t\t}", "function tambah_data($tabel,$data)\n {\n // http://thisinterestsme.com/pdo-prepared-multi-inserts/\n $rowsSQL = array();\n // buat bind param Prepared Statement\n $toBind = array();\n // list nama kolom\n $columnNames = array_keys($data[0]);\n // looping untuk mengambil isi dari kolom / values\n foreach($data as $arrayIndex => $row){\n $params = array();\n foreach($row as $columnName => $columnValue){\n $param = \":\" . $columnName . $arrayIndex;\n $params[] = $param;\n $toBind[$param] = $columnValue;\n }\n $rowsSQL[] = \"(\" . implode(\", \", $params) . \")\";\n }\n $sql = \"INSERT INTO $tabel (\" . implode(\", \", $columnNames) . \") VALUES \" . implode(\", \", $rowsSQL);\n $row = $this->db->prepare($sql);\n //Bind our values.\n foreach($toBind as $param => $val){\n $row ->bindValue($param, $val);\n }\n //Execute our statement (i.e. insert the data).\n return $row ->execute();\n }", "public function displaymahasiswa()\r\n {\r\n $query = \"select * from data_mahasiswa\";\r\n return $this->db->query($query);\r\n }", "public function data_mata_kuliah()\n\t{\n\t\t$query1 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Analisis Kimia'\";\n\t\t$query2 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query3 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Pengolahan Limbah Industri'\";\n\t\t$query4 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Analisis Kimia'\";\n\t\t$query5 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query6 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Pengolahan Limbah Industri'\";\n\t\t$data['semester1A'] = $this->m_aka->query_aka($query1);\n\t\t$data['semester2A'] = $this->m_aka->query_aka($query4);\n\t\t$data['semester1B'] = $this->m_aka->query_aka($query2);\n\t\t$data['semester2B'] = $this->m_aka->query_aka($query5);\n\t\t$data['semester1C'] = $this->m_aka->query_aka($query3);\n\t\t$data['semester2C'] = $this->m_aka->query_aka($query6);\n\t\t$data['data'] = $this->m_aka->data_mata_kuliah(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'mata_kuliah/data_mata_kuliah';\n\t\t$this->load->view('content', $data);\n\t}", "function SHOWALL(){\r\n\r\n $stmt = $this->db->prepare(\"SELECT * FROM edificio\");\r\n $stmt->execute();\r\n $edificios_db = $stmt->fetchAll(PDO::FETCH_ASSOC);\r\n $alledificios = array(); //array para almacenar los datos de todos los edificios\r\n\r\n //Recorremos todos las filas de edificios devueltas por la sentencia sql\r\n foreach ($edificios_db as $edificio){\r\n //Introducimos uno a uno los edificios recuperados de la BD\r\n array_push($alledificios,\r\n new EDIFICIO_Model(\r\n $edificio['edificio_id'],$edificio['nombre_edif'],$edificio['direccion_edif']\r\n ,$edificio['telef_edif'],$edificio['num_plantas'],$edificio['agrup_edificio']\r\n )\r\n );\r\n }\r\n return $alledificios;\r\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('obats')->truncate();\n \n $data =[\n ['id'=> 1, 'id_obat' => 'konimexsanbe', 'nama_obat' => 'Konimex', 'keterangan' => 'Obat sakit kepala', 'perusahaan' => 'SANBE', 'jenis'=>'TABLET', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=> 2, 'id_obat' => 'sanmolsanbe', 'nama_obat' => 'Sanmol', 'keterangan' => 'Obat penurun panas', 'perusahaan' => 'SANBE', 'jenis'=>'TABLET', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=> 3, 'id_obat' => 'decolgensanbe', 'nama_obat' => 'Decolgen', 'keterangan' => 'Obat flu', 'perusahaan' => 'SANBE', 'jenis'=>'TABLET', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=> 4, 'id_obat' => 'konidinsanbe', 'nama_obat' => 'Konidin', 'keterangan' => 'Obat batuk cair', 'perusahaan' => 'SANBE', 'jenis'=>'SIRUP', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime]\n ];\n DB::table('obats')->insert($data);\n }", "public function getAllDataGejala()\n {\n $query = $this->db->query('SELECT * FROM tb_gejala');\n return $query->result();\n }", "function db_dispense($table,$data){\n\t$db=R::dispense($table);\n\tforeach ($data as $key => $value) {\n\t\t$db->$key=$value;\n\t}\n\tR::store( $db );\n}", "public function tratarDados(){\r\n\t\r\n\t\r\n }", "public function importFromOraDB() {\n $main_db_ip = System::getInstance()->get('ORA_DB_HXWEB_IP');\n $main_db_port = System::getInstance()->get('ORA_DB_HXWEB_PORT');\n $latency = pingDomain($main_db_ip, $main_db_port);\n \n // not reachable\n if ($latency > 999 || $latency == '') {\n Logger::getInstance()->error(__METHOD__.': 無法連線主DB,無法進行匯入收件字快取資料庫。');\n return false;\n }\n\n $db = new OraDB();\n $sql = \"select * from MOIADM.RKEYN_ALL t\";\n $db->parse($sql);\n $db->execute();\n $rows = $db->fetchAll();\n $this->clean();\n $count = 0;\n foreach ($rows as $row) {\n $this->replace($row);\n $count++;\n }\n\n Logger::getInstance()->info(__METHOD__.': 匯入 '.$count.' 筆資料。 【RKEYN_ALL.db、RKEYN_ALL table】');\n\n return $count;\n }", "private function fetchDataFromDB($sql){\r\n $dbOps = new DBOperations();\r\n $dataFromDB = $dbOps->fetchData($sql);\r\n return $dataFromDB; \r\n }", "public function run()\n {\n DB::table('analisa_kursus_bahagian_b')->insert([[\n 'kursus' => 'Pengurusan pejabat',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Kepimpinan',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan Strategik',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pemikiran kreatif/selari',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Analytical Decision Making',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Penyeliaan berkesan',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Komunikasi berkesan',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan fail dan rekod',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan masa',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengendalian mesyuarat dan Penulisan minit berkualiti',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Perundingan berkesan',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Financial Reporting Standards and Accounting',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Auditing, assurance and risk management',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Taxation',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Management accounting and strategic management',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Transform to perform - The new emerging finance leaders',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pembangunan individu dan organisasi berintegriti',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Motivasi diri dan kecemerlangan diri',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pemanduan berhemah',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengukuhan Pasukan (Team Building)',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan stress',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Perhubungan perusahaan',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Penyelenggaraan fail dan rekod',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'mentoring and coaching',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'manual prosedur kerja',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'penulisan surat dan memo berkualiti',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'bahasa inggeris/mandarin/jepun',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'pengurusan projek di tapak bina',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kesihatan, keselamatan dan persekitaran (HSE) management system',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus green building index (GBI)',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Qlassic',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'International standards organization (ISO)',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus microsoft word 2007',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus microsoft excel 2007',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus microsoft power point 2007',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan Emel/Internet',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'pengurusan Portal/AutoCad',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ]\n ]);\n }", "function tampilkan(){\r\n\t\t\t$query \t= \"SELECT * FROM data\";\r\n\t\t\treturn result($query);\r\n\t\t}", "public function fetchAll(){\n $adapter = $this->adapter;\n $sql = new Sql($this->adapter);\n $select = $sql->select();\n $select->from('flota');\n $selectString = $sql->getSqlStringForSqlObject($select);\n $data = $adapter->query($selectString, $adapter::QUERY_MODE_EXECUTE);\n \n return $data;\n }", "public function getMaquinas() {\n\n\t\t $command = \\Yii::$app->db_mysql;\n\t\t $sql=\"\n\t\t\tSELECT *\n\t\t\tFROM pdp_maquina\n\t\t\t \n\t\t \";\n\t\t $result =$command->createCommand($sql)\n\t\t\t\t\t\t\t->queryAll();\n\t\t \n\t\treturn $result;\n\t\t\n\t}", "function getDataPararel($conn,$key) {\n\t\t\t$sql = \"select k.kelasmk, k.dayatampung, k.jumlahpeserta from \".static::table('ak_kelas').\" k\n\t\t\t\t\twhere \".static::getCondition($key,'thnkurikulum,kodemk,kodeunit,periode','k').\"\n\t\t\t\t\torder by k.kelasmk\";\n\t\t\t\n\t\t\treturn $conn->GetArray($sql);\n\t\t}", "function semuaMahasiswa($query)\n{\n //karena $conn yang ada di file database.php berada diluar function semuaMahasiswa. jadi buat variable global untuk memanggilnya\n // agar variable $conn dapat digunakan\n global $conn;\n\n // array kosong untuk menyimpan dataMahasiswa\n\n $dataMahasiswa = $conn->query($query);\n return $dataMahasiswa; // untuk membuat function ini bernilai data 'dataMahasiswa'\n}", "public function getAllMahasiswa()\r\n {\r\n $this->db->query('SELECT * FROM ' . $this->table);\r\n return $this->db->resultSet();\r\n }", "function tampil_mahasiswa($id_mhs){\n\t\t\tglobal $con;\n\n\t\t\t$query=mysqli_query($con, \"SELECT a.*,b.*\n\t\t\t\t\t\t\t\t\t\tFROM tb_mahasiswa a,tb_prodi b \n\t\t\t\t\t\t\t\t\t\tWHERE a.id_prodi=b.id_prodi\n\t\t\t\t\t\t\t\t\t\tAND a.id_mhs='$id_mhs'\");\n\t\t\twhile($row=mysqli_fetch_array($query))\n\t\t\t\t$data[] = $row;\n\n\t\t\t\treturn $data;\n\t\t}" ]
[ "0.67226934", "0.6349393", "0.63246936", "0.6273119", "0.6261216", "0.6241883", "0.6208263", "0.61770004", "0.6175767", "0.61625063", "0.6153764", "0.6153557", "0.6125575", "0.60748523", "0.6011169", "0.6004141", "0.6003991", "0.59848", "0.59411055", "0.5935175", "0.5933395", "0.59141296", "0.5913797", "0.5903536", "0.59009707", "0.58966875", "0.58956176", "0.5895393", "0.58828264", "0.5854021", "0.5852818", "0.585158", "0.5851009", "0.58452094", "0.58448935", "0.58442193", "0.5829554", "0.5820502", "0.5818324", "0.58145607", "0.57968557", "0.5784416", "0.577867", "0.5774778", "0.5760752", "0.5759456", "0.57584876", "0.5749857", "0.5745726", "0.5742129", "0.5732735", "0.5730221", "0.57162243", "0.5707189", "0.570348", "0.57015926", "0.5688526", "0.56852233", "0.5683742", "0.5682989", "0.568193", "0.5673256", "0.5672728", "0.5663369", "0.56568736", "0.56568074", "0.5656567", "0.56512254", "0.56498086", "0.56459695", "0.56399643", "0.56393427", "0.5628855", "0.5626855", "0.5624662", "0.5614827", "0.56088454", "0.560829", "0.56080693", "0.5607453", "0.5601229", "0.5598667", "0.55871475", "0.55823827", "0.5581728", "0.55809873", "0.558087", "0.5580637", "0.55806273", "0.55806094", "0.55761427", "0.5573699", "0.55726403", "0.5569748", "0.5565345", "0.55641997", "0.55622077", "0.5555706", "0.55539227", "0.55537677", "0.55504495" ]
0.0
-1
ambil data dari db
function dropdown_perusahaan() { $result = $this->db->get('tbl_perusahaan'); // bikin array // please select berikut ini merupakan tambahan saja agar saat pertama // diload akan ditampilkan text please select. $dd[''] = 'Please Select'; if ($result->num_rows() > 0) { foreach ($result->result() as $row) { // tentukan value (sebelah kiri) dan labelnya (sebelah kanan) $dd[$row->id_perusahaan] = $row->nama_perusahaan; } } return $dd; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ambil_data(){\n\t\t$this->db->order_by($this->id_admin,$this->order);\n\t\treturn $this->db->get($this->nama_table)->result();\n\t}", "function ambil_data()\n \t{\n \t\t$this->db->distinct();\n \t\t$this->db->select('bk.id_buku, s.nama_supplier, bk.judul, bk.tema, bk.penulis, bk.harga');\n \t\t$this->db->from('buku bk');\n \t\t$this->db->join('supplier s', 's.id_supplier = bk.id_supplier');\n \t\treturn $this->db->get($this->nama_table)->result();\n\n \t\t$data['buku'] = $this->db->order_by($this->id, $this->order);\n \t\treturn $this->db->get($this->nama_table)->result();\n \t}", "public function ambildata_perusahaan(){\n\t\t$query=$this->db->query(\"SELECT * FROM tb_perusahaan\");\n\t\treturn $query->result_array();\n\t}", "function ambil_data(){ //fungsi yang akan mengambil data pada table user\n\t\treturn $this->db->get('user'); //mengambil data dari database, mengembalikan data yang ditangkap pada controller yang memanggil function ambil_data\n\t}", "function allinea_db(){\n\t\tif ($this->attributes['BYTB']!='' ) $this->fields_value_bytb($this->attributes['BYTB']);\n\t\tif ($this->attributes['TB']!='no'){\n\t\t\t$i=0;\n\t\t\tforeach ($this->values as $key => $val){\n\t\t\t\t$ret[$i]=\"{$key} NUMBER\";\n\t\t\t\t$i++;\n\t\t\t\t$ret[$i]=\"D_{$key} VARCHAR2(200 CHAR)\";\n\t\t\t\t$i++;\n\t\t\t}\n\t\t\treturn $ret;\n\t\t}\n\t\telse return ;\n\t}", "public function readDataPerbaikanBelum(){\n $sql = \"SELECT c.tanggal,c.nomor,c.no_inventaris,c.nama_user,b.cost_center,c.no_ex,GROUP_CONCAT(e.pekerjaan SEPARATOR '<br>') as pekerjaan FROM entri c,perbaikan e,kendaraan a,user b WHERE c.nomor = e.id_entri AND a.no_inventaris = c.no_inventaris AND c.id_status = 1 AND b.id_user = a.id_user GROUP BY c.nomor ORDER BY c.tanggal DESC\";\n $query = $this->db->query($sql);\n return $query;\n }", "function tampil_data($tabel)\n {\n $row = $this->db->prepare(\"SELECT * FROM sms\");\n $row->execute();\n return $hasil = $row->fetchAll();\n }", "public function ambilDataBarang($id)\n {\n return Yii::app()->db->createCommand(\"\n\t\t\t\t\t\t\tselect\n\t\t\t\t\t\t\t\tb.nama,\n\t\t\t\t\t\t\t\tb.barcode,\n\t\t\t\t\t\t\t\tsb.nama satuan,\n\t\t\t\t\t\t\t\t(select harga_beli from pembelian_detail where barang_id=:barangId\n\t\t\t\t\t\t\t\torder by id desc limit 1) harga_beli,\n\t\t\t\t\t\t\t\t(select harga\n\t\t\t\t\t\t\t\tfrom barang_harga_jual\n\t\t\t\t\t\t\t\twhere barang_id =:barangId\n\t\t\t\t\t\t\t\torder by id desc limit 1) harga_jual,\n\t\t\t\t\t\t\t\t(select harga\n\t\t\t\t\t\t\t\tfrom barang_harga_jual_rekomendasi\n\t\t\t\t\t\t\t\twhere barang_id =:barangId\n\t\t\t\t\t\t\t\torder by id desc limit 1) rrp\n\t\t\t\t\t\t\tfrom barang b\n\t\t\t\t\t\t\tleft join barang_satuan sb on sb.id = b.satuan_id\n\t\t\t\t\t\t\twhere b.id=:barangId\n\t\t\t\t\t\t\t\")\n ->bindParam(':barangId', $id)\n ->queryRow();\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 }", "function ambilSemuaDataHasilHitung() {\n\tglobal $conn;\n\n\t$data = [];\n\t$query = \"SELECT * FROM `hasil_hitung`\";\n\t$hasil = $conn->query($query);\n\n\tif ($hasil->num_rows > 0) {\n\t\twhile ($barisData = $hasil->fetch_assoc()) {\n\t\t\t$data[] = $barisData;\n\t\t}\n\t}\n\n\treturn $data;\n}", "function tampil_jadwal(){\n\t\t\tglobal $con;\n\n\t\t\t$query=mysqli_query($con, \"select * from tb_jadwal\");\n\t\t\twhile($row=mysqli_fetch_array($query))\n\t\t\t\t$data[] = $row;\n\n\t\t\t\treturn $data;\n\t\t}", "public function modelFetchAll(){\n\t\t\t//lay bien ket noi de thao tac csdl\n\t\t\t$conn = Connection::getInstance();\n\t\t\t//thuc hien truy van, tra ket qua ve mot object\n\t\t\t$query = $conn->query(\"select * from phongban\");\n\t\t\t//tra ve tat ca cac ban ghi\n\t\t\treturn $query->fetchAll();\n\t\t}", "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 tabel_data()\n {\n $tampil = $this->koneksi()->prepare(\"SELECT id FROM tb_users\");\n $tampil->execute();\n $tampil->setFetchMode(PDO::FETCH_ASSOC);\n if (count($tampil)>0){\n while ($data=$tampil->fetch(PDO::FETCH_ORI_NEXT)){\n $user_id_array [] = $data['id'];\n }\n }\n\n $tampil = $this->koneksi()->prepare(\"SELECT id FROM tb_lbb\");\n $tampil->execute();\n $tampil->setFetchMode(PDO::FETCH_ASSOC);\n if (count($tampil)>0){\n while ($data=$tampil->fetch(PDO::FETCH_ORI_NEXT)){\n $lbb_id_array [] = $data['id'];\n }\n }\n\n foreach ($user_id_array as $user_id){\n foreach ($lbb_id_array as $lbb_id){\n $rating = \"0\";\n $tampil = $this->koneksi()->prepare(\"SELECT rating FROM tb_rating WHERE user_id=:user_id AND lbb_id=:lbb_id\");\n $tampil->bindParam(':user_id', $user_id);\n $tampil->bindParam(':lbb_id', $lbb_id);\n $tampil->execute();\n $tampil->setFetchMode(PDO::FETCH_ASSOC);\n if (count($tampil)>0){\n while ($data=$tampil->fetch(PDO::FETCH_ORI_NEXT)){\n $rating = $data['rating'];\n }\n }\n $tabel_data [$user_id] [$lbb_id] = $rating;\n }\n }\n\n return $tabel_data;\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 fetchDataBencana(){\n\n try {\n return Pemohon::find();\n } catch (\\Exception $e) {\n return [];\n }\n \n }", "public function ObtenerAvionesBD(){\n $aviones=DB::table('avion')\n ->get();\n return $aviones;\n }", "function datagolongan() {\n\t\t\t\t$koneksi = $this->koneksi;\n\t\t\t\t// SQL\n\t\t\t\t$query\t\t\t= \"SELECT * FROM golongan\";\n\t\t\t\t\n\t\t\t\t$sql\t\t\t= mysqli_query($koneksi,$query);\n\t\t\t\t\n\t\t\t\treturn $sql;\n\t\t\t}", "public function getDataToIza(){\n\n $criteria=new CDbCriteria;\n $criteria->select='AVG(result) as result, koef, name_post, name_vesh, id_posti, PDK_ss, id_vechestva';\n $criteria->group='name_vesh';\n $res=Allresult::model()->findAll($criteria);\n $restoret=\"\";\n // var_dump($res);\n foreach($res as $oneres){\n $restoret.='[\"'.$oneres->name_vesh.'\", '.pow(($oneres->result/$oneres->PDK_ss),$oneres->koef).'],';\n }\n //\n return substr($restoret, 0, strlen($restoret)-1);\n }", "public function ambildata_admin(){\n\t\t$query=$this->db->query(\"SELECT * FROM tb_admin\");\n\t\treturn $query->result_array();\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 }", "public function fullDataBase()\n {\n print \"<table cellpadding='10' border=solid bordercolor=black>\";\n print\"<tr>\n <td>ROW</td> <td>EXCHANGE</td>\n <td>NAME</td> <td>IPO</td>\n <td>SYMBOL</td> <td>PRICE</td>\n <td>CAP</td> <td>UPDATED</td>\n <td>SECTOR</td> <td>INDUSTRY</td>\n </tr>\";\n $sql = \"SELECT * FROM companies ORDER BY ipodate DESC, cap DESC\";\n\n foreach ($this->conn->query($sql) as $row) {\n print \"<tr> <td nowrap>\";\n print $row['id'] . \"</td><td nowrap>\";\n print $row['stockexchange'] . \"</td><td nowrap>\";\n print $row['name'] . \"</td><td nowrap>\";\n print $row['ipodate'] . \"</td><td nowrap>\";\n print $row['symbol'] . \"</td><td nowrap>\";\n print $row['price'] . \"</td><td nowrap>\";\n print $row['cap'] . \"</td><td nowrap>\";\n print $row['created_at'] . \"</td><td nowrap>\";\n print $row['sector'] . \"</td><td nowrap>\";\n print $row['industry'] . \"</td></tr>\";\n }\n print \"</table>\";\n }", "function tampil_data(){\n\t\t//query select user\n\t\t$data = mysqli_query($this->conn, \"SELECT * FROM table_1\");\n\t\twhile($d = mysqli_fetch_array($data)){\n\t\t\t$hasil[] = $d;\n\t\t}\n\t\treturn $hasil;\n\n\t}", "public function tampil_data(){\n $sql= \"Select * From penjualan Order By id_penjualan DESC\";\n $data=$this->konek->query($sql);\n while ($row=mysqli_fetch_array($data)) {\n $hasil[]=$row;\n }\n return $hasil;\n }", "public function dataMahasiswa()\n\t{\n\t\t$this->db->select('*');\n\t\t$this->db->from('tb_mahasiswa');\n\t\t$this->db->order_by('nim', 'asc');\n\t\t$data = $this->db->get('');\n\t\treturn $data;\n\t}", "function recuperer_bsm_entier(){\n global $db;\n $sql = \"SELECT * FROM bsm \";\n $req = $db->prepare($sql);\n $req-> execute();\n $results = array();\n while($rows = $req->fetchObject()){\n $results[] = $rows;\n }\n return $results;\n}", "function ambil_data_on_going()\n\t{\n\t\t\n\t\t$sql=\"SELECT * FROM irena_view_sbsn_on_going\";\n\t\treturn $this->db->query($sql);\n\t}", "public function readAll(){\n //select all data\n $query = \"SELECT\n id, num_compte, cle_rib, num_agence, duree_epargne, frais, solde, created\n FROM\n \" . $this->table_name . \"\n ORDER BY\n num_compte\";\n \n $stmt = $this->conn->prepare( $query );\n $stmt->execute();\n \n return $stmt;\n }", "function tampil_data()\n\t{\n\t\t# perintah join digunakan untuk menggabungkan 2 table, yaitu penduduk dan kematian, agar data yang tampil lebih detail, karena pada tabel kematian hanya terdapat sedikit kolom, sehingga dengan menambah kolom nik, maka data yang ada di tabel penduduk juga otomatis terdeteksi karena perintah join, dengan aturan, nik harus sama antara tabel kematian dan nik yang ada di penduduk.\n\t\treturn $this->db->query(\"SELECT*FROM `kematian` left join penduduk on kematian.nik = penduduk.nik\")->result();\n\t}", "public function getAllMahasiswa(){\n // melakukan prepare query\n $this->db->query('SELECT * FROM '. $this->tabel);\n // eksekusi query dan mengambil semua data mahasiswa\n return $this->db->resultAll();\n }", "function ambil_data(){\n\t\treturn $this->db->get('user'); //digunakan untuk mengambil data yang ditangkap pada controller yang memanggil function ambil_data(controller belelajar pada function user())\n\t}", "public function load()\n {\n $pdo = $this->getDbConnection();\n $query = \"SELECT * FROM {$this->dbTable}\";\n $data = $pdo->query($query)->fetchAll(\\PDO::FETCH_ASSOC);\n\n foreach ($data as ['key' => $key, 'value' => $value]) {\n $this->setData($key, $value);\n }\n }", "public function data($id = null)\n\t{\n if($id != null)\n {\n return $this->db->get($this->table, \"*\", [$this->primaryKey => $id]);\n }\n else\n {\n // return $this->db->query(\"SELECT bidang.*, pegawai.nama FROM bidang JOIN pegawai ON bidang.nip = pegawai.nip\")->fetchAll(PDO::FETCH_ASSOC);\n return $this->db->query(\"SELECT * from bidang\")->fetchAll(PDO::FETCH_ASSOC);\n }\n\t}", "private function getData(){\n\t\tdb::getAdapter();\n\t\t\n\t\t$counter=0;\n\t\t$arrayFieldQuery=array();\n\t\tforeach($this->fields as $field){\n\t\t\t$arrayFieldQuery[$field]=$this->types[$counter];\n\t\t\t$counter++;\n\t\t}\n\t\t\n\t\t$counter=0;\n\t\t$arrayFilters=array();\n\t\tforeach($this->filters as $filter){\n\t\t\t$arrayFilters[$this->fields[$filter[0]]]=array(\"type\"=>$this->types[$filter[0]],\"value\"=>$filter[1]);\n\t\t}\n\t\t\n\t\tif(db::getFields($this->table,$arrayFieldQuery,$arrayFilters,$this->orderQuery,$this->limit,true)){\n\t\t\t$this->pages=ceil(((int)db::getCalculatedRows())/((int)$this->maxRowsPerPage));\n\t\t\t$this->maxRows=(int)db::getCalculatedRows();\n\t\t\twhile($row=db::fetch(db::$FETCH_TYPE_ASSOC)){\n\t\t\t\t$this->addRow($row);\n\t\t\t}\n\t\t}\n\t}", "public function get_Banco(){\r\n $conectar=parent::conexion();\r\n parent::set_names();\r\n $sql=\"select * from banco;\";\r\n $sql=$conectar->prepare($sql);\r\n $sql->execute();\r\n return $resultado=$sql->fetchAll(PDO::FETCH_ASSOC);\r\n }", "public function tampilDataGalang(){\n\t\t\n\t}", "function einstellungen_data ()\n\t{\n\t\t$sql = sprintf(\"SELECT * FROM %s WHERE bgalset_id='1'\",\n\t\t\t$this->db_praefix.\"ecard_einstellungen\"\n\t\t);\n\t\t$temp_return = $this->db->get_row($sql, ARRAY_A);\n\t\treturn $temp_return;\n\t}", "protected function importDatabaseData() {}", "function getInfosBanque($id_bqe=NULL,$id_ag=NULL) {\n\n global $dbHandler;\n\n $db = $dbHandler->openConnection();\n $sql = \"SELECT * FROM adsys_banque\";\n if ($id_bqe != NULL) {\n if ($id_ag == NULL)\n $sql .=\" WHERE id_banque = $id_bqe\";\n else\n $sql .=\" WHERE id_banque = $id_bqe and id_ag = $id_ag \";\n }\n elseif ($id_ag != NULL) $sql .=\" WHERE id_ag = $id_ag\";\n $sql.= \";\";\n\n $result=$db->query($sql);\n if (DB::isError($result)) {\n $dbHandler->closeConnection(false);\n signalErreur(__FILE__,__LINE__,__FUNCTION__);\n }\n\n $dbHandler->closeConnection(true);\n\n if ($result->numRows() == 0) return NULL;\n\n while ( $row = $result->fetchRow(DB_FETCHMODE_ASSOC) )\n $DATAS[$row[\"id_banque\"]] = $row;\n\n return $DATAS;\n\n}", "public function getAllData($table){\n $sql = \"select * from $table\";\n $this->execute($sql);\n if($this->num_rows() == 0){\n $data = 0;\n }\n else {\n while($datas = $this->getData()){\n $data[] = $datas;\n }\n }\n return $data;\n }", "public function getCommondata()\n {\n $select = $this->select()\n // ->setIntegrityCheck(false)\n ->from(array('album' => 'album'),array('Id','name_n'))\n ->join('album_det','album_det.Id = album.Id',array('album_det.Id'));\n // $result=$this->fetchAll($hhh);\n $result = $this->fetchAll($select);\n \n echo \"<pre>\";\n print_r($result);exit;\n return $result;\n\n }", "function ambil_data(){\n\t\treturn $this->db->get('user');\n\t}", "public function run()\n {\n DB::table('harga_obats')->truncate();\n $data =[\n ['id'=>1, 'id_obat'=>'konimexsanbe', 'harga'=>10000, 'tgl_awal'=>new DateTime, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=>2, 'id_obat'=>'IBUPKIMITABLOBAT', 'harga'=>5000, 'tgl_awal'=>new DateTime, 'created_at' => new DateTime, 'updated_at' => new DateTime]\n ];\n DB::table('harga_obats')->insert($data);\n }", "function data_banco($databr) {\n\tif (!empty($databr)){\n\t$p_dt = explode('/',$databr);\n\t$data_sql = $p_dt[2].'-'.$p_dt[1].'-'.$p_dt[0];\n\treturn $data_sql;\n\t}\n}", "function all(){\n\t\t\t$query = \"SELECT * FROM khach_hang\";\n\t\t\t$data = array();\n\t\t\t$result = $this->conn->query($query);\n\t\t\twhile($row = $result->fetch_assoc()) {\n\t\t\t\t$data[] =$row;\n\t\t\t}\n\t\t\treturn $data;\n\n\t\t}", "public function getAllAMt() {\n $data = $this->db->query(\"select * from pegawai where (jabatan='SUPIR' or jabatan='KERNET')\");\n return $data;\n }", "public function get_makanan_buahs()\n\t{\n\t\t$database = $this->db->select('*')\n\t\t\t\t\t->from('makanan_buah')\n\t\t\t\t\t->get()->result();\n\n\t\treturn $database;\n\t\t// Result in Object\n\t}", "public function get_all_alamat(){\n \n\t$query = $this->db->query(\"select *,case when gender = '1' then 'Pria' else 'Wanita' end as genderstatus,date_format(start_date,'%d %M %Y') as tanggalmasuknya from human_pa_md_emp_personal order by personnel_id asc\");\n\n \treturn $query;\n\t}", "function readAll(){\n \n $query = \"SELECT * FROM \".$this->table_name.\" ORDER BY id_alternatif ASC\";\n $stmt = $this->conn->prepare($query);\n $stmt->execute();\n\n return $stmt;\n }", "public function allData()\n {\n return DB::table('tbl_laporankeluar')\n ->leftJoin('tbl_sales', 'tbl_sales.id_sales', '=', 'tbl_laporankeluar.id_sales')\n ->leftJoin('tbl_produk', 'tbl_produk.id_produk', '=', 'tbl_laporankeluar.id_produk')\n ->orderBy('id_laporan', 'desc')\n ->get();\n }", "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 getAll()\n\t{\n\t\treturn $this->db->get('data_b')->result();\n\t}", "public function run()\n {\n DB::table(\"produk\")->insert([\n \t[\n \t\t\"nama\" => \"banner\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat banner\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"nota\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat nota\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"undangan\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat undangan\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"sticker print\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat sticker print\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"kartu nama\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat kartu nama\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"brosur\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat brosur\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"sticker sablon\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat sticker sablon\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"buku yaasin\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat buku yaasin\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"umbul-umbul kain\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat umbul-umbul kain\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"id card\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat id card\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"kalender\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat kalender\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"nama dada\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat nama dada\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"sablon plastik/tas/kaos\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat sablon plastik/tas/kaos\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"stempel\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat stempel\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t[\n \t\t\"nama\" => \"neon box (papan nama)\",\n \t\t\"harga_satuan\" => 2000,\n\t\t\t\t\"satuan\" => 'lembar',\n\t\t\t\t\"deskripsi\" => \"deskripsi singkat neon box (papan nama)\",\n \t\t\"created_by\" => \"1\",\n \t],\n \t\n ]);\n }", "function all2($cod_programa) {\n \n $sql = \"SELECT * FROM inasistencia_grupo_motivos\";\n \n return DB::query($sql);\n }", "private function list_data_sql()\n\t{\n\t\t$this->db\n\t\t\t->from('tweb_penduduk u')\n\t\t\t->join('tweb_keluarga d', 'u.id_kk = d.id', 'left')\n\t\t\t->join('tweb_wil_clusterdesa a', 'd.id_cluster = a.id', 'left')\n\t\t\t->join('tweb_penduduk_sex x', 'u.sex = x.id', 'left')\n\t\t\t->join('tweb_penduduk_agama g', 'u.agama_id = g.id', 'left')\n\t\t\t->join('tweb_status_dasar sd', 'u.status_dasar = sd.id', 'left')\n\t\t\t->join('log_penduduk log', 'u.id = log.id_pend', 'left')\n\t\t\t->join('ref_pindah rp', 'rp.id = log.ref_pindah', 'left')\n\t\t\t->where('u.status_dasar >', 1)\n\t\t\t->where_in('log.id_detail', array(2, 3, 4));\n\n\t\t$this->search_sql();\n\t\t$this->status_dasar_sql();\n\t\t$this->sex_sql();\n\t\t$this->agama_sql();\n\t\t$this->dusun_sql();\n\t\t$this->rw_sql();\n\t\t$this->rt_sql();\n\t}", "public function getAll(){\n $sqlQuery = \"SELECT * FROM \".$this->t_name.\"\";\n //prepate stamt;\n $stmt = $this->conn->prepare($sqlQuery);\n $stmt->execute();\n //kembalikan nilai stmt\n return $stmt;\n }", "protected function loadData(){\n\t\t//SELECT from \".self::TABLE_NAME.\"_data WHERE \".self::TABLE_NAME.\"_id=\".$this->id.\"\n\t\t\n\t\t//return the data\n\t\treturn array();\n\t}", "public function ambildata_psikolog(){\n\t\t$query=$this->db->query(\"SELECT * FROM tb_psikolog\");\n\t\treturn $query->result_array();\n\t}", "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 getDatabaseData()\n {\n $data = array();\n $sql = 'SELECT * FROM `' . $this->table . '`';\n $db_success = mysql_query($sql)\n or die('Laden der Daten fehlgeschlagen: ' . mysql_error());\n while ($row = mysql_fetch_array($db_success, MYSQL_ASSOC))\n {\n $data[] = $row;\n }\n return $data;\n }", "private function ajustarDataReporte()\r\n\t\t{\r\n\t\t\tself::setConexion();\r\n\t\t\t$this->_conn->open();\r\n\t\t\t$this->_transaccion = $this->_conn->beginTransaction();\r\n\r\n\t\t\t$tabla = $this->tableName();\r\n\r\n\t\t\t//lapso=2 and ano_impositivo<year(fecha_pago) and impuesto=9 and fecha_pago>='2014-06-01\r\n\t\t\t$sql = \"UPDATE {$tabla} SET codigo=301035900, nombre_impuesto='Deuda Morosa Por Tasas'\r\n\t\t\t WHERE lapso=2 AND ano_impositivo<year(fecha_pago) AND impuesto=9 AND fecha_pago>='2014-06-01'\";\r\n\r\n\t\t\t$result = $this->_conn->createCommand($sql)->execute();\r\n\t\t\tif ( $result ) {\r\n\t\t\t\t$this->_transaccion->commit();\r\n\t\t\t} else {\r\n\t\t\t\t$this->_transaccion->rollBack();\r\n\t\t\t}\r\n\t\t\t$this->_conn->close();\r\n\t\t\treturn $result;\r\n\t\t}", "public function run()\n {\n DB::table('alumno')->insert([\n 'alum_id' => '1',\n 'alum_dni' => '75406456',\n 'alum_ape' => 'CAVERO AVILA',\n 'alum_nom' => 'MARIA CARMEN',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2006-02-05',\n 'alum_grad' => '3',\n 'alum_apod' => '1',\n 'alum_user' => '75406456'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '2',\n 'alum_dni' => '75200134',\n 'alum_ape' => 'ALVAREZ AGUILAR',\n 'alum_nom' => 'JUAN DIEGO',\n 'alum_sexo' => '1',\n 'alum_fnac' => '2006-08-20',\n 'alum_grad' => '3',\n 'alum_apod' => '2',\n 'alum_user' => '75200134'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '3',\n 'alum_dni' => '75246604',\n 'alum_ape' => 'SALAZAR AVILA',\n 'alum_nom' => 'CARLA',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2006-07-11',\n 'alum_grad' => '3',\n 'alum_apod' => '3',\n 'alum_user' => '75246604'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '4',\n 'alum_dni' => '75650012',\n 'alum_ape' => 'ROBLES LACHI',\n 'alum_nom' => 'DIANA',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2005-01-06',\n 'alum_grad' => '4',\n 'alum_apod' => '4',\n 'alum_user' => '75650012'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '5',\n 'alum_dni' => '79520105',\n 'alum_ape' => 'CHUMPITAZ TACSA',\n 'alum_nom' => 'ELSA',\n 'alum_sexo' => '0',\n 'alum_fnac' => '2005-10-12',\n 'alum_grad' => '4',\n 'alum_apod' => '5',\n 'alum_user' => '79520105'\n ]);\n\n DB::table('alumno')->insert([\n 'alum_id' => '6',\n 'alum_dni' => '78415200',\n 'alum_ape' => 'ARROYO HUAMAN',\n 'alum_nom' => 'DAVID',\n 'alum_sexo' => '1',\n 'alum_fnac' => '2005-08-28',\n 'alum_grad' => '4',\n 'alum_apod' => '6',\n 'alum_user' => '78415200'\n ]);\n\n\n }", "public function run()\n {\n $data=[];\n for($i=0;$i<100;$i++){\n \t$temp['typeid']=rand(1,11);\n \t$temp['goods']=str_random(10);\n \t$temp['price']=rand(1,10000);\n \t$temp['picname']='/upload/14869794804653.jpg';\n \t$temp['descr']='<p><img src=\"/upload/baidu/1486979474670564.jpg\" title=\"1486979474670564.jpg\"/></p><p><img src=\"/upload/baidu/1486922430402045.jpg\" title=\"1486922430402045.jpg\"/></p>';\n \t$temp['num']=rand(1,1000);\n \t$temp['created_at']=date('Y-m-d H:i:s');\n \t$temp['updated_at']=date('Y-m-d H:i:s');\n $temp['szie']=rand(0,2);\n \t$temp['state']=1;\n $data[]=$temp;\n }\n \\DB::table('goods')->insert($data);\n }", "public function fillDataBase(){\n $conn = $this->connectdb();\n $tweets_total = $this->getTweets();\n foreach ($tweets_total as $page){\n foreach($page as $key){\n $title = $this->stripTitle($key->text);\n $prepared_title = mysqli_real_escape_string($conn,$title);\n if(!empty($key->entities->urls)){\n $url_source = $key->entities->urls[0]->url; \n $url_dispaly_source = $key->entities->urls[0]->display_url;\n }\n else{\n $url_source=\".\";\n $url_dispaly_source = \".\";\n }\n $tweet_url = $key->id;\n $tweet_date = $this->customDate($key->created_at);\n $user_name = $key->user->name;\n $user_screen_name= $key->user->screen_name;\n $user_image_src= $key->user->profile_image_url;\n $sql=\"INSERT INTO tweets (title, url_source, tweet_url_id, created_date, url_display_source, user_name, user_screen_name, user_logo) \"\n . \"VALUES('$prepared_title','$url_source','$tweet_url','$tweet_date','$url_dispaly_source','$user_name','$user_screen_name','$user_image_src')\";\n mysqli_query($conn, $sql);\n }\n }\n }", "private function userDataFromDB($all) {\n\n foreach ($all as $value) {\n\n $user_data = $this->users->find($value->userId);\n $value->name = $user_data->name;\n $value->mail = $user_data->email;\n $value->gravatar = $user_data->gravatar;\n }\n return $all;\n }", "function dataSelect() {\n\t\t\t\t$koneksi = $this->koneksi;\n\t\t\t\t// SQL\n\t\t\t\t$query\t\t\t= \"SELECT * FROM pegawai ORDER BY id ASC\";\n\t\t\t\t\n\t\t\t\t$sql\t\t\t= mysqli_query($koneksi,$query);\n\t\t\t\t\n\t\t\t\treturn $sql;\n\t\t\t}", "public function queryAll(){\n\t\t$sql = 'SELECT * FROM cbt_jadwal_ujian';\n\t\t$sqlQuery = new SqlQuery($sql);\n\t\treturn $this->getList($sqlQuery);\n\t}", "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 function getData(){\n\n //Connetto al database\n $conn = $this->connection->sqlConnection();\n\n $sql = $conn->prepare(\"SELECT * FROM compra\");\n\n //Eseguo la query\n $sql->execute();\n\n $dataArray = array();\n //Se ci sono dei valori\n if($sql->rowCount() > 1) {\n\n // Ciclo tutti i valori\n while ($row = $sql->fetch()) {\n array_push($dataArray, $row);\n }\n //Se c'è un solo valore lo inserisco\n }else if($sql->rowCount() == 1) {\n $dataArray = $sql->fetch();\n }\n $conn = null;\n return $dataArray;\n }", "static function get_data($table) {\r\n $rekete = \"SELECT * FROM \" . $table . \" ORDER BY created DESC\";\r\n $result = Functions::commit_sql($rekete, \"\");\r\n if (Functions::is_void($result))\r\n return false;\r\n else\r\n return $result;\r\n }", "function get_records_bahan(){\n\t\t$output=array();\n\t\t/*data request dari client*/\n\t\t$request = $this->m_master->request_datatable();\n\t\t/*Token yang dikrimkan client, akan dikirim balik ke client*/\n\t\t$output['draw'] = $request['draw'];\n\t\n\t\t/*\n\t\t $output['recordsTotal'] adalah total data sebelum difilter\n\t\t$output['recordsFiltered'] adalah total data ketika difilter\n\t\tBiasanya kedua duanya bernilai sama pada saat load default(Tanpa filter), maka kita assignment\n\t\tkeduaduanya dengan nilai dari $total\n\t\t*/\n\t\t/*Menghitung total desa didalam database*/\n\t\t$total = count($this->m_master->get_jenis_bahan());\n\t\t$output['recordsTotal']= $output['recordsFiltered'] = $total;\n\t\n\t\t/*disini nantinya akan memuat data yang akan kita tampilkan\n\t\t pada table client*/\n\t\t$output['data'] = array();\n\t\n\t\n\t\t/*\n\t\t * jika keyword tidak kosong, maka menjalankan fungsi search\n\t\t* untuk ditampilkan di datable\n\t\t* */\n\t\tif($request['keyword'] !=\"\"){\n\t\t\t/*menjalankan fungsi filter or_like*/\n\t\t\t$this->m_master->search_like($request['keyword'],$this->column_bahan());\n\t\t}\n\t\t/*Pencarian ke database*/\n\t\t$query = $this->m_master->get_jenis_bahan('',$this->column_bahan()[$request['column']],$request['sorting'],$request['length'],$request['start']);\n\t\n\t\n\t\t/*Ketika dalam mode pencarian, berarti kita harus\n\t\t 'recordsTotal' dan 'recordsFiltered' sesuai dengan jumlah baris\n\t\tyang mengandung keyword tertentu\n\t\t*/\n\t\tif($request['keyword'] !=\"\"){\n\t\t\t$this->m_master->search_like($request['keyword'],$this->column_bahan());\n\t\t\t$total = count($this->m_master->get_jenis_bahan());\n\t\t\t/*total record yg difilter*/\n\t\t\t$output['recordsFiltered'] = $total;\n\t\t}\n\t\n\t\n\t\t$nomor_urut=$request['start']+1;\n\t\tforeach ($query as $row) {\n\t\t\t//show in html\n\t\t\t$output['data'][]=array($nomor_urut,\n\t\t\t\t\t$row->nama_product,\n\t\t\t\t\t$row->nama_kategori,\n\t\t\t\t\t$row->nama_supplier,\n\t\t\t\t\t'<button type=\"button\" class=\"btn btn-success btn-circle\" title=\"Pilih Bahan\" onclick=\"ajaxcall(\\''.base_url('bo/'.$this->class.'/pilih_bahan').'\\',\\''.$row->id_product.'#'.$row->nama_product.'#'.$row->nama_kategori.'#'.$row->id_form_order.'\\',\\'splcart\\')\"><i class=\"icon-download-alt\"></i></button>'\n\t\t\t);\n\t\t\t$nomor_urut++;\n\t\t}\n\t\techo json_encode($output);\n\t}", "public function getAllData()\n\t{\n\t\treturn $this->db\n\t\t\t->where('row_status', 'A')\n\t\t\t->where('jabatan_karyawan', 'Admin')\n\t\t\t->get($this->_karyawan)\n\t\t\t->result();\n\t}", "public function run()\n {\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '1',\n 'merk_barang' => 'Single, AMP Single',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '2',\n 'merk_barang' => 'Media Stand HP Designjet 110/500 series 24',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '3',\n 'merk_barang' => 'Royal R775-18',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-03-01',\n 'idbarang_fk' => '4',\n 'merk_barang' => 'Mesin Ketik Brother GX6750',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-11-03',\n 'idbarang_fk' => '5',\n 'merk_barang' => 'Newmark NM - 03C',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '7',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP C13LG-7',\n 'nup' => '8',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP C13LG-7',\n 'nup' => '9',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP LTC 22',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'DATASCRIP C13LG-7',\n 'nup' => '11',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B204',\n 'nup' => '12',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Cupboard datascrip CBRG/LF05',\n 'nup' => '13',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Cupboard datascrip CBRG/LF05',\n 'nup' => '14',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Cupboard datascrip CBRG/ET C22',\n 'nup' => '15',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Lemari Arsip Brother B-20',\n 'nup' => '16',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Lemari Arsip Brother B-20',\n 'nup' => '17',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother cardek',\n 'nup' => '18',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother Cardek',\n 'nup' => '19',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-204',\n 'nup' => '20',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-304',\n 'nup' => '21',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-304',\n 'nup' => '22',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-304',\n 'nup' => '23',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'lemari Sliding door Brother B-304',\n 'nup' => '24',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'lemari Arsip Brother B-203',\n 'nup' => '25',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-28',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-203',\n 'nup' => '26',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-28',\n 'idbarang_fk' => '6',\n 'merk_barang' => 'Brother B-203',\n 'nup' => '27',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '3',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '4',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '6',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '7',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '8',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '9',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B-104',\n 'nup' => '11',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'DATASCRIP FCD4-7',\n 'nup' => '12',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'DATASCRIP FCD4-7',\n 'nup' => '13',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Brother B104',\n 'nup' => '14',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet B-104',\n 'nup' => '15',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet B-104',\n 'nup' => '16',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet B-104',\n 'nup' => '17',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-104',\n 'nup' => '18',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-104',\n 'nup' => '19',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-104',\n 'nup' => '20',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2019-04-05',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-103',\n 'nup' => '21',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2019-04-05',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-103',\n 'nup' => '22',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2019-04-05',\n 'idbarang_fk' => '7',\n 'merk_barang' => 'Filing Cabinet Brother B-103',\n 'nup' => '23',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // brangkas\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '8',\n 'merk_barang' => 'Dragon DR-A1',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // locker\n\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '1',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '2',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '3',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '4',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '5',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '6',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'DATASCRIP LC3-7',\n 'nup' => '7',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'Alba LC-506',\n 'nup' => '8',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '9',\n 'merk_barang' => 'Alba LC-506',\n 'nup' => '9',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // lemari display\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '10',\n 'merk_barang' => 'BROTHER B-304',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '10',\n 'merk_barang' => 'BROTHER B-304',\n 'nup' => '2',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '10',\n 'merk_barang' => 'BROTHER B-304',\n 'nup' => '3',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // CCTV\n 'tanggal' => '2017-10-05',\n 'idbarang_fk' => '11',\n 'merk_barang' => 'Paket CCTV ANALOG 1 MP 720P, 1 DVR BCH',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '11',\n 'merk_barang' => 'CCTV 9 Kamera',\n 'nup' => '2',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // white board\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '12',\n 'merk_barang' => '120X240',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '120X240',\n 'nup' => '2',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '120X240',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '90X120',\n 'nup' => '4',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '90X120',\n 'nup' => '5',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => '90X120',\n 'nup' => '6',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'GM Economi DF',\n 'nup' => '7',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'GM Economi DF',\n 'nup' => '8',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '9',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '10',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '11',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '12',\n 'merk_barang' => 'Nusantara',\n 'nup' => '12',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat penghancur Kertas\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '13',\n 'merk_barang' => 'Secure Maxi 24SC',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat penghancur Kertas\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '13',\n 'merk_barang' => 'Secure Maxi 24SC',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '1',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '2',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '3',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '4',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '5',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '6',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // mesin absensi\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '14',\n 'merk_barang' => 'FINGERSPOT REVO DUO 128BNC',\n 'nup' => '7',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // lASER POINTER\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '15',\n 'merk_barang' => 'Logitech Wireless Presenter R400',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // lASER POINTER\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '15',\n 'merk_barang' => 'Logitech Wireless Presenter R400',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '19',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '20',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '21',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '22',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2016-11-24',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'SONY VPL EX 230',\n 'nup' => '23',\n 'idruang_fk' => '26'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP575',\n 'nup' => '24',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-12-1',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP575',\n 'nup' => '25',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP515',\n 'nup' => '26',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP670',\n 'nup' => '27',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MX810 ST',\n 'nup' => '28',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP660',\n 'nup' => '29',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ MP660',\n 'nup' => '30',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ans',\n 'nup' => '31',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'DELL 161011D',\n 'nup' => '32',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'DELL 161011D',\n 'nup' => '33',\n 'idruang_fk' => '6'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'DELL 161011D',\n 'nup' => '34',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '35',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '36',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '37',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '38',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '39',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '40',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'BENQ 2800 Ansi',\n 'nup' => '41',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '42',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '43',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '44',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '45',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '46',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LCD Projector/Infocus\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '16',\n 'merk_barang' => 'Infocus Projector(IN226)',\n 'nup' => '47',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 70\" Size 180x180',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 70\" Size 180x180',\n 'nup' => '2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 84\" Size 213x213',\n 'nup' => '3',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Focusing Screen\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '17',\n 'merk_barang' => 'Screen Prokector G-lite Tripot 84\" Size 213x213',\n 'nup' => '4',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // papan pengumuman\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '18',\n 'merk_barang' => 'GM Announcement Board',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // papan pengumuman\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '18',\n 'merk_barang' => 'GM Announcement Board',\n 'nup' => '2',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '33',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '34',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '35',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '36',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2016-07-28',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Active MTO 120',\n 'nup' => '37',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '38',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '39',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '40',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '41',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '42',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '43',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '44',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '45',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '46',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '47',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '48',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '49',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '50',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '51',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '52',\n 'idruang_fk' => '4'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '53',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n //meja kayu sekretaris\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '54',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '55',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '56',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '57',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '58',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '59',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Kayu Jati Texwood',\n 'nup' => '60',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil 180x90x75',\n 'nup' => '61',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Credenza',\n 'nup' => '62',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '63',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '64',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Profil',\n 'nup' => '65',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Espana 1275',\n 'nup' => '66',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Espana 1275',\n 'nup' => '67',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Fatoni',\n 'nup' => '68',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Fatoni',\n 'nup' => '69',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Kerja Active Galant MTO 120',\n 'nup' => '70',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Kerja Active Galant MTO 120',\n 'nup' => '71',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja kerja kayu\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '19',\n 'merk_barang' => 'Meja Kerja Active Galant MTO 120',\n 'nup' => '72',\n 'idruang_fk' => '15'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '1',\n 'idruang_fk' => '5'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '4',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '5',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '7',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '8',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '9',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Stainless Chrome',\n 'nup' => '10',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Ushinto 9035',\n 'nup' => '11',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel 147',\n 'nup' => '12',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel 147',\n 'nup' => '13',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '14',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '15',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '16',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Isebel ',\n 'nup' => '17',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '18',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '19',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '20',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '21',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '22',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '23',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '24',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '25',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '26',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '27',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '28',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato NN ',\n 'nup' => '29',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '30',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '31',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '32',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '33',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '34',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '35',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '36',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '37',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '38',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '39',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '40',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '41',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '42',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '43',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '44',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '45',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '46',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '47',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '48',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '49',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '50',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '51',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '52',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '53',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '54',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '55',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '56',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '57',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '58',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '59',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '60',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '61',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '62',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '63',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '64',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '65',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '66',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '67',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '68',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '69',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '70',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '71',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '72',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '73',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '74',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '75',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '76',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '77',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '78',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '79',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '80',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '81',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '82',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '83',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '84',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '85',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '86',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '87',\n 'idruang_fk' => '26'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '88',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '89',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '90',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '91',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '92',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '93',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '94',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '95',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '96',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '97',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '98',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '99',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '100',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '101',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '102',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '103',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '104',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal(rk 2)\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '105',\n 'idruang_fk' => '26'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '106',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '107',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '108',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '109',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '110',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '111',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '112',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '113',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '114',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '115',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '116',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '117',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '118',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '119',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '120',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '121',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '122',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '123',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '124',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '125',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '126',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '127',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '128',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '129',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '130',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '131',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '132',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '133',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '134',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '135',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '136',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '137',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '138',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '139',\n 'idruang_fk' => '8'\n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '140',\n 'idruang_fk' => '8'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '141',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '142',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '143',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '144',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '145',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '146',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '147',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '148',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '149',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato MDN Chrome ',\n 'nup' => '150',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '151',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '152',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '153',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '154',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '155',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'OSCAR FHANTASI VH ',\n 'nup' => '156',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO 608T OSCAR HITAM ',\n 'nup' => '157',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO 608T OSCAR HITAM ',\n 'nup' => '158',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO OSCAR ',\n 'nup' => '159',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO OSCAR ',\n 'nup' => '160',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'USHINTO OSCAR ',\n 'nup' => '161',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '162',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '163',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '164',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '165',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '166',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato INN ',\n 'nup' => '167',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '168',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '169',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '170',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '171',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '172',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '173',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 485 OSCAR HITAM ',\n 'nup' => '174',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '175',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '176',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509',\n 'nup' => '177',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '178',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '179',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '180',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'FUTURA FTR509 ',\n 'nup' => '181',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '182',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '183',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '184',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '185',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '186',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '187',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '188',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '189',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '190',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '191',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '192',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '193',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA',\n 'nup' => '194',\n 'idruang_fk' => '8'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '195',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal SAC\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '196',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal gudang\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '197',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal gudang\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '198',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal gudang\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose yamato AA ',\n 'nup' => '199',\n 'idruang_fk' => '18'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '200',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '201',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '202',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '203',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '204',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '205',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '206',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '207',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '208',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '209',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '210',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '211',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '212',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '213',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '214',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 1a\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '215',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '216',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '217',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '218',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '219',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '220',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '221',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '222',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '223',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '224',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '225',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '226',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '227',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '228',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '229',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '230',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '231',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '232',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '233',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '234',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '235',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '236',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '237',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '238',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '239',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '240',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '241',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '242',\n 'idruang_fk' => '6'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal BASDA\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '243',\n 'idruang_fk' => '5'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '244',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '245',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '246',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '247',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '248',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '249',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '250',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '251',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '252',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '253',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '254',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '255',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '256',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '257',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '258',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose cosmos MNR',\n 'nup' => '259',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL MR 357TLPM',\n 'nup' => '260',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL MR 357TLPM',\n 'nup' => '261',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '262',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '263',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '264',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '265',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'CISEBEL 311 TLLPP',\n 'nup' => '266',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '67',\n 'idruang_fk' => '13'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '268',\n 'idruang_fk' => '13'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '269',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '270',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '270',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '271',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal OEMRO\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '272',\n 'idruang_fk' => '11'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '273',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '274',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '275',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '276',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '277',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '278',\n 'idruang_fk' => '20'\n \n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '278',\n 'idruang_fk' => '20'\n \n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '279',\n 'idruang_fk' => '20'\n \n )); DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '280',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'ISEBEL 311 TLLPP',\n 'nup' => '281',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '282',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '283',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '284',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '285',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '286',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '287',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '288',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '289',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '290',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '291',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '292',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '293',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '294',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '295',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '296',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '297',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '298',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '299',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '300',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '301',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '302',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 3\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '303',\n 'idruang_fk' => '20'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '304',\n 'idruang_fk' => '21'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '305',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '306',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '307',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '308',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '309',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '310',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '311',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '312',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '313',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '314',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '315',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '316',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '317',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '318',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '319',\n 'idruang_fk' => '22'\n \n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '320',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '321',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '322',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '323',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '324',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '325',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '326',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '327',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '328',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '329',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '329',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '330',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '331',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '332',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '333',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '334',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '335',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '336',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '337',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '338',\n 'idruang_fk' => '22'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal kuliah 4\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '339',\n 'idruang_fk' => '1'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '340',\n 'idruang_fk' => '12'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '341',\n 'idruang_fk' => '12'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '342',\n 'idruang_fk' => '12'\n \n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '343',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '344',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '345',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '363',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '347',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '348',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '349',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '350',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '351',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi kasie\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '352',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '353',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '354',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '355',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '356',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '357',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi keuangan\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '358',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '360',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '361',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '362',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T906',\n 'nup' => '363',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '364',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '365',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '366',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '367',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '368',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '369',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '370',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '371',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '372',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '373',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '374',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '375',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '376',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '377',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '378',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '379',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '380',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '381',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '382',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '383',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '384',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '385',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '386',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Tiger T99 Hitam',\n 'nup' => '387',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '388',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '389',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '400',\n 'idruang_fk' => '18'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '401',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '402',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '403',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '404',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '405',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '406',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose',\n 'nup' => '407',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '408',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '409',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '410',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '411',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '412',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '413',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '414',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '415',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '416',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '417',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '418',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '419',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '420',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '421',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '422',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '423',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '424',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '425',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '426',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '427',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '428',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '429',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gudang\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '430',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '431',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '432',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '433',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '434',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '435',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '436',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '437',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '438',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '439',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '440',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '441',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '442',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '443',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '444',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '445',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '446',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '447',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '448',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '449',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi gis\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '450',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '451',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '452',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '453',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '454',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '455',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '456',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '457',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '458',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '459',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '460',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '461',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '462',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '463',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '464',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '465',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '466',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '467',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '468',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '469',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '470',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '471',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '472',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '473',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '474',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '475',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '476',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '477',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '478',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '479',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '480',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '481',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '482',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '483',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '484',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '485',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '486',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '487',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '488',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '489',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '490',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '491',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '492',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '493',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '494',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '495',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '496',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '497',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '498',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '499',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '500',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '501',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '502',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '503',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '504',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '505',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '506',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose MPR',\n 'nup' => '507',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chairman VC 1055',\n 'nup' => '508',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-18',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chairman VC 1055',\n 'nup' => '509',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '510',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '511',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '512',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '513',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '514',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '515',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '516',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '517',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '518',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 4\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '519',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '520',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '521',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '522',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '523',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi High Point ECO-01',\n 'nup' => '524',\n 'idruang_fk' => '24'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '525',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '526',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '527',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '528',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '529',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '530',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '531',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '532',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '533',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '534',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '535',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '536',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '537',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '538',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '539',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '540',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '541',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '542',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '543',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '544',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '545',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '546',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '547',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '548',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '549',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '550',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '551',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '552',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '553',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '554',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '555',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '556',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '557',\n 'idruang_fk' => '19'\n ));DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '558',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '559',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '560',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '561',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '562',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '563',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '564',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '565',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '566',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '567',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '568',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '569',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '570',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '571',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '572',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '573',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '574',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '575',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '576',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '577',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '576',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '577',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '578',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '578',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '579',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '580',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '581',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '582',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '583',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '584',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '585',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '586',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '587',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '588',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '589',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '590',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '591',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '592',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '593',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '594',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '595',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '596',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '597',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '598',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '599',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '600',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '601',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '602',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '603',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '604',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '605',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '606',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '607',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '608',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '609',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '610',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '611',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '612',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '613',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '614',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '615',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '616',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '617',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '618',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '619',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '620',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '621',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '622',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '623',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '624',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '625',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 1a\n 'tanggal' => '2013-11-07',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Type Cosmos MNR',\n 'nup' => '626',\n 'idruang_fk' => '19'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '627',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '628',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '629',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '630',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '631',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '632',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '634',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '635',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '636',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '637',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '638',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '639',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '640',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '641',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '642',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '643',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '644',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '645',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '646',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '647',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '648',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang baca\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '649',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '627',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '628',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '629',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '630',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '631',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '632',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '633',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '634',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '635',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '636',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '637',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '638',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '639',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '640',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '641',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '642',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '643',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '644',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '645',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '646',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '647',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '648',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '649',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '650',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '651',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '652',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '653',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '654',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '655',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '656',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '657',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '658',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '659',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '660',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '661',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '662',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '663',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '664',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '665',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '666',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang rapat/sidang\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '667',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '668',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '669',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '670',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '671',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang gis\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '672',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang RPL\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '673',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang RPL\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '674',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang RPL\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '675',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '676',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '677',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '678',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '679',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '680',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '681',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '682',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '683',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '684',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '685',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '686',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '687',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '689',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '690',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '691',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '692',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '693',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '694',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '695',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '696',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '697',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '698',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '699',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '700',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '701',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '702',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '703',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '704',\n 'idruang_fk' => '9'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '705',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '706',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '707',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '708',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '709',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '710',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '711',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '712',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '713',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '714',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '715',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '716',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '717',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '718',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '719',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '720',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '721',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '722',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '723',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '724',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose YAMATO HAA',\n 'nup' => '725',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi ruang dosen\n 'tanggal' => '2016-12-19',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Chitose Yamato HAA',\n 'nup' => '726',\n 'idruang_fk' => '15'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi Tunggu HighPoint Monterey AY405K',\n 'nup' => '727',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi Tunggu HighPoint Monterey AY405K',\n 'nup' => '728',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai\n 'tanggal' => '2017-11-21',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Kursi Tunggu HighPoint Monterey AY405K',\n 'nup' => '729',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '730',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi Kuliah 5\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '731',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '732',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '732',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '733',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '734',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '735',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '736',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '737',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '738',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '739',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '740',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '741',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '742',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '743',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '744',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '745',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '746',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '747',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '748',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '749',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '750',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '751',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '752',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '753',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '754',\n 'idruang_fk' => '15'\n));\nDB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '755',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi metal r dosen\n 'tanggal' => '2018-06-26',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Informa Council 689-2',\n 'nup' => '756',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '759',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '760',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '761',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '762',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '763',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Kursi besi lantai 1\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '20',\n 'merk_barang' => 'Highpoint Monterey AY405K',\n 'nup' => '764',\n 'idruang_fk' => '16'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'MINIMALIS',\n 'nup' => '1',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Sofa 211 Minimalis+Meja',\n 'nup' => '2',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2017-11-14',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Sofa 211 Minimalis+Meja',\n 'nup' => '3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Kursi Taman 2 set untuk Taman Fasilkom',\n 'nup' => '4',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // sice\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '21',\n 'merk_barang' => 'Kursi Taman 2 set untuk Taman Fasilkom',\n 'nup' => '5',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2009-12-17',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Kayu Jati',\n 'nup' => '1',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '2',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '3',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '4',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'MR 240',\n 'nup' => '5',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '6',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '7',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '8',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '9',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '10',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '11',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '12',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '13',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja rapat\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '22',\n 'merk_barang' => 'Tanpa Merk',\n 'nup' => '14',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '6',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '5',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '6',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '7',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '7',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '8',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '9',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '10',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '11',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '12',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1202 BEACH',\n 'nup' => '13',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '14',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '15',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '16',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '17',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '18',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '19',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '20',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '21',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD800P',\n 'nup' => '22',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '23',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '24',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '25',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '26',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '27',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '28',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '29',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-07-25',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'AZTEC CD 1201 Grey',\n 'nup' => '30',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '31',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '32',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '33',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '34',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '35',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '36',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '37',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '38',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '39',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '40',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '41',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '42',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '43',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '44',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '45',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '46',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '47',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '48',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '49',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '50',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '51',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '52',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '53',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '54',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '55',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '56',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '57',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '58',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '59',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '60',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '61',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '62',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '63',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '64',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '65',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '66',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '67',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '68',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '69',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '70',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '71',\n 'idruang_fk' => '8'\n )); DB::table('detail_data_barang')->insert(array(\n // meja komputer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '72',\n 'idruang_fk' => '8'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '73',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '74',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '75',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '76',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '77',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '78',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '79',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '80',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '81',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '82',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '83',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '84',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '85',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '86',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '87',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '88',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '89',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '90',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '91',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '92',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '93',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '94',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '95',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '96',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '97',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '98',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '99',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '100',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '101',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '102',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '103',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '104',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '105',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '106',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '107',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '108',\n 'idruang_fk' => '6'\n )); DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '109',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '110',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '111',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '112',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '113',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '114',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '115',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '116',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '117',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '118',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '119',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '120',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '121',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '122',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '123',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '124',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '125',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '126',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '127',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '128',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '129',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '130',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '131',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '132',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '133',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '134',\n 'idruang_fk' => '7'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '135',\n 'idruang_fk' => '15'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Orbitrend GST-1061',\n 'nup' => '136',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '137',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '138',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '139',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '140',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '141',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '142',\n 'idruang_fk' => '2'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '143',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '145',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Student High Point CT-3C',\n 'nup' => '146',\n 'idruang_fk' => '6'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Instruktur High Point CD-301',\n 'nup' => '147',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Instruktur High Point CD-301',\n 'nup' => '148',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Meja Komputer AZTEK',\n 'nup' => '149',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Meja Komputer AZTEK',\n 'nup' => '150',\n 'idruang_fk' => '3'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // meja komputer \n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '23',\n 'merk_barang' => 'Meja Komputer AZTEK',\n 'nup' => '151',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Lemari es\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '24',\n 'merk_barang' => 'PANASONIC A191D',\n 'nup' => '1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C CENTRAL\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '25',\n 'merk_barang' => 'pOLITRON 3PK',\n 'nup' => '1',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C CENTRAL\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '25',\n 'merk_barang' => 'pOLITRON 3PK',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2016-05-11',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIKAC',\n 'nup' => '35',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2016-05-11',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIKAC',\n 'nup' => '36',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2016-05-11',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIKAC',\n 'nup' => '37',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK 2PK',\n 'nup' => '38',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK 2PK',\n 'nup' => '39',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '40',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '41',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '42',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG CS-C18Y32',\n 'nup' => '43',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '44',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '45',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '46',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '47',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '48',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '49',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '50',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '51',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '52',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'LG S18LG-2',\n 'nup' => '53',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '54',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '55',\n 'idruang_fk' => '4'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '56',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '57',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 18KKP',\n 'nup' => '58',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC CS-PC 12KKP',\n 'nup' => '59',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC',\n 'nup' => '60',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC',\n 'nup' => '61',\n 'idruang_fk' => '20'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG',\n 'nup' => '62',\n 'idruang_fk' => '26'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG',\n 'nup' => '63',\n 'idruang_fk' => '26'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2013-02-15',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC',\n 'nup' => '64',\n 'idruang_fk' => '21'\n ));DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 2PK',\n 'nup' => '65',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 2PK',\n 'nup' => '66',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 2PK',\n 'nup' => '67',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 1,5PK',\n 'nup' => '68',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'CHANGHONG 1,5PK',\n 'nup' => '69',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC 2PK',\n 'nup' => '70',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC 2PK',\n 'nup' => '71',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2015-05-25',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIC R32 2PK',\n 'nup' => '72',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK Inverter CS-s18rkp I n/CU-S18RKP out 2pk',\n 'nup' => '73',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK CU-PN18SKP Outdoor/CS-PN18SKP/Indoee 2PK',\n 'nup' => '74',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'PANASONIK CU-PN18SKP Outdoor/CS-PN18SKP/Indoee 2PK',\n 'nup' => '75',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-05-31',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'AC PANASONIK 2PK',\n 'nup' => '76',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-05-31',\n 'idbarang_fk' => '26',\n 'merk_barang' => 'AC PANASONIK 2PK',\n 'nup' => '77',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-09-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => '2 PK CS-YN18TKP',\n 'nup' => '78',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // A.C SPLIT\n 'tanggal' => '2018-09-28',\n 'idbarang_fk' => '26',\n 'merk_barang' => '2 PK CS-YN18TKP',\n 'nup' => '79',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '4',\n 'idruang_fk' => '3'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '5',\n 'idruang_fk' => '5'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Maspion Exhousfan',\n 'nup' => '6',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2014-11-19',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Kipas Angin Berdiri MIYAKO',\n 'nup' => '7',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2014-11-19',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Kipas Angin Berdiri MIYAKO',\n 'nup' => '8',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // kipas angin\n 'tanggal' => '2014-12-04',\n 'idbarang_fk' => '76',\n 'merk_barang' => 'Hexos Van',\n 'nup' => '9',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Treng/Tandon air\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '27',\n 'merk_barang' => 'STANLESS 1000L',\n 'nup' => '1',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'PANASONIC VIERA TH-L32C20X',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'LG 42LK450',\n 'nup' => '2',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'LG 42LK450',\n 'nup' => '3',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2017-12-28',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'SHARP LED TV 60 INCH FHD+ BRACKET',\n 'nup'=>'4',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TELEVISI\n 'tanggal' => '2019-04-29',\n 'idbarang_fk' => '28',\n 'merk_barang' => 'Televisi SHARP 60\"',\n 'nup'=>'4',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // amplifier\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '29',\n 'merk_barang' => 'TOA',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LOADSPEAKER\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '30',\n 'merk_barang' => 'SPEAKER TOA',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // LOADSPEAKER\n 'tanggal' => '2018-07-27',\n 'idbarang_fk' => '30',\n 'merk_barang' => 'SPEAKER TOA',\n 'nup'=>'2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // SOUNDSYSTEM\n 'tanggal' => '2016-08-19',\n 'idbarang_fk' => '31',\n 'merk_barang' => 'LEXUS KM 500',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'AIRLIVE AIR VIDEO 2000',\n 'nup'=>'1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A1',\n 'nup'=>'2',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A1',\n 'nup'=>'3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A2',\n 'nup'=>'4',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // WIRELESS\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '32',\n 'merk_barang' => 'MIKROTIK RB800 WO834-A2',\n 'nup'=>'5',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TANGGA ALUM\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '33',\n 'merk_barang' => 'CALTEX DOUBLE TINGGI',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // TANGGA ALUM\n 'tanggal' => '2014-03-26',\n 'idbarang_fk' => '33',\n 'merk_barang' => 'TANPA MERK',\n 'nup'=>'2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'2',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // DISPENSER\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '34',\n 'merk_barang' => 'MODENA',\n 'nup'=>'5',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MIMBAR\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '35',\n 'merk_barang' => 'PODIUM KAYU',\n 'nup'=>'1',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'1',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'2',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'3',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'4',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'5',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'6',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'7',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'8',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'9',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'10',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'11',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'12',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'13',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'14',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'15',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'16',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'17',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'18',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'19',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'20',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'21',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'22',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'23',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'24',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // KABEL\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '36',\n 'merk_barang' => 'KABEL DAK SERVER',\n 'nup'=>'25',\n 'idruang_fk' => '10'\n ));\n \n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2016-07-26',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Shure',\n 'nup'=>'2',\n 'idruang_fk' => '10'\n )); \n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA ZW-3200',\n 'nup'=>'3',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA Wireless Michrophone ZW-G810CU + 2 Mic',\n 'nup'=>'4',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA Wireless Michrophone ZW-G810CU + 2 Mic',\n 'nup'=>'5',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-12-16',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'TOA Wireless Michrophone ZW-G810CU + 2 Mic',\n 'nup'=>'6',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2017-11-24',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Shure ULX 4 BETA 58',\n 'nup'=>'7',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2018-04-30',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Sound cress 801',\n 'nup'=>'8',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // MICHROPHONE\n 'tanggal' => '2018-04-30',\n 'idbarang_fk' => '37',\n 'merk_barang' => 'Mic Wireless Sound cress 801',\n 'nup'=>'9',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SUA3000I',\n 'nup'=>'1',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SUA3000I',\n 'nup'=>'2',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SUA1500I',\n 'nup'=>'3',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'KENIKA',\n 'nup'=>'4',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'DELL UPS RACK 3750W/5000VA',\n 'nup'=>'5',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'DELL UPS RACK 3750W/5000VA',\n 'nup'=>'6',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'7',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'8',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'9',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'UPS Rack 3750W/5000VA',\n 'nup'=>'10',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 4200W/6000VA',\n 'nup'=>'11',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 4200W/6000VA',\n 'nup'=>'12',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'13',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'14',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'15',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'16',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'Dell 500W/750Va Watt',\n 'nup'=>'17',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // UPS\n 'tanggal' => '2018-12-26',\n 'idbarang_fk' => '38',\n 'merk_barang' => 'APC SURT15KRMXLI',\n 'nup'=>'18',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // video presenter\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '39',\n 'merk_barang' => 'PROLINK PWP301',\n 'nup'=>'1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n //video conference\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '40',\n 'merk_barang' => 'Fancil D800',\n 'nup'=>'1',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Image View 118326',\n 'nup'=>'1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Image View 118326',\n 'nup'=>'2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Night Vision 260400',\n 'nup'=>'3',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Teropong Keker\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '41',\n 'merk_barang' => 'Bushnell Night Vision 260400',\n 'nup'=>'4',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Telephone\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '42',\n 'merk_barang' => 'Favorite TC416 PABX-16 Unit',\n 'nup'=>'1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Facsimile\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '43',\n 'merk_barang' => 'PANASONIC C KXFP 362 CX',\n 'nup'=>'1',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'3',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'4',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'5',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'6',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'7',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'8',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'9',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'COMEX',\n 'nup'=>'10',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'11',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'12',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'13',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'14',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'15',\n 'idruang_fk' => '1'\n ));DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'16',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'17',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'18',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat komunikasi lainnya\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '44',\n 'merk_barang' => 'Fanvil C58',\n 'nup'=>'19',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Finger Printer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '45',\n 'merk_barang' => 'Fingerspot Enterprise 2000C',\n 'nup'=>'1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Finger Printer\n 'tanggal' => '2018-04-30',\n 'idbarang_fk' => '45',\n 'merk_barang' => 'Fingerprint New Premier Series',\n 'nup'=>'2',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Peralatan Antena\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '46',\n 'merk_barang' => 'Trimble Tornado Antena for Mapping & GIS',\n 'nup'=>'1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Peralatan Antena\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '46',\n 'merk_barang' => 'Trimble Tornado Antena for Mapping & GIS',\n 'nup'=>'2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1900',\n 'nup'=>'1',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'2',\n 'idruang_fk' => '9'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'3',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'4',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'5',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'7',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'8',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'9',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'10',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'11',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'12',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'13',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'14',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'15',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'16',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'17',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'18',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'19',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'20',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'21',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'22',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'23',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'24',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'25',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'26',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'27',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'28',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'29',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'30',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'31',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'32',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'33',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'34',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'35',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'36',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'37',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'38',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'39',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'40',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'41',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'42',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'43',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'44',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'45',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'46',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'47',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'48',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'49',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'50',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'51',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'52',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'53',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'54',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'55',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'56',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'57',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'58',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'59',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'60',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'61',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'62',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'63',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'64',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'65',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'66',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'67',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'68',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'69',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'70',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'71',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'72',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'73',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'74',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'75',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'76',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'77',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'78',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'79',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'80',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'81',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'82',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'83',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'84',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'85',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'86',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'87',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'88',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'89',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'90',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'91',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'92',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'93',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'94',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'DELL Optrirlex 790',\n 'nup'=>'95',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '96',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '97',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '98',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '99',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER M1920, Built up',\n 'nup' => '100',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER Aspire M1900JM',\n 'nup' => '101',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'ACER Aspire M1900JM',\n 'nup' => '102',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '103',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '104',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '105',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '106',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dekstop PC Dell Optiplex 3010',\n 'nup' => '107',\n 'idruang_fk' => '3'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '108',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '109',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '110',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '111',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '112',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '113',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '114',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '115',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '116',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Optiplex 70110 Monitor 23\"',\n 'nup' => '117',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '118',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '120',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '121',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '122',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer Aspire M1800',\n 'nup' => '123',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '124',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '125',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '126',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '127',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '128',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '129',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '130',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '131',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '132',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '133',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '134',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '135',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '136',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '137',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '138',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '139',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '140',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '141',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '142',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2016-11-07',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Acer M3910',\n 'nup' => '143',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Power edge R730',\n 'nup' => '144',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Power edge R730',\n 'nup' => '145',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '146',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '147',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '148',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '149',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '150',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '151',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '152',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '153',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '154',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '155',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '156',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '157',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '158',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '159',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '160',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '161',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '162',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '163',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '164',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '165',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '166',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '167',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '168',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '169',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '170',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '171',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '172',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '173',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '174',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '175',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '176',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '177',\n 'idruang_fk' => '8'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '178',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '179',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '180',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '181',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '182',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '183',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '184',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '185',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '186',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '187',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell Inspiron 3277 AIO',\n 'nup' => '188',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '189',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '190',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '191',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '192',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '193',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '194',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '195',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '196',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '197',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '198',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '199',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '200',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '201',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '202',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '203',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '204',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '205',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '206',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '207',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '208',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '209',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Personal Computer\n 'tanggal' => '2018-12-18',\n 'idbarang_fk' => '47',\n 'merk_barang' => 'Dell All in One Inspiron 24 5477',\n 'nup' => '210',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Electronic Robot\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '48',\n 'merk_barang' => 'Wow Wee Rovio',\n 'nup' => '1',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Electronic Robot\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '48',\n 'merk_barang' => 'Arm MR-999E',\n 'nup' => '2',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kamera Digital\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '49',\n 'merk_barang' => 'Nikon D5 100 Kit TO',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kamera Digital\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '49',\n 'merk_barang' => 'Canon Digital EOS 77D With Lens18-55mm+Memory 32G',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Handheld GPS System Trimble Juno',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Handheld GPS System Trimble Juno',\n 'nup' => '2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Trimble geo explorer 6000',\n 'nup' => '3',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Trimble Recon Hendheld',\n 'nup' => '4',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // GPS\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '50',\n 'merk_barang' => 'Trimble Recon Hendheld',\n 'nup' => '5',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Omni\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '51',\n 'merk_barang' => 'Omni Mikrotik ANT APF24-20',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Omni\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '51',\n 'merk_barang' => 'Omni Mikrotik ANT APF24-20',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Omni\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '51',\n 'merk_barang' => 'Omni Mikrotik ANT APF24-20',\n 'nup' => '3',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '3',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '4',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '5',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '6',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '7',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '8',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '9',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '10',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '11',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '12',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '13',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '14',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '15',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '16',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '17',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '18',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '19',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '20',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '21',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '22',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '23',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '24',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '25',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '26',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '27',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '28',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '29',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '30',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '31',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '32',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '33',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '34',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '35',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '36',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '37',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '38',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '39',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '40',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '41',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '42',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '43',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '44',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '45',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '46',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '47',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '48',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '49',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '50',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '51',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '52',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '53',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '54',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '55',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '56',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '57',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '58',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '59',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Stavol\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '52',\n 'merk_barang' => 'Matsunaga',\n 'nup' => '60',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Mini Komputer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '53',\n 'merk_barang' => 'Tablet with GPS Pathfinder ProXH receiver',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'Dell Precision T1600',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'Precision T1600',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'Dell Precision T15500',\n 'nup' => '3',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '4',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '5',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '6',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC workstation\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '54',\n 'merk_barang' => 'DELL PRECISION T3600',\n 'nup' => '7',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '1',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '3',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '4',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '5',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '6',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // PC unit\n 'tanggal' => '2017-12-18',\n 'idbarang_fk' => '55',\n 'merk_barang' => 'ACER ALL In ONE C20-720',\n 'nup' => '7',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Fujitsu Lifebook TH700',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Toshiba Portege T210-1029 U',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'ASUS A42F-VX085D',\n 'nup' => '3',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Toshiba Satellite L635-1064',\n 'nup' => '4',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Toshiba Portege T210-1018R',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // laptop\n 'tanggal' => '2019-03-27',\n 'idbarang_fk' => '56',\n 'merk_barang' => 'Asus Ultra Slim 14 inch',\n 'nup' => '6',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Asus Eee PC 1005PX-Black',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Asus Eee PC 1005PX-Black',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2010-12-16',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Asus Eee PC 1005PX',\n 'nup' => '3',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Dell Latitude E6420',\n 'nup' => '4',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Dell Latitude E6420',\n 'nup' => '5',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Latitude E6420',\n 'nup' => '6',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Latitude E6420',\n 'nup' => '7',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Latitude E6420',\n 'nup' => '8',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'DELL Latitude E6230',\n 'nup' => '9',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'DELL Latitude E6230',\n 'nup' => '10',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Dell Precision M6700',\n 'nup' => '11',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2015-04-13',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'Apple Mac Book Air (MD7121D/B)',\n 'nup' => '12',\n 'idruang_fk' => '27'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '13',\n 'idruang_fk' => '12'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '14',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '15',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Notebook\n 'tanggal' => '2017-10-26',\n 'idbarang_fk' => '57',\n 'merk_barang' => 'ASUS Business Notebook P243OUA',\n 'nup' => '16',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'DELL Ultra Sharp U2410',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'DELL Ultra Sharp U2410',\n 'nup' => '2',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'Interactive pen Display Wacom DTU-2231 A',\n 'nup' => '3',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Monitor\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '58',\n 'merk_barang' => 'Interactive pen Display Wacom DTU-2231 A',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'LASERJET P1005 HP',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP LASERJET PRO P1 102',\n 'nup' => '2',\n 'idruang_fk' => '23'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-11-25',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP LASERJET PRO P1 102',\n 'nup' => '3',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'CANON PIXMA MP276',\n 'nup' => '4',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'CANON PIXMA MP276',\n 'nup' => '5',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Pro P1 102',\n 'nup' => '6',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-07-26',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Epson L100',\n 'nup' => '7',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Canon pixma MGR 170',\n 'nup' => '8',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Canon pixma MGR 170',\n 'nup' => '9',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Lip CP3525dn',\n 'nup' => '10',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet Pro MI 212',\n 'nup' => '11',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'CANON PIXMA IP4870',\n 'nup' => '12',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP LAser Jet Pro MO 212',\n 'nup' => '13',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'EPSON LQ 2190',\n 'nup' => '14',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '15',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '16',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-18',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'INK Jet EPSON L110',\n 'nup' => '17',\n 'idruang_fk' => '14'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '18',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '19',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '20',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '21',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1002',\n 'nup' => '22',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP DESIGNjet 510 AO 42\" (AO+) CH337A',\n 'nup' => '23',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'EPSON L360',\n 'nup' => '24',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'EPSON L360',\n 'nup' => '25',\n 'idruang_fk' => '11'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1102',\n 'nup' => '26',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1102',\n 'nup' => '27',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2015-12-15',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'HP Laser Jet P1102',\n 'nup' => '28',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '29',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '30',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '31',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer EpsonL 360',\n 'nup' => '32',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer HP Laser Jet Pro M102a (G3Q34A)',\n 'nup' => '33',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer HP Laser Jet Pro M102a (G3Q34A)',\n 'nup' => '34',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Printer\n 'tanggal' => '2017-10-16',\n 'idbarang_fk' => '59',\n 'merk_barang' => 'Printer HP Laser Jet Pro M102a (G3Q34A)',\n 'nup' => '35',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Scanner\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '60',\n 'merk_barang' => 'EPSON GT-2900',\n 'nup' => '1',\n 'idruang_fk' => '4'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Scanner\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'EPSON GT-2900',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '3',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Exsternal portable hardisk\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '61',\n 'merk_barang' => 'SEAGATE STAC4000100',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-06-06',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'QNAP TS 559 Pro+',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '3',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '4',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '5',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'DELL PowerEdge T410',\n 'nup' => '6',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'SUPERMI CRO Super Server 1029P-WTR',\n 'nup' => '7',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'SUPERMI CRO Super Server 1029P-WTR',\n 'nup' => '8',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Server\n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '62',\n 'merk_barang' => 'ATEN 8-Port PS/2-USB VGA LCD KVM Switch with daisy',\n 'nup' => '9',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Rackmount, Nikrotik RB110',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Rackmount, Nikrotik RB110',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '3',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '6',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '7',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '8',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '9',\n 'idruang_fk' => '1'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Buit, Mikrotik RB450',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Router\n 'tanggal' => '2011-12-22',\n 'idbarang_fk' => '63',\n 'merk_barang' => 'Mikrotik Core Router',\n 'nup' => '11',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // HUb\n 'tanggal' => '2010-12-01',\n 'idbarang_fk' => '64',\n 'merk_barang' => 'D-LINK DGS-1024D',\n 'nup' => '1',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Rak Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '65',\n 'merk_barang' => 'Dell PowerEdge Rack 4220',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Rak Server\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '65',\n 'merk_barang' => 'Dell PowerEdge Rack 4220',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Swiitch Rak\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '66',\n 'merk_barang' => 'Fortuna 8u double door',\n 'nup' => '1',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '1',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '2',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '3',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 MT Cable',\n 'nup' => '4',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 UTP Cable',\n 'nup' => '7',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'DRAKA CAT6 UTP Cable',\n 'nup' => '8',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Kabel UTP\n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '67',\n 'merk_barang' => 'Belden Cat 6',\n 'nup' => '9',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'TP Link Switch HUB',\n 'nup' => '14',\n 'idruang_fk' => '5'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2016-03-14',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'TP Link Switch HUB',\n 'nup' => '15',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '16',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '17',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '18',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '19',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-16/r',\n 'nup' => '20',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '21',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '22',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '23',\n 'idruang_fk' => '7'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '24',\n 'idruang_fk' => '6'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '25',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'D-LINK DGS 1210-24/E',\n 'nup' => '26',\n 'idruang_fk' => '15'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'LINK TL-SG 1024',\n 'nup' => '27',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'LINK TL-SG 1024',\n 'nup' => '28',\n 'idruang_fk' => '18'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-02-23',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'SWITCH MANAGE Cisco SLM2008T-EU',\n 'nup' => '29',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-02-23',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'SWITCH MANAGE Cisco SLM2008T-EU',\n 'nup' => '30',\n 'idruang_fk' => '13'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'CISCO SG95D-08/-Port Gigabit Dekstop Switch',\n 'nup' => '31',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-08-30',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'CISCO SG95D-08/-Port Gigabit Dekstop Switch',\n 'nup' => '32',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-11-29',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'JUNIPER Switch Manage EX2200-24T-4G',\n 'nup' => '33',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Switch \n 'tanggal' => '2018-12-12',\n 'idbarang_fk' => '68',\n 'merk_barang' => 'TP-LINK AC1200 Dual-Band Wifi Gigabit Router',\n 'nup' => '34',\n 'idruang_fk' => '10'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Acces Point\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '69',\n 'merk_barang' => 'D-Link DAP-1360',\n 'nup' => '1',\n 'idruang_fk' => '24'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Acces Point\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '69',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '2',\n 'idruang_fk' => '19'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '3',\n 'idruang_fk' => '26'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '4',\n 'idruang_fk' => '20'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '5',\n 'idruang_fk' => '21'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '6',\n 'idruang_fk' => '22'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Converter\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '70',\n 'merk_barang' => 'Converter VGA to HDMI',\n 'nup' => '7',\n 'idruang_fk' => '8'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Jet Pump\n 'tanggal' => '2010-03-18',\n 'idbarang_fk' => '71',\n 'merk_barang' => 'LAKONI 505',\n 'nup' => '1',\n 'idruang_fk' => '17'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '1',\n 'idruang_fk' => '25'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '2',\n 'idruang_fk' => '25'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '3',\n 'idruang_fk' => '25'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'Dell Power Vault MI 1200',\n 'nup' => '4',\n 'idruang_fk' => '25'\n ));\n\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'WD Sentinel DX4000 WDBLGTO 1 20KBK',\n 'nup' => '5',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Storage Pile\n 'tanggal' => '2011-12-13',\n 'idbarang_fk' => '72',\n 'merk_barang' => 'WD Sentinel DX4000 WDBLGTO 1 20KBK',\n 'nup' => '6',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat tenis meja\n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '73',\n 'merk_barang' => 'Meja Pingpong Lokal',\n 'nup' => '1',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat tenis meja\n 'tanggal' => '2018-03-29',\n 'idbarang_fk' => '73',\n 'merk_barang' => 'Tanis Meja Nittaku 2003B',\n 'nup' => '2',\n 'idruang_fk' => '16'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat Music Modern\n 'tanggal' => '2016-07-26',\n 'idbarang_fk' => '74',\n 'merk_barang' => 'Keyboard Roland E 09',\n 'nup' => '1',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Alat music \n 'tanggal' => '2011-12-28',\n 'idbarang_fk' => '74',\n 'merk_barang' => 'Korg PA50 RU',\n 'nup' => '2',\n 'idruang_fk' => '18'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB 7',\n 'nup' => '1',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Parallel computing',\n 'nup' => '2',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Opsfullzation Toolbox',\n 'nup' => '3',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '74',\n 'merk_barang' => 'MATLAB Symbolic Math Toolbox',\n 'nup' => '4',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Partial Differential',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Global Optimization',\n 'nup' => '6',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Statistics rootbox',\n 'nup' => '7',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Neural Network Toolbox',\n 'nup' => '8',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Curve Fitting Toolbox',\n 'nup' => '9',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Image Proces Toolbox',\n 'nup' => '10',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Vision System Toolbox',\n 'nup' => '11',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Mapping toolbox',\n 'nup' => '12',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Bioinformatics Toolbox',\n 'nup' => '13',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Simbiology',\n 'nup' => '14',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Compiler',\n 'nup' => '5',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Spreadsheet link EX',\n 'nup' => '16',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Builder NE',\n 'nup' => '17',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Builder EX',\n 'nup' => '18',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Huilder JA',\n 'nup' => '19',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Database Toolbox',\n 'nup' => '20',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2011-12-01',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'MATLAB Report Generator',\n 'nup' => '21',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Trimble Trim Pix Pro',\n 'nup' => '22',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Trimble Trim Pix pro',\n 'nup' => '23',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Software Trimble Terrasync Pro 45955-VG',\n 'nup' => '24',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GPS Correct Extention For esri ArPad 46837-VG',\n 'nup' => '25',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GPS Analyst Extention For esri ArcGis 52726-VG',\n 'nup' => '26',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GPS pathfinder Office Software 34191-VG',\n 'nup' => '27',\n 'idruang_fk' => '2'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Dekstop GIS ESRI Advanced (Arcinfo)',\n 'nup' => '28',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GIS Analysis Extention ESRi ArcGis Schematcs',\n 'nup' => '29',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Extention Esri ArcGis Analyst Schematics',\n 'nup' => '30',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Produktivity ArcGis Data Interoperability',\n 'nup' => '31',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'ArcGis Geostatistical Analyst',\n 'nup' => '32',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => ' Extention ESRI ArcGIS Network Analyst',\n 'nup' => '33',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Extention ESRI ArcGIS Spatial Analyst',\n 'nup' => '34',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Extention ESRI ArcGIS Tracking Analyst',\n 'nup' => '35',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'Mobile GIS ESRI ArcPad 10',\n 'nup' => '36',\n 'idruang_fk' => '1'\n ));\n DB::table('detail_data_barang')->insert(array(\n // Software\n 'tanggal' => '2012-12-13',\n 'idbarang_fk' => '75',\n 'merk_barang' => 'GIS for Server ESRi ArcGis',\n 'nup' => '37',\n 'idruang_fk' => '1'\n ));\n }", "public function run()\n {\n \n\n \\DB::table('halamanstatis')->delete();\n \n \\DB::table('halamanstatis')->insert(array (\n 0 => \n array (\n 'id_halaman' => 1,\n 'judul' => 'Profil',\n 'isi_halaman' => '<p>\n<strong>Bukulokomedia.com</strong> merupakan website resmi dari penerbit\nLokomedia yang bermarkas di Jl. Jambon. Perum. Pesona Alam Hijau 2 Blok B-4 Kricak, Jatimulyo, Yogyakarta\n55242. Dirintis pertama kali oleh Lukmanul Hakim pada tanggal 14 Maret\n2008.<br />\n<br />\nProduk unggulan dari penerbit Lokomedia adalah buku-buku serta aksesoris bertema Web, terutama PHP (<span style=\"font-weight: bold; font-style: italic\">PHP: Hypertext Preprocessor</span>) yang merupakan pemrograman Internet paling handal saat ini.\n</p>\n',\n 'tgl_posting' => '2010-05-31',\n 'gambar' => 'gedungku.jpg',\n ),\n 1 => \n array (\n 'id_halaman' => 2,\n 'judul' => 'Visi dan Misi',\n 'isi_halaman' => '<p>\nVisi :\n</p>\n<p>\n&nbsp;\n</p>\n<p>\n&nbsp;\n</p>\n<p>\nMisi :\n</p>\n<p>\n&nbsp;\n</p>\n',\n 'tgl_posting' => '2010-05-31',\n 'gambar' => '',\n ),\n 2 => \n array (\n 'id_halaman' => 3,\n 'judul' => 'Struktur Organisasi',\n 'isi_halaman' => 'Isikan struktur organisasi di bagian ini\n',\n 'tgl_posting' => '2010-05-31',\n 'gambar' => '',\n ),\n ));\n \n \n }", "public function simpan_data_penerima_bansos()\n {\n $noKK = $this->request->getVar('noKK');\n $kepalaKeluarga = $this->request->getVar('kepalaKeluarga');\n $idBansos = $this->request->getVar('idBansos');\n $namaBansos = $this->request->getVar('namaBansos');\n $kategori = $this->request->getVar('kategori');\n $pendamping = $this->request->getVar('pendamping');\n $nominal = $this->request->getVar('nominal');\n $jumlahData = count($noKK);\n $jumlahBerhasil = 0;\n $jumlahGagal = 0;\n $jumlahTerdaftar = 0;\n $jumlahDataKKTidakDitemukan = 0;\n $jumlahDataBansosTidakDitemukan = 0;\n $jumlahBelumDisetujui = 0;\n for ($i = 0; $i < $jumlahData; $i++) {\n // cek apakah fieldnya kosong\n if ($noKK[$i] == 0 || $idBansos[$i] == 0) {\n $jumlahGagal++;\n } else {\n // cek pada database apakah data KK tersebut ada\n $dataKeluarga = $this->KeluargaModel->where('noKK', $noKK[$i])->first();\n if ($dataKeluarga) {\n // cek pada database apakah data bansos ada\n $dataBansos = $this->DataBansosModel->where('idBansos', $idBansos[$i])->first();\n if ($dataBansos) {\n // cek apakah data keluarga sudah\n $status = 'Disetujui';\n $disetujui = $this->KeluargaModel->where('noKK', $noKK[$i])->where('status', $status)->first();\n if ($disetujui) {\n // cek data peserta apakah sudah terdaftar\n $pesertaBansos = $this->BansosModel->where('noKK', $noKK[$i])->where('idBansos', $idBansos[$i])->first();\n if ($pesertaBansos) {\n $jumlahTerdaftar++;\n } else {\n\n $this->BansosModel->save([\n 'noKK' => $noKK[$i],\n 'kepalaKeluarga' => $kepalaKeluarga[$i],\n 'idBansos' => $idBansos[$i],\n 'namaBansos' => $namaBansos[$i],\n 'kategori' => $kategori[$i],\n 'pendamping' => $pendamping[$i],\n 'nominal' => $nominal[$i],\n 'statusAnggota' => 'Aktif'\n ]);\n $jumlahBerhasil++;\n }\n } else {\n $jumlahBelumDisetujui++;\n }\n } else {\n $jumlahDataBansosTidakDitemukan++;\n }\n } else {\n $jumlahDataKKTidakDitemukan++;\n }\n }\n }\n session()->setFlashdata('pesan', '' . $jumlahBerhasil . ' Berhasil Disimpan, ' . $jumlahTerdaftar . ' Telah Terdaftar, ' . $jumlahDataKKTidakDitemukan . ' Data KK Tidak Ditemukan, ' . $jumlahDataBansosTidakDitemukan . ' Data Bansos Tidak Ditemukan dan ' . $jumlahBelumDisetujui . ' Belum Disetujui');\n return redirect()->to('/Admin/penerima_bansos');\n }", "function newskomentar_listdata($tbl_newskomentar){\n\t\t$sql = mysql_query(\"SELECT * FROM $tbl_newskomentar\");\n\t\treturn $sql;\n}", "public function buscarDatosDeCodigo($lote, $suc){\n $db = new My();\n $my = new My();\n $datos = array();\n $query = \"SELECT a.codigo AS Codigo,l.lote,CONCAT( a.descrip, '-', p.nombre_color) AS Descrip , s.suc, s.cantidad AS Stock, s.estado_venta,a.um AS UM,l.ancho AS Ancho,l.gramaje AS Gramaje,l.tara AS Tara,l.padre AS Padre,s.ubicacion AS U_ubic,\n l.img AS Img, l.kg_desc AS U_kg_desc,h.fecha_hora AS entDate\n\n FROM articulos a INNER JOIN lotes l ON a.codigo = l.codigo INNER JOIN stock s ON l.codigo = s.codigo AND l.lote = s.lote \n INNER JOIN pantone p ON l.pantone = p.pantone INNER JOIN historial h ON l.codigo = h.codigo AND l.lote = h.lote\n WHERE s.cantidad > 0 AND s.suc = '$suc' AND l.lote ='$lote' GROUP BY lote ORDER BY h.fecha_hora ASC LIMIT 1\";\n \n $my->Query($query);\n if($my->NextRecord()){\n $datos = $my->Record;\n if(count($datos)){\n $datos = array_map(\"utf8_encode\",$datos);\n // print_r($datos);\n \n $rem = \"SELECT CONCAT(fecha_cierre,' ',hora_cierre) AS fecha_ingreso FROM nota_remision n, nota_rem_det d WHERE n.n_nro = d.n_nro AND lote = '$lote' AND n.estado = 'Cerrada' AND n.suc_d = '$suc'\";\n \n $db->Query($rem);\n if($db->NumRows() > 0){ \n $db->NextRecord();\n $fecha_ingreso = $db->Record['fecha_ingreso'];\n $datos['entDate'] = $fecha_ingreso;\n }\n // Buscar si esta en una Remision Abierta o En Proceso\n $rem2 = \"SELECT n.n_nro, n.suc_d FROM nota_remision n, nota_rem_det d WHERE n.n_nro = d.n_nro AND lote = '$lote' AND n.estado != 'Cerrada' AND n.suc = '$suc'\";\n \n $db->Query($rem2);\n if($db->NumRows() > 0){ \n $db->NextRecord();\n $n_nro = $db->Record['n_nro'];\n $destino = $db->Record['suc_d'];\n $datos['NroRemision'] = $n_nro;\n $datos['Destino'] = $destino;\n $datos['Mensaje']=\"En Remision\";\n }else{\n $datos['Mensaje']=\"Ok\"; \n }\n \n }\n echo json_encode($datos);\n }else{\n echo '{\"Mensaje\":\"Error: Codigo no encontrado!\"}';\n } \n $my->Close();\n }", "public function run()\n {\n DB::table('obat_masuk')->insert(array(\n \tarray('id_jenis_obat'=>1, 'id_stok_obat'=>1, 'waktu_masuk'=>'2017-01-07 09:12:00', 'jumlah'=>170, 'harga_beli_satuan'=>9100.00),\n\t\t\tarray('id_jenis_obat'=>2, 'id_stok_obat'=>2, 'waktu_masuk'=>'2017-01-15 09:16:00', 'jumlah'=>110, 'harga_beli_satuan'=>11000.00),\n\t\t\tarray('id_jenis_obat'=>3, 'id_stok_obat'=>3, 'waktu_masuk'=>'2017-01-22 09:26:00', 'jumlah'=>380, 'harga_beli_satuan'=>49000.00),\n\t\t\tarray('id_jenis_obat'=>4, 'id_stok_obat'=>4, 'waktu_masuk'=>'2017-02-06 09:32:00', 'jumlah'=>480, 'harga_beli_satuan'=>1300.00),\n\t\t\tarray('id_jenis_obat'=>5, 'id_stok_obat'=>5, 'waktu_masuk'=>'2017-02-07 09:42:00', 'jumlah'=>380, 'harga_beli_satuan'=>1400.00),\n\t\t\tarray('id_jenis_obat'=>6, 'id_stok_obat'=>6, 'waktu_masuk'=>'2017-02-21 09:46:00', 'jumlah'=>310, 'harga_beli_satuan'=>1600.00),\n\t\t\tarray('id_jenis_obat'=>7, 'id_stok_obat'=>7, 'waktu_masuk'=>'2017-03-15 10:02:00', 'jumlah'=>450, 'harga_beli_satuan'=>900.00),\n\t\t\tarray('id_jenis_obat'=>8, 'id_stok_obat'=>8, 'waktu_masuk'=>'2017-03-28 10:08:00', 'jumlah'=>90, 'harga_beli_satuan'=>2700.00),\n\t\t\tarray('id_jenis_obat'=>9, 'id_stok_obat'=>9, 'waktu_masuk'=>'2017-04-05 10:10:00', 'jumlah'=>230, 'harga_beli_satuan'=>470),\n\t\t\tarray('id_jenis_obat'=>10, 'id_stok_obat'=>10, 'waktu_masuk'=>'2017-04-16 10:16:00', 'jumlah'=>320, 'harga_beli_satuan'=>450),\n\t\t\tarray('id_jenis_obat'=>11, 'id_stok_obat'=>11, 'waktu_masuk'=>'2017-04-19 10:22:00', 'jumlah'=>30, 'harga_beli_satuan'=>6800.00),\n\t\t\tarray('id_jenis_obat'=>12, 'id_stok_obat'=>12, 'waktu_masuk'=>'2017-04-29 10:36:00', 'jumlah'=>330, 'harga_beli_satuan'=>7400.00),\n\t\t\tarray('id_jenis_obat'=>13, 'id_stok_obat'=>13, 'waktu_masuk'=>'2017-05-05 10:38:00', 'jumlah'=>20, 'harga_beli_satuan'=>6300.00),\n\t\t\tarray('id_jenis_obat'=>14, 'id_stok_obat'=>14, 'waktu_masuk'=>'2017-05-23 10:44:00', 'jumlah'=>320, 'harga_beli_satuan'=>6300.00),\n\t\t\tarray('id_jenis_obat'=>15, 'id_stok_obat'=>15, 'waktu_masuk'=>'2017-06-05 10:48:00', 'jumlah'=>180, 'harga_beli_satuan'=>9700.00),\n\t\t\tarray('id_jenis_obat'=>16, 'id_stok_obat'=>16, 'waktu_masuk'=>'2017-06-18 10:56:00', 'jumlah'=>190, 'harga_beli_satuan'=>12200.00),\n\t\t\tarray('id_jenis_obat'=>17, 'id_stok_obat'=>17, 'waktu_masuk'=>'2017-06-20 10:58:00', 'jumlah'=>420, 'harga_beli_satuan'=>700.00),\n\t\t\tarray('id_jenis_obat'=>18, 'id_stok_obat'=>18, 'waktu_masuk'=>'2017-06-25 11:00:00', 'jumlah'=>280, 'harga_beli_satuan'=>1500.00),\n\t\t\tarray('id_jenis_obat'=>19, 'id_stok_obat'=>19, 'waktu_masuk'=>'2017-06-27 11:02:00', 'jumlah'=>340, 'harga_beli_satuan'=>630),\n\t\t\tarray('id_jenis_obat'=>20, 'id_stok_obat'=>20, 'waktu_masuk'=>'2017-07-02 11:06:00', 'jumlah'=>50, 'harga_beli_satuan'=>8000.00),\n\t\t\tarray('id_jenis_obat'=>21, 'id_stok_obat'=>21, 'waktu_masuk'=>'2017-08-06 11:08:00', 'jumlah'=>150, 'harga_beli_satuan'=>5100.00),\n\t\t\tarray('id_jenis_obat'=>22, 'id_stok_obat'=>22, 'waktu_masuk'=>'2017-08-23 11:20:00', 'jumlah'=>210, 'harga_beli_satuan'=>500.00),\n\t\t\tarray('id_jenis_obat'=>23, 'id_stok_obat'=>23, 'waktu_masuk'=>'2017-08-24 11:22:00', 'jumlah'=>250, 'harga_beli_satuan'=>900.00),\n\t\t\tarray('id_jenis_obat'=>24, 'id_stok_obat'=>24, 'waktu_masuk'=>'2017-08-30 11:24:00', 'jumlah'=>440, 'harga_beli_satuan'=>600.00),\n\t\t\tarray('id_jenis_obat'=>25, 'id_stok_obat'=>25, 'waktu_masuk'=>'2017-09-10 11:26:00', 'jumlah'=>420, 'harga_beli_satuan'=>2100.00),\n\t\t\tarray('id_jenis_obat'=>26, 'id_stok_obat'=>26, 'waktu_masuk'=>'2017-01-05 11:28:00', 'jumlah'=>270, 'harga_beli_satuan'=>4400.00),\n\t\t\tarray('id_jenis_obat'=>27, 'id_stok_obat'=>27, 'waktu_masuk'=>'2017-01-17 11:30:00', 'jumlah'=>500, 'harga_beli_satuan'=>15500.00),\n\t\t\tarray('id_jenis_obat'=>28, 'id_stok_obat'=>28, 'waktu_masuk'=>'2017-01-24 11:34:00', 'jumlah'=>310, 'harga_beli_satuan'=>39200.00),\n\t\t\tarray('id_jenis_obat'=>29, 'id_stok_obat'=>29, 'waktu_masuk'=>'2017-02-15 11:38:00', 'jumlah'=>260, 'harga_beli_satuan'=>400.00),\n\t\t\tarray('id_jenis_obat'=>30, 'id_stok_obat'=>30, 'waktu_masuk'=>'2017-02-19 11:40:00', 'jumlah'=>500, 'harga_beli_satuan'=>3100.00),\n\t\t\tarray('id_jenis_obat'=>31, 'id_stok_obat'=>31, 'waktu_masuk'=>'2017-03-05 11:50:00', 'jumlah'=>160, 'harga_beli_satuan'=>350),\n\t\t\tarray('id_jenis_obat'=>32, 'id_stok_obat'=>32, 'waktu_masuk'=>'2017-03-16 11:54:00', 'jumlah'=>180, 'harga_beli_satuan'=>370),\n\t\t\tarray('id_jenis_obat'=>33, 'id_stok_obat'=>33, 'waktu_masuk'=>'2017-03-18 11:56:00', 'jumlah'=>380, 'harga_beli_satuan'=>200.00),\n\t\t\tarray('id_jenis_obat'=>34, 'id_stok_obat'=>34, 'waktu_masuk'=>'2017-03-20 12:02:00', 'jumlah'=>390, 'harga_beli_satuan'=>500.00),\n\t\t\tarray('id_jenis_obat'=>35, 'id_stok_obat'=>35, 'waktu_masuk'=>'2017-03-22 12:12:00', 'jumlah'=>440, 'harga_beli_satuan'=>1100.00),\n\t\t\tarray('id_jenis_obat'=>36, 'id_stok_obat'=>36, 'waktu_masuk'=>'2017-03-24 12:28:00', 'jumlah'=>210, 'harga_beli_satuan'=>220),\n\t\t\tarray('id_jenis_obat'=>37, 'id_stok_obat'=>37, 'waktu_masuk'=>'2017-03-31 12:30:00', 'jumlah'=>280, 'harga_beli_satuan'=>3300.00),\n\t\t\tarray('id_jenis_obat'=>38, 'id_stok_obat'=>38, 'waktu_masuk'=>'2017-04-08 12:42:00', 'jumlah'=>460, 'harga_beli_satuan'=>7100.00),\n\t\t\tarray('id_jenis_obat'=>39, 'id_stok_obat'=>39, 'waktu_masuk'=>'2017-04-10 12:52:00', 'jumlah'=>250, 'harga_beli_satuan'=>8800.00),\n\t\t\tarray('id_jenis_obat'=>40, 'id_stok_obat'=>40, 'waktu_masuk'=>'2017-04-11 13:02:00', 'jumlah'=>230, 'harga_beli_satuan'=>16400.00),\n\t\t\tarray('id_jenis_obat'=>41, 'id_stok_obat'=>41, 'waktu_masuk'=>'2017-05-14 13:16:00', 'jumlah'=>270, 'harga_beli_satuan'=>2400.00),\n\t\t\tarray('id_jenis_obat'=>42, 'id_stok_obat'=>42, 'waktu_masuk'=>'2017-05-30 13:28:00', 'jumlah'=>360, 'harga_beli_satuan'=>520),\n\t\t\tarray('id_jenis_obat'=>43, 'id_stok_obat'=>43, 'waktu_masuk'=>'2017-06-03 13:30:00', 'jumlah'=>470, 'harga_beli_satuan'=>360),\n\t\t\tarray('id_jenis_obat'=>44, 'id_stok_obat'=>44, 'waktu_masuk'=>'2017-06-04 13:48:00', 'jumlah'=>120, 'harga_beli_satuan'=>660),\n\t\t\tarray('id_jenis_obat'=>45, 'id_stok_obat'=>45, 'waktu_masuk'=>'2017-06-10 14:00:00', 'jumlah'=>30, 'harga_beli_satuan'=>720),\n\t\t\tarray('id_jenis_obat'=>46, 'id_stok_obat'=>46, 'waktu_masuk'=>'2017-06-19 14:10:00', 'jumlah'=>250, 'harga_beli_satuan'=>410),\n\t\t\tarray('id_jenis_obat'=>47, 'id_stok_obat'=>47, 'waktu_masuk'=>'2017-06-20 14:12:00', 'jumlah'=>420, 'harga_beli_satuan'=>4300.00),\n\t\t\tarray('id_jenis_obat'=>48, 'id_stok_obat'=>48, 'waktu_masuk'=>'2017-06-27 14:14:00', 'jumlah'=>470, 'harga_beli_satuan'=>5000.00),\n\t\t\tarray('id_jenis_obat'=>49, 'id_stok_obat'=>49, 'waktu_masuk'=>'2017-07-15 14:16:00', 'jumlah'=>60, 'harga_beli_satuan'=>7900.00),\n\t\t\tarray('id_jenis_obat'=>50, 'id_stok_obat'=>50, 'waktu_masuk'=>'2017-07-28 14:18:00', 'jumlah'=>100, 'harga_beli_satuan'=>9200.00),\n\t\t\tarray('id_jenis_obat'=>51, 'id_stok_obat'=>51, 'waktu_masuk'=>'2017-01-08 14:24:00', 'jumlah'=>260, 'harga_beli_satuan'=>7500.00),\n\t\t\tarray('id_jenis_obat'=>52, 'id_stok_obat'=>52, 'waktu_masuk'=>'2017-01-11 14:32:00', 'jumlah'=>20, 'harga_beli_satuan'=>7800.00),\n\t\t\tarray('id_jenis_obat'=>53, 'id_stok_obat'=>53, 'waktu_masuk'=>'2017-02-11 14:40:00', 'jumlah'=>170, 'harga_beli_satuan'=>8800.00),\n\t\t\tarray('id_jenis_obat'=>54, 'id_stok_obat'=>54, 'waktu_masuk'=>'2017-02-13 14:42:00', 'jumlah'=>100, 'harga_beli_satuan'=>100.00),\n\t\t\tarray('id_jenis_obat'=>55, 'id_stok_obat'=>55, 'waktu_masuk'=>'2017-03-02 14:46:00', 'jumlah'=>380, 'harga_beli_satuan'=>9400.00),\n\t\t\tarray('id_jenis_obat'=>56, 'id_stok_obat'=>56, 'waktu_masuk'=>'2017-03-03 14:52:00', 'jumlah'=>410, 'harga_beli_satuan'=>3600.00),\n\t\t\tarray('id_jenis_obat'=>57, 'id_stok_obat'=>57, 'waktu_masuk'=>'2017-03-20 15:04:00', 'jumlah'=>490, 'harga_beli_satuan'=>8100.00),\n\t\t\tarray('id_jenis_obat'=>58, 'id_stok_obat'=>58, 'waktu_masuk'=>'2017-03-21 15:14:00', 'jumlah'=>380, 'harga_beli_satuan'=>8500.00),\n\t\t\tarray('id_jenis_obat'=>59, 'id_stok_obat'=>59, 'waktu_masuk'=>'2017-03-23 15:18:00', 'jumlah'=>270, 'harga_beli_satuan'=>14200.00),\n\t\t\tarray('id_jenis_obat'=>60, 'id_stok_obat'=>60, 'waktu_masuk'=>'2017-03-29 15:36:00', 'jumlah'=>10, 'harga_beli_satuan'=>22100.00),\n\t\t\tarray('id_jenis_obat'=>61, 'id_stok_obat'=>61, 'waktu_masuk'=>'2017-04-03 15:46:00', 'jumlah'=>100, 'harga_beli_satuan'=>7300.00),\n\t\t\tarray('id_jenis_obat'=>62, 'id_stok_obat'=>62, 'waktu_masuk'=>'2017-04-06 15:54:00', 'jumlah'=>260, 'harga_beli_satuan'=>19000.00),\n\t\t\tarray('id_jenis_obat'=>63, 'id_stok_obat'=>63, 'waktu_masuk'=>'2017-04-07 15:56:00', 'jumlah'=>450, 'harga_beli_satuan'=>24300.00),\n\t\t\tarray('id_jenis_obat'=>64, 'id_stok_obat'=>64, 'waktu_masuk'=>'2017-05-02 16:06:00', 'jumlah'=>490, 'harga_beli_satuan'=>17200.00),\n\t\t\tarray('id_jenis_obat'=>65, 'id_stok_obat'=>65, 'waktu_masuk'=>'2017-05-09 16:08:00', 'jumlah'=>400, 'harga_beli_satuan'=>35000.00),\n\t\t\tarray('id_jenis_obat'=>66, 'id_stok_obat'=>66, 'waktu_masuk'=>'2017-05-16 16:10:00', 'jumlah'=>290, 'harga_beli_satuan'=>37000.00),\n\t\t\tarray('id_jenis_obat'=>67, 'id_stok_obat'=>67, 'waktu_masuk'=>'2017-05-26 16:18:00', 'jumlah'=>450, 'harga_beli_satuan'=>1600.00),\n\t\t\tarray('id_jenis_obat'=>68, 'id_stok_obat'=>68, 'waktu_masuk'=>'2017-05-27 16:38:00', 'jumlah'=>90, 'harga_beli_satuan'=>3200.00),\n\t\t\tarray('id_jenis_obat'=>69, 'id_stok_obat'=>69, 'waktu_masuk'=>'2017-06-22 16:42:00', 'jumlah'=>140, 'harga_beli_satuan'=>5600.00),\n\t\t\tarray('id_jenis_obat'=>70, 'id_stok_obat'=>70, 'waktu_masuk'=>'2017-06-28 16:44:00', 'jumlah'=>300, 'harga_beli_satuan'=>700.00),\n\t\t\tarray('id_jenis_obat'=>71, 'id_stok_obat'=>71, 'waktu_masuk'=>'2017-07-06 16:48:00', 'jumlah'=>210, 'harga_beli_satuan'=>800.00),\n\t\t\tarray('id_jenis_obat'=>72, 'id_stok_obat'=>72, 'waktu_masuk'=>'2017-07-17 16:52:00', 'jumlah'=>500, 'harga_beli_satuan'=>1200.00)\n ));\n }", "function input_data($data,$table){\n\t\t$this->db->insert($table,$data);//menginputkan data ke database dengan function input_data\n }", "public function run()\n {\n \n\n \\DB::table('bahan')->delete();\n \n \\DB::table('bahan')->insert(array (\n 0 => \n array (\n 'ID_BAHAN' => 'B001',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Kertas saring',\n ),\n 1 => \n array (\n 'ID_BAHAN' => 'B002',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Lakmus merah',\n ),\n 2 => \n array (\n 'ID_BAHAN' => 'B003',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Lakmus biru',\n ),\n 3 => \n array (\n 'ID_BAHAN' => 'B004',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Indicator universal',\n ),\n 4 => \n array (\n 'ID_BAHAN' => 'B005',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Gula pasir',\n ),\n 5 => \n array (\n 'ID_BAHAN' => 'B006',\n 'ID_LEMARI' => 7,\n 'NAMA_BAHAN' => 'Urea',\n ),\n 6 => \n array (\n 'ID_BAHAN' => 'L1/B001',\n 'ID_LEMARI' => 11,\n 'NAMA_BAHAN' => 'Kertas grafik/millimeter',\n ),\n 7 => \n array (\n 'ID_BAHAN' => 'L1/B002',\n 'ID_LEMARI' => 11,\n 'NAMA_BAHAN' => 'Kertas grafik/millimeter 2cm',\n ),\n ));\n \n \n }", "function all(){\n try{\n $link= connecter_db();\n $rp=$link->prepare(\"select * from etudiant order by id desc\");\n $rp->execute();\n $resultat= $rp->fetchAll(); \n\n return $resultat;\n }catch(PDOException $e ){\n die (\"erreur de recuperation des etudiants dans la base de donnees \".$e->getMessage());\n }\n\n}", "public function selectdata(){\n$this->autoRender=false;\n$data=$this->connection->execute(\"select * from users\")->fetchAll();\nprint_r($data);\n}", "public function busca_alunos(){\n\n\t\t\t$sql = \"SELECT * FROM aluno\";\n\n\t\t\t/*\n\t\t\t*isntrução que realiza a consulta de animes\n\t\t\t*PDO::FETCH_CLASS serve para perdir o retorno no modelo de uma classe\n\t\t\t*PDO::FETCH_PROPS_LATE serve para preencher os valores depois de executar o contrutor\n\t\t\t*/\n\n\t\t\t$resultado = $this->conexao->query($sql, PDO::FETCH_CLASS | PDO::FETCH_PROPS_LATE, 'Aluno');\n\n $alunos = [];\n\n foreach($resultado as $aluno){\n $alunos[] = $aluno;\n }\n\n \t\t\treturn $alunos;\n\t\t}", "function tambah_data($tabel,$data)\n {\n // http://thisinterestsme.com/pdo-prepared-multi-inserts/\n $rowsSQL = array();\n // buat bind param Prepared Statement\n $toBind = array();\n // list nama kolom\n $columnNames = array_keys($data[0]);\n // looping untuk mengambil isi dari kolom / values\n foreach($data as $arrayIndex => $row){\n $params = array();\n foreach($row as $columnName => $columnValue){\n $param = \":\" . $columnName . $arrayIndex;\n $params[] = $param;\n $toBind[$param] = $columnValue;\n }\n $rowsSQL[] = \"(\" . implode(\", \", $params) . \")\";\n }\n $sql = \"INSERT INTO $tabel (\" . implode(\", \", $columnNames) . \") VALUES \" . implode(\", \", $rowsSQL);\n $row = $this->db->prepare($sql);\n //Bind our values.\n foreach($toBind as $param => $val){\n $row ->bindValue($param, $val);\n }\n //Execute our statement (i.e. insert the data).\n return $row ->execute();\n }", "public function displaymahasiswa()\r\n {\r\n $query = \"select * from data_mahasiswa\";\r\n return $this->db->query($query);\r\n }", "public function data_mata_kuliah()\n\t{\n\t\t$query1 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Analisis Kimia'\";\n\t\t$query2 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query3 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '1' AND prodi = 'Pengolahan Limbah Industri'\";\n\t\t$query4 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Analisis Kimia'\";\n\t\t$query5 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Penjaminan Mutu Industri Pangan'\";\n\t\t$query6 = \"SELECT t_mk.kode_mk,t_mk.nama_mk,t_mk.jumlah_sks\t,t_mk.sks_teori,t_mk.sks_praktek,t_mk.semester,t_mk.pengisian_nilai,t_mk.status,t_mk.flag,t_mk.id_mk_prasarat,t_mk.id_mk_prak,t_mk.is_pratikum,t_mk.id_mk,t_prodi.id_prodi,t_prodi.prodi FROM t_mk INNER JOIN t_prodi ON t_mk.id_prodi=t_prodi.id_prodi WHERE semester = '2' AND prodi = 'Pengolahan Limbah Industri'\";\n\t\t$data['semester1A'] = $this->m_aka->query_aka($query1);\n\t\t$data['semester2A'] = $this->m_aka->query_aka($query4);\n\t\t$data['semester1B'] = $this->m_aka->query_aka($query2);\n\t\t$data['semester2B'] = $this->m_aka->query_aka($query5);\n\t\t$data['semester1C'] = $this->m_aka->query_aka($query3);\n\t\t$data['semester2C'] = $this->m_aka->query_aka($query6);\n\t\t$data['data'] = $this->m_aka->data_mata_kuliah(); \n\t\t$data['pagination'] = $this->pagination->create_links();\n\t\t$data['content'] = 'mata_kuliah/data_mata_kuliah';\n\t\t$this->load->view('content', $data);\n\t}", "function SHOWALL(){\r\n\r\n $stmt = $this->db->prepare(\"SELECT * FROM edificio\");\r\n $stmt->execute();\r\n $edificios_db = $stmt->fetchAll(PDO::FETCH_ASSOC);\r\n $alledificios = array(); //array para almacenar los datos de todos los edificios\r\n\r\n //Recorremos todos las filas de edificios devueltas por la sentencia sql\r\n foreach ($edificios_db as $edificio){\r\n //Introducimos uno a uno los edificios recuperados de la BD\r\n array_push($alledificios,\r\n new EDIFICIO_Model(\r\n $edificio['edificio_id'],$edificio['nombre_edif'],$edificio['direccion_edif']\r\n ,$edificio['telef_edif'],$edificio['num_plantas'],$edificio['agrup_edificio']\r\n )\r\n );\r\n }\r\n return $alledificios;\r\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('obats')->truncate();\n \n $data =[\n ['id'=> 1, 'id_obat' => 'konimexsanbe', 'nama_obat' => 'Konimex', 'keterangan' => 'Obat sakit kepala', 'perusahaan' => 'SANBE', 'jenis'=>'TABLET', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=> 2, 'id_obat' => 'sanmolsanbe', 'nama_obat' => 'Sanmol', 'keterangan' => 'Obat penurun panas', 'perusahaan' => 'SANBE', 'jenis'=>'TABLET', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=> 3, 'id_obat' => 'decolgensanbe', 'nama_obat' => 'Decolgen', 'keterangan' => 'Obat flu', 'perusahaan' => 'SANBE', 'jenis'=>'TABLET', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime],\n ['id'=> 4, 'id_obat' => 'konidinsanbe', 'nama_obat' => 'Konidin', 'keterangan' => 'Obat batuk cair', 'perusahaan' => 'SANBE', 'jenis'=>'SIRUP', 'kategori' => 'Obat', 'status' => 1, 'created_at' => new DateTime, 'updated_at' => new DateTime]\n ];\n DB::table('obats')->insert($data);\n }", "public function getAllDataGejala()\n {\n $query = $this->db->query('SELECT * FROM tb_gejala');\n return $query->result();\n }", "function db_dispense($table,$data){\n\t$db=R::dispense($table);\n\tforeach ($data as $key => $value) {\n\t\t$db->$key=$value;\n\t}\n\tR::store( $db );\n}", "public function tratarDados(){\r\n\t\r\n\t\r\n }", "public function importFromOraDB() {\n $main_db_ip = System::getInstance()->get('ORA_DB_HXWEB_IP');\n $main_db_port = System::getInstance()->get('ORA_DB_HXWEB_PORT');\n $latency = pingDomain($main_db_ip, $main_db_port);\n \n // not reachable\n if ($latency > 999 || $latency == '') {\n Logger::getInstance()->error(__METHOD__.': 無法連線主DB,無法進行匯入收件字快取資料庫。');\n return false;\n }\n\n $db = new OraDB();\n $sql = \"select * from MOIADM.RKEYN_ALL t\";\n $db->parse($sql);\n $db->execute();\n $rows = $db->fetchAll();\n $this->clean();\n $count = 0;\n foreach ($rows as $row) {\n $this->replace($row);\n $count++;\n }\n\n Logger::getInstance()->info(__METHOD__.': 匯入 '.$count.' 筆資料。 【RKEYN_ALL.db、RKEYN_ALL table】');\n\n return $count;\n }", "private function fetchDataFromDB($sql){\r\n $dbOps = new DBOperations();\r\n $dataFromDB = $dbOps->fetchData($sql);\r\n return $dataFromDB; \r\n }", "public function run()\n {\n DB::table('analisa_kursus_bahagian_b')->insert([[\n 'kursus' => 'Pengurusan pejabat',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Kepimpinan',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan Strategik',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pemikiran kreatif/selari',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Analytical Decision Making',\n 'analisa_bahagian_bahagian_b_id' => 1,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Penyeliaan berkesan',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Komunikasi berkesan',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan fail dan rekod',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan masa',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengendalian mesyuarat dan Penulisan minit berkualiti',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Perundingan berkesan',\n 'analisa_bahagian_bahagian_b_id' => 2,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Financial Reporting Standards and Accounting',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Auditing, assurance and risk management',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Taxation',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Management accounting and strategic management',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Transform to perform - The new emerging finance leaders',\n 'analisa_bahagian_bahagian_b_id' => 3,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pembangunan individu dan organisasi berintegriti',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Motivasi diri dan kecemerlangan diri',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pemanduan berhemah',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengukuhan Pasukan (Team Building)',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan stress',\n 'analisa_bahagian_bahagian_b_id' => 4,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Perhubungan perusahaan',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Penyelenggaraan fail dan rekod',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'mentoring and coaching',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'manual prosedur kerja',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'penulisan surat dan memo berkualiti',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'bahasa inggeris/mandarin/jepun',\n 'analisa_bahagian_bahagian_b_id' => 5,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'pengurusan projek di tapak bina',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kesihatan, keselamatan dan persekitaran (HSE) management system',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus green building index (GBI)',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Qlassic',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'International standards organization (ISO)',\n 'analisa_bahagian_bahagian_b_id' => 6,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus microsoft word 2007',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus microsoft excel 2007',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'kursus microsoft power point 2007',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'Pengurusan Emel/Internet',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ], [\n 'kursus' => 'pengurusan Portal/AutoCad',\n 'analisa_bahagian_bahagian_b_id' => 7,\n 'created_at' => \\Carbon\\Carbon::now()->toDateTimeString(),\n 'updated_at' => \\Carbon\\Carbon::now()->toDateTimeString()\n ]\n ]);\n }", "function tampilkan(){\r\n\t\t\t$query \t= \"SELECT * FROM data\";\r\n\t\t\treturn result($query);\r\n\t\t}", "public function fetchAll(){\n $adapter = $this->adapter;\n $sql = new Sql($this->adapter);\n $select = $sql->select();\n $select->from('flota');\n $selectString = $sql->getSqlStringForSqlObject($select);\n $data = $adapter->query($selectString, $adapter::QUERY_MODE_EXECUTE);\n \n return $data;\n }", "public function getMaquinas() {\n\n\t\t $command = \\Yii::$app->db_mysql;\n\t\t $sql=\"\n\t\t\tSELECT *\n\t\t\tFROM pdp_maquina\n\t\t\t \n\t\t \";\n\t\t $result =$command->createCommand($sql)\n\t\t\t\t\t\t\t->queryAll();\n\t\t \n\t\treturn $result;\n\t\t\n\t}", "function getDataPararel($conn,$key) {\n\t\t\t$sql = \"select k.kelasmk, k.dayatampung, k.jumlahpeserta from \".static::table('ak_kelas').\" k\n\t\t\t\t\twhere \".static::getCondition($key,'thnkurikulum,kodemk,kodeunit,periode','k').\"\n\t\t\t\t\torder by k.kelasmk\";\n\t\t\t\n\t\t\treturn $conn->GetArray($sql);\n\t\t}", "function semuaMahasiswa($query)\n{\n //karena $conn yang ada di file database.php berada diluar function semuaMahasiswa. jadi buat variable global untuk memanggilnya\n // agar variable $conn dapat digunakan\n global $conn;\n\n // array kosong untuk menyimpan dataMahasiswa\n\n $dataMahasiswa = $conn->query($query);\n return $dataMahasiswa; // untuk membuat function ini bernilai data 'dataMahasiswa'\n}", "public function getAllMahasiswa()\r\n {\r\n $this->db->query('SELECT * FROM ' . $this->table);\r\n return $this->db->resultSet();\r\n }", "function tampil_mahasiswa($id_mhs){\n\t\t\tglobal $con;\n\n\t\t\t$query=mysqli_query($con, \"SELECT a.*,b.*\n\t\t\t\t\t\t\t\t\t\tFROM tb_mahasiswa a,tb_prodi b \n\t\t\t\t\t\t\t\t\t\tWHERE a.id_prodi=b.id_prodi\n\t\t\t\t\t\t\t\t\t\tAND a.id_mhs='$id_mhs'\");\n\t\t\twhile($row=mysqli_fetch_array($query))\n\t\t\t\t$data[] = $row;\n\n\t\t\t\treturn $data;\n\t\t}" ]
[ "0.67226934", "0.6349393", "0.63246936", "0.6273119", "0.6261216", "0.6241883", "0.6208263", "0.61770004", "0.6175767", "0.61625063", "0.6153764", "0.6153557", "0.6125575", "0.60748523", "0.6011169", "0.6004141", "0.6003991", "0.59848", "0.59411055", "0.5935175", "0.5933395", "0.59141296", "0.5913797", "0.5903536", "0.59009707", "0.58966875", "0.58956176", "0.5895393", "0.58828264", "0.5854021", "0.5852818", "0.585158", "0.5851009", "0.58452094", "0.58448935", "0.58442193", "0.5829554", "0.5820502", "0.5818324", "0.58145607", "0.57968557", "0.5784416", "0.577867", "0.5774778", "0.5760752", "0.5759456", "0.57584876", "0.5749857", "0.5745726", "0.5742129", "0.5732735", "0.5730221", "0.57162243", "0.5707189", "0.570348", "0.57015926", "0.5688526", "0.56852233", "0.5683742", "0.5682989", "0.568193", "0.5673256", "0.5672728", "0.5663369", "0.56568736", "0.56568074", "0.5656567", "0.56512254", "0.56498086", "0.56459695", "0.56399643", "0.56393427", "0.5628855", "0.5626855", "0.5624662", "0.5614827", "0.56088454", "0.560829", "0.56080693", "0.5607453", "0.5601229", "0.5598667", "0.55871475", "0.55823827", "0.5581728", "0.55809873", "0.558087", "0.5580637", "0.55806273", "0.55806094", "0.55761427", "0.5573699", "0.55726403", "0.5569748", "0.5565345", "0.55641997", "0.55622077", "0.5555706", "0.55539227", "0.55537677", "0.55504495" ]
0.0
-1
Create a new controller instance.
public function __construct() { $this->middleware('auth'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function createController()\n {\n $this->createClass('controller');\n }", "protected function createController()\n {\n $controller = Str::studly(class_basename($this->getNameInput()));\n\n $modelName = $this->qualifyClass('Models/'.$this->getNameInput());\n\n $this->call('make:controller', array_filter([\n 'name' => \"{$controller}Controller\",\n '--model' => $modelName,\n '--api' => true,\n ]));\n }", "protected function createController()\n {\n $controller = Str::studly(class_basename($this->argument('name')));\n $model_name = $this->qualifyClass($this->getNameInput());\n $name = Str::contains($model_name, ['\\\\']) ? Str::afterLast($model_name, '\\\\') : $model_name;\n\n $this->call('make:controller', [\n 'name' => \"{$controller}Controller\",\n '--model' => $model_name,\n ]);\n\n $path = base_path() . \"/app/Http/Controllers/{$controller}Controller.php\";\n $this->cleanupDummy($path, $name);\n }", "private function makeInitiatedController()\n\t{\n\t\t$controller = new TestEntityCRUDController();\n\n\t\t$controller->setLoggerWrapper(Logger::create());\n\n\t\treturn $controller;\n\t}", "protected function createController()\n {\n $controller = Str::studly(class_basename($this->argument('name')));\n\n $modelName = $this->qualifyClass($this->getNameInput());\n\n $this->call(ControllerMakeCommand::class, array_filter([\n 'name' => \"{$controller}/{$controller}Controller\",\n '--model' => $this->option('resource') || $this->option('api') ? $modelName : null,\n ]));\n\n $this->call(ControllerMakeCommand::class, array_filter([\n 'name' => \"Api/{$controller}/{$controller}Controller\",\n '--model' => $this->option('resource') || $this->option('api') ? $modelName : null,\n '--api' => true,\n ]));\n }", "protected function createController()\n {\n $name = str_replace(\"Service\",\"\",$this->argument('name'));\n\n $this->call('make:controller', [\n 'name' => \"{$name}Controller\"\n ]);\n }", "protected function createController()\n {\n $params = [\n 'name' => $this->argument('name'),\n ];\n\n if ($this->option('api')) {\n $params['--api'] = true;\n }\n\n $this->call('wizard:controller', $params);\n }", "public function generateController () {\r\n $controllerParam = \\app\\lib\\router::getPath();\r\n $controllerName = \"app\\controller\\\\\" . end($controllerParam);\r\n $this->controller = new $controllerName;\r\n }", "public static function newController($controller)\n\t{\n\t\t$objController = \"App\\\\Controllers\\\\\".$controller;\n\t\treturn new $objController;\n\t}", "public function createController()\n\t{\n\t\tif(class_exists($this->controller))\n\t\t{\n\t\t\t// get the parent class he extends\n\t\t\t$parents = class_parents($this->controller);\n\n\t\t\t// $parents = class_implements($this->controller); used if our Controller was just an interface not a class\n\n\t\t\t// check if the class implements our Controller Class\n\t\t\tif(in_array(\"Controller\", $parents))\n\t\t\t{\n\t\t\t\t// check if the action in the request exists in that class\n\t\t\t\tif(method_exists($this->controller, $this->action))\n\t\t\t\t{\n\t\t\t\t\treturn new $this->controller($this->action, $this->request);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t// Action is not exist\n\t\t\t\t\techo 'Method '. $this->action .' doesn\\'t exist in '. $this->controller;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// The controller doesn't extends our Controller Class\n\t\t\t\techo $this->controller.' doesn\\'t extends our Controller Class';\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// Controller Doesn't exist\n\t\t\techo $this->controller.' doesn\\'t exist';\n\t\t}\n\t}", "public function createController( ezcMvcRequest $request );", "public function createController() {\n //check our requested controller's class file exists and require it if so\n /*if (file_exists(__DIR__ . \"/../Controllers/\" . $this->controllerName . \".php\")) {\n require(__DIR__ . \"/../Controllers/\" . $this->controllerName . \".php\");\n } else {\n throw new Exception('Route does not exist');\n }*/\n\n try {\n require_once __DIR__ . '/../Controllers/' . $this->controllerName . '.php';\n } catch (Exception $e) {\n return $e;\n }\n \n //does the class exist?\n if (class_exists($this->controllerClass)) {\n $parents = class_parents($this->controllerClass);\n \n //does the class inherit from the BaseController class?\n if (in_array(\"BaseController\",$parents)) { \n //does the requested class contain the requested action as a method?\n if (method_exists($this->controllerClass, $this->endpoint)) {\n return new $this->controllerClass($this->args, $this->endpoint, $this->domain);\n } else {\n throw new Exception('Action does not exist');\n }\n } else {\n throw new Exception('Class does not inherit correctly.');\n }\n } else {\n throw new Exception('Controller does not exist.');\n }\n }", "public static function create()\n\t{\n\t\t//check, if a JobController instance already exists\n\t\tif(JobController::$jobController == null)\n\t\t{\n\t\t\tJobController::$jobController = new JobController();\n\t\t}\n\n\t\treturn JobController::$jobController;\n\t}", "private function controller()\n {\n $location = $this->args[\"location\"] . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR;\n $relative_location = $this->args['application_folder'] . DIRECTORY_SEPARATOR . 'controllers' . DIRECTORY_SEPARATOR;\n\n if (!empty($this->args['subdirectories']))\n {\n $location .= $this->args['subdirectories'] . DIRECTORY_SEPARATOR;\n $relative_location .= $this->args['subdirectories'] . DIRECTORY_SEPARATOR;\n }\n\n if (!is_dir($location))\n {\n mkdir($location, 0755, TRUE);\n }\n\n $relative_location .= $this->args['filename'];\n $filename = $location . $this->args['filename'];\n\n $args = array(\n \"class_name\" => ApplicationHelpers::camelize($this->args['name']),\n \"filename\" => $this->args['filename'],\n \"application_folder\" => $this->args['application_folder'],\n \"parent_class\" => (isset($this->args['parent'])) ? $this->args['parent'] : $this->args['parent_controller'],\n \"extra\" => $this->extra,\n 'relative_location' => $relative_location,\n 'helper_name' => strtolower($this->args['name']) . '_helper',\n );\n\n $template = new TemplateScanner(\"controller\", $args);\n $controller = $template->parse();\n\n $message = \"\\t\";\n if (file_exists($filename))\n {\n $message .= 'Controller already exists : ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'light_blue');\n }\n $message .= $relative_location;\n }\n elseif (file_put_contents($filename, $controller))\n {\n $message .= 'Created controller: ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'green');\n }\n $message .= $relative_location;\n }\n else\n {\n $message .= 'Unable to create controller: ';\n if (php_uname(\"s\") !== \"Windows NT\")\n {\n $message = ApplicationHelpers::colorize($message, 'red');\n }\n $message .= $relative_location;\n }\n\n // The controller has been generated, output the confirmation message\n fwrite(STDOUT, $message . PHP_EOL);\n\n // Create the helper files.\n $this->helpers();\n\n $this->assets();\n\n // Create the view files.\n $this->views();\n\n return;\n }", "public function createController( $controllerName ) {\r\n\t\t$refController \t\t= $this->instanceOfController( $controllerName );\r\n\t\t$refConstructor \t= $refController->getConstructor();\r\n\t\tif ( ! $refConstructor ) return $refController->newInstance();\r\n\t\t$initParameter \t\t= $this->setParameter( $refConstructor );\r\n\t\treturn $refController->newInstanceArgs( $initParameter ); \r\n\t}", "public function create($controllerName) {\r\n\t\tif (!$controllerName)\r\n\t\t\t$controllerName = $this->defaultController;\r\n\r\n\t\t$controllerName = ucfirst(strtolower($controllerName)).'Controller';\r\n\t\t$controllerFilename = $this->searchDir.'/'.$controllerName.'.php';\r\n\r\n\t\tif (preg_match('/[^a-zA-Z0-9]/', $controllerName))\r\n\t\t\tthrow new Exception('Invalid controller name', 404);\r\n\r\n\t\tif (!file_exists($controllerFilename)) {\r\n\t\t\tthrow new Exception('Controller not found \"'.$controllerName.'\"', 404);\r\n\t\t}\r\n\r\n\t\trequire_once $controllerFilename;\r\n\r\n\t\tif (!class_exists($controllerName) || !is_subclass_of($controllerName, 'Controller'))\r\n\t\t\tthrow new Exception('Unknown controller \"'.$controllerName.'\"', 404);\r\n\r\n\t\t$this->controller = new $controllerName();\r\n\t\treturn $this;\r\n\t}", "private function createController($controllerName)\n {\n $className = ucfirst($controllerName) . 'Controller';\n ${$this->lcf($controllerName) . 'Controller'} = new $className();\n return ${$this->lcf($controllerName) . 'Controller'};\n }", "public function createControllerObject(string $controller)\n {\n $this->checkControllerExists($controller);\n $controller = $this->ctlrStrSrc.$controller;\n $controller = new $controller();\n return $controller;\n }", "public function create_controller($controller, $action){\n\t $creado = false;\n\t\t$controllers_dir = Kumbia::$active_controllers_dir;\n\t\t$file = strtolower($controller).\"_controller.php\";\n\t\tif(file_exists(\"$controllers_dir/$file\")){\n\t\t\tFlash::error(\"Error: El controlador '$controller' ya existe\\n\");\n\t\t} else {\n\t\t\tif($this->post(\"kind\")==\"applicationcontroller\"){\n\t\t\t\t$filec = \"<?php\\n\t\t\t\\n\tclass \".ucfirst($controller).\"Controller extends ApplicationController {\\n\\n\\t\\tfunction $action(){\\n\\n\\t\\t}\\n\\n\t}\\n\t\\n?>\\n\";\n\t\t\t\tif(@file_put_contents(\"$controllers_dir/$file\", $filec)){\n\t\t\t\t $creado = true;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\t$filec = \"<?php\\n\t\t\t\\n\tclass \".ucfirst($controller).\"Controller extends StandardForm {\\n\\n\\t\\tpublic \\$scaffold = true;\\n\\n\\t\\tpublic function __construct(){\\n\\n\\t\\t}\\n\\n\t}\\n\t\\n?>\\n\";\n\t\t\t\tfile_put_contents(\"$controllers_dir/$file\", $filec);\n\t\t\t\tif($this->create_model($controller, $controller, \"index\")){\n\t\t\t\t $creado = true;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif($creado){\n\t\t\t Flash::success(\"Se cre&oacute; correctamente el controlador '$controller' en '$controllers_dir/$file'\");\n\t\t\t}else {\n\t\t\t Flash::error(\"Error: No se pudo escribir en el directorio, verifique los permisos sobre el directorio\");\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t$this->route_to(\"controller: $controller\", \"action: $action\");\n\t}", "private function instanceController( string $controller_class ): Controller {\n\t\treturn new $controller_class( $this->request, $this->site );\n\t}", "public function makeController($controller_name)\n\t{\n\t\t$model\t= $this->_makeModel($controller_name, $this->_storage_type);\n\t\t$view\t= $this->_makeView($controller_name);\n\t\t\n\t\treturn new $controller_name($model, $view);\n\t}", "public function create()\n {\n $output = new \\Symfony\\Component\\Console\\Output\\ConsoleOutput();\n $output->writeln(\"<info>Controller Create</info>\");\n }", "protected function createDefaultController() {\n Octopus::requireOnce($this->app->getOption('OCTOPUS_DIR') . 'controllers/Default.php');\n return new DefaultController();\n }", "private function createControllerDefinition()\n {\n $id = $this->getServiceId('controller');\n if (!$this->container->has($id)) {\n $definition = new Definition($this->getServiceClass('controller'));\n $definition\n ->addMethodCall('setConfiguration', [new Reference($this->getServiceId('configuration'))])\n ->addMethodCall('setContainer', [new Reference('service_container')])\n ;\n $this->container->setDefinition($id, $definition);\n }\n }", "public function createController( $ctrlName, $action ) {\n $args['action'] = $action;\n $args['path'] = $this->path . '/modules/' . $ctrlName;\n $ctrlFile = $args['path'] . '/Controller.php';\n // $args['moduleName'] = $ctrlName;\n if ( file_exists( $ctrlFile ) ) {\n $ctrlPath = str_replace( CITRUS_PATH, '', $args['path'] );\n $ctrlPath = str_replace( '/', '\\\\', $ctrlPath ) . '\\Controller';\n try { \n $r = new \\ReflectionClass( $ctrlPath ); \n $inst = $r->newInstanceArgs( $args ? $args : array() );\n\n $this->controller = Citrus::apply( $inst, Array( \n 'name' => $ctrlName, \n ) );\n if ( $this->controller->is_protected == null ) {\n $this->controller->is_protected = $this->is_protected;\n }\n return $this->controller;\n } catch ( \\Exception $e ) {\n prr($e, true);\n }\n } else {\n return false;\n }\n }", "protected function createTestController() {\n\t\t$controller = new CController('test');\n\n\t\t$action = $this->getMock('CAction', array('run'), array($controller, 'test'));\n\t\t$controller->action = $action;\n\n\t\tYii::app()->controller = $controller;\n\t\treturn $controller;\n\t}", "public static function newController($controllerName, $params = [], $request = null) {\n\n\t\t$controller = \"App\\\\Controllers\\\\\".$controllerName;\n\n\t\treturn new $controller($params, $request);\n\n\t}", "private function loadController() : void\n\t{\n\t\t$this->controller = new $this->controllerName($this->request);\n\t}", "public function createController($pi, array $params)\n {\n $class = $pi . '_Controller_' . ucfirst($params['page']);\n\n return new $class();\n }", "public function createController() {\n //check our requested controller's class file exists and require it if so\n \n if (file_exists(\"modules/\" . $this->controllerName . \"/controllers/\" . $this->controllerName .\".php\" ) && $this->controllerName != 'error') {\n require(\"modules/\" . $this->controllerName . \"/controllers/\" . $this->controllerName .\".php\");\n \n } else {\n \n $this->urlValues['controller'] = \"error\";\n require(\"modules/error/controllers/error.php\");\n return new ErrorController(\"badurl\", $this->urlValues);\n }\n\n //does the class exist?\n if (class_exists($this->controllerClass)) {\n $parents = class_parents($this->controllerClass);\n //does the class inherit from the BaseController class?\n if (in_array(\"BaseController\", $parents)) {\n //does the requested class contain the requested action as a method?\n if (method_exists($this->controllerClass, $this->action)) { \n return new $this->controllerClass($this->action, $this->urlValues);\n \n } else {\n //bad action/method error\n $this->urlValues['controller'] = \"error\";\n require(\"modules/error/controllers/error.php\");\n return new ErrorController(\"badview\", $this->urlValues);\n }\n } else {\n $this->urlValues['controller'] = \"error\";\n //bad controller error\n echo \"hjh\";\n require(\"modules/error/controllers/error.php\");\n return new ErrorController(\"b\", $this->urlValues);\n }\n } else {\n \n //bad controller error\n require(\"modules/error/controllers/error.php\");\n return new ErrorController(\"badurl\", $this->urlValues);\n }\n }", "protected static function createController($name) {\n $result = null;\n\n $name = self::$_namespace . ($name ? $name : self::$defaultController) . 'Controller';\n if(class_exists($name)) {\n $controllerClass = new \\ReflectionClass($name);\n if($controllerClass->hasMethod('run')) {\n $result = new $name();\n }\n }\n\n return $result;\n }", "public function createController(): void\n {\n $minimum_buffer_min = 3;\n $token_ok = $this->routerService->ds_token_ok($minimum_buffer_min);\n if ($token_ok) {\n # 2. Call the worker method\n # More data validation would be a good idea here\n # Strip anything other than characters listed\n $results = $this->worker($this->args);\n\n if ($results) {\n # Redirect the user to the NDSE view\n # Don't use an iFrame!\n # State can be stored/recovered using the framework's session or a\n # query parameter on the returnUrl\n header('Location: ' . $results[\"redirect_url\"]);\n exit;\n }\n } else {\n $this->clientService->needToReAuth($this->eg);\n }\n }", "protected function createController($controllerClass)\n {\n $cls = new ReflectionClass($controllerClass);\n return $cls->newInstance($this->environment);\n }", "protected function createController($name)\n {\n $controllerClass = 'controller\\\\'.ucfirst($name).'Controller';\n\n if(!class_exists($controllerClass)) {\n throw new \\Exception('Controller class '.$controllerClass.' not exists!');\n }\n\n return new $controllerClass();\n }", "protected function initController() {\n\t\tif (!isset($_GET['controller'])) {\n\t\t\t$this->initDefaultController();\n\t\t\treturn;\n\t\t}\n\t\t$controllerClass = $_GET['controller'].\"Controller\";\n\t\tif (!class_exists($controllerClass)) {\n\t\t\t//Console::error(@$_GET['controller'].\" doesn't exist\");\n\t\t\t$this->initDefaultController();\n\t\t\treturn;\n\t\t}\n\t\t$this->controller = new $controllerClass();\n\t}", "public function makeTestController(TestController $controller)\r\n\t{\r\n\t}", "static function factory($GET=array(), $POST=array(), $FILES=array()) {\n $type = (isset($GET['type'])) ? $GET['type'] : '';\n $objectController = $type.'_Controller';\n $addLocation = $type.'/'.$objectController.'.php';\n foreach ($_ENV['locations'] as $location) {\n if (is_file($location.$addLocation)) {\n return new $objectController($GET, $POST, $FILES);\n } \n }\n throw new Exception('The controller \"'.$type.'\" does not exist.');\n }", "public function create()\n {\n $general = new ModeloController();\n\n return $general->create();\n }", "public function makeController($controllerNamespace, $controllerName, Log $log, $session, Request $request, Response $response)\r\n\t{\r\n\t\t$fullControllerName = '\\\\Application\\\\Controller\\\\' . (!empty($controllerNamespace) ? $controllerNamespace . '\\\\' : '') . $controllerName;\r\n\t\t$controller = new $fullControllerName();\r\n\t\t$controller->setConfig($this->config);\r\n\t\t$controller->setRequest($request);\r\n\t\t$controller->setResponse($response);\r\n\t\t$controller->setLog($log);\r\n\t\tif (isset($session))\r\n\t\t{\r\n\t\t\t$controller->setSession($session);\r\n\t\t}\r\n\r\n\t\t// Execute additional factory method, if available (exists in \\Application\\Controller\\Factory)\r\n\t\t$method = 'make' . $controllerName;\r\n\t\tif (is_callable(array($this, $method)))\r\n\t\t{\r\n\t\t\t$this->$method($controller);\r\n\t\t}\r\n\r\n\t\t// If the controller has an init() method, call it now\r\n\t\tif (is_callable(array($controller, 'init')))\r\n\t\t{\r\n\t\t\t$controller->init();\r\n\t\t}\r\n\r\n\t\treturn $controller;\r\n\t}", "public static function create()\n\t{\n\t\t//check, if an AccessGroupController instance already exists\n\t\tif(AccessGroupController::$accessGroupController == null)\n\t\t{\n\t\t\tAccessGroupController::$accessGroupController = new AccessGroupController();\n\t\t}\n\n\t\treturn AccessGroupController::$accessGroupController;\n\t}", "public static function buildController()\n\t{\n\t\t$file = CONTROLLER_PATH . 'indexController.class.php';\n\n\t\tif(!file_exists($file))\n\t\t{\n\t\t\tif(\\RCPHP\\Util\\Check::isClient())\n\t\t\t{\n\t\t\t\t$controller = '<?php\nclass indexController extends \\RCPHP\\Controller {\n public function index(){\n echo \"Welcome RcPHP!\\n\";\n }\n}';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$controller = '<?php\nclass indexController extends \\RCPHP\\Controller {\n public function index(){\n echo \\'<style type=\"text/css\">*{ padding: 0; margin: 0; } div{ padding: 4px 48px;} body{ background: #fff; font-family: \"微软雅黑\"; color: #333;} h1{ font-size: 100px; font-weight: normal; margin-bottom: 12px; } p{ line-height: 1.8em; font-size: 36px }</style><div style=\"padding: 24px 48px;\"> <h1>:)</h1><p>Welcome <b>RcPHP</b>!</p></div>\\';\n }\n}';\n\t\t\t}\n\t\t\tfile_put_contents($file, $controller);\n\t\t}\n\t}", "public function getController( );", "public static function getInstance() : Controller {\n if ( null === self::$instance ) {\n self::$instance = new self();\n self::$instance->options = new Options(\n self::OPTIONS_KEY\n );\n }\n\n return self::$instance;\n }", "static function appCreateController($entityName, $prefijo = '') {\n\n $controller = ControllerBuilder::getController($entityName, $prefijo);\n $entityFile = ucfirst(str_replace($prefijo, \"\", $entityName));\n $fileController = \"../../modules/{$entityFile}/{$entityFile}Controller.class.php\";\n\n $result = array();\n $ok = self::createArchive($fileController, $controller);\n ($ok) ? array_push($result, \"Ok, {$fileController} created\") : array_push($result, \"ERROR creating {$fileController}\");\n\n return $result;\n }", "public static function newInstance($path = \\simpleChat\\Utility\\ROOT_PATH)\n {\n $request = new Request();\n \n \n if ($request->isAjax())\n {\n return new AjaxController();\n }\n else if ($request->jsCode())\n {\n return new JsController();\n }\n else\n {\n return new StandardController($path);\n }\n }", "private function createInstance()\n {\n $objectManager = new \\Magento\\Framework\\TestFramework\\Unit\\Helper\\ObjectManager($this);\n $this->controller = $objectManager->getObject(\n \\Magento\\NegotiableQuote\\Controller\\Adminhtml\\Quote\\RemoveFailedSku::class,\n [\n 'context' => $this->context,\n 'logger' => $this->logger,\n 'messageManager' => $this->messageManager,\n 'cart' => $this->cart,\n 'resultRawFactory' => $this->resultRawFactory\n ]\n );\n }", "function loadController(){\n $name = ucfirst($this->request->controller).'Controller' ;\n $file = ROOT.DS.'Controller'.DS.$name.'.php' ;\n /*if(!file_exists($file)){\n $this->error(\"Le controleur \".$this->request->controller.\" n'existe pas\") ;\n }*/\n require_once $file;\n $controller = new $name($this->request);\n return $controller ;\n }", "public function __construct(){\r\n $app = Application::getInstance();\r\n $this->_controller = $app->getController();\r\n }", "public static function & instance()\n {\n if (self::$instance === null) {\n Benchmark::start(SYSTEM_BENCHMARK.'_controller_setup');\n\n // Include the Controller file\n require Router::$controller_path;\n\n try {\n // Start validation of the controller\n $class = new ReflectionClass(ucfirst(Router::$controller).'_Controller');\n } catch (ReflectionException $e) {\n // Controller does not exist\n Event::run('system.404');\n }\n\n if ($class->isAbstract() or (IN_PRODUCTION and $class->getConstant('ALLOW_PRODUCTION') == false)) {\n // Controller is not allowed to run in production\n Event::run('system.404');\n }\n\n // Run system.pre_controller\n Event::run('system.pre_controller');\n\n // Create a new controller instance\n $controller = $class->newInstance();\n\n // Controller constructor has been executed\n Event::run('system.post_controller_constructor');\n\n try {\n // Load the controller method\n $method = $class->getMethod(Router::$method);\n\n // Method exists\n if (Router::$method[0] === '_') {\n // Do not allow access to hidden methods\n Event::run('system.404');\n }\n\n if ($method->isProtected() or $method->isPrivate()) {\n // Do not attempt to invoke protected methods\n throw new ReflectionException('protected controller method');\n }\n\n // Default arguments\n $arguments = Router::$arguments;\n } catch (ReflectionException $e) {\n // Use __call instead\n $method = $class->getMethod('__call');\n\n // Use arguments in __call format\n $arguments = array(Router::$method, Router::$arguments);\n }\n\n // Stop the controller setup benchmark\n Benchmark::stop(SYSTEM_BENCHMARK.'_controller_setup');\n\n // Start the controller execution benchmark\n Benchmark::start(SYSTEM_BENCHMARK.'_controller_execution');\n\n // Execute the controller method\n $method->invokeArgs($controller, $arguments);\n\n // Controller method has been executed\n Event::run('system.post_controller');\n\n // Stop the controller execution benchmark\n Benchmark::stop(SYSTEM_BENCHMARK.'_controller_execution');\n }\n\n return self::$instance;\n }", "protected function instantiateController($class)\n {\n $controller = new $class();\n\n if ($controller instanceof Controller) {\n $controller->setContainer($this->container);\n }\n\n return $controller;\n }", "public function __construct (){\n $this->AdminController = new AdminController();\n $this->ArticleController = new ArticleController();\n $this->AuditoriaController = new AuditoriaController();\n $this->CommentController = new CommentController();\n $this->CourseController = new CourseController();\n $this->InscriptionsController = new InscriptionsController();\n $this->ModuleController = new ModuleController();\n $this->PlanController = new PlanController();\n $this->ProfileController = new ProfileController();\n $this->SpecialtyController = new SpecialtyController();\n $this->SubscriptionController = new SubscriptionController();\n $this->TeacherController = new TeacherController();\n $this->UserController = new UserController();\n $this->WebinarController = new WebinarController();\n }", "protected function makeController($prefix)\n {\n new MakeController($this, $this->files, $prefix);\n }", "public function createController($route)\n {\n $controller = parent::createController('gymv/' . $route);\n return $controller === false\n ? parent::createController($route)\n : $controller;\n }", "public static function createFrontController()\n {\n return self::createInjectorWithBindings(self::extractArgs(func_get_args()))\n ->getInstance('net::stubbles::websites::stubFrontController');\n }", "public static function controller($name)\n {\n $name = ucfirst(strtolower($name));\n \n $directory = 'controller';\n $filename = $name;\n $tracker = 'controller';\n $init = (boolean) $init;\n $namespace = 'controller';\n $class_name = $name;\n \n return self::_load($directory, $filename, $tracker, $init, $namespace, $class_name);\n }", "protected static function instantiateMockController()\n {\n /** @var Event $oEvent */\n $oEvent = Factory::service('Event');\n\n if (!$oEvent->hasBeenTriggered(Events::SYSTEM_STARTING)) {\n\n require_once BASEPATH . 'core/Controller.php';\n\n load_class('Output', 'core');\n load_class('Security', 'core');\n load_class('Input', 'core');\n load_class('Lang', 'core');\n\n new NailsMockController();\n }\n }", "private static function controller()\n {\n $files = ['Controller'];\n $folder = static::$root.'MVC'.'/';\n\n self::call($files, $folder);\n }", "public function createController()\n\t{\n\t\t$originalFile = app_path('Http/Controllers/Reports/SampleReport.php');\n\t\t$newFile = dirname($originalFile) . DIRECTORY_SEPARATOR . $this->class . $this->sufix . '.php';\n\n\t\t// Read original file\n\t\tif( ! $content = file_get_contents($originalFile))\n\t\t\treturn false;\n\n\t\t// Replace class name\n\t\t$content = str_replace('SampleReport', $this->class . $this->sufix, $content);\n\n\t\t// Write new file\n\t\treturn (bool) file_put_contents($newFile, $content);\n\t}", "public function runController() {\n // Check for a router\n if (is_null($this->getRouter())) {\n \t // Set the method to load\n \t $sController = ucwords(\"{$this->getController()}Controller\");\n } else {\n\n // Set the controller with the router\n $sController = ucwords(\"{$this->getController()}\".ucfirst($this->getRouter()).\"Controller\");\n }\n \t// Check for class\n \tif (class_exists($sController, true)) {\n \t\t// Set a new instance of Page\n \t\t$this->setPage(new Page());\n \t\t// The class exists, load it\n \t\t$oController = new $sController();\n\t\t\t\t// Now check for the proper method \n\t\t\t\t// inside of the controller class\n\t\t\t\tif (method_exists($oController, $this->loadConfigVar('systemSettings', 'controllerLoadMethod'))) {\n\t\t\t\t\t// We have a valid controller, \n\t\t\t\t\t// execute the initializer\n\t\t\t\t\t$oController->init($this);\n\t\t\t\t\t// Set the variable scope\n\t \t\t$this->setViewScope($oController);\n\t \t\t// Render the layout\n\t \t\t$this->renderLayout();\n\t\t\t\t} else {\n\t\t\t\t\t// The initializer does not exist, \n\t\t\t\t\t// which means an invalid controller, \n\t\t\t\t\t// so now we let the caller know\n\t\t\t\t\t$this->setError($this->loadConfigVar('errorMessages', 'invalidController'));\n\t\t\t\t\t// Run the error\n\t\t\t\t\t// $this->runError();\n\t\t\t\t}\n \t// The class does not exist\n \t} else {\n\t\t\t\t// Set the system error\n\t \t\t$this->setError(\n\t\t\t\t\tstr_replace(\n\t\t\t\t\t\t':controllerName', \n\t\t\t\t\t\t$sController, \n\t\t\t\t\t\t$this->loadConfigVar(\n\t\t\t\t\t\t\t'errorMessages', \n\t\t\t\t\t\t\t'controllerDoesNotExist'\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t);\n \t\t// Run the error\n\t\t\t\t// $this->runError();\n \t}\n \t// Return instance\n \treturn $this;\n }", "public function controller()\n\t{\n\t\n\t}", "protected function buildController()\n {\n $columns = collect($this->columns)->pluck('column')->implode('|');\n\n $permissions = [\n 'create:'.$this->module->createPermission->name,\n 'edit:'.$this->module->editPermission->name,\n 'delete:'.$this->module->deletePermission->name,\n ];\n\n $this->controller = [\n 'name' => $this->class,\n '--model' => $this->class,\n '--request' => $this->class.'Request',\n '--permissions' => implode('|', $permissions),\n '--view-folder' => snake_case($this->module->name),\n '--fields' => $columns,\n '--module' => $this->module->id,\n ];\n }", "function getController(){\n\treturn getFactory()->getBean( 'Controller' );\n}", "protected function getController()\n {\n $uri = WingedLib::clearPath(static::$parentUri);\n if (!$uri) {\n $uri = './';\n $explodedUri = ['index', 'index'];\n } else {\n $explodedUri = explode('/', $uri);\n if (count($explodedUri) == 1) {\n $uri = './' . $explodedUri[0] . '/';\n } else {\n $uri = './' . $explodedUri[0] . '/' . $explodedUri[1] . '/';\n }\n }\n\n $indexUri = WingedLib::clearPath(\\WingedConfig::$config->INDEX_ALIAS_URI);\n if ($indexUri) {\n $indexUri = explode('/', $indexUri);\n }\n\n if ($indexUri) {\n if ($explodedUri[0] === 'index' && isset($indexUri[0])) {\n static::$controllerName = Formater::camelCaseClass($indexUri[0]) . 'Controller';\n $uri = './' . $indexUri[0] . '/';\n }\n if (isset($explodedUri[1]) && isset($indexUri[1])) {\n if ($explodedUri[1] === 'index') {\n static::$controllerAction = 'action' . Formater::camelCaseMethod($indexUri[1]);\n $uri .= $indexUri[1] . '/';\n }\n } else {\n $uri .= 'index/';\n }\n }\n\n $controllerDirectory = new Directory(static::$parent . 'controllers/', false);\n if ($controllerDirectory->exists()) {\n $controllerFile = new File($controllerDirectory->folder . static::$controllerName . '.php', false);\n if ($controllerFile->exists()) {\n include_once $controllerFile->file_path;\n if (class_exists(static::$controllerName)) {\n $controller = new static::$controllerName();\n if (method_exists($controller, static::$controllerAction)) {\n try {\n $reflectionMethod = new \\ReflectionMethod(static::$controllerName, static::$controllerAction);\n $pararms = [];\n foreach ($reflectionMethod->getParameters() as $parameter) {\n $pararms[$parameter->getName()] = $parameter->isOptional();\n }\n } catch (\\Exception $exception) {\n $pararms = [];\n }\n return [\n 'uri' => $uri,\n 'params' => $pararms,\n ];\n }\n }\n }\n }\n return false;\n }", "public function __construct()\n {\n $this->controller = new DHTController();\n }", "public function createController($controllers) {\n\t\tforeach($controllers as $module=>$controllers) {\n\t\t\tforeach($controllers as $key=>$controller) {\n\t\t\t\tif(!file_exists(APPLICATION_PATH.\"/modules/$module/controllers/\".ucfirst($controller).\"Controller.php\")) {\n\t\t\t\t\tMy_Class_Maerdo_Console::display(\"3\",\"Create '\".ucfirst($controller).\"' controller in $module\");\t\t\t\t\n\t\t\t\t\texec(\"zf create controller $controller index-action-included=0 $module\");\t\t\t\t\t\n\t\t\t\t}\telse {\n\t\t\t\t\tMy_Class_Maerdo_Console::display(\"3\",ucfirst($controller).\"' controller in $module already exists\");\t\n\t\t\t\t}\n\t\t\t}\t\n\t\t}\n\t}", "protected function instantiateController($class)\n {\n return new $class($this->routesMaker);\n }", "private function createController($table){\n\n // Filtering file name\n $fileName = $this::cleanToName($table[\"name\"]) . 'Controller.php';\n\n // Prepare the Class scheme inside the controller\n $contents = '<?php '.$fileName.' ?>';\n\n\n // Return a boolean to process completed\n return Storage::disk('controllers')->put($this->appNamePath.'/'.$fileName, $contents);\n\n }", "public function GetController()\n\t{\n\t\t$params = $this->QueryVarArrayToParameterArray($_GET);\n\t\tif (!empty($_POST)) {\n\t\t\t$params = array_merge($params, $this->QueryVarArrayToParameterArray($_POST));\n\t\t}\n\n\t\tif (!empty($_GET['q'])) {\n\t\t\t$restparams = GitPHP_Router::ReadCleanUrl($_SERVER['REQUEST_URI']);\n\t\t\tif (count($restparams) > 0)\n\t\t\t\t$params = array_merge($params, $restparams);\n\t\t}\n\n\t\t$controller = null;\n\n\t\t$action = null;\n\t\tif (!empty($params['action']))\n\t\t\t$action = $params['action'];\n\n\t\tswitch ($action) {\n\n\n\t\t\tcase 'search':\n\t\t\t\t$controller = new GitPHP_Controller_Search();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'commitdiff':\n\t\t\tcase 'commitdiff_plain':\n\t\t\t\t$controller = new GitPHP_Controller_Commitdiff();\n\t\t\t\tif ($action === 'commitdiff_plain')\n\t\t\t\t\t$controller->SetParam('output', 'plain');\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'blobdiff':\n\t\t\tcase 'blobdiff_plain':\n\t\t\t\t$controller = new GitPHP_Controller_Blobdiff();\n\t\t\t\tif ($action === 'blobdiff_plain')\n\t\t\t\t\t$controller->SetParam('output', 'plain');\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'history':\n\t\t\t\t$controller = new GitPHP_Controller_History();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'shortlog':\n\t\t\tcase 'log':\n\t\t\t\t$controller = new GitPHP_Controller_Log();\n\t\t\t\tif ($action === 'shortlog')\n\t\t\t\t\t$controller->SetParam('short', true);\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'snapshot':\n\t\t\t\t$controller = new GitPHP_Controller_Snapshot();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'tree':\n\t\t\tcase 'trees':\n\t\t\t\t$controller = new GitPHP_Controller_Tree();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'tags':\n\t\t\t\tif (empty($params['tag'])) {\n\t\t\t\t\t$controller = new GitPHP_Controller_Tags();\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\tcase 'tag':\n\t\t\t\t$controller = new GitPHP_Controller_Tag();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'heads':\n\t\t\t\t$controller = new GitPHP_Controller_Heads();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'blame':\n\t\t\t\t$controller = new GitPHP_Controller_Blame();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'blob':\n\t\t\tcase 'blobs':\n\t\t\tcase 'blob_plain':\t\n\t\t\t\t$controller = new GitPHP_Controller_Blob();\n\t\t\t\tif ($action === 'blob_plain')\n\t\t\t\t\t$controller->SetParam('output', 'plain');\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'atom':\n\t\t\tcase 'rss':\n\t\t\t\t$controller = new GitPHP_Controller_Feed();\n\t\t\t\tif ($action == 'rss')\n\t\t\t\t\t$controller->SetParam('format', GitPHP_Controller_Feed::RssFormat);\n\t\t\t\telse if ($action == 'atom')\n\t\t\t\t\t$controller->SetParam('format', GitPHP_Controller_Feed::AtomFormat);\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'commit':\n\t\t\tcase 'commits':\n\t\t\t\t$controller = new GitPHP_Controller_Commit();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'summary':\n\t\t\t\t$controller = new GitPHP_Controller_Project();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'project_index':\n\t\t\tcase 'projectindex':\n\t\t\t\t$controller = new GitPHP_Controller_ProjectList();\n\t\t\t\t$controller->SetParam('txt', true);\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'opml':\n\t\t\t\t$controller = new GitPHP_Controller_ProjectList();\n\t\t\t\t$controller->SetParam('opml', true);\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'login':\n\t\t\t\t$controller = new GitPHP_Controller_Login();\n\t\t\t\tif (!empty($_POST['username']))\n\t\t\t\t\t$controller->SetParam('username', $_POST['username']);\n\t\t\t\tif (!empty($_POST['password']))\n\t\t\t\t\t$controller->SetParam('password', $_POST['password']);\n\t\t\t\tbreak;\n\n\t\t\tcase 'logout':\n\t\t\t\t$controller = new GitPHP_Controller_Logout();\n\t\t\t\tbreak;\n\n\n\t\t\tcase 'graph':\n\t\t\tcase 'graphs':\n\t\t\t\t//$controller = new GitPHP_Controller_Graph();\n\t\t\t\t//break;\n\t\t\tcase 'graphdata':\n\t\t\t\t//$controller = new GitPHP_Controller_GraphData();\n\t\t\t\t//break;\n\t\t\tdefault:\n\t\t\t\tif (!empty($params['project'])) {\n\t\t\t\t\t$controller = new GitPHP_Controller_Project();\n\t\t\t\t} else {\n\t\t\t\t\t$controller = new GitPHP_Controller_ProjectList();\n\t\t\t\t}\n\t\t}\n\n\t\tforeach ($params as $paramname => $paramval) {\n\t\t\tif ($paramname !== 'action')\n\t\t\t\t$controller->SetParam($paramname, $paramval);\n\t\t}\n\n\t\t$controller->SetRouter($this);\n\n\t\treturn $controller;\n\t}", "public function testCreateTheControllerClass()\n {\n $controller = new Game21Controller();\n $this->assertInstanceOf(\"\\App\\Http\\Controllers\\Game21Controller\", $controller);\n }", "public static function createController( MShop_Context_Item_Interface $context, $name = null );", "public function __construct()\n {\n\n $url = $this->splitURL();\n // echo $url[0];\n\n // check class file exists\n if (file_exists(\"../app/controllers/\" . strtolower($url[0]) . \".php\")) {\n $this->controller = strtolower($url[0]);\n unset($url[0]);\n }\n\n // echo $this->controller;\n\n require \"../app/controllers/\" . $this->controller . \".php\";\n\n // create Instance(object)\n $this->controller = new $this->controller(); // $this->controller is an object from now on\n if (isset($url[1])) {\n if (method_exists($this->controller, $url[1])) {\n $this->method = $url[1];\n unset($url[1]);\n }\n }\n\n // run the class and method\n $this->params = array_values($url); // array_values 값들인 인자 0 부터 다시 배치\n call_user_func_array([$this->controller, $this->method], $this->params);\n }", "public function getController();", "public function getController();", "public function getController();", "public function createController($pageType, $template)\n {\n $controller = null;\n\n // Use factories first\n if (isset($this->controllerFactories[$pageType])) {\n $callable = $this->controllerFactories[$pageType];\n $controller = $callable($this, 'templates/'.$template);\n\n if ($controller) {\n return $controller;\n }\n }\n\n // See if a default controller exists in the theme namespace\n $class = null;\n if ($pageType == 'posts') {\n $class = $this->namespace.'\\\\Controllers\\\\PostsController';\n } elseif ($pageType == 'post') {\n $class = $this->namespace.'\\\\Controllers\\\\PostController';\n } elseif ($pageType == 'page') {\n $class = $this->namespace.'\\\\Controllers\\\\PageController';\n } elseif ($pageType == 'term') {\n $class = $this->namespace.'\\\\Controllers\\\\TermController';\n }\n\n if (class_exists($class)) {\n $controller = new $class($this, 'templates/'.$template);\n\n return $controller;\n }\n\n // Create a default controller from the stem namespace\n if ($pageType == 'posts') {\n $controller = new PostsController($this, 'templates/'.$template);\n } elseif ($pageType == 'post') {\n $controller = new PostController($this, 'templates/'.$template);\n } elseif ($pageType == 'page') {\n $controller = new PageController($this, 'templates/'.$template);\n } elseif ($pageType == 'search') {\n $controller = new SearchController($this, 'templates/'.$template);\n } elseif ($pageType == 'term') {\n $controller = new TermController($this, 'templates/'.$template);\n }\n\n return $controller;\n }", "private function loadController($controller)\r\n {\r\n $className = $controller.'Controller';\r\n \r\n $class = new $className($this);\r\n \r\n $class->init();\r\n \r\n return $class;\r\n }", "public static function newInstance ($class)\n {\n try\n {\n // the class exists\n $object = new $class();\n\n if (!($object instanceof sfController))\n {\n // the class name is of the wrong type\n $error = 'Class \"%s\" is not of the type sfController';\n $error = sprintf($error, $class);\n\n throw new sfFactoryException($error);\n }\n\n return $object;\n }\n catch (sfException $e)\n {\n $e->printStackTrace();\n }\n }", "public function create()\n {\n //TODO frontEndDeveloper \n //load admin.classes.create view\n\n\n return view('admin.classes.create');\n }", "private function generateControllerClass()\n {\n $dir = $this->bundle->getPath();\n\n $parts = explode('\\\\', $this->entity);\n $entityClass = array_pop($parts);\n $entityNamespace = implode('\\\\', $parts);\n\n $target = sprintf(\n '%s/Controller/%s/%sController.php',\n $dir,\n str_replace('\\\\', '/', $entityNamespace),\n $entityClass\n );\n\n if (file_exists($target)) {\n throw new \\RuntimeException('Unable to generate the controller as it already exists.');\n }\n\n $this->renderFile($this->skeletonDir, 'controller.php', $target, array(\n 'actions' => $this->actions,\n 'route_prefix' => $this->routePrefix,\n 'route_name_prefix' => $this->routeNamePrefix,\n 'dir' => $this->skeletonDir,\n 'bundle' => $this->bundle->getName(),\n 'entity' => $this->entity,\n 'entity_class' => $entityClass,\n 'namespace' => $this->bundle->getNamespace(),\n 'entity_namespace' => $entityNamespace,\n 'format' => $this->format,\n ));\n }", "static public function Instance()\t\t// Static so we use classname itself to create object i.e. Controller::Instance()\r\n {\r\n // Only one object of this class is required\r\n // so we only create if it hasn't already\r\n // been created.\r\n if(!isset(self::$_instance))\r\n {\r\n self::$_instance = new self();\t// Make new instance of the Controler class\r\n self::$_instance->_commandResolver = new CommandResolver();\r\n\r\n ApplicationController::LoadViewMap();\r\n }\r\n return self::$_instance;\r\n }", "private function create_mock_controller() {\n eval('class TestController extends cyclone\\request\\SkeletonController {\n function before() {\n DispatcherTest::$beforeCalled = TRUE;\n DispatcherTest::$route = $this->_request->route;\n }\n\n function after() {\n DispatcherTest::$afterCalled = TRUE;\n }\n\n function action_act() {\n DispatcherTest::$actionCalled = TRUE;\n }\n}');\n }", "public function AController() {\r\n\t}", "protected function initializeController() {}", "public function dispatch()\n { \n $controller = $this->formatController();\n $controller = new $controller($this);\n if (!$controller instanceof ControllerAbstract) {\n throw new Exception(\n 'Class ' . get_class($controller) . ' is not a valid controller instance. Controller classes must '\n . 'derive from \\Europa\\ControllerAbstract.'\n );\n }\n $controller->action();\n return $controller;\n }", "public function controller()\n {\n $method = $_SERVER['REQUEST_METHOD'];\n if ($method == 'GET') {\n $this->getController();\n };\n if ($method == 'POST') {\n check_csrf();\n $this->createController();\n };\n }", "private function addController($controller)\n {\n $object = new $controller($this->app);\n $this->controllers[$controller] = $object;\n }", "function Controller($ControllerName = Web\\Application\\DefaultController) {\n return Application()->Controller($ControllerName);\n }", "public function getController($controllerName) {\r\n\t\tif(!isset(self::$instances[$controllerName])) {\r\n\t\t $package = $this->getPackage(Nomenclature::getVendorAndPackage($controllerName));\r\n\t\t if(!$package) {\r\n\t\t $controller = new $controllerName();\r\n\t\t $controller->setContext($this->getContext());\r\n\t\t return $controller;\r\n\t\t //return false;\r\n\t\t }\r\n\r\n\t\t if(!$package || !$package->controllerExists($controllerName)) {\r\n\t\t $controller = new $controllerName();\r\n\t\t $controller->setContext($this->getContext());\r\n\t\t $package->addController($controller);\r\n\t\t } else {\r\n\t\t $controller = $package->getController($controllerName);\r\n\t\t }\r\n\t\t} else {\r\n\t\t $controller = self::$instances[$controllerName];\r\n\t\t}\r\n\t\treturn $controller;\r\n\t}", "public function testInstantiateSessionController()\n {\n $controller = new SessionController();\n\n $this->assertInstanceOf(\"App\\Http\\Controllers\\SessionController\", $controller);\n }", "private static function loadController($str) {\n\t\t$str = self::formatAsController($str);\n\t\t$app_controller = file_exists(APP_DIR.'/Mvc/Controller/'.$str.'.php');\n\t\t$lib_controller = file_exists(LIB_DIR.'/Mvc/Controller/'.$str.'.php');\n\t\t\n\t\tif ( $app_controller || $lib_controller ) {\n\t\t\tif ($app_controller) {\n\t\t\t\trequire_once(APP_DIR.'/Mvc/Controller/'.$str.'.php');\n\t\t\t}\n\t\t\telse {\n\t\t\t\trequire_once(LIB_DIR.'/Mvc/Controller/'.$str.'.php');\n\t\t\t}\n\t\n\t\t\t$controller = new $str();\n\t\t\t\n\t\t\tif (!$controller instanceof Controller) {\n\t\t\t\tthrow new IsNotControllerException();\n\t\t\t}\n\t\t\telse {\n\t\t\t\treturn $controller;\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tthrow new ControllerNotExistsException($str);\n\t\t}\n\t}", "public function __construct()\n {\n // and $url[1] is a controller method\n if ($_GET['url'] == NULL) {\n $url = explode('/', env('defaultRoute'));\n } else {\n $url = explode('/', rtrim($_GET['url'],'/'));\n }\n\n $file = 'controllers/' . $url[0] . '.php';\n if (file_exists($file)) {\n require $file;\n $controller = new $url[0];\n\n if (isset($url[1])) {\n $controller->{$url[1]}();\n }\n } else {\n echo \"404 not found\";\n }\n }", "protected function _controllers()\n {\n $this['watchController'] = $this->factory(static function ($c) {\n return new Controller\\WatchController($c['app'], $c['searcher']);\n });\n\n $this['runController'] = $this->factory(static function ($c) {\n return new Controller\\RunController($c['app'], $c['searcher']);\n });\n\n $this['customController'] = $this->factory(static function ($c) {\n return new Controller\\CustomController($c['app'], $c['searcher']);\n });\n\n $this['waterfallController'] = $this->factory(static function ($c) {\n return new Controller\\WaterfallController($c['app'], $c['searcher']);\n });\n\n $this['importController'] = $this->factory(static function ($c) {\n return new Controller\\ImportController($c['app'], $c['saver'], $c['config']['upload.token']);\n });\n\n $this['metricsController'] = $this->factory(static function ($c) {\n return new Controller\\MetricsController($c['app'], $c['searcher']);\n });\n }", "public function __construct() {\r\n $this->controllerLogin = new ControllerLogin();\r\n $this->controllerGame = new ControllerGame();\r\n $this->controllerRegister = new ControllerRegister();\r\n }", "public function controller ($post = array())\n\t{\n\n\t\t$name = $post['controller_name'];\n\n\t\tif (is_file(APPPATH.'controllers/'.$name.'.php')) {\n\n\t\t\t$message = sprintf(lang('Controller_s_is_existed'), APPPATH.'controllers/'.$name.'.php');\n\n\t\t\t$this->msg[] = $message;\n\n\t\t\treturn $this->result(false, $this->msg[0]);\n\n\t\t}\n\n\t\t$extends = null;\n\n\t\tif (isset($post['crud'])) {\n\n\t\t\t$crud = true;\n\t\t\t\n\t\t}\n\t\telse{\n\n\t\t\t$crud = false;\n\n\t\t}\n\n\t\t$file = $this->_create_folders_from_name($name, 'controllers');\n\n\t\t$data = '';\n\n\t\t$data .= $this->_class_open($file['file'], __METHOD__, $extends);\n\n\t\t$crud === FALSE || $data .= $this->_crud_methods_contraller($post);\n\n\t\t$data .= $this->_class_close();\n\n\t\t$path = APPPATH . 'controllers/' . $file['path'] . strtolower($file['file']) . '.php';\n\n\t\twrite_file($path, $data);\n\n\t\t$this->msg[] = sprintf(lang('Created_controller_s'), $path);\n\n\t\t//echo $this->_messages();\n\t\treturn $this->result(true, $this->msg[0]);\n\n\t}", "protected function getController(Request $request) {\n try {\n $controller = $this->objectFactory->create($request->getControllerName(), self::INTERFACE_CONTROLLER);\n } catch (ZiboException $exception) {\n throw new ZiboException('Could not create controller ' . $request->getControllerName(), 0, $exception);\n }\n\n return $controller;\n }", "public function create() {}", "public function __construct()\n {\n $this->dataController = new DataController;\n }", "function __contrruct(){ //construdor do controller, nele é possivel carregar as librari, helpers, models que serão utilizados nesse controller\n\t\tparent::__contrruct();//Chamando o construtor da classe pai\n\t}", "public function __construct() {\n\n // Get the URL elements.\n $url = $this->_parseUrl();\n\n // Checks if the first URL element is set / not empty, and replaces the\n // default controller class string if the given class exists.\n if (isset($url[0]) and ! empty($url[0])) {\n $controllerClass = CONTROLLER_PATH . ucfirst(strtolower($url[0]));\n unset($url[0]);\n if (class_exists($controllerClass)) {\n $this->_controllerClass = $controllerClass;\n }\n }\n\n // Replace the controller class string with a new instance of the it.\n $this->_controllerClass = new $this->_controllerClass;\n\n // Checks if the second URL element is set / not empty, and replaces the\n // default controller action string if the given action is a valid class\n // method.\n if (isset($url[1]) and ! empty($url[1])) {\n if (method_exists($this->_controllerClass, $url[1])) {\n $this->_controllerAction = $url[1];\n unset($url[1]);\n }\n }\n\n // Check if the URL has any remaining elements, setting the controller\n // parameters as a rebase of it if true or an empty array if false.\n $this->_controllerParams = $url ? array_values($url) : [];\n\n // Call the controller and action with parameters.\n call_user_func_array([$this->_controllerClass, $this->_controllerAction], $this->_controllerParams);\n }", "private function setUpController()\n {\n $this->controller = new TestObject(new SharedControllerTestController);\n\n $this->controller->dbal = DBAL::getDBAL('testDB', $this->getDBH());\n }", "public function create() {\n $class_name = $this->getOption('className');\n return new $class_name();\n }" ]
[ "0.82668066", "0.8173394", "0.78115296", "0.77052677", "0.7681875", "0.7659338", "0.74860525", "0.74064577", "0.7297601", "0.7252339", "0.7195181", "0.7174191", "0.70150065", "0.6989306", "0.69835985", "0.69732994", "0.6963521", "0.6935819", "0.68973273", "0.68920785", "0.6877748", "0.68702674", "0.68622285", "0.6839049", "0.6779292", "0.6703522", "0.66688496", "0.66600126", "0.6650373", "0.66436416", "0.6615505", "0.66144013", "0.6588728", "0.64483404", "0.64439476", "0.6429303", "0.6426485", "0.6303757", "0.6298291", "0.6293319", "0.62811387", "0.6258778", "0.62542456", "0.616827", "0.6162314", "0.61610043", "0.6139887", "0.613725", "0.61334985", "0.6132223", "0.6128982", "0.61092585", "0.6094611", "0.60889256", "0.6074893", "0.60660255", "0.6059098", "0.60565156", "0.6044235", "0.60288006", "0.6024102", "0.60225666", "0.6018304", "0.60134345", "0.60124683", "0.6010913", "0.6009284", "0.6001683", "0.5997471", "0.5997012", "0.59942573", "0.5985074", "0.5985074", "0.5985074", "0.5967613", "0.5952533", "0.5949068", "0.5942203", "0.5925731", "0.5914304", "0.5914013", "0.59119135", "0.5910308", "0.5910285", "0.59013796", "0.59003943", "0.5897524", "0.58964556", "0.58952993", "0.58918965", "0.5888943", "0.5875413", "0.5869938", "0.58627135", "0.58594996", "0.5853714", "0.5839484", "0.5832913", "0.582425", "0.58161044", "0.5815566" ]
0.0
-1
Display a listing of the resource.
public function welcome() { /*$isLoggedIn = Auth::check(); if ($isLoggedIn == false) { return redirect('/login'); }*/ return view('welcome'); }
{ "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
Store a newly created resource in storage.
public function store(Request $request) { $request->validate([ 'name' => 'required|min:3|max:128', 'status' => 'required|in:ongoing,deleted,completed', 'dueDate' => 'required', ]); $user_id = Auth::user()->id; $request->request->add(['responsible_id' => $user_id]); $request->request->add(['user_id' => $user_id]); Task::create($request->all()); //Task::create(request(['name', 'responsible_id', 'dueDate', 'status'])); $tasks = Task::all(); // And then redirect to the tasks page return ['data' => $tasks]; }
{ "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
Update the specified resource in storage.
public function update(Request $request) { $request->validate([ 'id' => 'required|exists:tasks,id', 'name' => 'required', 'status' => 'required|in:ongoing,deleted,completed', 'dueDate' => 'required', ]); /*$task = Task::findOrFail($request->id); $task = Task::where('id', $request->id)->first(); $task->name = $request->name; $task->responsible = $request->responsiple; $task->dueDate = $request->dueDate; $task->save();*/ $task = Task::findOrFail($request->id)->update($request->toArray()); // PATCH/ tasks/id //Task::patch(request(['name', 'responsible', 'dueDate', 'status'])->where('id', $id)); // $task = Task::only(['name', 'responsible', 'dueDate', 'status']); // And then redirect to the tasks page return ['data' => $task]; }
{ "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 delete($id) { // DELETE /tasks/id $task = Task::findOrFail($id)->delete(); return ['data' => $task]; }
{ "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
This class represents a single player on the LVP server. It keeps track of random stats as well as some less random information, like the ID and nickname of the player.
public function __construct($nId) { $this->setInfoKeys(); // Set all variables to their defaults. foreach (self::$s_aInfoKeys as $sKey) { unset($this[$sKey]); } $this['ID'] = $nId; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getPlayer()\n {\n return $this->player;\n }", "public function getPlayer()\n {\n return $this->player;\n }", "public function getPlayer()\n {\n return $this->player;\n }", "public function getPlayer()\n\t{\n\t\treturn $this->player;\n\t}", "public function getPlayer();", "public function getPlayer()\n {\n return $this->get(self::_PLAYER);\n }", "public function getPlayer()\n {\n return $this->get(self::_PLAYER);\n }", "public function player() : Player\n {\n return $this->player;\n }", "public function getPlayerId(){\n\t\treturn $this->playerId;\n\t}", "public function getPlayerUsername()\n {\n return $this->playerUsername;\n }", "public function getPlayerId()\n {\n return $this->playerId;\n }", "public function getPlayerId() {\n return $this->playerId;\n }", "public function getPlayer()\n {\n return $this->hasOne(Player::class, ['id' => 'player_id']);\n }", "public function getPlayer()\n {\n return $this->hasOne(Player::class, ['id' => 'player_id']);\n }", "public function getPlayer_id() {\n return $this->getValue('player_id');\n }", "public function player()\n {\n return $this->hasOne('Bitaac\\Contracts\\Player', 'id', 'player_id');\n }", "public function getIdPlayer()\n {\n return $this->idPlayer;\n }", "public function getPlayer() {\n return $this->db->getPlayerById($this->playerId);\n }", "public function playerInfo()\n {\n return $this->hasOne( 'ADKGamers\\\\Webadmin\\\\Models\\\\Battlefield\\\\Player', 'PlayerID', 'player_id' );\n }", "public function setPlayer(Player $player);", "public function getPlayerName(){\n\t\treturn $this->playerName;\n\t}", "public function __construct(\\App\\Player $player)\n {\n $this->player = $player;\n }", "public function player()\n {\n return $this->hasOne('App\\Models\\Player');\n }", "public function getPlayer()\n {\n return $this->participation->getPlayer();\n }", "public function player() {\n\t\treturn $this->hasOne('App\\Models\\Player', 'id', 'player_id');\n\t}", "public static function generateNewPlayer($username){\n $dungeon = null;\n include 'Game/tutorial_dungeon.php';\n $player = new \\LinkedWorldsCore\\Player($username, $dungeon);\n\n return $player;\n }", "public function getPlayerName() {\n\t\treturn $this->playerName;\n\t}", "public function getMe()\n {\n return $this->players[$this->myId];\n }", "function newPlayer($player) {\n\n\t\t// creates player object ...\n\t\t$player_item = new Player($player);\n\t\tif ($player_item->login == \"\")\n\t\t\t{\n\t\t\t//$this->console(\"New broken Player entered - ignored.\");\n\t\t\treturn;\n\t\t\t}\n\t\t\n\t\tif ($player_item->id == $this->lastloginid)\n\t\t\t{\n\t\t\t//$this->console(\"Dublicated join event - ignored.\");\n\t\t\treturn;\n\t\t\t}\n\t\t$this->lastloginid = $player_item->id;\n\n\t\t// adds a new player to the intern player list ...\n\t\t$this->server->players->addPlayer($player_item);\n\n\t\t// display console message ...\n\t\t$this->console('<< player {1} joined the game [{2}]',\n\t\t\t$player_item->id,\n\t\t\t$player_item->login);\n\n\t\t// send chat message to player ...\n\t\t// format message parameters ...\n\t\t$message = myWelcomeMessage($this, $player_item);\n\n\t\t// replace colors ...\n\t\t$message = $this->formatColors($message);\n\n\t\t// send the message ...\n\t\t$message = str_replace('{br}', \"\\n\", $message);\n\t\tif ($this->settings['welcome_msg_window']) {\n\t\t \tif ($player_item->login)\n\t\t\t\tpopup_msg($player_item->login, $message, 10000);\n\t\t} else {\n\t\t\t$this->client->addCall('ChatSendServerMessageToLogin', array(str_replace(\"\\n\\n\", \"\\n\", $message), $player_item->login));\n\t\t\t$this->client->multiquery();\n\t\t}\n\n\t\t// release a new player connect event ...\n\t\t$this->releaseEvent('onPlayerConnect', $player_item);\n\t}", "public function getPlayerName()\n {\n return $this->get(self::_PLAYER_NAME);\n }", "public static function player($row) {\n\t\t\t$result = new Player($row);\n\t\t\treturn \"<div id=\\\"player\\\">\".$result->getName().$result->getTeam().$result->getGP().$result->getMin().$result->getFG().$result->get3PT().$result->getFT().$result->getRebound().$result->getPPG().$result->getAst().\"</div>\";\n\t\t}", "function initPlayer($player) {\n\t\t// creates player object ...\n\t\t$player_item = new Player($player);\n\n\t\tldb_playerConnect($this, $player_item);\n\n\t\t// adds a new player to the intern player list ...\n\t\t$this->server->players->addPlayer($player_item);\n\n\t\t// display console message ...\n\t\t$this->console('<< player {1} online [{2}] {3} wins',\n\t\t\t$player_item->id,\n\t\t\t$player_item->login,\n\t\t\t$player_item->getWins());\n\t}", "public function getPlayerId() {\n\t\treturn ($this->playerId);\n\t}", "function __construct($player) {\n\t\t\t$this->name = $player['Name'];\n\t\t\t$this->team = $player['Team'];\n\t\t\t$this->gp = $player['GP'];\n\t\t\t$this->min = $player['Min'];\n\t\t\t$this->fg = $player['Pct-FG'];\n\t\t\t$this->pt = $player['Pct-3PT'];\n\t\t\t$this->ft = $player['Pct-FT'];\n\t\t\t$this->rebound = $player['Tot-Rb'];\n\t\t\t$this->ppg = $player['PPG'];\n\t\t\t$this->ast = $player['Ast'];\n\t\t}", "public function getHostPlayer() {\n return $this->hostPlayer;\n }", "static function createPlayer(Player $player) {\n CommonDao::connectToDb();\n $query = \"insert into player(first_name, last_name, mlb_team_id, birth_date, sportsline_id)\n values (\\\"\" .\n $player->getFirstName() . \"\\\", \\\"\" . $player->getLastName() . \"\\\", \" .\n $player->getMlbTeam()->getId() . \", '\" . $player->getBirthDate() . \"', \" .\n $player->getSportslineId() . \")\";\n $result = mysql_query($query);\n if (!$result) {\n echo \"Player \" . $player->getFullName() . \" already exists in DB. Try again.\";\n return null;\n }\n\n $idQuery = \"select player_id from player where first_name = \\\"\" . $player->getFirstName() .\n \"\\\" and last_name = \\\"\" . $player->getLastName() . \"\\\" and birth_date = '\" .\n $player->getBirthDate() . \"'\";\n $result = mysql_query($idQuery) or die('Invalid query: ' . mysql_error());\n $row = mysql_fetch_assoc($result);\n $player->setId($row[\"player_id\"]);\n return $player;\n }", "public function getPlayerUsername(): string {\n\t\treturn ($this->playerUsername);\n\t}", "public function show(Player $player)\n {\n return response()->json(['data' => $player]);\n }", "static function getPlayerById($playerId) {\n CommonDao::connectToDb();\n $query = \"select * from player\n where player_id = $playerId\";\n return PlayerDao::createPlayerFromQuery($query);\n }", "private function initPlayer(): void\n {\n $name = $this->getConfig()->getPlayerName();\n $interaction = $this->getConfig()->getInteractionInterface();\n\n $this->player = PlayerFabric::createReal($this->pile, $name, $interaction);\n }", "public function consultByIdPlayer(Player $idPlayer){\n $sql = \"SELECT * FROM jogador WHERE id_jogador = '{$idPlayer}'\";\n $result = $this->connection->dataBase->Execute($sql);\n $record = $result->FetchNextObject();\n $playerData = new Player();\n $playerData->__constructOverload($record->ID_JOGADOR, $record->TIME_ID_TIME,\n $record->NOME, $record->DATA_NASCIMENTO,\n $record->CPF, $record->NUMERO);\n return $playerData;\n\t}", "public function getPlayerType()\n {\n return $this->playerType;\n }", "public function show(Player $player)\n {\n return new PlayerResource($player->load('team', 'role', 'country'));\n }", "public function getPlayer() {\n\t\tif($this->practice)\n\t\t\treturn $this->practice->golfer;\n\n\t\treturn $this->registration->competition->rule->team_score ? $this->registration->team : $this->registration->golfer;\n\t}", "public function player(string $player)\n {\n $this->player = $player;\n\n return $this;\n }", "static public function getPlayerCount() {\n\t\treturn (int)self::$playercount;\n\t}", "public function __construct($playerId, $playerUsername) {\n\t\t$this->setPlayerId($playerId);\n\t\t$this->setPlayerUsername($playerUsername);\n\t}", "public function playerO(){\n return $this->hasOne(\"App\\Models\\Auth\\User\", \"id\", \"player_o_id\");\n }", "public function getPlayerName(): string {\n\t\treturn $this->pet->getPetOwnerName();\n\t}", "public function authPlayer()\n {\n $player = Player::where(array('name'=>Input::get('name'),'password' => md5(Input::get('password'))))->get();\n if($player->isEmpty())\n {\n return \"false\";\n }\n else{\n $playerattr = File::get(public_path().'/playerattr.json');\n $player = $player->toArray();\n foreach(json_decode($playerattr,true) as $key => $value){\n if($value['id'] === $player[0]['id']){\n $player[0]['defence_set_length'] = $value['defence_set_length'];\n break;\n }\n }\n return $player[0];\n }\n }", "public function playerX(){\n return $this->hasOne(\"App\\Models\\Auth\\User\", \"id\", \"player_x_id\");\n }", "public static function populatePlayer($playerDb) {\n \treturn new Player($playerDb[\"player_id\"], $playerDb[\"first_name\"], $playerDb[\"last_name\"],\n \t $playerDb[\"birth_date\"], $playerDb[\"mlb_team_id\"], $playerDb[\"sportsline_id\"]);\n }", "public function findOrCreatePlayer(string $name, $type)\n {\n $player = $this->find($name);\n\n if (! $player) {\n $stats = $this->playerService->getPlayerStats($name, $type);\n\n if (! $stats) {\n abort(404, 'Player not found');\n }\n\n $player = Player::create([\n 'name' => $name,\n 'type' => $type ?: 'normal',\n 'last_updated' => Carbon::now()\n ]);\n }\n\n return $player;\n }", "public function get_point_owner()\n {\n $player_obj = User::find($this->player_id);\n\n return $player_obj;\n }", "public function GetPlayer($username)\n {\n $nono = new db($this->returnType);\n return $nono->Get(\"select * from players where username='$username';\");\n }", "static public function PlayerCount() {\n\t\tif (self::$serverstatus == 1) {\n\t\t\tself::$playercount = 0;\n\t\t\treturn null;\n\t\t}\n\n\t\t$db = &Database::getPostgreSQL('illarionserver');\n\t\t$db->setQuery('SELECT COUNT(*) FROM onlineplayer', 0, 1);\n\t\tself::$playercount = $db->loadResult();\n\t\treturn null;\n\t}", "public function registerPlayer(Player $player) {\r\n\r\n if($player->isSpectator() || \r\n\r\n (!is_null($this->getMain()->getServer()->getPluginManager()->getPlugin(\"SpectatorPlus\")) &&\r\n\r\n $this->getMain()->getServer()->getPluginManager()->getPlugin(\"SpectatorPlus\")->isSpectator($player))) { // Support for spectator Plus\r\n\r\n $this->spectators[$player->getName()] = $player;\r\n\r\n $player->HideAndSeekRole = self::ROLE_SPECTATE;\r\n\r\n } elseif($this->step == self::STEP_WAIT || $this->step == self::STEP_START) {$player->hideAndSeekGame = $this;\r\n\r\n // API inside player's class (easilier to get data)\r\n\r\n $player->HideAndSeekRole = self::ROLE_WAIT;\r\n\r\n $player->playsHideAndSeek = true;\r\n\r\n $this->players[$player->getName()] = $player;\r\n\r\n $player->setGamemode(2); // Set it to adventure so player cannot break blocks.\r\n\r\n $this->sendMessage(\"§a\" . $player->getName() . \" joined (\" . count($this->players) . \"/\" . $this->getMaxPlayers() . \"). \" . (round($this->getMaxPlayers() * 0.75) - count($this->players)) . \" players left before starting\");\r\n\r\n } else {\r\n\r\n $this->spectators[$player->getName()] = $player;\r\n\r\n $player->HideAndSeekRole = self::ROLE_SPECTATE;\r\n\r\n $player->setGamemode(3);\r\n\r\n }\r\n\r\n }", "public function show(Player $player)\n {\n return new PlayerResource(Player::findOrFail($player->id));\n }", "protected function selectPlayer(){\r\n $this->currentPlayer = rand(1,2);\r\n selectRandPlayerMsg($this->currentPlayer);\r\n }", "function CreatePlayerIfFirstTimePlaying($PlayerID, $PlayerName, $SaltValue) {\n $link = mysql_connect($this->servername, $this->username, $this->password);\n if (!$link) {\n die('Could not connect: ' . mysql_error());\n }\n \n //Make Players the current database\n $db_selected = mysql_select_db($this->dbname, $link);\n \n $select = \"SELECT PlayerID FROM Player where PlayerID = $PlayerID\";\n $result = mysql_query($select, $link);\n \n if(mysql_num_rows($result) > 0){\n //don't need to add new player since they already exist\n }else{\n $create = \"INSERT INTO Player (PlayerID, Name, Credits, LifetimeSpins, SaltValue) VALUES ($PlayerID, '$PlayerName', 5000, 1, '$SaltValue')\";\n\n if (mysql_query($create)) {\n echo \"New record created successfully\";\n $this->GenerateJSONResponseData();\n } else {\n echo \"There was an error when creating new record\";\n }\n }\n \n mysql_close($link);\n }", "public function get_players()\n {\n return $this->players;\n }", "public function setPlayerUsername(string $playerUsername)\n {\n $this->playerUsername = $playerUsername;\n\n return $this;\n }", "public function player()\n\t{\n\t\treturn $this->belongsTo('App\\Player');\n\t}", "public function setPlayer(Player $player)\n {\n $this->player = $player;\n\n return $this;\n }", "private function generatePlayers() : void\n {\n $indexes = array_rand($this->availablePlayerNames, $this->numOfPlayers);\n \n $firstIndex = $indexes[0];\n $firstName = $this->availablePlayerNames[$firstIndex];\n\n $firstPlayer = new Player();\n $firstPlayer->setName($firstName);\n\n $this->firstPlayer = $firstPlayer;\n $this->curPlayer = $this->firstPlayer;\n\n for ($i=1; $i < count($indexes); $i++) {\n $curIndex = $indexes[$i];\n $curName = $this->availablePlayerNames[$curIndex];\n\n $curPlayer = new Player();\n $curPlayer->setName($curName);\n \n $this->curPlayer->setNext($curPlayer);\n\n $this->curPlayer = $this->curPlayer->getNext();\n }\n }", "public function GetPlayerById( $id=NULL )\n {\n $player = new stdClass;\n\n if (!$id)\n return $player;\n\n $this->db->select(\"*\");\n $this->db->from('primary_info AS prim');\n $this->db->join('additional_info AS addi', 'prim.ID = addi.ID', 'INNER'); \n $this->db->where('prim.ID=' . $id);\n $query = $this->db->get();\n\n if ($query->num_rows() == 0)\n return $player;\n\n $row = $query->row();\n $player = array(\n \"ID\"=> $row->ID,\n \"Name\"=> $row->Name,\n \"Age\"=> $row->Age,\n \"Location\"=> array(\n \"City\"=> $row->City,\n \"Province\"=> $row->Province,\n \"Country\"=> $row->Country\n )\n );\n\n return array(\"Player\"=> $player);\n }", "public function create(Player $player) {\r\n // on se connecte à la DB\r\n $this->connexion->connect();\r\n\r\n // on recupère l'ensemble des attrubut de notre objet player\r\n $shoots = serialize($player->getShoots());\r\n $pseudo = $player->getPseudo();\r\n $ships = serialize($player->getShips()); // on serialise le tableau pour faciliter l'enregistrement en DB\r\n\r\n // On lance la requête\r\n $result = pg_query_params(\r\n $this->connexion->getConnexion(),\r\n 'INSERT INTO player (pseudo, shoots, ships) VALUES ($1, $2, $3) RETURNING * ',\r\n array($pseudo, $shoots, $ships)\r\n );\r\n\r\n // pour toutes les lignes renvoyées, on créer un objet de type Player grace à la fonction toPlayerFromDB\r\n $players = null;\r\n while ($data = pg_fetch_object($result)) {\r\n $players = Player::toPlayerFromDB($data);\r\n }\r\n\r\n pg_free_result($result);\r\n\r\n return $players;\r\n }", "public function show($id)\n {\n return Player::find($id);\n }", "public function GetPlayerById($playerId)\n {\n $dbTalker = new DbTalker();\n return $dbTalker->GetPlayerById($playerId) ?: 0;\n }", "public function player()\n {\n return $this->belongsTo(Player::class);\n }", "public function player()\n {\n return $this->belongsTo(Player::class);\n }", "public function testCreateThePlayerClass()\n {\n $controller = new Player(\"test\", \"player\");\n $this->assertInstanceOf(\"\\Jeso20\\Game\\Player\", $controller);\n\n $type = $controller->getType();\n $exp = \"player\";\n $this->assertEquals($exp, $type);\n\n $player = $controller->presentPlayer();\n $exp = [\n \"name\" => \"test\",\n \"combinations\" => []\n ];\n $this->assertEquals($exp, $player);\n }", "function set_PlayerR($PlayerID, $username, $numberWins, $numberLoss, $numberReports, $imageID, $message)\n {\n $this->PlayerID = $PlayerID;\n $this->username = $username;\n $this->numberWins = $numberWins;\n $this->numberLoss = $numberLoss;\n $this->numberReports = $numberReports;\n $this->imageID = $imageID;\n $this->message = $message;\n\n }", "public function __construct()\n {\n $this->matchFinished = false;\n //$this->player1 = new Player('A');\n //$this->player2 = new Player('B');\n }", "public function getPlayer($id)\n {\n $player = Players::find($id);\n return response()->json($player);\n }", "public function getPlayerOnTurn() {\n\t\tif ($this['turn']) {\n\t\t\t$playerRepository = new PlayerRepository();\n\t\t\treturn $playerRepository->getOneById($this['turn']);\n\t\t}\n\t\treturn NULL;\n\t}", "public function getRider(): ?Player\n {\n return $this->rider;\n }", "function addPlayer ($player) {\r\n\t\t$this->members = array_push($this->members,$player);\r\n\t}", "final public function getCreatureOwner(): Player\n {\n return $this->creatureOwner;\n }", "public function show(Player $player)\n {\n return view('players.show', [\n 'player' => $player\n ]);\n }", "private function displayIndividualStats($player)\n {\n $changes = $player->statChanges();\n if (count($changes) > 0) {\n $this->ui->display(\"| $player->name:\");\n foreach ($changes as $change) {\n $this->ui->display(\"| \" . $change->type . \": \" . $change->value);\n }\n }\n $player->saveStats();\n }", "public function spawnTo(Player $player) {\n\t\t$pk = new AddMobPacket();\n\t\t$pk->type = Slime::NETWORK_ID;\n\t\t$pk->eid = $this->getId();\n\t\t$pk->x = $this->x;\n\t\t$pk->y = $this->y;\n\t\t$pk->z = $this->z;\n\t\t$pk->pitch = $this->pitch;\n\t\t$pk->yaw = $this->yaw;\n\t\t$pk->metadata = $this->getData();\n\n\t\t$player->dataPacket($pk);\n\t\t$player->addEntityMotion($this->getId(), $this->motionX, $this->motionY, $this->motionZ);\n\t\tparent::spawnTo($player);\n\t}", "public function setNextPlayer($idPlayer)\n {\n if ($this->id_player6 == 0)\n {\n $this->id_player6 = $idPlayer;\n }\n else if ($this->id_player7 == 0)\n {\n $this->id_player7 = $idPlayer;\n }\n else if ($this->id_player8 == 0)\n {\n $this->id_player8 = $idPlayer;\n }\n else if ($this->id_player9 == 0)\n {\n $this->id_player9 = $idPlayer;\n }\n else if ($this->id_player10 == 0)\n {\n $this->id_player10 = $idPlayer;\n }\n else if ($this->id_player11 == 0)\n {\n $this->id_player11 = $idPlayer;\n }\n else if ($this->id_player12 == 0)\n {\n $this->id_player12 = $idPlayer;\n }\n else if ($this->id_player13 == 0)\n {\n $this->id_player13 = $idPlayer;\n }\n else if ($this->id_player14 == 0)\n {\n $this->id_player14 = $idPlayer;\n }\n else if ($this->id_player15 == 0)\n {\n $this->id_player15 = $idPlayer;\n }\n else if ($this->id_player16 == 0)\n {\n $this->id_player16 = $idPlayer;\n }\n else if ($this->id_player17 == 0)\n {\n $this->id_player17 = $idPlayer;\n }\n else if ($this->id_player18 == 0)\n {\n $this->id_player18 = $idPlayer;\n }\n else if ($this->id_player19 == 0)\n {\n $this->id_player19 = $idPlayer;\n }\n else if ($this->id_player20 == 0)\n {\n $this->id_player20 = $idPlayer;\n }\n return $this;\n }", "public function getPlayerByUsername($username)\n {\n foreach ($this->players as $player) {\n if ($player->username == $username) {\n return $player;\n }\n }\n return null;\n }", "public function addPlayer(string|Player $player): Game {\r\n if ( is_string($player) )\r\n $player = new HumanPlayer($player);\r\n\r\n array_push($this->players, $player);\r\n return $this;\r\n }", "private function onPlayerCreated(Player $player) : void{\n\t\t$rm = new ReflectionMethod(NetworkSession::class, \"onPlayerCreated\");\n\t\t$rm->invoke($this, $player);\n\t\t$this->player_add_resolver->resolve($player);\n\t}", "public function __construct($player, $session)\n {\n $this->player = $player;\n $this->session = $session;\n }", "public function getPlayers();", "public function getPlayers();", "public function show(Player $player)\n {\n return view('player.show', [\n 'player' => $player\n ]);\n }", "private function getPlayerData()\n\t{\n\t\t$data = new Application_Model_NBTFile();\n\t\t$data->load($this->getDatFilePath());\n\t\t\n\t\treturn $data;\n\t}", "public function __construct(){\n\t\t\n\t\t$this->dataMgr = createNewDataManager();\n\t\t$this->player = null;\n\t}", "public function getMarkedPlayer(): Player\n {\n return $this->players[$this->getPlayerIndexMarker()];\n }", "public function UpdatePlayer($player)\n {\n if ($this->IsMember($player->expires) && !$player->memberNumber) {\n $player->memberNumber = $this->GetNextMemberNumber();\n }\n\n $dbTalker = new DbTalker();\n return $dbTalker->updatePlayer($player);\n }", "public function getPlayers ()\r\n {\r\n return $this->players;\r\n }", "public function isplayer()\n\t{\n\t\treturn $this->Players->isplayer($this->SqueezePlyrID);\n\t}", "public function show($id)\n {\n $player = $this->repository->findByField('player_id',$id);\n return response()->json([\n 'data' => $player,\n ]);\n \n }", "public function player()\n {\n return $this->belongsTo('App\\Player');\n }", "public function getPlayer($playerId)\n {\n return $this->players[$playerId];\n }", "public function getSemanticNodeType() {\n return 'Player';\n }", "public function PlayerVO(){ }" ]
[ "0.6384383", "0.6384383", "0.6384383", "0.630152", "0.6278767", "0.6180404", "0.6180404", "0.6175783", "0.61753845", "0.61298007", "0.6095726", "0.6070103", "0.60579306", "0.60579306", "0.6028009", "0.6007781", "0.59988445", "0.5988335", "0.59506565", "0.5945088", "0.59012914", "0.5860543", "0.57983345", "0.5780115", "0.5740231", "0.57126147", "0.56941295", "0.567525", "0.56650907", "0.5604424", "0.55666685", "0.55646336", "0.55551124", "0.554804", "0.5544232", "0.5542467", "0.5492244", "0.5488871", "0.5460761", "0.5391533", "0.5384032", "0.53571653", "0.5331798", "0.5329976", "0.5320576", "0.5311747", "0.5303384", "0.5290906", "0.52775073", "0.5238789", "0.52074283", "0.51937383", "0.51790714", "0.51734626", "0.51681525", "0.5163673", "0.5157439", "0.51465136", "0.5143921", "0.51350516", "0.5113453", "0.5112446", "0.50950325", "0.50921947", "0.5087684", "0.5079167", "0.50728804", "0.50720674", "0.5070717", "0.50683606", "0.50683606", "0.50586087", "0.5058373", "0.50572187", "0.5045879", "0.50026846", "0.49984053", "0.4996803", "0.49915814", "0.4990362", "0.49831453", "0.4980044", "0.4974072", "0.49718276", "0.4963368", "0.49626258", "0.4957787", "0.49467915", "0.49467915", "0.4937881", "0.4935716", "0.49355662", "0.4926872", "0.4912092", "0.4912033", "0.48968333", "0.4896403", "0.48859447", "0.48844707", "0.48560327", "0.48534238" ]
0.0
-1
This method will set the all important information keys array, where the serialize functionality works with, as well as the ArrayAccess functionality.
private function setInfoKeys() { if (!empty(self::$s_aInfoKeys)) { return; } self::$s_aInfoKeys = array( 'ID', 'ProfileID', 'Nickname', 'Level', 'TempLevel', 'IP', 'JoinTime', 'LogInTime', ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function setSerializableOptionsArray()\n {\n $this->serializableOptions = [\n 'root' => $this->base()->lowercase()->singular(),\n 'collection_root' => $this->base()->lowercase()->plural(),\n 'include_root' => TRUE,\n 'additional_methods' => [],\n 'include_subclasses' => [],\n ];\n }", "public function setKeysFromInserted()\n\t{\n\t\t$keys = $this->database->getNewKeys();\n\n\t\t$this->data = Arr::mergeDeep($this->data, $keys);\n\n\t\t$this->key = $keys[$this->primaryKey] ?? null;\n\t}", "public function serialize() {\n\t\t$aInformation = array();\n\t\tforeach (self::$s_aInfoKeys as $sKey) {\n\t\t\t$aInformation[$sKey] = $this[$sKey];\n\t\t}\n\n\t\treturn serialize($aInformation);\n\t}", "function prepare_array() {\n\n\t\t$obj['name'] = $this->name->value;\n\t\t$obj['url'] = $this->url->value;\n\t\t$obj['image'] = $this->image->value;\n\t\t$obj['description'] = $this->description->value;\n\t\t/*\n\t\tforeach($this as $key => $value) {\n\n\t\t\t$obj[$key] = $value;\n\n\t\t}\n\t*/\n\t\treturn $obj;\n\t}", "protected function _setupMapperArray()\n\t{\n\t\t$this->mapperArray = array();\n\t\t\n\t\t$this->mapperArray['property_id'] = 'properties_id';\n\t\t$this->mapperArray['sort_order'] = 'sort_order';\n\t\t\n\t\t$this->mapperArray['name'] = 'properties_name';\n\t\t$this->mapperArray['admin_name'] = 'properties_admin_name';\n\t}", "public function setDictionary()\n {\n self::$dictionary = array();\n }", "function resetKeys() {\n $this->keys = array_keys($this->records);\n }", "public function toAssociativeArray() {\n // TODO\n }", "public function toAssociativeArray() {\n // TODO\n }", "public function store()\n {\n $this->storeKeys();\n }", "public function __construct() {\n $this->_map = [];\n $this->_keys = [];\n }", "protected function setKeyMapping(): array\n {\n return ['node-meta' => 'node_meta'];\n }", "private function set_keys() {\n\t\t$this->skeleton->load('customers_id', !empty($_SESSION['customer_id'])?$_SESSION['customer_id']:NULL);\n\t\t$this->skeleton->load('customers_extra_logins_id', !empty($_SESSION['customer_extra_login_id'])?$_SESSION['customer_extra_login_id']:NULL);\n\n\t\t// this will set the ID as the session value, if one is found, otherwise if there is an existing cart for this user, pull it out\n\t\tif (empty($this->id()) && $header = self::fetch('cart_header_by_key', [':cart_key' => $this->get_cart_key()])) {\n\t\t\t$this->id($header['cart_id']);\n\t\t}\n\n\t\t//var_dump([$this->skeleton->get('customers_id'), $_SESSION['customer_id']]);\n\t}", "public function actionSetKeys()\n {\n $this->setKeys($this->generateKeysPaths);\n }", "public function encryptableFields()\n {\n return array(\"key\");\n }", "public function __construct() {\n\t\t$this->keysDB = array();\n\t}", "public function createKeyArray(){\n\t$keyArray = array();\n\tif (isset($this->id)) $keyArray[\"id\"] = $this->id;\n\tif (isset($this->codice_categoria)) $keyArray[\"codice_categoria\"] = $this->codice_categoria;\n\tif (isset($this->codice)) $keyArray[\"codice\"] = $this->codice;\n\tif (isset($this->descrizione)) $keyArray[\"descrizione\"] = $this->descrizione;\n\treturn $keyArray;\n}", "function setExtraVarKeys($extra_keys)\n\t{\n\t\tif(!is_array($extra_keys) || count($extra_keys) < 1)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tforeach($extra_keys as $val)\n\t\t{\n\t\t\t$obj = new ExtraItem($val->module_srl, $val->idx, $val->name, $val->type, $val->default, $val->desc, $val->is_required, $val->search, $val->value, $val->eid);\n\t\t\t$this->keys[$val->idx] = $obj;\n\t\t}\n\t}", "protected function getNonVersionArrayKeys()\n {\n return array('description', 'alternative');\n }", "protected function setup_transients() {\n\n\t\t$this->transients = array(\n\t\t\t'notices' => array(\n\t\t\t\t'update' => '_wp_sh_plugin_browser_available_updates',\n\t\t\t\t'notice' => '_wp_sh_plugin_browser_notices',\n\t\t\t),\n\t\t);\n\n\t}", "public function set(){\n\t\t\t//Get incoming data\t\t\n\t\t\t$data = $this->data;\n\t\t\t\n\t\t\t//what action are we taking?\n\t\t\t$action = $this->action;\n\t\t\t\n\t\t\t//What data set are we taking action on. \n\t\t\t$action_set = $action. '_set';\n\t\t\t\n\t\t\t//load keys from that data set. \n\t\t\t$keys = $this->$action_set;\n\t\t\t//dump( __LINE__, __METHOD__, $data ); \n\t\t\t\n\t\t\t//Now we start to build. \n\t\t\tforeach( $keys as $key ){\n\t\t\t\tif( !empty( $data[ $key ] ) ){\n\t\t\t\t\t$this->data_set[ $key ] = $data[ $key ];\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif( !empty( $data[ 'data' ] ) && is_array( $data[ 'data' ] ) ){\n\t\t\t\t\t//looking deeper into the source arrays for data that matches the requesting field.\n\t\t\n\t\t\t\t\t//first check if field is available in top level of nested array. \n\t\t\t\t\tif( !empty( $data[ 'data' ][ $key ] ) ){\n\t\t\t\t\t\t$this->data_set[ $key ] = $data[ 'data' ][ $key ];\n\t\t\t\t\t\tcontinue;\t\n\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t//else look deeper by referencing the first word of the key to find it's associated array. \n\t\t\t\t\t$pos = strpos( $key, '_' );\n\t\t\t\t\t$sub_arr = substr( $key, 0, $pos );\n\t\t\t\t\t\n\t\t\t\t\tif( !isset( $data[ 'data' ][ $sub_arr ] ) )\n\t\t\t\t\t\tcontinue;\n\t\t\t\t\t \n\t\t\t\t\tif( is_array( $data[ 'data' ][ $sub_arr ] ) ){\n\t\t\t\t\t\t$sub_key = substr( $key, $pos + 1 );\t\t\t\t\t\n\t\t\t\t\t\t$this->data_set[ $key ] = $data[ 'data' ][ $sub_arr ][ $sub_key ] ?? '';\n\t\t\t\t\t\tcontinue;\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\t\t/* if( strcmp( $key, 'src_data' ) === 0 ){\n\t\t\t\t\t$this->data_set[ 'src_data' ] = $data;\n\t\t\t\t\tcontinue;\n\t\t\t\t} */\n\t\t\t\t\n\t\t\t\t$this->data_set[ $key ] = '';\n\t\t\t}\t\n\t\t\t\n\t\t\t\n\t\t\t//The final data set is specific to the initiating action being performed \n\t\t\t//$this->data_set = $this->$action();\n\t\t\t\n\t\t\treturn true;\n\t\t}", "function __data() {\n\t\tif ($data = $this->Session->read('data')) {\n\t\t\tforeach ($data as $k => $i) {\n\t\t\t\t$obj = ClassRegistry::init($k);\n\t\t\t\t$this->data[$k] = $i;\n\t\t\t}\n\t\t\t$this->Session->write('data', null);\n\t\t}\n\t\t// attempts to remember identity of commentor and prefill fields\n\t\tif (empty($this->data['Comment']) && $data = $this->Cookie->read('CommentUser')) {\n\t\t\t$this->data['Comment'] = $data;\n\t\t}\n\t}", "function infoDictionary() {}", "private function dataBaseRepresentation() {\n\t\t$array['website'] = $this->website;\n\t\t$array['name'] = $this->name;\n\t\t$array['country'] = $this->country;\n\t\treturn $array;\n\t}", "public function copyAttributesToKey()\n\t{\n\t\t$primarykey = $this->factory->getPrimarykey ;\n\t\tforeach( $primarykey->fields as $n=>$field )\n\t\t{\n\t\t\t$this->key[$field] = $this->$field ;\n\t\t}\n\t}", "private function setValues()\n {\n foreach($this->data as $type => $values)\n if(!preg_match('/(library)/i', $type))\n foreach($values as $key => $value)\n $this->{strtolower($type)}[$key] = $value;\n }", "public function set()\n {\n $args = func_get_args();\n $num = func_num_args();\n if ($num == 2) {\n self::$data[$args[0]] = $args[1];\n } else {\n if (is_array($args[0])) {\n foreach ($args[0] as $k => $v) {\n self::$data[$k] = $v;\n }\n }\n }\n }", "private function set_markerArray()\n {\n $markerArray = $this->pObj->objMarker->extend_marker();\n $this->markerArray = $markerArray;\n\n// // Add mode and view\n// $this->markerArray['###MODE###'] = $this->pObj->piVar_mode;\n// $this->markerArray['###VIEW###'] = $this->pObj->view;\n//\n// // Add cObj->data and piVars\n// $this->markerArray = $this->pObj->objMarker->extend_marker_wi_cObjData($this->markerArray);\n// $this->markerArray = $this->pObj->objMarker->extend_marker_wi_pivars($this->markerArray);\n }", "protected function setAvailableFields() {\r\n\t\t$this->availableFieldsArray = array(\r\n\t\t\t'uid',\r\n\t\t\t'pid',\r\n\t\t\t'tstamp',\r\n\t\t\t'crdate',\r\n\t\t\t'cruser_id',\r\n\t\t\t'deleted',\r\n\t\t\t'hidden',\r\n\t\t\t'name',\r\n\t\t\t'hint',\r\n\t\t\t'image',\r\n\t\t\t'use_arcticle_stock_info'\r\n\t\t);\r\n\t}", "public function createObjKeyArray(array $keyArray){\n\tif (isset($keyArray[\"id\"])) $this->id = $keyArray[\"id\"];\n\tif (isset($keyArray[\"codice_categoria\"])) $this->codice_categoria = $keyArray[\"codice_categoria\"];\n\tif (isset($keyArray[\"codice\"])) $this->codice = $keyArray[\"codice\"];\n\tif (isset($keyArray[\"descrizione\"])) $this->descrizione = $keyArray[\"descrizione\"];\n}", "public function __construct()\n {\n parent::__construct();\n $this->keys = array_keys(self::KEYS);\n $this->uniqueKeys = array_keys(array_filter(self::KEYS, function ($key) {\n return $key;\n }));\n }", "public function encryptableFields() {\n\t\t\n\t\treturn array(\"key\");\n\t}", "protected function setInfoArray($infoCollection)\n\t{\n\t\t/*\n\t\t* in app/auth.php set the fields array with each value\n\t\t* as a field you want from active directory\n\t\t* If you have 'user' => 'samaccountname' it will set the $info['user'] = $infoCollection->samaccountname\n\t\t* refer to the adLDAP docs for which fields are available.\n\t\t*/\n\t\t$info = [];\n\t\tforeach ($infoCollection->getAttributes() as $key=>$value) {\n\t\t\tif (is_array($value) && $value['count'] == 1 ) {\n\t\t\t\t$info[ $key ] = $value[0];\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$info[ $key ] = $value;\n\t\t\t}\n\t\t}\n\t\t$info[ 'groups' ] = $this->getAllGroups($infoCollection->memberof);\n\t\t$info[ 'primarygroup' ] = $this->getPrimaryGroup($infoCollection->distinguishedname);\n\t\t/*\n\t\t* I needed a user list to populate a dropdown\n\t\t* Set userlist to true in app/config/auth.php and set a group in app/config/auth.php as well\n\t\t* The table is the OU in Active directory you need a list of.\n\t\t*/\n\t\tif ( ! empty($this->config['userList'])) {\n\t\t\t$info['userlist'] = $this->ad->folder()->listing(array($this->config['group']));\n\t\t}\n\t\treturn $info;\n\t}", "protected function store()\n\t{\n\t\t// rebuild the keys table\n\t\t$this->reindex();\n\t\t//---------------------\n\t\t// Your code goes here\n\t\t// --------------------\n\t}", "abstract protected function setup_info();", "function SetKey( $i ) { $this->_key = $i; $this->SetValue('_key', $i ); }", "abstract protected function prepareKeys($models);", "public function getInfo()\n {\n return array(\n 'store' => array_keys($this->_store)\n );\n }", "private function setGetParameters() {\n\t\tforeach(array_keys($_GET) as $currentKey) {\n\t\t\t$this->getArray[$currentKey] = $_GET[$currentKey];\n\t\t}\n\t}", "public function set_keys( $keys )\n\t{\n\t\t$this->keys = $keys;\n\t}", "public function setAll($array) {\n // this is a kind of bad because sesData is just a property with no protected or private config\n\n foreach($array as $k=>$v){\n if( stristr($k,self::SESSIONNAMESPACE)!==false ){\n $k = str_replace(self::SESSIONNAMESPACE, '', $k);\n $this->storeObject($v, $k);\n }\n }\n\n\t}", "private function loadAPIKeys() {\n $results = $this->interface->getAPIKeys();\n $this->APIKeys = [ ];\n\n foreach ($results as $row)\n $this->APIKeys[ $row[ 'service' ] ] = $row[ 'key' ];\n }", "public function __construct(){\n $this->dictionnary = array();\n }", "public function __serialize(): array\n {\n return ['name' => $this->name];\n }", "protected function initData()\n {\n foreach (['data', 'uploads'] as $option) {\n $value = $this->option($option);\n if ($value) {\n $this->info[$option] = explode(',', $value);\n }\n }\n }", "protected static function keyToAttributeMapping()\n {\n return array();\n }", "function _getSerializeList()\n {\n return array('username', 'certificateFile',\n 'subject', 'environment');\n }", "public function __construct()\n {\n parent::__construct();\n $this->keyarray = [\n '本文约',\n '文章内容',\n '相关阅读',\n '《》',\n '相干浏览',\n '面击拜访',\n '七君',\n '文去自',\n '参考材料',\n '大家皆是产物司理',\n '扫码',\n 'Reference',\n 'https',\n 'http',\n '本文链接',\n '本文题目',\n '本题目',\n '参考文献',\n '常识星球截图',\n '编纂',\n '滥觞大众号',\n '本文由',\n '大众号',\n '本文本',\n '来源公众号',\n '文章出处',\n '参考链接',\n '本文来自'\n ];\n }", "public function keys()\n {\n }", "function key_setup($key) {\r\n\t\tif(is_array($key))\r\n \t$this->key = $key;\r\n\t\telse if(isset($key) && !empty($key))\r\n\t\t\t$this->key = $this->_str2long(str_pad($key, 16, $key));\r\n\t\telse\r\n\t\t\t$this->key = array(0,0,0,0);\r\n }", "public function exchangeArray($data) {\n\t\t$this->id = (isset ( $data ['id'] )) ? $data ['id'] : null;\n\t\t$this->descriptionkey = (isset ( $data ['descriptionkey'] )) ? $data ['descriptionkey'] : null;\n\t\t$this->title = (isset ( $data ['title'] )) ? $data ['title'] : null;\n\t\t//$this->imgkey = (isset ( $data ['imgkey']['name'] )) ? $data ['imgkey']['name'] : null;\n\t\t$this->imgkey = (isset ( $data ['imgkey'] )) ? $data ['imgkey'] : null;\n\t\t$this->patient_id = (isset ( $data ['patient_id'])) ? $data ['patient_id'] : null;\n\t}", "private function _getSettings()\n {\n $properties = $this->_class->getProperties();\n foreach ($properties as $property) {\n $prop = new Property($property);\n $prop->fillSettings($this->_reflect);\n }\n if (empty($this->_reflect->listField)) {\n $keys = array_keys($this->_reflect->fields);\n $this->_reflect->listField = array_shift($keys);\n }\n $this->_reflect->fieldNames = array_keys($this->_reflect->fields);\n }", "protected abstract function setFields();", "private function setupMapping()\n {\n $this->mapping = array();\n $fields = array();\n\n $aliases = array_keys($this->getJoinSettings());\n\n foreach ($aliases as $i => $alias) {\n $fields = array_merge($fields, $this->mapAlias($alias));\n }\n\n $this->mapping['fields'] = array_replace_recursive($fields, $this->getCustomMapping());\n $this->mapping['joins'] = $this->getJoinSettings();\n }", "public function toArray()\n {\n $a = parent::toArray();\n if ($this->accounts) {\n $ab = array();\n foreach ($this->accounts as $i => $x) {\n $ab[$i] = $x->toArray();\n }\n $a['accounts'] = $ab;\n }\n if ($this->addresses) {\n $ab = array();\n foreach ($this->addresses as $i => $x) {\n $ab[$i] = $x->toArray();\n }\n $a['addresses'] = $ab;\n }\n if ($this->emails) {\n $ab = array();\n foreach ($this->emails as $i => $x) {\n $ab[$i] = $x->toArray();\n }\n $a['emails'] = $ab;\n }\n if ($this->homepage) {\n $a[\"homepage\"] = $this->homepage->toArray();\n }\n if ($this->identifiers) {\n $ab = array();\n foreach ($this->identifiers as $i => $x) {\n $ab[$i] = array();\n foreach ($x as $j => $y) {\n $ab[$i][$j] = $y->getValue();\n }\n }\n $a['identifiers'] = $ab;\n }\n if ($this->names) {\n $ab = array();\n foreach ($this->names as $i => $x) {\n $ab[$i] = $x->toArray();\n }\n $a['names'] = $ab;\n }\n if ($this->openid) {\n $a[\"openid\"] = $this->openid->toArray();\n }\n if ($this->phones) {\n $ab = array();\n foreach ($this->phones as $i => $x) {\n $ab[$i] = $x->toArray();\n }\n $a['phones'] = $ab;\n }\n return $a;\n }", "public function setDataSignature() \n {\n $this->dataSignature = array(\n \"order_no\" => array(\"required\" => 1, \"type\" => \"int\"),\n \"order_status\" => array(\"required\" => 1, \"type\" => \"int\"),\n );\n }", "public function jsonSerialize()\n {\n return array_merge([\n 'settings' => $this->settings(),\n 'actions' => $this->actions(),\n 'columns' => $this->columns(),\n 'filters' => $this->filters(),\n 'cacheKey' => $this->generateCacheKey()\n ], parent::jsonSerialize());\n }", "private function setPostParameters() {\n\t\tforeach (array_keys($_POST) as $currentKey) {\n\t\t\t$this->postArray[$currentKey] = $_POST[$currentKey];\n\t\t}\n\t}", "public function initModulesKeys() {\n $this->data['module_keys'] = array(\n 'status',\n 'allow_guest',\n 'custom_css',\n 'limit_seller',\n 'allow_seller',\n 'notify_admin',\n 'email_subject',\n 'email_text',\n 'email_notification',\n 'email_notification_subject',\n 'email_accept_subject',\n 'email_accept_text',\n 'custom_css_email_accept',\n 'email_reject_subject',\n 'email_reject_text',\n 'custom_css_email_reject',\n 'registered_request',\n 'unregistered_request',\n 'coupon_name',\n 'coupon_validity'\n );\n }", "public function getRequestFieldsToSave(){\n\t\treturn array();\n\t}", "public function settingsData() {\n\n $arraySettings = array (\n 'Generic Param' => $this->_genericParam\n );\n\n return $arraySettings;\n\n }", "public function setDatas()\n\t{\n\t\t$this->data[\"skeleton\"] = $this->getSkeleton();\n\t\t$this->data[\"css\"] = $this->getCss();\n\t\t$this->data[\"javascript\"] = $this->getJavascript();\n\t\t$this->data[\"module\"] = $this->getModule();\n\t\t$this->data[\"site\"] = $this->getSite();\n\t\t\t\t\t\t\n\t\t$this->_nodeName = $this->getNodeName();\n\t\t$this->_value = $this->getNodeValue();\n\t}", "function protected_attributes() {\n\t\treturn array();\n\n\t}", "protected function setProperties()\n {\n foreach ($this->data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function setKeyedItems(array $keyedItems)\r\n {\r\n $this->keyedItems = $keyedItems;\r\n }", "function set_keys($keys)\n\t{\n\t\tif(!is_array($keys)) $keys = explode(',', $keys);\n\t\tforeach($keys as $key) $this->set_key($key);\n\t}", "public function dataSetter($infoArray) {\n\t\tforeach ($infoArray as $key => $value) {\n\t\t\t$this->dataInfo[$key] = $value;\n\t\t}\n\t}", "public function __construct()\n {\n parent::__construct();\n\n $this->keys = collect([\n 'rel_type',\n 'child_part_num',\n 'parent_part_num',\n ]);\n }", "protected function _setupTableMapperArray()\n\t{\n\t\t$this->tableMapperArray = array();\n\t\t\n\t\t$this->tableMapperArray['property_id'] = 'properties';\n\t\t$this->tableMapperArray['external_property_id'] = 'properties';\n\t\t$this->tableMapperArray['sort_order'] = 'properties';\n\t\t\n\t\t$this->tableMapperArray['name'] = 'properties_description';\n\t\t$this->tableMapperArray['admin_name'] = 'properties_description';\n \n\t\t$this->languageDependentMapperArray = array('properties_description');\n\t}", "public function setKeys($keys)\n {\n $this->_keys = $keys;\n }", "function prepareFields() {\r\n\t\t$data = array_keys($this->modx->getFieldMeta('msProductData'));\r\n\t\tforeach ($this->resourceArray as $k => $v) {\r\n\t\t\tif (is_array($v) && in_array($k, $data)) {\r\n\t\t\t\t$tmp = $this->resourceArray[$k];\r\n\t\t\t\t$this->resourceArray[$k] = array();\r\n\t\t\t\tforeach ($tmp as $v2) {\r\n\t\t\t\t\tif (!empty($v2)) {\r\n\t\t\t\t\t\t$this->resourceArray[$k][] = array('value' => $v2);\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\tif (empty($this->resourceArray['vendor'])) {\r\n\t\t\t$this->resourceArray['vendor'] = '';\r\n\t\t}\r\n\t}", "public function __construct ( $keyvalues ) \n\t{\t\t\t\n\t\t$this->keyvalues = $keyvalues;\t\t\n }", "function get_meta_keys()\n {\n }", "abstract protected function serializeData();", "public function setAndGetItemProvider()\n {\n return array(\n array('true', true),\n array('false', false),\n array('int', 123),\n array('double', 12.34),\n array('string', 'my string'),\n array('array', array(1, '2', 3.4)),\n array('object', new \\DateTime()),\n array('null', null),\n );\n }", "private function READ_FIELDS()\r\r {\r\r foreach($this->_fields as $key => $attributes)\r\r {\r\r foreach($attributes as $attrib_key => $attribute)\r\r {\r\r if(is_numeric($attrib_key))\r\r {\r\r $this->_ready_fields[$key][$attribute] = true;\r\r }\r\r else\r\r {\r\r $this->_ready_fields[$key][$attrib_key] = $attribute; \r\r } \r\r }\r\r } \r\r }", "function set_key($key)\n\t{\n\t\tif(empty($key) || !isset($GLOBALS['ACCESS_KEYS'][$key])) return;\n\t\tif(ACCESS_MODEL === \"roles\") {\n\t\t\tforeach($GLOBALS['ACCESS_KEYS'][$key] as $k) {\n\t\t\t\tif(substr($k, 0, 1) == '@') {\n\t\t\t\t\t// This key references another role - pull in all keys from that role\n\t\t\t\t\t$this->set_key(substr($k, 1));\n\t\t\t\t} else {\n\t\t\t\t\t$this->access_keys[] = $k;\n\t\t\t\t}\n\t\t\t}\n\t\t} else if(ACCESS_MODEL === \"discrete\") {\n\t\t\t$this->access_keys[] = $key;\n\t\t}\n\n\t\t$_SESSION['_ACCESS']['keys'] = $this->access_keys;\n\t}", "function initData() {\n\t\tif (isset($this->journalId)) {\n\t\t\t$journalDao =& DAORegistry::getDAO('JournalDAO');\n\t\t\t$journal =& $journalDao->getById($this->journalId);\n\n\t\t\tif ($journal != null) {\n\t\t\t\t$this->_data = array(\n\t\t\t\t\t'title' => $journal->getSetting('title', null), // Localized\n\t\t\t\t\t'description' => $journal->getSetting('description', null), // Localized\n\t\t\t\t\t'journalPath' => $journal->getPath(),\n\t\t\t\t\t'enabled' => $journal->getEnabled()\n\t\t\t\t);\n\n\t\t\t} else {\n\t\t\t\t$this->journalId = null;\n\t\t\t}\n\t\t}\n\t\tif (!isset($this->journalId)) {\n\t\t\t$this->_data = array(\n\t\t\t\t'enabled' => 1\n\t\t\t);\n\t\t}\n\t}", "protected function _getDictionary() {}", "protected function _getDictionary() {}", "protected function _beforePrepareDocumentData()\n {\n $this->_documentData = array();\n $this->_documentTextSearch = array();\n $this->_documentCategoryNames = array();\n $this->_documentAutocompleteSearch = array();\n }", "protected function prepareJsonStructure(){\n\t\t\n\t}", "protected function _fillAvailableProperties()\n {\n $properties = array(\n __(\"Special Properties\") => array(\n 0 => __(\"<Unmapped>\"),\n -1 => __(\"Tags\"),\n -2 => __(\"File\"),\n -3 => __(\"Item Type\"),\n -4 => __(\"Collection\"),\n -5 => __(\"Public\"),\n -6 => __(\"Featured\"),\n )\n );\n $elementSets = $this->_helper->db->getTable('ElementSet')->findAll();\n foreach ($elementSets as $elementSet)\n {\n $idNamePairs = array();\n $elementTexts = $elementSet->getElements();\n foreach ($elementTexts as $elementText)\n {\n $idNamePairs[$elementText->id] = $elementText->name;\n }\n $properties[$elementSet->name] = $idNamePairs;\n }\n $this->view->available_properties = $properties;\n }", "protected function initStorageObjects()\n {\n $this->sellerDetail = new \\TYPO3\\CMS\\Extbase\\Persistence\\ObjectStorage();\n }", "public function __debugInfo() {\n\t\t$info = parent::__debugInfo();\n\t\t$info['get'] = $this->getVars ? $this->getVars->getArray() : null;\n\t\t$info['post'] = $this->postVars ? $this->postVars->getArray() : null;\n\t\t$info['cookie'] = $this->cookieVars ? $this->cookieVars->getArray() : null;\n\t\t$info['whitelist'] = $this->whitelist ? $this->whitelist->getArray() : null;\n\t\t$info['urlSegments'] = $this->urlSegments;\n\t\t$info['pageNum'] = $this->pageNum;\n\t\treturn $info;\n\t}", "public static function addToDetails($keys,$d){\nif(is_object($d))$d=(array)$d; //Allow $d to be an object\nif(!is_array($keys))$keys=array($keys); //So it will work when $keys is a string\nif(is_array($d)){\n foreach($keys as $k){\n if(array_key_exists($k,$d))self::$details[$k]=$d[$k];\n }\n }\n}", "private function _init()\n\t{\n\t\t$data = array();\n\t\t$data['CONTROLLER_NAME'] = $this->controllerTemplate->get_name();\n\t\t$data['VIEW_NAME'] = $this->viewTemplate->get_name();\n\t\t$data['VIEW_NAME_LINK'] = $this->viewTemplate->get_link();\n\t\t$data['MODEL_NAME'] = $this->modelTemplate->get_name();\n\t\t$data['TABLE_VIEW'] = $this->tableTemplate->get_name();\n\t\t$data['TABLE_VIEW_LINK'] = $this->tableTemplate->get_link();\n\t\t$data['DB_TABLE_NAME'] = $this->model->get_table_name();\n\t\t$data['MODEL_INSTANCE_VARIABLES'] = $this->modelTemplate->get_vars();\n\t\t$data['MODEL_SELECT_COLUMNS'] = $this->modelTemplate->get_columns();\n\n\t\treturn $data;\n\t}", "public function getIndexableMetaKeys(){\n\t\treturn array_keys( $this->keys );\n\t}", "protected function _getNonAttributeKeys()\n {\n return array(static::K_CONTENT, static::K_BASE_NAMESPACE_DEPTH);\n }", "protected static function initIndexes()\n {\n static::$indexes = [];\n foreach (static::$indexesConf as $name => &$index) {\n if (!isset($index['type'])) {\n $index['type'] = 'Generic';\n }\n $index['name'] = $name;\n $index['modelClass'] = static::class;\n\n $class = ClassFinder::getNamespace(\\Zer0\\Model\\Indexes\\AbstractIndex::class) . '\\\\' . $index['type'];\n\n static::$indexes[$name] = new $class($index);\n }\n }", "public function __construct(array $_aKey) {\n $this->fnInit($_aKey); // plain array, non associated\n }", "public function getAuthInfoArray() {}", "function setArray( array $storearray ) {\n$this->array = $storearray;\n}", "function set(array $data) {\n\t\tforeach ($data as $key => $value) {\n\t\t\t$this->$key = $value;\n\t\t}\n\t}", "public function __construct()\n {\n // Setup internal data arrays\n self::internals();\n }", "protected function setFilterArray() {\n $primary_keys = getPrimaryKeys($this->table_name);\n foreach ($primary_keys as $pk) {\n if (isset($_GET[$pk])) {\n $this->filter[$pk] = Mysql::SQLValue($_GET[$pk]);\n }\n }\n }", "private function dataBaseRepresentation() {\n\t\t$array['recipe'] \t\t= $this->recipeId;\n\t\t$array['name'] \t\t\t= $this->name;\n\t\t$array['description'] \t= $this->description;\n\t\t$array['url'] \t\t\t= $this->url;\n\t\treturn $array;\n\t}", "public function init()\n {\n parent::init();\n $this->storage = Instance::ensure($this->storage, '\\ArrayAccess');\n }", "public function key_setup($key)\n\t{\n if (is_array($key))\n\t\t{\n $this->key = $key;\n }\n\t\telseif (isset($key) AND ! empty($key))\n\t\t{\n $this->key = $this->_str2long(str_pad($key, 16, $key));\n }\n\t\telse\n\t\t{\n $this->key = array(0,0,0,0);\n\t\t}\n\t}", "protected function prepareData()\n {\n parent::prepareData();\n $this->prepareConfigurableProductOptions();\n $this->prepareAttributeSet();\n }" ]
[ "0.6061503", "0.5942292", "0.5877831", "0.58777785", "0.5778004", "0.5725188", "0.5706095", "0.56988376", "0.56988376", "0.56564474", "0.55834246", "0.5578728", "0.55576175", "0.5550427", "0.5546914", "0.55340296", "0.5532984", "0.5532149", "0.5520324", "0.55184746", "0.5516693", "0.54997104", "0.54775715", "0.5477518", "0.5460401", "0.5459236", "0.54390043", "0.5434813", "0.54292893", "0.54274696", "0.54145604", "0.5396671", "0.5378021", "0.5363338", "0.5358436", "0.5357155", "0.5355789", "0.5352458", "0.53443253", "0.5334021", "0.5332719", "0.53258735", "0.5318926", "0.5300794", "0.52836686", "0.52807844", "0.5280376", "0.5270821", "0.5263532", "0.52508205", "0.52338475", "0.52239025", "0.5219964", "0.5219458", "0.5215619", "0.52012163", "0.5188847", "0.51885843", "0.5185368", "0.5182696", "0.5178186", "0.51625156", "0.5161502", "0.516063", "0.5152155", "0.51503986", "0.51502633", "0.51437986", "0.5133983", "0.5131064", "0.5130759", "0.51147676", "0.51138294", "0.51119006", "0.51070505", "0.5106447", "0.5104496", "0.51006", "0.51003593", "0.51003593", "0.5098362", "0.50977725", "0.5092277", "0.5089141", "0.5087446", "0.50845397", "0.50842273", "0.5083979", "0.50814253", "0.50762486", "0.5073068", "0.50670683", "0.5063923", "0.5061428", "0.50571954", "0.50520146", "0.5051822", "0.5048836", "0.50451803", "0.5043557" ]
0.7523614
0
This method will serialize all the information in this object into a single array. Updating this method is not necessary when new properties are added to this object in the future. Only the InfoKeys array should be updated with all the properties.
public function serialize() { $aInformation = array(); foreach (self::$s_aInfoKeys as $sKey) { $aInformation[$sKey] = $this[$sKey]; } return serialize($aInformation); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function toArray()\n {\n return $this->info;\n }", "public function jsonSerialize()\n {\n return array_merge([\n 'settings' => $this->settings(),\n 'actions' => $this->actions(),\n 'columns' => $this->columns(),\n 'filters' => $this->filters(),\n 'cacheKey' => $this->generateCacheKey()\n ], parent::jsonSerialize());\n }", "public function jsonSerialize()\n {\n $publicProperties = get_object_vars($this);\n unset($publicProperties['properties']);\n\n return array_merge($publicProperties, $this->getPropertiesField());\n }", "public function jsonSerialize(): array\n {\n return get_object_vars($this);\n }", "public function getInfo(): array\n {\n return $this->_info;\n }", "public function serialize(): array\n {\n return [\n 'className' => get_class($this),\n 'id' => $this->id,\n 'backendId' => $this->backendId,\n 'queue' => $this->queue,\n 'arguments' => serialize(new ArrayObject($this->arguments)),\n 'attempts' => $this->attempts,\n 'enqueued' => $this->enqueued,\n 'serialized' => date('Y-m-d H:i:s'),\n ];\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function serialize()\n {\n return serialize(get_object_vars($this));\n }", "public function serialize()\n {\n return serialize(get_object_vars($this));\n }", "public function serialize()\n {\n return serialize(get_object_vars($this));\n }", "public function getInfo(): array\n {\n return $this->info;\n }", "private function setInfoKeys() {\n\t\tif (!empty(self::$s_aInfoKeys)) {\n\t\t\treturn;\n\t\t}\n\n\t\tself::$s_aInfoKeys = array(\n\t\t\t'ID', 'ProfileID', 'Nickname', 'Level', 'TempLevel',\n\t\t\t'IP', 'JoinTime', 'LogInTime',\n\t\t);\n\t}", "public function jsonSerialize() : array {\n\t\t$fields = get_object_vars($this);\n\n\t\t$fields[\"userId\"] = $this->userId->toString();\n\t\t$fields[\"userProfileId\"] = $this->userProfileId->toString();\n\n\t\treturn($fields);\n\t}", "public function jsonSerialize() {\n return get_object_vars($this);\n }", "public function jsonSerialize() {\n return get_object_vars($this);\n }", "public function JsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\treturn ($fields);\n\t}", "public function JsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\treturn ($fields);\n\t}", "public function jsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\tunset($fields[\"volEmailActivation\"]);\n\t\tunset($fields[\"volHash\"]);\n\t\tunset($fields[\"volSalt\"]);\n\t\treturn($fields);\n\t}", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize(): array {\n\t\t$fields = get_object_vars($this);\n\n\t\t$fields[\"articleId\"] = $this->articleId->toString();\n\t\t$fields[\"articleProfileId\"] = $this->articleProfileId->toString();\n\n\t\t//format the date so that the front end can consume it\n\t\t$fields[\"articleDate\"] = round(floatval($this->articleDate->format(\"U.u\")) * 1000);\n\t\treturn ($fields);\n\t}", "public function jsonSerialize() : array {\n\t\t$fields = get_object_vars($this);\n\n\t\t$fields[\"cookbookRecipeId\"] = $this->cookbookRecipeId->toString();\n\t\t$fields[\"cookbookUserId\"] = $this->cookbookUserId->toString();\n\n\t\treturn($fields);\n\t}", "public function jsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\treturn ($fields);\n\t}", "public function jsonSerialize() : array {\n\t\t$fields = get_object_vars($this);\n\t\t$fields[\"saveJobPostingId\"] = $this->savedJobPostingId->toString();\n\t}", "public function jsonSerialize()\r\n {\r\n return get_object_vars($this);\r\n }", "public function jsonSerialize()\n\t{\n\n\t\treturn get_object_vars($this);\n\n\t}", "public function jsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\treturn($fields);\n\t}", "public function jsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\treturn($fields);\n\t}", "public function jsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\treturn($fields);\n\t}", "public function jsonSerialize()\n {\n return array_merge([\n 'component' => $this->component(),\n 'prefixComponent' => true,\n 'INDEX' => self::INDEX,\n 'ATTRIBUTE_PREFIX' => self::ATTRIBUTE_PREFIX,\n 'UNCHANGED' => self::UNCHANGED,\n 'CREATED' => self::CREATED,\n 'REMOVED' => self::REMOVED,\n 'UPDATED' => self::UPDATED,\n 'STATUS' => self::STATUS,\n 'PREFIX' => self::PREFIX,\n 'name' => $this->name,\n 'singularName' => str_singular($this->name),\n ], $this->meta());\n }", "public function __serialize(): array\n {\n return ['name' => $this->name];\n }", "public function jsonSerialize() {\n\t\treturn(get_object_vars($this));\n\t}", "public function serializar() {\n\t return json_encode(get_object_vars($this), JSON_FORCE_OBJECT);\n\t\t}", "public function serializar() {\n\t return json_encode(get_object_vars($this), JSON_FORCE_OBJECT);\n\t\t}", "public function serialize(): array\n {\n return array_merge([\n 'inputs' => SerializeUtil::serializeArray($this->inputs),\n 'balance' => $this->balance->serialize(),\n ], parent::serialize());\n }", "public function __serialize(): array\n {\n return $this->buffered()->toArray();\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function jsonSerialize(): array\n {\n return array_merge(parent::jsonSerialize(), [\n 'cropable' => $this->cropable,\n 'ratio' => $this->ratio,\n 'size' => $this->size,\n ]);\n }", "public function getSerializableData()\n {\n return [\n 'id' => $this->getId(),\n 'name' => $this->getName(),\n 'description' => $this->getDescription(),\n 'profile' => $this->getProfile(),\n 'salt' => $this->getSalt(),\n 'type' => $this->getType(),\n 'value' => $this->getValue(),\n ];\n }", "public function toArray() {\n\t\t\t\n\t\t\treturn array_merge(get_object_vars($this), array(\n\t\t\t\t'base' => $this->getBase()\n\t\t\t));\n \t\t\n\t\t}", "public function jsonSerialize(): array\n {\n return [\n 'sys' => $this->sys,\n 'name' => $this->name,\n ];\n }", "public function getInfo() {\n return array(\n \"Hash\" => $this->getName(),\n \"Connected\" => $this->isConnected() ? \"yes\" : \"no\",\n \"IP:Port\" => $this->getIp().\":\".$this->getPort(),\n \"Line In\" => $this->getLineIn(),\n \"Line Out \" => $this->getLineOut(),\n \"Dec Key\" => Utils::bin2hex($this->getDecryptionKey(),64),\n \"Enc Key\" => Utils::bin2hex($this->getEncryptionKey(),64),\n );\n }", "public function __debugInfo()\r\n {\r\n return $this->toArray();\r\n }", "public function __debugInfo()\n {\n return [\n 'name' => $this->name,\n 'projectId' => $this->projectId,\n 'info' => $this->info,\n 'connection' => get_class($this->connection)\n ];\n }", "function jsonSerialize()\n {\n return get_object_vars($this);\n }", "function jsonSerialize()\n {\n return get_object_vars($this);\n }", "function jsonSerialize()\n {\n return get_object_vars($this);\n }", "public function __debugInfo() : array\n {\n return [\n 'time' => $this->format('Y-m-d H:i:s.u'),\n ] + get_object_vars($this);\n }", "public function jsonSerialize(): array\n {\n return array_merge([\n 'sendTrytesResult' => $this->sendTrytesResult->serialize(),\n 'bundle' => $this->bundle->serialize(),\n ], parent::serialize());\n }", "public function getInfo()\n {\n return array(\n 'store' => array_keys($this->_store)\n );\n }", "public function getInfoData() {\n return [\n 'name' => $this->name,\n 'brand' => $this->brand,\n 'price' => $this->price,\n 'shipping_price' => $this->shippingPrice,\n 'shipping_time' => $this->shippingTime\n ];\n }", "function jsonSerialize()\n {\n return get_object_vars($this);\n // TODO: Implement jsonSerialize() method.\n }", "public function __debugInfo(): array\n {\n return $this->toArray();\n }", "function jsonSerialize()\n\t{\n\t\treturn [\n\t\t\t'id' => $this->getId(),\n\t\t\t'metadata' => $this->getMetadata()\n\t\t];\n\t}", "public function jsonSerialize()\n {\n $json = array();\n $json['Name'] = $this->name;\n $json['MvaNumber'] = $this->mvaNumber;\n $json['CompanyPhone'] = $this->companyPhone;\n $json['CompanyEmail'] = $this->companyEmail;\n $json['Id'] = $this->id;\n $json['CustomerNumber'] = $this->customerNumber;\n $json['Resources'] = $this->resources;\n $json['CompanyUrl'] = $this->companyUrl;\n $json['Contact'] = $this->contact;\n $json['Address'] = $this->address;\n $json['Dealer'] = $this->dealer;\n $json['Settings'] = $this->settings;\n $json['Country'] = $this->country;\n\n return array_merge($json, $this->additionalProperties);\n }", "public function jsonSerialize()\n {\n return [\n self::CLASS_INDEX => $this->class,\n self::CONSTRUCTOR_ARGUMNETS_INDEX => $this->constructorArguments,\n self::PROPERTIES_INDEX => $this->properties,\n ];\n }", "public function __debugInfo(): array\n\t{\n\t\t$help = Help::forMethods($this->object, $this->allowedMethods());\n\n\t\treturn [\n\t\t\t'type' => $this::CLASS_ALIAS,\n\t\t\t'methods' => $help,\n\t\t\t'value' => $this->toArray()\n\t\t];\n\t}", "public function jsonSerialize()\n {\n return [\n 'id' => $this->getId(),\n 'name' => $this->getName(),\n 'fields' => $this->getFields(),\n 'memberCount' => $this->getMemberCount(),\n ];\n }", "public function safeToArray()\n {\n return array(\n 'id' => $this->getId(),\n 'name' => $this->getName(),\n 'counts' => $this->getCounts()->toArray(),\n 'settings' => $this->getSettings()->safeToArray(),\n 'hasCuratorRole' => $this->hasRole('ROLE_CURATOR'),\n );\n }", "public function __debugInfo(): array\n {\n return $this->toArray(false);\n }", "public function toArray()\n {\n $data = array(\n 'id' => $this->getId(),\n 'status' => $this->getStatus(),\n 'title' => $this->field ? ($this->field->getAlertDescription() ? $this->field->getAlertDescription() : $this->field->getAlertTitle()) : '',\n 'alert_description' => $this->field ? ($this->field->getAlertDescription() ? $this->field->getAlertDescription() : $this->field->getAlertTitle()) : '',\n 'field' => $this->field ? $this->field->toArray() : null,\n 'vehicle' => $this->getVehicle()->toInfoArray(),\n 'user' => $this->check_list ? $this->check_list->getUser()->toInfoArray() : array(),\n 'description' => $this->getDescription(),\n 'images' => $this->getImages(),\n 'thumbnail' => $this->getThumbnail(),\n 'comments' => $this->getComments(),\n 'creation_date' => $this->getCreationDate()->getTimestamp(),\n 'update_date' => $this->getUpdateDate()->getTimestamp(),\n 'history' => $this->getHistory(),\n 'refreshed_times' => $this->getRefreshedTimes()\n );\n return $data;\n }", "public function toArray() {\n $a = parent::toArray();\n if( $this->version ) {\n $a[\"version\"] = $this->version;\n }\n if( $this->accountLocked ) {\n $a[\"accountLocked\"] = $this->accountLocked;\n }\n if( $this->phoneNumber ) {\n $a[\"phoneNumber\"] = $this->phoneNumber;\n }\n if( $this->firstName ) {\n $a[\"firstName\"] = $this->firstName;\n }\n if( $this->lastName ) {\n $a[\"lastName\"] = $this->lastName;\n }\n if( $this->username ) {\n $a[\"username\"] = $this->username;\n }\n if( $this->credentialsExpired ) {\n $a[\"credentialsExpired\"] = $this->credentialsExpired;\n }\n if( $this->address ) {\n $a[\"address\"] = $this->address->toArray();\n }\n if( $this->accountExpired ) {\n $a[\"accountExpired\"] = $this->accountExpired;\n }\n if( $this->enabled ) {\n $a[\"enabled\"] = $this->enabled;\n }\n if( $this->email ) {\n $a[\"email\"] = $this->email;\n }\n if( $this->id ) {\n $a[\"id\"] = $this->id;\n }\n if( $this->website ) {\n $a[\"website\"] = $this->website;\n }\n if( $this->roles ) {\n $ab = array();\n foreach( $this->roles as $i => $x ) {\n $ab[$i] = $x->toArray();\n }\n $a['roles'] = $ab;\n }\n return $a;\n }", "public final function __toArray()\n {\n $data = array();\n \n $all_fields = $this->__get_fields();\n \n foreach ($all_fields as $key => $value)\n {\n $data[$key] = $value;\n }\n \n $data[self::CLASS_FIELD_KEY] = $this->__getRawClassName();\n \n return $data;\n }", "public function jsonSerialize() : array {\n\t\t$fields = get_object_vars($this);\n\n\t\t$fields[\"matchUserId\"] = $this->matchUserId->toString();\n\t\t$fields[\"matchToUserId\"] = $this->matchToUserId->toString();\n\n\t\treturn($fields);\n\t}", "public function jsonSerialize() : array {\n\t\t$fields = get_object_vars($this);\n\n\t\t$fields[\"reportId\"] = $this->reportId->toString();\n\t\t$fields[\"reportUserId\"] = $this->reportUserId->toString();\n\t\t$fields[\"reportAbuserId\"] = $this->reportAbuserId->toString();\n\n\t\t//format the date so that the front end can consume it\n\t\t$fields[\"reportDate\"] = round(floatval($this->reportDate->format(\"U.u\")) * 1000);\n\t\treturn($fields);\n\t}", "public function toArray()\n {\n return array_merge(get_object_vars($this), parent::toArray());\n }", "function jsonSerialize()\n {\n return Helper::serialize(get_object_vars($this));\n }", "public function jsonSerialize()\n {\n $json = array();\n $json['id'] = $this->id;\n $json['abbrvName'] = $this->abbrvName;\n $json['logoUrl'] = $this->logoUrl;\n $json['decryptionKeyActivated'] = $this->decryptionKeyActivated;\n $json['createdDate'] = $this->createdDate;\n $json['lastModifiedDate'] = $this->lastModifiedDate;\n $json['status'] = $this->status;\n\n return array_merge($json, $this->additionalProperties);\n }", "public function __debugInfo()\n {\n return array_merge(parent::__debugInfo(), [\n 'consumer_tag' => $this->consumerTag,\n 'delivery_tag' => $this->deliveryTag,\n 'redeliver' => $this->redeliver,\n 'exchange' => $this->exchange,\n 'routing_key' => $this->routingKey,\n 'channel_object_hash' => spl_object_hash($this->channel),\n ]);\n }", "public function __debugInfo() : array\n {\n return get_object_vars($this);\n }", "public function getInfo()\n\t{\n\t\treturn array();\n\t}", "public function customSerialize()\n {\n return [\n 'id' => $this->getId(),\n 'name' => $this->getName(),\n 'lastName' => $this->getLastName(),\n 'age' => $this->getAge(),\n 'company' =>[\n 'id' => $this->getCompany()->getId(),\n 'name' => $this->getCompany()->getName(),\n ],\n 'type' => [\n 'id' => $this->getTypes()->getId(),\n 'name' => $this->getTypes()->getName(),\n ]\n ];\n }", "public function jsonSerialize(): array\n {\n return $this->getAttributes();\n }", "public function jsonSerialize()\n {\n if (method_exists($this, 'toArray')) {\n return $this->toArray();\n }\n\n return [];\n }", "public function toArray() {\n return get_object_vars($this);\n }", "public function toArray() {\n return get_object_vars($this);\n }", "public function getToApiObjectFields() {\n return array();\n }", "public function toArray() {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n return array_merge([\n 'component' => $this->component(),\n 'prefixComponent' => true,\n 'indexName' => $this->name,\n 'name' => $this->name,\n 'attribute' => $this->attribute,\n 'value' => $this->value,\n 'panel' => $this->panel,\n 'sortable' => $this->sortable,\n 'nullable' => $this->nullable,\n 'readonly' => $this->isReadonly(App::make(NovaRequest::class)),\n 'textAlign' => $this->textAlign,\n ], $this->meta());\n }", "public function jsonSerialize() : array {\n\t\t$fields = get_object_vars($this);\n\t\t$fields[\"userProfileId\"] = $this->userProfileId->toString();\n\t\treturn($fields);\n\t}", "protected function getUpdateInfo()\n {\n return array_fill_keys(\n array_keys($this->getSelected()),\n $this->getUpdateInfoElement()\n );\n }", "public function jsonSerialize() {\n return $this->toArray();\n }", "public function jsonSerialize(): array {\n\t\t$fields = get_object_vars($this);\n\t\t$fields[\"commentId\"] = $this->commentId->toString();\n\t\t$fields[\"commentProfileId\"] = $this->commentProfileId->toString();\n\t\t$fields[\"commentTrailId\"] = $this->commentTrailId->toString();\n\t\t//format the date so that the front end can consume it\n\t\t$fields[\"commentTimestamp\"] = round(floatval($this->commentTimestamp->format(\"U.u\")) * 1000);\n\t\treturn ($fields);\n\t}", "public function toArray() {\n return get_object_vars($this);\n }", "public function toJson() {\n return json_encode(get_object_vars($this));\n }", "public function jsonSerialize()\n {\n return array_merge(parent::jsonSerialize(),[]);\n }", "public function jsonSerialize()\n {\n return [\n 'AuthenticationKey' => $this->getAuthenticationKey(),\n 'RetailerGuid' => $this->getRetailerGuid(),\n 'RetailerId' => $this->getRetailerId(),\n ];\n }", "public function jsonSerialize(): array\n {\n return array(\n 'id' => $this->id,\n 'username' => utf8_encode($this->username),\n 'email' => utf8_encode($this->email),\n 'enabled' => $this->enabled,\n 'admin' => $this->isAdmin\n );\n }", "public function __debugInfo()\n {\n return $this->_properties + [\n '[new]' => $this->isNew(),\n ];\n }", "public function __serialize() { \n $serialized = [\n 'instance_name' => $this->instance_name,\n 'local_columns' => array_map(fn($column) => $this->serializeColumn($column), $this->getLocalColumns()),\n 'referenced_columns' => array_map(fn($column) => $this->serializeColumn($column), $this->getReferencedColumns()),\n 'is_reversed_relation' => $this->is_reverse_relation,\n 'target_relation' => $this->getTargetRelation(),\n 'type' => $this->type,\n ];\n\n return $serialized;\n\n }", "public function toArray() :array {\n return get_object_vars($this);\n }", "function getInfo()\n\t{\n\t\treturn array_merge($this->getDeveloperInfo(), $this->getContact()->getInfo());\n\t}", "public function toArray() {\n return get_object_vars($this);\n }", "public function jsonSerialize()\n {\n $json = array();\n $json['id'] = $this->id;\n $json['name'] = $this->name;\n $json['voa'] = $this->voa;\n $json['voi'] = $this->voi;\n $json['stateAgg'] = $this->stateAgg;\n $json['ach'] = $this->ach;\n $json['transAgg'] = $this->transAgg;\n $json['aha'] = $this->aha;\n $json['accountTypeDescription'] = $this->accountTypeDescription;\n $json['phone'] = $this->phone;\n $json['urlHomeApp'] = $this->urlHomeApp;\n $json['urlLogonApp'] = $this->urlLogonApp;\n $json['oauthEnabled'] = $this->oauth_Enabled;\n $json['urlForgotPassword'] = $this->urlForgotPassword;\n $json['urlOnlineRegistration'] = $this->urlOnlineRegistration;\n $json['class'] = $this->mclass;\n $json['specialText'] = $this->specialText;\n $json['specialInstructions'] = $this->specialInstructions;\n $json['address'] = $this->address;\n $json['currency'] = $this->currency;\n $json['email'] = $this->email;\n $json['status'] = $this->status;\n $json['newInstitutionId'] = $this->newInstitutionId;\n $json['branding'] = $this->branding;\n $json['oauthInstitutionId'] = $this->oauth_InstitutionId;\n\n return array_merge($json, $this->additionalProperties);\n }", "public function jsonSerialize()\n {\n $json = array();\n $json['MvaNumber'] = $this->mvaNumber;\n $json['Prokura'] = $this->prokura;\n $json['Signature'] = $this->signature;\n $json['Report'] = $this->report;\n\n return array_merge($json, $this->additionalProperties);\n }" ]
[ "0.64947146", "0.62652767", "0.6263716", "0.6253974", "0.6228656", "0.62259215", "0.6186687", "0.61436033", "0.61436033", "0.61436033", "0.61313325", "0.61070704", "0.6099184", "0.6097074", "0.6097074", "0.60861224", "0.60861224", "0.60814995", "0.60717505", "0.60717505", "0.60717505", "0.60717505", "0.60717505", "0.60717505", "0.60670376", "0.60655063", "0.60644656", "0.6056405", "0.60503733", "0.604748", "0.604422", "0.604422", "0.604422", "0.60152024", "0.60125273", "0.599622", "0.59928554", "0.59928554", "0.5978702", "0.59741884", "0.5963287", "0.5963287", "0.59484714", "0.59311134", "0.59028804", "0.59014535", "0.5898978", "0.5887615", "0.58793634", "0.5869265", "0.5869265", "0.5869265", "0.58501893", "0.5844982", "0.5843662", "0.5833505", "0.5830148", "0.5828828", "0.58254194", "0.582032", "0.58145535", "0.58086467", "0.5807069", "0.5803054", "0.57970613", "0.57785195", "0.57782084", "0.5774976", "0.5768929", "0.5767044", "0.5766274", "0.5764091", "0.5761993", "0.5759515", "0.5759477", "0.5750743", "0.5726674", "0.5719665", "0.5718935", "0.5718513", "0.5718513", "0.57093596", "0.5708683", "0.5708199", "0.5707623", "0.5704746", "0.5691369", "0.5690774", "0.56778234", "0.56755465", "0.56746054", "0.5671272", "0.56686443", "0.5663963", "0.56604296", "0.56587917", "0.5656768", "0.5656481", "0.5655029", "0.56514716" ]
0.71195203
0
This method will unserialize the date that was serialized earlier in the serialize () method, and set the properties to the values as specified in the serialized data.
public function unserialize($sSerialized) { $this->setInfoKeys(); $aInformation = unserialize($sSerialized); foreach ($aInformation as $sKey => $mValue) { $this[$sKey] = $mValue; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __wakeup(): void\n {\n /**\n * Prior to unserialization, this is a string.\n *\n * @var string $timezone\n */\n $timezone = $this->timezone;\n\n $this->timezone = new DateTimeZone($timezone);\n parent::__construct($this->date, $this->timezone);\n }", "public function unserialize($serialized)\n {\n // older data which does not include all properties.\n $data = array_merge(unserialize($serialized), array_fill(0, 2, null));\n\n list($this->email, $this->id) = $data;\n }", "public function unserialize($data)\n {\n foreach (unserialize($data) as $propertyName => $propertyValue) {\n $this->$propertyName = $propertyValue;\n }\n }", "function unserialize($data){\r\n\t\t$data = unserialize($data);\r\n\t\t$this -> firstName = $data['first'];\r\n\t\t$this -> lastName = $data['last'];\r\n\t}", "function setData($data)\n {\n $this->date=$data;\n }", "public function load()\n {\n parent::load();\n\n // appointments are not to the second, so remove the :00 at the end of the datetime field\n $this->datetime = substr( $this->datetime, 0, -3 );\n }", "public function jsonSerialize(){\n if( ! $this->isPersisted() ){\n $properties = (object) get_object_vars($this);\n unset($properties->id);\n return $properties;\n }\n $properties = (object) get_object_vars($this);\n $properties->startUTC = $properties->startUTC->format('c');\n $properties->endUTC = $properties->endUTC->format('c');\n $properties->repeatEndUTC = !is_null($properties->repeatEndUTC) ? $properties->repeatEndUTC->format('c') : null;\n $properties->weeklyDays = is_null($properties->weeklyDays) ? array() :\n // All this does is cast the exploded values from strings to integers\n array_map(function($day){ return (int)$day; }, explode(',',$properties->weeklyDays));\n return $properties;\n }", "public function unserialize($serialized)\r\n {\r\n $str = unserialize($serialized);\r\n\r\n foreach ($str as $member => $value) {\r\n $this->$member = $value;\r\n }\r\n }", "abstract protected function serializeData($unSerializedData);", "public function unserialize($serialized)\n {\n $this->data = unserialize($serialized);\n }", "public function __wakeup()\n\t{\n\t\tforeach( get_object_vars( $this ) as $k => $v )\n\t\t{\n\t\t\t$this->$k = null;\n\t\t}\n\t\t\n\t\tthrow new Exception(\"Cannot unserialize this object\");\n\t}", "protected function setProperties()\n {\n foreach ($this->data as $key => $value) {\n $this->$key = $value;\n }\n }", "public function unserialize($serialized)\n {\n $raw = unserialize($serialized);\n\n $this->setIdentity($raw['identity']);\n $this->setName($raw['name']);\n $this->setEmailAddress($raw['emailAddress']);\n }", "public function beforeSave() {\n foreach ($this->dateFields as $item) {\n $this->data[$this->name][$item] = $this->_date4Db($this->data[$this->name][$item]);\n }\n return parent::beforeSave();\n }", "public function unserialize($serialized)\n {\n $data = unserialize($serialized);\n // add a few extra elements in the array to ensure that we have enough keys when unserializing\n // older data which does not include all properties.\n $data = array_merge($data, array_fill(0, 2, null));\n \n list ($this->password, $this->salt, $this->usernameCanonical, $this->username, $this->expired, $this->locked, $this->credentialsExpired, $this->enabled, $this->id) = $data;\n }", "private function _setDate(){\n\t\tif($this->_year>=1970&&$this->_year<=2038){\n\t\t\t$this->_day = date('d', $this->_timestamp);\n\t\t\t$this->_month = date('m', $this->_timestamp);\n\t\t\t$this->_year = date('Y', $this->_timestamp);\n\t\t} else {\n\t\t\t$dateParts = self::_getDateParts($this->_timestamp, true);\n\t\t\t$this->_day = sprintf('%02s', $dateParts['mday']);\n\t\t\t$this->_month = sprintf('%02s', $dateParts['mon']);\n\t\t\t$this->_year = $dateParts['year'];\n\t\t}\n\t\t$this->_date = $this->_year.'-'.$this->_month.'-'.$this->_day;\n\t}", "abstract public function unserialize($serialized);", "public function unserialize($serialized)\n {\n $data=unserialize($serialized);\n $this->id=$data['id'];\n\n }", "public function unserialize($serialized)\n {\n list (\n $this->id,\n $this->usuario,\n $this->clave,\n ) = unserialize($serialized);\n }", "public function unserialize($data)\n {\n list($this->facebookId, $parentData) = unserialize($data);\n parent::unserialize($parentData);\n }", "abstract protected function unSerializeData();", "abstract protected function serializeData();", "public function unserialize($data) {}", "public function exchangeArray($data)\n {\n $this->date = (isset($data['date'])) ? $data['date'] : null;\n }", "public function set_dates(){\n // if the id is not set, this means its anew item being created\n if(property_exists($this, 'created_on') && empty($this->id)){\n $this->created_on = date('Y-m-d H:i:s');\n }\n\n // if id is set, its an update\n if(property_exists($this, 'last_updated_on') && isset($this->id)){\n $this->last_updated_on = date('Y-m-d H:i:s');\n }\n }", "public function __unserialize(array $data): void\n {\n $this->__construct($data);\n }", "public function setDate($date);", "public function setData($data)\n\t{\n\t\t$this->_data = unserialize($data);\n\t\t$this->_hashFunc = $this->_data['hashFunc'];\n\t}", "public function parseDate(){\n \t$attrs = ['requested_at', 'replied_at', 'fixed_begin', 'fixed_end'];\n \tforeach ($attrs as $a){\n \t\tif (is_string($d = $this->getAttribute($a))){\n \t\t\t$d = \\DateTime::createFromFormat('Y-m-d H:i:s', $d);\n \t\t\tif ($d){\n\t \t\t\t$this->setAttribute($a, ['date' => $d->format('Y-m-d'), 'time' => $d->format('H:i:s')]);\n \t\t\t} else {\n\t \t\t\t$this->setAttribute($a, ['date' => date('Y-m-d'), 'time' => date('H:i:s')]);\n \t\t\t}\n \t\t}\n \t}\n }", "#[\\ReturnTypeWillChange]\n public function unserialize($data)\n {\n }", "public function __wakeup()\n {\n // clean all properties\n foreach(get_object_vars($this) as $k => $v) {\n $this->$k = null;\n }\n throw new Exception(\"Not a serializable object\");\n }", "#[\\ReturnTypeWillChange]\n public function __unserialize($data)\n {\n }", "public function __wakeup() {\r\n\t\t_doing_it_wrong( __FUNCTION__, esc_html__( 'Unserializing instances of this class is forbidden.', 'wc_name_your_price' ), '3.0.0' );\r\n\t}", "public function unserialize($serialized)\n {\n $data = unserialize($serialized);\n\n foreach ($data as $key => $value) {\n $this->{$key} = $value;\n }\n\n \\XTAIN\\Bundle\\JoomlaBundle\\Library\\Loader::injectStaticDependencies(__CLASS__);\n\n $this->connection = self::$entityManager->getConnection();\n $this->platform = $this->connection->getDatabasePlatform();\n $this->driver = $this->connection->getDriver();\n }", "public function setDate()\n\t{\n\t\tif($this->isNewRecord)\n\t\t\t$this->create_time=$this->update_time=time();\n\t\telse\n\t\t\t$this->update_time=time();\n\t}", "public function setDate()\n\t{\n\t\tif($this->isNewRecord)\n\t\t\t$this->create_time=$this->update_time=time();\n\t\telse\n\t\t\t$this->update_time=time();\n\t}", "public function __wakeup() {\n\t\t\t_doing_it_wrong( __FUNCTION__, __( 'Unserializing is forbidden!', 'be-table-ship' ), '4.0' );\n\t\t}", "public function unserialize($serialized)\n {\n }", "public function setUpdated(): void\n {\n $this->originalData = $this->itemReflection->dehydrate($this->item);\n }", "public function setData()\n {\n $this->data=new \\DateTime('now');\n\n }", "function setData($data, $format = DATE_FORMAT_ISO)\r\n {\r\n switch($format) {\r\n case DATE_FORMAT_ISO:\r\n if (preg_match(\"/^([0-9]{4})-([0-9]{2})-([0-9]{2})[ ]([0-9]{2}):([0-9]{2}):([0-9]{2})/i\",$data,$regs)) {\r\n $this->ano = $regs[1];\r\n $this->mes = $regs[2];\r\n $this->dia = $regs[3];\r\n $this->hora = $regs[4];\r\n $this->minuto = $regs[5];\r\n $this->segundo = $regs[6];\r\n } else {\r\n $this->ano = 0;\r\n $this->mes = 1;\r\n $this->dia = 1;\r\n $this->hora = 0;\r\n $this->minuto = 0;\r\n $this->segundo = 0;\r\n }\r\n break;\r\n case DATE_FORMAT_TIMESTAMP:\r\n if (preg_match(\"/^([0-9]{4})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})/i\",$data,$regs)) {\r\n $this->ano = $regs[1];\r\n $this->mes = $regs[2];\r\n $this->dia = $regs[3];\r\n $this->hora = $regs[4];\r\n $this->minuto = $regs[5];\r\n $this->segundo = $regs[6];\r\n } else {\r\n $this->ano = 0;\r\n $this->mes = 1;\r\n $this->dia = 1;\r\n $this->hora = 0;\r\n $this->minuto = 0;\r\n $this->segundo = 0;\r\n }\r\n break;\r\n case DATE_FORMAT_UNIXTIME:\r\n $this->setData(date(\"Y-m-d H:i:s\", intval($data)));\r\n break;\r\n }\r\n }", "abstract protected function unserializeData(array $data);", "public function populateDefaults(){\n\t\tparent::populateDefaults();\n\t\t\n\t\t$this->setField('Date', date('Y-m-d H:i:s', strtotime('now')));\n\t}", "public static function sanitizeForSerialization($postData)\n {\n foreach ($postData as $key => $value) {\n if (is_a($value, \"DateTime\")) {\n $postData->{$key} = $value->format(DateTime::ISO8601);\n }\n }\n return $postData;\n }", "public function __unserialize(array $data): void\n {\n $this->createFromArray($data);\n }", "public function unserialize($serialized);", "public function unserialize($serialized);", "private function formate_change_individual($data) {\n foreach ($data as $key => $value) {\n $data[$key]->class_start_datetime = date('d-m-Y', strtotime($value->class_start_datetime));\n $data[$key]->class_end_datetime = date('d-m-Y', strtotime($value->class_end_datetime));\n $data[$key]->enrolled_on = date('d-m-Y', strtotime($value->enrolled_on));\n }\n return $data;\n }", "public function afterSave()\r\n\t{\r\n\t\tif(count($this->serialAttributes)) {\r\n\t\t\tforeach($this->serialAttributes as $attribute) {\r\n\t\t\t\t$_att = $this->owner->$attribute;\r\n\t\t\t\tif(!empty($_att)\r\n\t\t\t\t && is_scalar($_att)) {\r\n\t\t\t\t\t$a = @unserialize($_att);\r\n\t\t\t\t\tif($a !== false) {\r\n\t\t\t\t\t\t$this->owner->$attribute = $a;\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\t$this->owner->$attribute = null;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\t\t\t\r\n\t\t}\r\n\t}", "public function setDate($date){\n\t\t$this->date = $date;\n\t}", "public function bsonUnserialize( array $data ): void {\n\t\t//get the called class name\n\t\t$calledClassFqn = typeHelpers::classNameToFqn( get_called_class() );\n\n\t\ttry {\n\t\t\t$rClass = new \\ReflectionClass( $calledClassFqn );\n\t\t}\n\t\tcatch( \\ReflectionException $e ) {\n\t\t\tthrow new databaseException( 'Failed to unserialize bson data for ' . $calledClassFqn, 500, $e );\n\t\t}\n\n\t\t$this->_meta = new _meta( $calledClassFqn );\n\n\t\t//get properties of the class and set their values to the data provided from the database\n\t\t$rProperties = $rClass->getProperties();\n\t\tforeach( $rProperties as $rProperty ) {\n\t\t\t$propertyName = $rProperty->getName();\n\n\t\t\t//if property is not meant to be unserialized, exclude it\n\t\t\t$attributes = $rProperty->getAttributes( excludeBsonUnserialize::class );\n\t\t\tif( count( $attributes )>0 ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$propertyType = null;\n\t\t\t$propertyTypeName = '';\n\n\t\t\tif( $rProperty->hasType() ) {\n\t\t\t\t$propertyType = $rProperty->getType();\n\n\t\t\t\tif( !( $propertyType instanceof \\ReflectionUnionType ) ) {\n\t\t\t\t\t$propertyTypeName = $propertyType->getName();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//if the property is an array, check if the doc comment defines the type\n\t\t\t$propertyIsTypedArray = false;\n\t\t\tif( $propertyTypeName=='array' ) {\n\t\t\t\t$arrayType = typeHelpers::getVarTypeFromDocComment( $rProperty->getDocComment() );\n\t\t\t\tif( $arrayType!='array' && $arrayType!='string' && $arrayType!='float' && $arrayType!='int' ) {\n\t\t\t\t\t$propertyIsTypedArray = true;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif( $propertyIsTypedArray ) {\n\t\t\t\tif( !isset( $data[ $propertyName ] ) ) {\n\t\t\t\t\tlog::info( 'MongoUnserialize', $calledClassFqn.'.'.$propertyName.' of type '.$propertyType.' set to default value' );\n\t\t\t\t\t$data[ $propertyName ] = $rProperty->getDefaultValue();\n\t\t\t\t}\n\t\t\t\tforeach( $data[ $propertyName ] as $key => $value ) {\n\t\t\t\t\tlog::info( 'MongoUnserialize', $calledClassFqn.'.'.$propertyName.' key '.$key.' of type '.$propertyType.' set' );\n\t\t\t\t\t$this->$propertyName[ $key ] = $this->bsonUnserializeDataItem( $rProperty, $propertyType, $arrayType, $value );\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\tif( !array_key_exists( $propertyName, $data ) ) {\n\t\t\t\t\tlog::info( 'MongoUnserialize', $calledClassFqn.'.'.$propertyName.' value not in provided data' );\n\t\t\t\t\t$value = null;\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\t$value = $data[ $propertyName ];\n\t\t\t\t}\n\n\t\t\t\t//set the class property = the parsed value from the database\n\t\t\t\ttry {\n\t\t\t\t\tlog::info( 'MongoUnserialize', $calledClassFqn.'.'.$propertyName.' of type '.$propertyType.' set' );\n\t\t\t\t\t$this->$propertyName = $this->bsonUnserializeDataItem( $rProperty, $propertyType, $propertyTypeName, $value );\n\t\t\t\t}\n\t\t\t\tcatch( \\Exception|\\TypeError $e ) {\n\t\t\t\t\terror_log( $e );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t//if this is a text search that has provided the score of the result via the _score field\n\t\tif( isset( $data[ '_score' ] ) ) {\n\t\t\t$this->_meta->score = round( $data[ '_score' ], 2 );\n\t\t}\n\n\t\tif( method_exists( $this, '_afterBsonUnserialize' ) ) {\n\t\t\t$this->_afterBsonUnserialize( $data );\n\t\t}\n\t}", "public function unserialize($serialized)\n {\n $data = unserialize($serialized);\n\n //TODO load references with id ?\n }", "public function __clone()\n {\n foreach ($this as $key => $val)\n {\n if (is_object($val) || is_array($val))\n $this->{$key} = unserialize(serialize($val));\n }\n }", "public function setDateToSend($data)\n {\n if ($data == '0000-00-00 00:00:00') {\n $data = null;\n }\n if ($data === 'CURRENT_TIMESTAMP' || is_null($data)) {\n $data = \\Zend_Date::now()->setTimezone('UTC');\n }\n\n if ($data instanceof \\Zend_Date) {\n\n $data = new \\DateTime($data->toString('yyyy-MM-dd HH:mm:ss'), new \\DateTimeZone($data->getTimezone()));\n\n } elseif (!is_null($data) && !$data instanceof \\DateTime) {\n\n $data = new \\DateTime($data, new \\DateTimeZone('UTC'));\n }\n if ($data instanceof \\DateTime && $data->getTimezone()->getName() != 'UTC') {\n\n $data->setTimezone(new \\DateTimeZone('UTC'));\n }\n\n if ($this->_dateToSend != $data) {\n $this->_logChange('dateToSend');\n }\n\n $this->_dateToSend = $data;\n return $this;\n }", "public function deserialize($param)\n {\n if ($param === null) {\n return;\n }\n if (array_key_exists(\"BizId\",$param) and $param[\"BizId\"] !== null) {\n $this->BizId = $param[\"BizId\"];\n }\n\n if (array_key_exists(\"StartDate\",$param) and $param[\"StartDate\"] !== null) {\n $this->StartDate = $param[\"StartDate\"];\n }\n\n if (array_key_exists(\"EndDate\",$param) and $param[\"EndDate\"] !== null) {\n $this->EndDate = $param[\"EndDate\"];\n }\n }", "public function __wakeup()\n\t{\n\t\t// Re-initialize start time on wake-up\n\t\t$this->start_time = $this->microtime_float();\n\t}", "public function __unserialize(array $data): void\n {\n $this->name = $data['name'];\n }", "public function onPrePersist()\n {\n $this->createdAt = new DateTime();\n $this->updatedAt = new DateTime();\n }", "public function onPrePersist()\n {\n $this->createdAt = new DateTime();\n $this->updatedAt = new DateTime();\n }", "protected function resetProperties() {}", "public function set($post_to_display) {\n foreach ($post_to_display as $key=>&$value) {\n if ($key === \"date\") {\n $this->{$key} = new DateTime($value->date);\n } else {\n $this->{$key} = $value;\n }\n }\n }", "public function __clone()\n\t{\n\t\tforeach ($this as $k => $v)\n\t\t{\n\t\t\tif ((is_object($v)) || is_array($v)) {\n\t\t\t\t$this->{$k} = unserialize(serialize($v));\n\t\t\t}\n\t\t}\n\t}", "public function __clone()\n\t{\n\t\tforeach ($this as $k => $v)\n\t\t{\n\t\t\tif ((is_object($v)) || is_array($v)) {\n\t\t\t\t$this->{$k} = unserialize(serialize($v));\n\t\t\t}\n\t\t}\n\t}", "public function unserialize($serialized)\n {\n $temp = json_decode($serialized);\n\n if (isset($temp->url)) {\n $this->url = $temp->url;\n }\n\n if (isset($temp->action)) {\n $this->action = $temp->action;\n }\n\n if (isset($temp->filename)) {\n $this->filename = $temp->filename;\n }\n }", "public function unserialize($serialized)\n {\n list (\n $this->id,\n $this->email,\n $this->name,\n $this->password,\n // see section on salt below\n // $this->salt\n ) = unserialize($serialized);\n }", "public function touch()\n\t{\n\t\t$this['last_dismiss_date'] = new \\DateTime();\n\t\t$this['last_email_date'] = new \\DateTime();\n\t}", "public function __clone()\n\t{\n\t\tforeach ($this as $k => $v)\n\t\t{\n\t\t\tif (is_object($v) || is_array($v))\n\t\t\t{\n\t\t\t\t$this->{$k} = unserialize(serialize($v));\n\t\t\t}\n\t\t}\n\t}", "public function __wakeup() {\n\t\t\tparent::__wakeup();\n\t\t}", "#[ReturnTypeWillChange]\n public function __unserialize($data)\n {\n foreach ($data as $item) {\n $this->unshift($item);\n }\n }", "public function jsonSerialize() {\n\t\t$fields = get_object_vars($this);\n\t\t// format the date so that the front end can consume it\n\t\t$fields[\"reviewDateTime\"] = round(floatval($this->reviewDateTime->format(\"U.u\")) * 1000);\n\t\treturn ($fields);\n\t}", "public function prepAttributesForUse()\n\t{\n\t\t$attributes = $this->defineAttributes();\n\t\t$attributes['dateUpdated'] = array('0' => AttributeType::DateTime, 'required' => true);\n\t\t$attributes['dateCreated'] = array('0' => AttributeType::DateTime, 'required' => true);\n\n\t\tforeach ($attributes as $name => $config)\n\t\t{\n\t\t\t$config = ModelHelper::normalizeAttributeConfig($config);\n\t\t\t$value = $this->getAttribute($name);\n\n\t\t\tswitch ($config['type'])\n\t\t\t{\n\t\t\t\tcase AttributeType::DateTime:\n\t\t\t\t{\n\t\t\t\t\tif ($value)\n\t\t\t\t\t{\n\t\t\t\t\t\tif (DateTimeHelper::isValidTimeStamp($value))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$dateTime = new DateTime('@'.$value);\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// TODO: MySQL specific.\n\t\t\t\t\t\t\t$dateTime = DateTime::createFromFormat(DateTime::MYSQL_DATETIME, $value);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$this->setAttribute($name, $dateTime);\n\t\t\t\t\t}\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\tcase AttributeType::Mixed:\n\t\t\t\t{\n\t\t\t\t\tif (!empty($value) && is_string($value))\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->setAttribute($name, JsonHelper::decode($value));\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->setAttribute($name, array());\n\t\t\t\t\t}\n\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function deserialize($param)\n {\n if ($param === null) {\n return;\n }\n if (array_key_exists(\"Time\",$param) and $param[\"Time\"] !== null) {\n $this->Time = $param[\"Time\"];\n }\n\n if (array_key_exists(\"CompanyId\",$param) and $param[\"CompanyId\"] !== null) {\n $this->CompanyId = $param[\"CompanyId\"];\n }\n\n if (array_key_exists(\"ShopId\",$param) and $param[\"ShopId\"] !== null) {\n $this->ShopId = $param[\"ShopId\"];\n }\n\n if (array_key_exists(\"StartDay\",$param) and $param[\"StartDay\"] !== null) {\n $this->StartDay = $param[\"StartDay\"];\n }\n\n if (array_key_exists(\"EndDay\",$param) and $param[\"EndDay\"] !== null) {\n $this->EndDay = $param[\"EndDay\"];\n }\n\n if (array_key_exists(\"Limit\",$param) and $param[\"Limit\"] !== null) {\n $this->Limit = $param[\"Limit\"];\n }\n\n if (array_key_exists(\"Offset\",$param) and $param[\"Offset\"] !== null) {\n $this->Offset = $param[\"Offset\"];\n }\n }", "public function unserialize($serialized=null){ }", "protected function __wakeup() {\n trigger_error('Cannot deserialize instance of Singleton pattern ...', E_USER_ERROR);\n }", "public function prepAttributesForSave()\n\t{\n\t\t$attributes = $this->defineAttributes();\n\t\t$attributes['dateUpdated'] = array('0' => AttributeType::DateTime, 'required' => true);\n\t\t$attributes['dateCreated'] = array('0' => AttributeType::DateTime, 'required' => true);\n\n\t\tforeach ($attributes as $name => $config)\n\t\t{\n\t\t\t$config = ModelHelper::normalizeAttributeConfig($config);\n\t\t\t$value = $this->getAttribute($name);\n\n\t\t\t$this->setAttribute($name, ModelHelper::packageAttributeValue($config, $value, true));\n\t\t}\n\n\t\t// Populate dateCreated and uid if this is a new record\n\t\tif ($this->isNewRecord())\n\t\t{\n\t\t\t$this->dateCreated = DateTimeHelper::currentTimeForDb();\n\t\t\t$this->uid = StringHelper::UUID();\n\t\t}\n\n\t\t// Update the dateUpdated\n\t\t$this->dateUpdated = DateTimeHelper::currentTimeForDb();\n\t}", "public function setDate()\n\t{\n\t\tif ($this->getIsNewRecord())\n\t\t\t$this->create_time = time();\n\t}", "public function setPublishedAtAttribute($date){ //guarda el campo published_at como si fuera una instancia de Carbon para que se guarde con hora\n \t$this->attributes['published_at']=Carbon::parse($date); \n }", "public function unserialize($serialized)\n {\n list($this->id, $this->username, $this->password,) = unserialize($serialized);\n }", "public function setDateAttribute($date)\n {\n \t$this->attributes['date'] = Carbon::parse($date);\n }", "public function setDate($date) {\n $this->date = $date;\n }", "public function save()\n {\n if ( ! $start_date = $this->getData(\"start_date\"))\n {\n $start_date = time();\n }\n\n $start_date = strtotime($start_date);\n $this->setData(\"start_date\", date(\"Y-m-d\", $start_date));\n\n // We only need to do end dates if they are provided.\n if ($end_date = $this->getData(\"end_date\"))\n {\n $end_date = strtotime($end_date);\n $this->setData(\"end_date\", date(\"Y-m-d\", $end_date));\n }\n else\n {\n $this->setData(\"end_date\", NULL);\n }\n\n parent::save();\n }", "private function set_date()\r\n\t{\r\n\t\tif ($this->month > 12)\r\n\t\t{\r\n\t\t\t$this->month=1;\r\n\t\t\t$this->year++;\r\n\t\t}\r\n\r\n\t\tif ($this->month < 1)\r\n\t\t{\r\n\t\t\t$this->month=12;\r\n\t\t\t$this->year--;\r\n\t\t}\r\n\r\n\t\tif ($this->year > 2037) $this->year = 2037;\r\n\t\tif ($this->year < 1971) $this->year = 1971;\r\n\t}", "protected function hydrate($dataSet)\r\n {\r\n $this->id = $dataSet['id'];\r\n $this->dateEnvoi = $dataSet['date_envoi'];\r\n $this->contenu = $dataSet['contenu'];\r\n $this->modele = $dataSet['modele_mail_id'];\r\n $this->destinataire = $dataSet['user_id'];\r\n }", "public function setDate($date)\n\t{\n\t\t$this->date = $date;\n\t}", "public function onPrePersist()\n {\n $this->createdAt = new \\DateTime();\n $this->updatedAt = new \\DateTime();\n }", "public function onPrePersist()\n {\n $this->createdAt = new \\DateTime();\n $this->updatedAt = new \\DateTime();\n }", "public function __wakeup() {\n\t\t$this->validateFileContents();\n\t}", "public function testDeconstructFieldsDateTime() {\n\t\t$this->skipIf($this->db instanceof Sqlserver, 'This test is not compatible with SQL Server.');\n\n\t\t$this->loadFixtures('Apple');\n\t\t$TestModel = new Apple();\n\n\t\t//test null/empty values first\n\t\t$data['Apple']['created']['year'] = '';\n\t\t$data['Apple']['created']['month'] = '';\n\t\t$data['Apple']['created']['day'] = '';\n\t\t$data['Apple']['created']['hour'] = '';\n\t\t$data['Apple']['created']['min'] = '';\n\t\t$data['Apple']['created']['sec'] = '';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => ''));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['date']['year'] = '';\n\t\t$data['Apple']['date']['month'] = '';\n\t\t$data['Apple']['date']['day'] = '';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('date' => ''));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['year'] = '2007';\n\t\t$data['Apple']['created']['month'] = '08';\n\t\t$data['Apple']['created']['day'] = '20';\n\t\t$data['Apple']['created']['hour'] = '';\n\t\t$data['Apple']['created']['min'] = '';\n\t\t$data['Apple']['created']['sec'] = '';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => '2007-08-20 00:00:00'));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['year'] = '2007';\n\t\t$data['Apple']['created']['month'] = '08';\n\t\t$data['Apple']['created']['day'] = '20';\n\t\t$data['Apple']['created']['hour'] = '10';\n\t\t$data['Apple']['created']['min'] = '12';\n\t\t$data['Apple']['created']['sec'] = '';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => '2007-08-20 10:12:00'));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['year'] = '2007';\n\t\t$data['Apple']['created']['month'] = '';\n\t\t$data['Apple']['created']['day'] = '12';\n\t\t$data['Apple']['created']['hour'] = '20';\n\t\t$data['Apple']['created']['min'] = '';\n\t\t$data['Apple']['created']['sec'] = '';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => ''));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['hour'] = '20';\n\t\t$data['Apple']['created']['min'] = '33';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => ''));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['hour'] = '20';\n\t\t$data['Apple']['created']['min'] = '33';\n\t\t$data['Apple']['created']['sec'] = '33';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => ''));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['hour'] = '13';\n\t\t$data['Apple']['created']['min'] = '00';\n\t\t$data['Apple']['date']['year'] = '2006';\n\t\t$data['Apple']['date']['month'] = '12';\n\t\t$data['Apple']['date']['day'] = '25';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array(\n\t\t\t'Apple' => array(\n\t\t\t'created' => '',\n\t\t\t'date' => '2006-12-25'\n\t\t));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['year'] = '2007';\n\t\t$data['Apple']['created']['month'] = '08';\n\t\t$data['Apple']['created']['day'] = '20';\n\t\t$data['Apple']['created']['hour'] = '10';\n\t\t$data['Apple']['created']['min'] = '12';\n\t\t$data['Apple']['created']['sec'] = '09';\n\t\t$data['Apple']['date']['year'] = '2006';\n\t\t$data['Apple']['date']['month'] = '12';\n\t\t$data['Apple']['date']['day'] = '25';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array(\n\t\t\t'Apple' => array(\n\t\t\t\t'created' => '2007-08-20 10:12:09',\n\t\t\t\t'date' => '2006-12-25'\n\t\t));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['year'] = '--';\n\t\t$data['Apple']['created']['month'] = '--';\n\t\t$data['Apple']['created']['day'] = '--';\n\t\t$data['Apple']['created']['hour'] = '--';\n\t\t$data['Apple']['created']['min'] = '--';\n\t\t$data['Apple']['created']['sec'] = '--';\n\t\t$data['Apple']['date']['year'] = '--';\n\t\t$data['Apple']['date']['month'] = '--';\n\t\t$data['Apple']['date']['day'] = '--';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => '', 'date' => ''));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['created']['year'] = '2007';\n\t\t$data['Apple']['created']['month'] = '--';\n\t\t$data['Apple']['created']['day'] = '20';\n\t\t$data['Apple']['created']['hour'] = '10';\n\t\t$data['Apple']['created']['min'] = '12';\n\t\t$data['Apple']['created']['sec'] = '09';\n\t\t$data['Apple']['date']['year'] = '2006';\n\t\t$data['Apple']['date']['month'] = '12';\n\t\t$data['Apple']['date']['day'] = '25';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('created' => '', 'date' => '2006-12-25'));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$data = array();\n\t\t$data['Apple']['date']['year'] = '2006';\n\t\t$data['Apple']['date']['month'] = '12';\n\t\t$data['Apple']['date']['day'] = '25';\n\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$expected = array('Apple' => array('date' => '2006-12-25'));\n\t\t$this->assertEquals($expected, $TestModel->data);\n\n\t\t$db = ConnectionManager::getDataSource('test');\n\t\t$data = array();\n\t\t$data['Apple']['modified'] = $db->expression('NOW()');\n\t\t$TestModel->data = null;\n\t\t$TestModel->set($data);\n\t\t$this->assertEquals($TestModel->data, $data);\n\t}", "public function dispense() {\n\t\t$bean = $this->unbox();\n\t\t$time = time();\n\t\t$bean->created = R::isoDateTime($time);\n\t\t$this->loadedProperties = false;\n\t\t$this->properties = array();\n\t\t$this->properties['deploymentDate'] = date('YmdHis', $time);\n\t}", "public function exchangeObject($data)\n {\n foreach ($data AS $key => $datum) {\n if (property_exists($this, $key)) {\n $this->{$key} = $datum;\n }\n }\n }", "public function prePersist()\n {\n $this->updatedAt = new \\DateTime();\n $this->createdAt = new \\DateTime();\n }", "protected function beforeSave()\r\n \t{\r\n \t\tif (parent::beforeSave()) {\r\n \t\t\tif (!empty($this->date_open)) {\r\n \t\t\t\tif (!is_numeric($this->date_open)) {\r\n \t\t\t\t\t$this->date_open = strtotime($this->date_open);\r\n \t\t\t\t}\r\n \t\t\t}\r\n \t\t\tif (!empty($this->date_close)) {\r\n \t\t\t\tif (!is_numeric($this->date_close)) {\r\n \t\t\t\t\t$this->date_close = strtotime($this->date_close);\r\n \t\t\t\t}\r\n \t\t\t}\r\n\r\n \t\t\t// auto deal with date added and date modified\r\n \t\t\tif ($this->isNewRecord) {\r\n \t\t\t\t$this->date_added = $this->date_modified = time();\r\n \t\t\t} else {\r\n \t\t\t\t$this->date_modified = time();\r\n \t\t\t}\r\n\r\n \t\t\t// json\r\n \t\t\t$this->json_structure = json_encode($this->jsonArray_structure);\r\n \t\t\tif ($this->json_structure == 'null') {\r\n \t\t\t\t$this->json_structure = null;\r\n \t\t\t}\r\n \t\t\t$this->json_stage = json_encode($this->jsonArray_stage);\r\n \t\t\tif ($this->json_stage == 'null') {\r\n \t\t\t\t$this->json_stage = null;\r\n \t\t\t}\r\n \t\t\t$this->json_event_mapping = json_encode($this->jsonArray_event_mapping);\r\n \t\t\tif ($this->json_event_mapping == 'null') {\r\n \t\t\t\t$this->json_event_mapping = null;\r\n \t\t\t}\r\n \t\t\t$this->json_extra = json_encode($this->jsonArray_extra);\r\n \t\t\tif ($this->json_extra == 'null') {\r\n \t\t\t\t$this->json_extra = null;\r\n \t\t\t}\r\n\r\n \t\t\t// save as null if empty\r\n \t\t\tif (empty($this->slug)) {\r\n \t\t\t\t$this->slug = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->json_structure)) {\r\n \t\t\t\t$this->json_structure = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->json_stage)) {\r\n \t\t\t\t$this->json_stage = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->text_short_description)) {\r\n \t\t\t\t$this->text_short_description = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->timezone)) {\r\n \t\t\t\t$this->timezone = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->text_note)) {\r\n \t\t\t\t$this->text_note = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->json_event_mapping)) {\r\n \t\t\t\t$this->json_event_mapping = null;\r\n \t\t\t}\r\n \t\t\tif (empty($this->json_extra)) {\r\n \t\t\t\t$this->json_extra = null;\r\n \t\t\t}\r\n\r\n \t\t\treturn true;\r\n \t\t} else {\r\n \t\t\treturn false;\r\n \t\t}\r\n \t}", "public function setDate($date)\n {\n $this->date = $date;\n }", "public function setDate($date)\n {\n $this->date = $date;\n }", "private function setData(){\n if(isset($this->Data['submitxmllogomarca'])):\n $logomarca = $this->Data['logomarca'];\n unset($this->Data['submitxmllogomarca']);\n unset($this->Data['logomarca']); \n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['logomarca'] = $logomarca;\n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n elseif(isset($this->Data['submitxmllogoadmin'])):\n $logomarcaadmin = $this->Data['logomarcaadmin'];\n unset($this->Data['submitxmllogoadmin']);\n unset($this->Data['logomarcaadmin']); \n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['logomarcaadmin'] = $logomarcaadmin;\n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n elseif(isset($this->Data['submitxmlfavicon'])):\n $favicon = $this->Data['favicon'];\n unset($this->Data['submitxmlfavicon']);\n unset($this->Data['favicon']); \n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['favicon'] = $favicon;\n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n elseif(isset($this->Data['submitxmlmarcadagua'])):\n $marca_dagua = $this->Data['marca_dagua'];\n unset($this->Data['submitxmlmarcadagua']);\n unset($this->Data['marca_dagua']); \n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['marca_dagua'] = $marca_dagua;\n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n elseif(isset($this->Data['submitxmlImgTopo'])):\n $Imgtopo = $this->Data['imgtopo'];\n unset($this->Data['submitxmlImgTopo']);\n unset($this->Data['imgtopo']); \n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['imgtopo'] = $Imgtopo;\n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n elseif(isset($this->Data['InfoGerais'])):\n $Metaimg = $this->Data['metaimg']; \n unset($this->Data['InfoGerais']);\n unset($this->Data['metaimg']);\n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['metaimg'] = $Metaimg;\n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n elseif(isset($this->Data['submitseo'])):\n unset($this->Data['submitseo']);\n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['sitemapdata'] = date('Y-m-d');\n $this->Data['sitemap'] = BASE.'/sitemap.xml'; \n $this->Data['uppdate'] = date('Y-m-d H:i:s'); \n elseif(isset($this->Data['submitrss'])):\n unset($this->Data['submitrss']);\n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data); \n $this->Data['rssdata'] = date('Y-m-d');\n $this->Data['rss'] = BASE.'/rss.xml'; \n $this->Data['uppdate'] = date('Y-m-d H:i:s');\n else:\n $this->Data = array_map('strip_tags', $this->Data);\n $this->Data = array_map('trim', $this->Data);\n endif; \n }", "public function setObjectData(&$data)\n {\n $objVarNames = array_keys(get_object_vars($this));\n $theData = $data;\n if (is_object($theData)) $theData = get_object_vars($data);\n foreach($theData as $propertyName => &$propertyValue)\n {\n foreach ($objVarNames as &$varName)\n {\n if (strcasecmp($varName, $propertyName) == 0)\n {\n $this->$varName = $propertyValue;\n }\n }\n }\n }", "function copy($data)\r\n {\r\n $this->ano = $data->ano;\r\n $this->mes = $data->mes;\r\n $this->dia = $data->dia;\r\n $this->hora = $data->hora;\r\n $this->minuto = $data->minuto;\r\n $this->segundo = $data->segundo;\r\n $this->tz = $data->tz;\r\n }", "function jsonSerialize()\n {\n\n $clone = $this->getArrayCopy();\n\n if(count($this) == 0)\n return $clone;\n\n $clone['departure'] = $this['departure']->format('Y-m-d H:i:00');\n $clone['arrival'] = $this['arrival']->format('Y-m-d H:i:00');\n return $clone;\n }", "private function setData($data){\n\t\n\t\t$this->setIdusuario($data['idusuario']);\n\t\t$this->setDeslogin($data['deslogin']);\n\t\t$this->setDessenha($data['dessenha']);\n\t\t$this->setDtcadastro(new DateTime($data['dtcadastro']));\t\t\n\t}", "public function setElementProperties() {\r\n $properties = null;\r\n $propertyData = $this->getProperty('propdata',null);\r\n if ($propertyData != null && is_string($propertyData)) {\r\n $propertyData = $this->modx->fromJSON($propertyData);\r\n }\r\n if (is_array($propertyData)) {\r\n $this->object->setProperties($propertyData);\r\n }\r\n return $propertyData;\r\n }", "protected function fillProperties()\n {\n foreach ($this as $key => $value) {\n if ($this->isPrivate($key)) {\n continue;\n }\n $this->currentProperties[\"{$key}\"] = $value;\n $this->newProperties[\"{$key}\"] = $value;\n }\n }" ]
[ "0.6574882", "0.6297245", "0.596108", "0.58610624", "0.56909925", "0.5613909", "0.56097376", "0.5553858", "0.5527206", "0.55071855", "0.5504767", "0.5483814", "0.547384", "0.546954", "0.5457689", "0.5430142", "0.5382233", "0.5350159", "0.53082156", "0.5297222", "0.5296882", "0.5289655", "0.52674544", "0.52610964", "0.5250648", "0.5248108", "0.5245593", "0.5245327", "0.52117497", "0.51945865", "0.518706", "0.5136468", "0.512314", "0.5120538", "0.51127654", "0.51127654", "0.51096463", "0.50896764", "0.506577", "0.5052102", "0.50339615", "0.5022805", "0.5007006", "0.5001239", "0.499896", "0.49840462", "0.49840462", "0.49761388", "0.49669802", "0.4964961", "0.4964917", "0.49637216", "0.49401137", "0.49319097", "0.4924814", "0.49221176", "0.49206284", "0.49124387", "0.49124387", "0.491157", "0.4903854", "0.4901893", "0.4901893", "0.4893171", "0.48837942", "0.48668513", "0.48645777", "0.4864149", "0.4863805", "0.48637003", "0.48620778", "0.48585588", "0.48566484", "0.48513582", "0.48491174", "0.48474205", "0.4847075", "0.48458895", "0.48443097", "0.48379925", "0.4833473", "0.4832228", "0.48318782", "0.48248544", "0.48126435", "0.48126435", "0.48116", "0.48076507", "0.48058784", "0.48003605", "0.47986048", "0.479684", "0.47930506", "0.47930506", "0.47923267", "0.47843552", "0.47781265", "0.47752944", "0.47728372", "0.4768685", "0.4767461" ]
0.0
-1
LVP's central database contains a shed load of information. Using this method, we'll fetch whatever we may need from there and store it in some variable until it's needed. At the moment this method only fetches the crew status of a user.
public function fetchInformation($database, $profileId) { $this->m_nProfileId = $profileId; $pResult = $database->query( 'SELECT u.level, u.is_developer FROM lvp_mainserver.users u WHERE u.user_id = ' . (int) $profileId); if ($pResult !== false && $pResult->num_rows != 0) { $aInformation = $pResult->fetch_assoc(); $this['Level'] = LVPCrewHandler::translateGamemodeLevel($aInformation['level'], $aInformation['is_developer']); $pResult->free(); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function load_status() {\n // New ID\n if (!isset($this->id) || $this->id === 0)\n return;\n $col = $this->get_col_pfx();\n $table = $this->table;\n $sql = \"SELECT * FROM $table WHERE ${col}id = :id\";\n $db_result = $this->db->query($sql, array(\":id\" => $this->id));\n if (!$db_result || !isset($db_result[0]))\n throw new \\RuntimeException(\"No ID found $this->id\");\n $db_result = $db_result[0];\n $this->status = $db_result[$col . \"status\"];\n $this->time_created = $db_result[$col . \"time_created\"];\n $this->time_started = $db_result[$col . \"time_started\"];\n $this->time_completed = $db_result[$col . \"time_completed\"];\n }", "protected function fetchDetails() {\n\t\t$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t'tstamp, crdate, cruser_id, name',\n\t\t\t'tx_passwordmgr_group',\n\t\t\t'uid=' . $GLOBALS['TYPO3_DB']->fullQuoteStr($this['uid'],'tx_passwordmgr_group')\n\t\t);\n\t\t$row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);\n\t\t$this['name'] = $row['name'];\n\t\t$this['timeStamp'] = $row['timeStamp'];\n\t\t$this['createDate'] = $row['crdate'];\n\t\t$this['cruserUid'] = $row['cruser_id'];\n\t}", "function status()\n{\n\t$username = $this->Session->read('user');\n\tif (!$username){\n\t$this->redirect('/users/login');}\n\t\n\t// set knownusers\n\t$this->set('knownusers', $this->User->findAll(null, array('id', 'username',\n\t'first_name', 'last_name', 'last_login'), 'id DESC'));\n}", "public function getLeaderboard(){\n\t\t$query = \"SELECT `id`, `username`, `email`, `fullName`, `role`, `studentRollId`,`birthday`, `gender`, `address`,\n `phoneNo`, `mobileNo`, `studentClass`, `parentProfession`, `photo`, `isLeaderBoard`, `transport` \n FROM `users` WHERE isLeaderBoard != ''\"; //\n\t\t$dbcontroller = new DBController();\n\t\t$this->leaderboard = $dbcontroller->executeSelectQuery($query);\n\t\treturn $this->leaderboard;\n }", "public function load() {\n\t\tif(isset($_SESSION[\"user_id\"])) {\n\t\t\t$sql = \"SELECT notification_id, notification_message, notification_url, notification_created, notification_read FROM notifications_grumble WHERE user_id = \" . $_SESSION[\"user_id\"] . \" ORDER BY notification_created DESC LIMIT 10\";\n\t\t\t$result = $this->db->query($sql);\n\t\t\treturn $result;\n\t\t}\n\t}", "public function Info()\n\t{\n\t\t$sql = \"SELECT \n\t\t\t\t\t\t*, \n\t\t\t\t\t\tmajor.name AS majorName, \n\t\t\t\t\t\tsubject.name AS name,\n\t\t\t\t\t\tcourse.tipo as tipoCuatri,\n\t\t\t\t\t\tsubject.totalPeriods,\n\t\t\t\t\t\t(SELECT IF((course.modality = 'Online'), subject.crm_id_online, subject.crm_id_local)) AS crm_id,\n\t\t\t\t\t\t(SELECT IF((course.modality = 'Online'), subject.crm_name_online, subject.crm_name_local)) AS crm_name\n\t\t\t\t\tFROM\n\t\t\t\t\t\tcourse\n\t\t\t\t\tLEFT JOIN subject ON subject.subjectId = course.subjectId\n\t\t\t\t\tLEFT JOIN major ON major.majorId = subject.tipo\n\t\t\t\t\tWHERE\n\t\t\t\t\t\tcourseId='\" . $this->courseId . \"'\";\n\t\t//configuramos la consulta con la cadena de actualizacion\n\n\t\t//$sql=\"select \";\n\n\t\t$this->Util()->DB()->setQuery($sql);\n\t\t//ejecutamos la consulta y obtenemos el resultado\n\t\t$result = $this->Util()->DB()->GetRow();\n\t\tif ($result) {\n\t\t\t//\t\t\t\t$result = $this->Util->EncodeRow($result);\n\t\t}\n\n\t\t$result[\"access\"] = explode(\"|\", $result[\"access\"]);\n\n\t\t$user = new User;\n\t\t$user->setUserId($result[\"access\"][0]);\n\t\t$info = $user->Info();\n\t\t$result[\"encargado\"] = $info;\n\t\treturn $result;\n\t}", "public function freshness() {\n // Return 'fresh', 'stale', 'expired', or 'missing' depending on age thresholds.\n //\n // NOTE: if this function is called on a Crew that has Helicopters, the freshness verb will\n // refer to the length of time that has passed since ANY of this Crew's helicopters were updated.\n\n $max_fresh_age = config('app.hours_until_updates_go_stale');\n $expiration_age= config('app.days_until_updates_expire') * 24; // Converted to hours\n\n $now = Carbon::now();\n $last_status = $this->status();\n if(is_null($last_status->id)) $freshness = \"missing\"; // No Status has ever been created for this Crew\n else {\n $last_update = $last_status->created_at;\n $age_hours = $now->diffInHours($last_update); // The number of hours between NOW and the last update\n \n if($age_hours <= $max_fresh_age) $freshness = \"fresh\";\n elseif(($age_hours > $max_fresh_age) && ($age_hours < $expiration_age)) $freshness = \"stale\";\n else $freshness = \"expired\";\n }\n\n return $freshness;\n }", "private function retrieveData(){\n\t\t\n\t\t$dbo=new DB();\n\t\t$db=$dbo->db;\n\t\t$stmt = $db->prepare(\t'SELECT `description`, '.\n\t\t\t\t\t\t\t\t\t\t'`duration` '.\n\t\t\t\t\t\t\t\t'FROM `status` '.\t\t\n\t\t\t\t\t\t\t\t'WHERE `status` = ? '.\n\t\t\t\t\t\t\t\t'LIMIT 1'\n\t\t\t\t\t\t\t\t);\n\t $stmt->bind_param(\"s\", $this->id);\n\t $stmt->bind_result($this->description,$this->duration);\n\t $stmt->execute();\n\t $stmt->fetch();\n \t\t$stmt->close();\n \t\t\n\t}", "function d4os_io_db_070_os_users_is_alive() {\n return array(\n 'success' => d4os_io_db_070_mysql_is_alive('os_robust', 'os robust'),\n );\n}", "function loadFromDatabase() {\n\t # Paranoia\n\t $this->mId = intval( $this->mId );\n\t $this->mCedarId = intval( $this->mCedarId );\n\n\t /** Anonymous user */\n\t if( !$this->mId ) {\n\t\tif( !$this->mCedarId ) {\n\t\t if( $this->mName == '' ) {\n\t\t\t$this->loadDefaults();\n\t\t\treturn false;\n\t\t }\n\t\t}\n\t }\n\n\t $dbr =& wfGetDB( DB_MASTER );\n\t if( $this->mId ) {\n\t\t$s = $dbr->selectRow( 'cedar_user_info', '*', array( 'user_id' => $this->mId ), __METHOD__ );\n\t }\n\t else if( $this->mCedarId ) {\n\t\t$s = $dbr->selectRow( 'cedar_user_info', '*', array( 'user_info_id' => $this->mCedarId ), __METHOD__ );\n\t }\n\t else if( $this->mName != '' ) {\n\t\t$s = $dbr->selectRow( 'cedar_user_info', '*', array( 'user_name' => $this->mName ), __METHOD__ );\n\t }\n\n\t if ( $s !== false ) {\n\t\t # Initialise user table data\n\t\t $this->mCedarId = $s->user_info_id ;\n\t\t $this->mOrg = $s->organization ;\n\t\t $this->mAddress1 = $s->address1 ;\n\t\t $this->mAddress2 = $s->address2 ;\n\t\t $this->mCity = $s->city ;\n\t\t $this->mState = $s->state ;\n\t\t $this->mCountry = $s->country ;\n\t\t $this->mPostalCode = $s->postal_code ;\n\t\t $this->mPhone = $s->phone ;\n\t\t $this->mMobilePhone = $s->mobile_phone ;\n\t\t $this->mFax = $s->fax ;\n\t\t $this->mSupervisorName = $s->supervisor_name ;\n\t\t $this->mSupervisorEmail = $s->supervisor_email ;\n\t\t $this->mRegistrationDate = $s->registration_date ;\n\t\t return true;\n\t } else {\n\t\t # Invalid user_id\n\t\t $this->mId = 0;\n\t\t $this->loadDefaults();\n\t\t return false;\n\t }\n }", "function verClienteActual(){ \r\n\t$query = sprintf(\"SELECT * FROM usuarios WHERE userId=%d\",$_SESSION['userId']);\r\n\treturn getFromDB($query);}", "public function get_info()\n {\n // if database connection opened\n if ($this->databaseConnection()) {\n // try to update user with specified information\n $query_user = $this->db_connection->prepare('SELECT * FROM directory WHERE username = :user_name AND id = :id');\n $query_user->bindValue(':user_name', $_SESSION['user_name'], PDO::PARAM_STR);\n $query_user->bindValue(':id', $_SESSION['user_id'], PDO::PARAM_STR);\n $query_user->execute();\n\n if ($query_user->rowCount() > 0) {\n return $query_user->fetchObject();\n } else {\n return false;\n }\n }\n }", "protected function getMainRepositoryStatus() {}", "function fetchAllCrew() : Array {\n\t $sql = \"SELECT * FROM crew ORDER BY crew_name ASC \";\n\t $result = $this->conn->query($sql);\n\t if($result->num_rows > 0) {\n while($row = $result->fetch_assoc()) {\n $crew[] = new Crew($row['crew_id'],$row['crew_type'],$row['crew_name'], '');\n }\n return $crew;\n }else {\n\t return [];\n }\n }", "function status() {\n\t\t//If the user id does not exist, then the admin level is 0\n\t\tif(!isset($_SESSION['language_server_rand_ID']) || !isset($_SESSION['language_server_' . $_SESSION['language_server_rand_ID']])) {\n\t\t\treturn 0;\n\t\t}\n\t\t\n\t\t//Because the id was hidden using a rand function, we should get the value into a more readable var\n\t\t$id = $_SESSION['language_server_' . $_SESSION['language_server_rand_ID']];\n\t\t$user = $_SESSION['language_server_user'];\n\t\t\n\t\t//If the mysql command fails at any point, then the admin level is 0\n\t\t$connection = new mysqli(IP, USER, PASSWORD, DATABASE);\n\t\tif ($connection->connect_errno)\n\t\t{\n\t\t\techo \"Cannot establish connection: (\" . $connection->errno . \") \" . $connection->error;\n\t\t\treturn 0;\n\t\t}\n\t\t$command = 'SELECT admin FROM accounts WHERE username = ? && account_id = ? LIMIT 0, 1;';\n\t\tif(!($stmt = $connection->prepare($command)))\n\t\t{\n\t\t\techo \"Prepare failed: (\" . $connection->errno . \") \" . $connection->error;\n\t\t\treturn 0;\n\t\t}\n\t\tif(!$stmt->bind_param('ss', $user, $id))\n\t\t{\n\t\t\techo \"Binding parameters failed: (\" . $stmt->errno . \") \" . $stmt->error;\n\t\t\treturn 0;\n\t\t}\n\t\telseif (!$stmt->execute())\n\t\t{\n\t\t\techo \"Execute failed: (\" . $stmt->errno . \") \" . $stmt->error;\n\t\t\treturn 0;\n\t\t}\n\t\t$results = $stmt->get_result();\n\t\t$connection->close();\n \tif($results->num_rows != 0) {\n\t \t$results->data_seek(0);\n\t\t\t$result = $results->fetch_assoc();\n\t\t\treturn $result['admin'];\n\t\t}\n\t\telse {\n\t\t\treturn 0;\n\t\t}\n\t}", "public function getUserData()\n\t{\n\t\t$fbuid = $this->getFBUID();\n\t\t$rs = $this->db->query(\"SELECT * from selective_status_users where fbuid = \" . $this->db->quote($fbuid) . \" limit 1\");\n\t\tif ($rs && $row = $rs->fetch()) {\n\t\t\treturn $row;\n\t\t}\n\t}", "public function getLobby(){\n\t\t$sql = \"SELECT lobby.userID as userID, users.name as name, users.role as role, users.email as email FROM lobby JOIN `users` ON users.userID=lobby.userID\";\n\t\t//$sql = \"SELECT * FROM `lobby`\";\n\t\t$result = $this->db->query($sql);\n\t\t//preDump($result);\n\t\t//$data = $result->fetch(PDO::FETCH_ASSOC);\n\t\t$data = $result->fetchAll(PDO::FETCH_CLASS, \"User\");\n\t\tif ($data) {\n\t\t\treturn $data;\n\t\t} \n\t\treturn false;\n\t}", "public function get_status()\n\t{\n\t\ttry\n\t\t{\n\t\t\t$q = $this->_conn->prepare(\"select * from sandbox.dbo.daemon where dbtype = :dbtype order by object asc\");\n\t\t\t\n\t\t\t$dbtype = 'live';\n\t\t\t$q->bindParam(':dbtype', $dbtype);\n\n\t\t\t$q->execute();\n\t\t\t$rs = $q->fetchAll(PDO::FETCH_ASSOC);\n\t\t}\n\t\tcatch (PDOException $e)\n\t\t{\n\t\t\treturn 'ERRORdd: ' . $e->getMessage();\n\t\t}\n\t\t\n\t\treturn $rs;\n\t}", "private function fetch()\n\t\t{\n\t\t\tif(!isset($this->id))\n\t\t\t\treturn FALSE;\n\t\t\t\n\t\t\tglobal $conn;\n\t\t\t\n\t\t\t$f = $conn->prepare(\"SELECT name, `default`, priorityLevels, scaleLevels, widgetCount FROM ServiCenter_Workspace WHERE id = ? LIMIT 1\");\n\t\t\t$f->bindParam(1, $this->id);\n\t\t\t$f->execute();\n\t\t\t\n\t\t\tif($f->rowCount() != 1)\n\t\t\t\treturn FALSE;\n\t\t\t\n\t\t\t$w = $f->fetch();\n\t\t\t\n\t\t\t$this->name = $w['name'];\n\t\t\t$this->default = $w['default'];\n\t\t\t$this->priorityLevels = $w['priorityLevels'];\n\t\t\t$this->scaleLevels = $w['scaleLevels'];\n\t\t\t$this->widgetCount = $w['widgetCount'];\n\t\t\treturn TRUE;\n\t\t}", "function printLego()\n{ \n\t\t\n\tinclude 'storedInfo.php';\n\tini_set('display_errors', 'On');\t\n\t\n\t$mysqli = new mysqli(\"oniddb.cws.oregonstate.edu\", \"jonesmi-db\", $myPassword, \"jonesmi-db\");\n\tif ($mysqli->connect_errno) \n\t{\n\t\techo \"Failed to connect to MySQL: (\" . $mysqli->connect_errno . \") \" . $mysqli->connect_error;\n\t} else \n\t{\n\t\t//echo \"connection worked!<br><br>\";\n\t} \n\t\n\t\t\t/* Get all data from LegoCollections2 and LibraryUsers databases for display. */\n\tif (!($stmt = $mysqli->prepare(\"SELECT LegoCollections2.LegoNumber, LibraryUsers.userName, LegoCollections2.disc, LegoCollections2.checkOut \n\t\tFROM LibraryUsers \n\t\tINNER JOIN LegoCollections2 ON LibraryUsers.id = LegoCollections2.owner\"))) \n\t{\n\t\techo \"Prepare failed: (\" . $mysqli->errno . \") \" . $mysqli->error;\n\t}\n\t\tif (!$stmt->execute()) \n\t{\n\t\techo \"Execute failed: (\" . $mysqli->errno . \") \" . $mysqli->error;\n\t}\n\n\t$out_Check = NULL;\n\t$out_Num = NULL;\n\t$out_pKey = NULL;\n\t$out_disc = NULL;\n\n\tif (!$stmt->bind_result($out_Num, $out_pKey, $out_disc, $out_Check)) \n\t{\n\t\techo \"Binding output parameters failed: (\" . $stmt->errno . \") \" . $stmt->error;\n\t}\n\t$display_string = \"<table style = 'text-align:center;' border = '1';> <tr> <th> Lego Set Number </th> <th> owner </th> <th> disc </th> <th> checked out </th>\";\n\n\t\t// Insert a new row in the table for each person returned\n\t\t// Table creation used with assistance from http://www.tutorialspoint.com/php/php_and_ajax.htm\n\twhile($stmt -> fetch())\n\t{\n\t\t$display_string .= \"<tr>\";\n\t\t$display_string .= \"<td>\".$out_Num.\"</td>\";\n\t\t$display_string .= \"<td>\".$out_pKey.\"</td>\";\n\t\t$display_string .= \"<td>\".$out_disc.\"</td>\";\n\t\t$display_string .= \"<td>\".$out_Check.\"</td>\";\n\t\t$display_string .= \"</tr>\";\n\t}\n\t$display_string .= \"</table>\";\n\techo $display_string;\n\t$mysqli->close();\n}", "function printLegoSet()\n{\n\tinclude 'storedInfo.php';\n\t\tini_set('display_errors', 'On');\t\n\t\t$check = $_SESSION['check'];\n\t\t$mysqli = new mysqli(\"oniddb.cws.oregonstate.edu\", \"jonesmi-db\", $myPassword, \"jonesmi-db\");\n\t\tif ($mysqli->connect_errno) \n\t\t{\n\t\t\techo \"Failed to connect to MySQL: (\" . $mysqli->connect_errno . \") \" . $mysqli->connect_error;\n\t\t} else \n\t\t{\n\t\t\t//echo \"connection worked!<br><br>\";\n\t\t} \t\t\n\t\tif (!($stmt = $mysqli->prepare(\"SELECT LegoCollections2.LegoNumber, LibraryUsers.userName, LegoCollections2.disc, LegoCollections2.checkOut \n\t\t\tFROM LibraryUsers \n\t\t\tINNER JOIN LegoCollections2 \n\t\t\tON LibraryUsers.id = LegoCollections2.owner \n\t\t\tWHERE legoNumber = ?\"))) \n\t\t{\n\t\t\techo \"Prepare failed: (\" . $mysqli->errno . \") \" . $mysqli->error;\n\t\t}\n\t\tif(!($stmt->bind_param(\"s\", $check)))\n\t\t{\n\t\t\techo \"Bind failed: \" . $stmt->errno . \" \" . $stmt->error;\n\t\t}\n\t\tif (!$stmt->execute()) \n\t\t{\n\t\t\techo \"Execute failed: (\" . $mysqli->errno . \") \" . $mysqli->error;\n\t\t}\n\n\t\t$pKey = NULL;\n\t\t$out_Check = NULL;\n\t\t$out_Num = NULL;\n\t\t$out_pKey = NULL;\n\t\t$out_disc = NULL;\n\n\t\tif (!$stmt->bind_result($out_Num, $out_pKey, $out_disc, $out_Check)) \n\t\t{\n\t\t\techo \"Binding output parameters failed: (\" . $stmt->errno . \") \" . $stmt->error;\n\t\t}\n\t\techo \"<table style = 'text-align:center;' border = '1';> <tr> <th> Lego Set Number </th> <th> owner </th> <th> disc </th> <th> checked out </th>\";\n\t\twhile ($stmt->fetch()) //pulls each row \n\t\t{ \n\t\t\techo \"<tr>\";\n\t\t\techo \"<td>\".$out_Num.\"</td>\";\n\t\t\techo \"<td>\".$out_pKey.\"</td>\";\n\t\t\techo \"<td>\".$out_disc.\"</td>\";\n\t\t\techo \"<td>\".$out_Check.\"</td>\";\n\n\t\t\techo \"</tr>\";\n\t\t} \n\t\techo \"</table>\";\n\t$mysqli->close();\n}", "function makeStatus() {\n\t\t$ap = $this->me->get(\"ap\");\n\t\t$dollar = $this->me->get(\"dollar\");\n\t\t$name = $this->me->get(\"name\");\n\t\t$userName = $this->sysObj->userLogin;\n\t\t$myCityId = $this->me->get(\"city\");\n\t\t$myCityName = getOneThing(\"name\", \"mapdata_cities\", \"id=\".$myCityId);\n\t\t$round = getOneThing(\"current_round\", \"gamestate\", \"gameid=$this->gameId\");\n\t\tif ($this->IAmPlaying) {\n\t\t\t$curCharName = $name;\n\t\t\t$curPlayerName = $userName;\n\t\t} else {\n\t\t\t$curCharName = $this->curChar->get(\"name\");\n\t\t\t$curPlayerName = getOneThing(\"login\", \"user\", \"id=\".getOneThing(\"playedby\", \"gamestate_characters\", \"id=\".$this->curCharId));\n\t\t}\n\t\t$rv = \"\n\t\tgamestate.ap = \".$ap.\";\\n\n\t\tgamestate.dollar = \".$dollar.\";\\n\n\t\tgamestate.charname = '\".$name.\"';\\n\n\t\tgamestate.username = '\".$userName.\"';\\n\n\t\tgamestate.curcityname = '\".$myCityName.\"';\\n\n\t\tgamestate.round = \".$round.\";\\n\n\t\tgamestate.curcharname = '\".$curCharName.\"';\\n\n\t\tgamestate.curplayername = '\".$curPlayerName.\"';\\n\n\t\tgamestate.me = \".$this->myId.\";\\n\";\n\t\treturn $rv;\t\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}", "protected function fetchUserSessionFromDB() {}", "public function fetchData()\n\t{\n\t\t$this->items = Rights::getAuthorizer()->getAuthItemChildren($this->owner->name);\n\t\treturn parent::fetchData();\n\t}", "private function fetchConnections() {\t\t\n\t\t$query = Registry::get(\"database\")->query(\"SELECT * FROM security WHERE type=\".$this->id.\" AND ip='\".SecurityManager::$IP.\"' AND timestamp > (NOW() - INTERVAL \".$this->timeframe.\")\") or die(Registry::get(\"database\")->getError());\n\t\tif ($query) {\n\t\t\treturn $query->rowCount();\n\t\t}\n\t\treturn 0;\n\t}", "public function stale_users() {\n\t\tif (!$this->get_settings()) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t$http = new HttpSocket(array(\n\t\t\t'timeout' => 15,\n\t\t\t'ssl_verify_host' => false // PHP does not seem to check SANs for CNs\n\t\t));\n\t\ttry {\n\t\t\t$results = $http->get($this->settings['hostname.mbd'].'/panelists/stale?X-ApiKey='.$this->settings['mbd.api_key'], array(), $this->options);\n\t\t} catch (Exception $e) {\n\t\t\t$this->out('Stale Api endpoint failed.');\n\t\t\treturn;\n\t\t}\n\n\t\t$results = json_decode($results['body'], true);\n\t\tCakeLog::write('mbd.stale', print_r($results, true));\n\t\tprint_r($results);\n\t}", "public function fetch()\n\t{\n\t\t//$this -> error();\n\t\t$dbName = $this -> databaseName;\n\t\treturn $dbName() -> fetch();\n\t}", "private function load() {\r\n\t\t$sql_statement = 'SELECT no.contract_id, no.termination_date FROM '. TBL_NOTICE .' AS no WHERE no.notice_id = '. (int) $this->notice_id;\r\n\t\t$query = db_query($sql_statement);\r\n\r\n\t\tif(db_num_results($query) == 1) {\r\n\t\t\t$data = db_fetch_array($query);\r\n\t\t\t\t\r\n\t\t\t$this->contract_id = $data['contract_id'];\r\n\t\t\t$this->termination_date = $data['termination_date'];\r\n\t\t}\r\n\t}", "function fetch_user_privilege(){ //get all records from database \n\t\t//mandatory requirements for pages loading nav and sidebar\n\t\tif($this->session->userdata('logged_in')==\"\")\n\t\t\theader(\"Location: \".$this->config->base_url().\"Login\");\n\t\t$this->cache_update();\n\t\t$this->check_privilege(12);\n\t\t$this->load->driver('cache',array('adapter' => 'file'));\n\t\t$u_type = array('var'=>$this->cache->get('Active_status'.$this->session->userdata('loginid'))['user_type_id_fk']);\n\t\t$this->load->model('profile_model');\n\t\t$noti = array('meeting'=>$this->profile_model->meeting_notification());\n\t\t$u_type['notification'] = $noti;\n\t\t$u_type['noti1']=$this->profile_model->custom_notification();\n\t\t$this->load->view('dashboard/navbar',$u_type);\n\t\t$da = $this->profile_model->get_profile_info($this->session->userdata('uid'));\n\t\t$this->load->view('dashboard/sidebar',$da);\n\t\t//mandatory requirements end\n\t\t \n\t\t$this->load->model('Sup_admin');\n\t \t$query=$this->Sup_admin->fetch_user_privilege();\n\t\t$data['records']=$query->result();\n\t\t$this->load->model('Crud_model');\n\t\t$this->db->trans_off();\n $this->db->trans_strict(FALSE);\n $this->db->trans_start();\n\t\t$this->Crud_model->audit_upload($this->session->userdata('loginid'),\n\t\t\t\t\t\t\tcurrent_url(),\n\t\t\t\t\t\t\t'Visited User Privilage Active page',\n\t\t\t\t\t\t\t'Custom message here');\n\t\t$this->db->trans_complete();\n\t\t$this->load->view('view_user_privilege',$data); \n\t\t$this->load->view('dashboard/footer');\n \t}", "public function readNewMembers(){\r\n $results = array();\r\n\r\n if ( null !== $this->getDB() ) {\r\n $dbs = $this->getDB()->prepare('select * from Members, MemberStatus where members.MemberID = memberstatus.MemberID and StatusCode = \"A\" and DateNew = CURDATE()');\r\n\r\n if ( $dbs->execute() && $dbs->rowCount() > 0 ) {\r\n $results = $dbs->fetchAll(PDO::FETCH_ASSOC);\r\n }\r\n } \r\n return $results;\r\n }", "function getUser() {\n $DBA = new DatabaseInterface();\n $fields = array(0 => 'username', 1 => 'title', 2 => 'first_name', 3 => 'last_name', 4 => 'password', 5 => 'contactemail', 6 => 'contacttelephone', 7 => 'newsletter', 8 =>'pcode', 9 => 'store_owner', 10 => 'house', 11 => 'street', 12 => 'town', 13 => 'county', 14 => 'geolong', 15 => 'geolat', 16 => 'avatar', 17 => 'mobile', 18 => 'optout');\n $idfields = array(0 => 'id');\n $idvals = array(0 => $this->ID);\n $rs = $DBA->selectQuery(DBUSERTABLE, $fields, $idfields, $idvals);\n\n if (!isset($rs[2]))\n {\n while ($res = mysql_fetch_array($rs[0]))\n {\n $this->setUserVar('Username', $res['username']);\n $this->setUserVar('Title', $res['title']);\n $this->setUserVar('FirstName', $res['first_name']);\n $this->setUserVar('LastName', $res['last_name']);\n $this->setUserVar('ContactEmail', $res['contactemail']);\n $this->setUserVar('ContactTelephone', $res['contacttelephone']);\n $this->setUserVar('NewsletterSubscriber', $res['newsletter']);\n $this->setUserVar('Area', $res['pcode']);\n $this->setUserVar('StoreOwner', $res['store_owner']);\n $this->setUserVar('House', $res['house']);\n $this->setUserVar('Street', $res['street']);\n $this->setUserVar('Town', $res['town']);\n $this->setUserVar('County', $res['county']);\n $this->setUserVar('PCode', $res['pcode']);\n $this->setUserVar('Long', $res['geolong']);\n $this->setUserVar('Lat', $res['geolat']);\n $this->setUserVar('Avatar', $res['avatar']);\n $this->setUserVar('Mobile', $res['mobile']);\n $this->setUserVar('DMOptOut', $res['optout']);\n $this->formatAddress();\n $this->formatEmail();\n if ($this->Lat == '')\n {\n $this->GeoLocate();\n }\n }\n }\n }", "protected function autoCheck(){\n // setting variables\n $time = date('Y-m-d H:i:s',time());\n $coll = '';\n // if configured, set MySQL collation\n CONF_DB_COLLATION ? $coll = ' COLLATE '.CONF_DB_COLLATION : NULL;\n // connect to database, if not exists create it\n if(!mysql_select_db(CONF_DB_NAME,$this->connection)):\n mysql_query('CREATE DATABASE IF NOT EXISTS '\n .CONF_DB_NAME.$coll)\n or die(W_DB_ERROR_PRIVILEGE);\n mysql_select_db(CONF_DB_NAME,$this->connection);\n endif;\n // auto creating tables\n if(CONF_DB_AUTO_CREATE):\n // use prefix if configured\n $pre = CONF_DB_PREFIX;\n // create users\n mysql_query(\"CREATE TABLE IF NOT EXISTS {$pre}users (\n id INT(100) NOT NULL AUTO_INCREMENT, \n username VARCHAR(100), \n password VARCHAR(100), \n email VARCHAR(100), \n joined DATETIME,\n PRIMARY KEY (id))\".$coll)\n or die(W_DB_ERROR_CREATION);\n mysql_query(\"INSERT IGNORE INTO {$pre}users (\n id,\n username,\n password,\n email,\n joined\n ) VALUES (\n 1,\n 'admin',\n '65cb59645b852c2394ba3ff8b295e83c',\n '\".SITE_OWNER_EMAIL.\"',\n '{$time}'\n )\")\n or die(W_DB_ERROR_CREATION);\n // create users_meta\n mysql_query(\"CREATE TABLE IF NOT EXISTS {$pre}users_meta (\n id INT(100) NOT NULL AUTO_INCREMENT, \n user_id INT(100), \n label VARCHAR(100), \n value TEXT, \n updated DATETIME,\n PRIMARY KEY (id))\".$coll)\n or die(W_DB_ERROR_CREATION);\n // create content\n mysql_query(\"CREATE TABLE IF NOT EXISTS {$pre}content (\n id INT(100) NOT NULL AUTO_INCREMENT, \n URL VARCHAR(100), \n title VARCHAR(100), \n content TEXT,\n type VARCHAR(50),\n created DATETIME,\n PRIMARY KEY (id))\".$coll)\n or die(W_DB_ERROR_CREATION);\n // create welcome page\n if(!mysql_num_rows(\n mysql_query(\"SELECT id FROM {$pre}content \n WHERE URL='index'\"))):\n mysql_query(\"INSERT IGNORE INTO {$pre}content (\n id,URL,title,content,type,created\n ) VALUES (\n 1,'index','Welcome',\n '<section id=\\\"page\\\"><h2>Welcome</h2>\".\n \"<p class=\\\"center\\\">This is your AquaCMS site</p>',\n 'page','{$time}'\n )\")or die(W_DB_ERROR_CREATION);\n endif;\n // create content_meta\n mysql_query(\"CREATE TABLE IF NOT EXISTS {$pre}content_meta (\n id INT(100) NOT NULL AUTO_INCREMENT, \n content_id INT(100), \n label VARCHAR(100), \n value TEXT, \n updated DATETIME,\n PRIMARY KEY (id))\".$coll)\n or die(W_DB_ERROR_CREATION);\n // create options\n mysql_query(\"CREATE TABLE IF NOT EXISTS {$pre}options (\n id INT(100) NOT NULL AUTO_INCREMENT,\n name VARCHAR(100),\n value VARCHAR(100),\n PRIMARY KEY (id))\".$coll)\n or die(W_DB_ERROR_CREATION);\n $allConst = get_defined_constants(true);\n $const = $allConst['user'];\n if(!empty($const)): foreach($const as $key => $value):\n if($key!='CONF_DB_BASED'\n &&$key!='CONF_DB_AUTO_CREATE'\n &&$key!='CONF_DB'\n &&$key!='CONF_DB_NAME'\n &&$key!='CONF_DB_USER'\n &&$key!='CONF_DB_PASSWORD'\n &&$key!='CONF_DB_PREFIX'\n &&substr($key,0,2)!=\"W_\"):\n if(!mysql_num_rows(\n mysql_query(\"SELECT id FROM {$pre}options WHERE\n name='{$key}'\"))):\n mysql_query(\"INSERT IGNORE INTO {$pre}options\n (id,name,value)\n VALUES \n (NULL,'{$key}','\".constant($key).\"')\")\n or die(W_DB_ERROR_CREATION);\n endif;\n endif;\n endforeach; endif;\n endif;\n // setting MySQL names if configured\n if(CONF_DB_SET_NAMES):\n mysql_query(\"SET NAMES '\".CONF_DB_SET_NAMES.\"'\") \n or die(W_DB_ERROR_CREATION); \n endif;\n }", "public function isOnline() {\n\t\tif(check($this->_username)) {\n\t\t\t$result = $this->db->queryFetchSingle(\"SELECT \"._CLMN_CONNSTAT_.\" FROM \"._TBL_MS_.\" WHERE \"._CLMN_USERNM_.\" = ? AND \"._CLMN_CONNSTAT_.\" = ?\", array($this->_username, 1));\n\t\t\tif(!is_array($result)) return;\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\t$accountData = $this->getAccountData();\n\t\tif(is_array($accountData)) {\n\t\t\t$result = $this->db->queryFetchSingle(\"SELECT \"._CLMN_CONNSTAT_.\" FROM \"._TBL_MS_.\" WHERE \"._CLMN_USERNM_.\" = ? AND \"._CLMN_CONNSTAT_.\" = ?\", array($accountData[_CLMN_USERNM_], 1));\n\t\t\tif(!is_array($result)) return;\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn;\n\t}", "function read_all(){\n \n // select all query\n $query = \"SELECT\n *\n FROM\n \" . $this->table_name . \"\n ORDER BY\n date DESC\";\n //SELECT id, username, date, content, IF(private, 'true', 'false') private\n \n // prepare query statement\n $stmt = $this->conn->prepare($query);\n \n // execute query\n $stmt->execute();\n \n return $stmt;\n }", "public function fetchCriticalInfo ()\r\n {\r\n $member_id = $this->getMember_id(true);\r\n return $this->getMapper()->fetchCriticalInfo($member_id);\r\n }", "public function all_aboutUs_rules_info(){\r\n $query = \"SELECT * FROM tbl_aboutus_rules WHERE publication_status = 1\";\r\n if(mysqli_query($this->db_connect, $query)){\r\n $query_result = mysqli_query($this->db_connect, $query);\r\n return $query_result;\r\n }else{\r\n die(\"Query Problem! \".mysqli_error($this->db_connect));\r\n }\r\n }", "function fetchUserTime () {\n\t\t$this->conf['currTime'] = time(); // Current time for several Items like month, week, day and list\n\t\t$y = (!empty($this->piVars['year']) AND is_numeric($this->piVars['year']) ) ? $this->piVars['year']:strftime('%Y', $this->conf['currTime']);\n\t\t$m = (!empty($this->piVars['month']) AND is_numeric($this->piVars['month']) ) ? $this->piVars['month']:strftime('%m', $this->conf['currTime']);\n\t\t$d = (!empty($this->piVars['day']) AND is_numeric($this->piVars['day']) ) ? $this->piVars['day']:strftime('%d', $this->conf['currTime']);\n\t\t$this->conf['currTime'] = strtotime( $y.'-'.$m.'-'.$d);\n\t\treturn;\n\t}", "function IsExisting_UserDetails($dbhandle)\n{\n $logger = LoggerSingleton::GetInstance();\n $logger->LogInfo(\"IsExisting_UserDetails : Enter\");\n\n global $UserDetailsTable_Name;\n\n // check if table exists\n $query = \"SELECT 1 FROM $UserDetailsTable_Name LIMIT 1\";\n $status = $dbhandle->query($query);\n\n $logger->LogInfo(\"IsExisting_UserDetails : Exit - \");\n return $status;\n}", "public function getStatus(){\n $pdo = new DBConnection();\n $db = $pdo->DBConnect();\n try{\n $db->beginTransaction();\n $sql = \"SELECT * from status ORDER BY id asc\";\n $record = $db->prepare($sql); \n $record->execute();\n $regExists = $record->rowCount();\n if ($regExists) {\n $dataList = $record->fetchAll(PDO::FETCH_ASSOC);\n $db->commit();\n $db = null;\n return $dataList;\n } else {\n $db->commit();\n $db = null;\n return $regExists;\n }\n }catch (PDOException $exc){\n $db->rollback();\n $db = null;\n echo $exc->getMessage();\n return null;\n } \n }", "public function retrieveAllUsers () {\n return $this->usersDB;\n }", "function get_db_stat($mode)\n{\n\tglobal $db;\n\n\tswitch( $mode )\n\t{\n\t\tcase 'usercount':\n\t\t\t$sql = \"SELECT COUNT(user_id) AS total\n\t\t\t\tFROM \" . USERS_TABLE . \"\n\t\t\t\tWHERE user_id <> \" . ANONYMOUS;\n\t\t\tbreak;\n\n\t\tcase 'newestuser':\n\t\t\t$sql = \"SELECT user_id, username\n\t\t\t\tFROM \" . USERS_TABLE . \"\n\t\t\t\tWHERE user_id <> \" . ANONYMOUS . \"\n\t\t\t\tORDER BY user_id DESC\n\t\t\t\tLIMIT 1\";\n\t\t\tbreak;\n\n\t\tcase 'postcount':\n\t\tcase 'topiccount':\n\t\t\t$sql = \"SELECT SUM(forum_topics) AS topic_total, SUM(forum_posts) AS post_total\n\t\t\t\tFROM \" . FORUMS_TABLE;\n\t\t\tbreak;\n\t}\n\n\tif ( !($result = $db->sql_query($sql)) )\n\t{\n\t\treturn false;\n\t}\n\n\t$row = $db->sql_fetchrow($result);\n\n\tswitch ( $mode )\n\t{\n\t\tcase 'usercount':\n\t\t\treturn $row['total'];\n\t\t\tbreak;\n\t\tcase 'newestuser':\n\t\t\treturn $row;\n\t\t\tbreak;\n\t\tcase 'postcount':\n\t\t\treturn $row['post_total'];\n\t\t\tbreak;\n\t\tcase 'topiccount':\n\t\t\treturn $row['topic_total'];\n\t\t\tbreak;\n\t}\n\n\treturn false;\n}", "function returnLego()\n{\n\tinclude 'storedInfo.php';\n\tini_set('display_errors', 'On');\n\t$username = $_SESSION['username'];\n\t$mysqli = new mysqli(\"oniddb.cws.oregonstate.edu\", \"jonesmi-db\", $myPassword, \"jonesmi-db\");\n\tif ($mysqli->connect_errno) \n\t{\n\t\techo \"Failed to connect to MySQL: (\" . $mysqli->connect_errno . \") \" . $mysqli->connect_error;\n\t} else \n\t{\n\t\t//echo \"connection worked!<br><br>\";s\n\t} \n\t$check = $_REQUEST['returnLegoSet'];\n\t$_SESSION['check'] = $check;\n\tif (!($stmt = $mysqli->prepare(\"SELECT legoNumber, owner, disc, checkOut\n\t\tFROM LegoCollections2 \n\t\tWHERE legoNumber = ? \"))) \n\t\t{\n\t\t\techo \"Prepare failed: (\" . $mysqli->errno . \") \" . $mysqli->error;\n\t\t}\n\tif(!($stmt->bind_param(\"s\", $check)))\n\t{\n\t\techo \"Bind failed: \" . $stmt->errno . \" \" . $stmt->error;\n\t}\n\tif (!$stmt->execute()) \n\t{\n\techo \"Execute failed: (\" . $mysqli->errno . \") \" . $mysqli->error;\n\t}\n\t\t//stores my stmt for use with num_rows\n\t$stmt->store_result();\n\t$rows = $stmt->num_rows;\n\t$pKey = NULL;\n\t$out_checkOut = NULL;\n\t$out_Num = NULL;\n\t$out_Owner = NULL;\n\t$out_Disc = NULL;\n\n\tif (!$stmt->bind_result($out_Num, $out_Name, $out_Disc, $out_checkOut)) \n\t{\n\t\techo \"Binding output parameters failed: (\" . $stmt->errno . \") \" . $stmt->error;\n\t}\n\n\tif ($rows != 0)\n\t{\n\t\twhile ($stmt->fetch()) //pulls each row\n\t\t{\n\t\t\t\t/* if checkOut contains available then able to reserve. */\n\t\t\tif ($out_checkOut == \"available\")\n\t\t\t{\n\t\t\t\techo \"This set is not checked out. There is no need to return it.\";\n\t\t\t}else\n\t\t\t{\n\t\t\tif(!($stmt1 = $mysqli->prepare(\"UPDATE LegoCollections2 SET checkout = 'available'\n\t\t\t\t\tWHERE legoNumber = ?\")))\n\t\t\t\t{\n\t\t\t\t\techo \"Prepare failed: \" . $stmt1->errno . \" \" . $stmt1->error;\n\t\t\t\t}\n\n\t\t\t\tif(!($stmt1->bind_param(\"s\",$check)))\n\t\t\t\t{\n\t\t\t\t\techo \"Bind failed: \" . $stmt1->errno . \" \" . $stmt1->error;\n\t\t\t\t}\n\n\t\t\t\tif(!$stmt1->execute())\n\t\t\t\t{\n\t\t\t\t\techo \"Execute failed: \" . $mysqli->connect_errno . \" \" . $mysqli->connect_error;\n\t\t\t\t}\n\t\t\t\t\t/* Print Lego set to show it is now checked out */\n\t\t\t\tprintLegoSet(); \n\t\t\t}\n\t\t}\n\t}else echo \"That set was not found please make sure set number is in the database.<br>\n\t\t\t\tYou can click Print Lego Table to see which ones we have.<br>\";\n\t$mysqli->close();\n}", "function dataGetPublishStatus($p_id)\n {\n $p_id = parent::escape($p_id);\n \n $sql = 'SELECT isactive ';\n $sql .= 'FROM user ';\n $sql .= 'WHERE id = ' . $p_id . ' ';\n \n $result_mysqli = parent::query($sql);\n $result = parent::fetchAllRows($result_mysqli);\n parent::clear($result_mysqli); \n\n return $result; \n }", "function onLaunch() {\n // context and resourceLink properties of the class instance\n // to access the current user, context and resource link.\n\n//\t$this->reason = 'Incomplete data';\n// $this->ok = false;\n//\t$users = $context->getMemberships();\n\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 }", "function usersWith(){\n\t\t\t\t\trequire_once(\"database\\database_connection.php\");\n\t\t\t\t\t$conn=database();\n\t\t\t\t\t//Query the database\n\t\t\t\t\t$resultSet = $conn->query(\"SELECT * FROM users_cs_count_view\");\n\n\t\t\t\t\tif($resultSet->num_rows != 0){\n\t\t\t\t\t\twhile($rows = $resultSet->fetch_assoc()){\n\t\t\t\t\t\t\t$users = $rows['users_with_cs'];\n\n\t\t\t\t\t\t\techo \"<h4 class='heading'>\n\t\t\t\t\t\t\tRegistered users with CS:GO: $users\n\t\t\t\t\t\t\t</h4>\";\n\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\telse{\n\t\t\t\t\t\techo\"ERROR\";\n\t\t\t\t\t}\n\t\t \t\t$conn->close();\n}", "public static function get_public_users()\n {\n $connection = Yii::$app->getDb();\n /*$users = Yii::$app->db->createCommand(\"SELECT core_users.*,(SELECT core_sessions.date_created FROM core_sessions WHERE core_sessions.user_id = core_users.user_id ORDER BY core_sessions.date_created DESC LIMIT 1) last_login FROM core_users where core_users.user_type =:user_type\")\n ->bindValue(':user_type', 1)\n ->queryAll();*/\n $users = Yii::$app->db->createCommand(\"SELECT core_users.*,\"\n . \"(SELECT core_sessions.date_created FROM core_sessions WHERE core_sessions.user_id = core_users.user_id ORDER BY core_sessions.date_created DESC LIMIT 1) last_login,\"\n . \"(SELECT core_user_roles.role_name FROM core_user_roles WHERE core_user_roles.role_id = core_users.user_type) role_name FROM core_users \"\n . \"where core_users.user_type = 1\")->queryAll();\n /*$users = $connection->createCommand(\"SELECT core_users.*,(SELECT core_sessions.date_created FROM core_sessions WHERE core_sessions.user_id = core_users.user_id ORDER BY core_sessions.date_created DESC LIMIT 1) last_login FROM core_users where core_users.user_type = 1\")->queryAll();*/\n /*$users = $query->select(['core_users.*','core_sessions.date_created'])->from('core_users')\n ->innerJoin('core_sessions','core_users.user_id = core_sessions.user_id')\n ->where(\"core_users.user_type = '1'\")\n ->orderBy(['core_sessions.date_created' => SORT_DESC])\n ->groupBy('core_sessions.user_id')\n ->All();*/\n return $users;\n }", "public function _checkAndGetUserActive()\n {\n return $this->find('id_user,name,lastname,email,salt,password', [\n 'username' => $this->username,\n 'sw_active' => 1\n ]);\n }", "public function fetch_web_managers($member_deg_id, $admin_id ) {\r\n \r\n $statement = $this->db->query('SELECT member_user_id, `member_fname`, `member_lname` FROM `team_members` \r\n LEFT JOIN admin_user ON admin_user.admin_user_id= team_members.`admin_user_id`\r\n WHERE `member_deg_id` = '.$member_deg_id.' AND team_members.`admin_user_id` = '.$admin_id.' '); \r\n\t\t\t\t\t\t\t\t\t \r\n \t $statement->setFetchMode(PDO::FETCH_ASSOC);\t\t \r\n\t\t $clients = array(); \r\n\t\t if ($statement->rowCount() > 0) {\t \r\n \r\n while( $row = $statement->fetch() ) { \r\n $clients[] = $row; \r\n \r\n }\r\n return $clients; \r\n } else {\r\n\t\treturn FALSE;\r\n\t\t}\r\n }", "protected function fetchDetails() {\n\t\t$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t'be_users.uid AS uid, be_users.username AS username, be_users.tx_passwordmgr_cert AS cert, tx_passwordmgr_group_be_users_mm.rights AS rights',\n\t\t\t'be_users, tx_passwordmgr_group_be_users_mm',\n\t\t\t'tx_passwordmgr_group_be_users_mm.be_users_uid=be_users.uid' . // Join Constraint\n\t\t\t\t' AND be_users.uid='.$GLOBALS['TYPO3_DB']->fullQuoteStr($this['beUserUid'], 'be_users') .\n\t\t\t\t' AND tx_passwordmgr_group_be_users_mm.group_uid='.$GLOBALS['TYPO3_DB']->fullQuoteStr($this['groupUid'], 'tx_passwordmgr_group_be_users_mm')\n\t\t);\n\t\tif ( $GLOBALS['TYPO3_DB']->sql_num_rows($res) == 1 ) {\n\t\t\t$row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);\n\t\t\t$this['name'] = $row['username'];\n\t\t\t$this['certificate'] = $row['cert'];\n\t\t\t$this['publicKey'] = tx_passwordmgr_openssl::extractPublicKeyFromCertificate($this['certificate']);\n\t\t\t$this['rights'] = $row['rights'];\n\t\t} else {\n\t\t\tthrow new Exception ('Error getting group member details. user / group: ' . $this['beUserUid'] . ' ' . $this['groupUid']);\n\t\t}\n\t}", "private function getCrendentials()\n {\n $db = parse_ini_file('db.ini');\n $this->username = $db['user'];\n $this->password = $db['password'];\n $this->host = $db['host'];\n $this->dbname = $db['dbname'];\n }", "function datos_internacionalizacion() {\n\t\t$query = \"SELECT * FROM internacionalizacion\";\n\n\t\t$connection = mysql_connect($this->HOST, $this->USERNAME, $this->PASSWORD);\n\t\t$SelectedDB = mysql_select_db($this->DBNAME);\n\t\t\n\t\t$result = mysql_query($query);\n\t\t$numrows = mysql_num_rows($result);\n\n\t\tif ($numrows == 0) {\n\t\t\tmysql_close($connection);\n\t\t\treturn $result;\n\t\t}\n\t\telse {\n\t\t\tmysql_close($connection);\n\t\t\treturn $result;\n\t\t}\n\t}", "public function loadData()\n {\n $this->sendApiCall(self::ACTION_RETRIEVE, $this->getCreateUrl());\n }", "function load() {\n\t\tif ( $this->getUserID() ) {\n\t\t\t// 'Approved','Pending','Rejected'\n\t\t\t$query = '\n\t\t\t\tSELECT\n\t\t\t\t (SELECT COUNT(userMovieGrants.id) FROM '.system::getConfig()->getDatabase('mofilm_content').'.userMovieGrants WHERE status = 2 AND userID = :UserID) AS totalApproved,\n\t\t\t\t\t(SELECT COUNT(userMovieGrants.id) FROM '.system::getConfig()->getDatabase('mofilm_content').'.userMovieGrants WHERE status = 3 AND userID = :UserID) AS totalRejected,\n\t\t\t\t\t(SELECT COUNT(userMovieGrants.id) FROM '.system::getConfig()->getDatabase('mofilm_content').'.userMovieGrants WHERE status = 1 AND userID = :UserID) AS totalPending,\n\t\t\t\t\t(SELECT COUNT(userMovieGrants.id) FROM '.system::getConfig()->getDatabase('mofilm_content').'.userMovieGrants WHERE userID = :UserID) AS totalApplied';\n\t\t\t\n\t\t\t$oStmt = dbManager::getInstance()->prepare($query);\n\t\t\t$oStmt->bindValue(':UserID', $this->getUserID(), PDO::PARAM_INT);\n\t\t\tif ( $oStmt->execute() ) {\n\t\t\t\t$res = $oStmt->fetchAll();\n\t\t\t\tif ( is_array($res) && count($res) == 1 ) {\n\t\t\t\t\t$this->getOptionsSet()->setOptions($res[0]);\n\t\t\t\t}\n\t\t\t\tunset($res);\n\t\t\t}\n\t\t\t$oStmt->closeCursor();\n\t\t}\n\t\treturn true;\n\t}", "protected function fetchStatus()\n {\n return $this->fetch([\n 'model' => Status::class,\n 'query' => function ($model) {\n return $model->orderBy('name', 'ASC');\n },\n ]);\n }", "public function getInfoFromDatabase() {\n $db = \\Helper::getDB();\n $db->join('users u', 'd.ownerId = u.id', 'LEFT');\n $db->where('d.id', $db->escape((int) $this->getId()));\n // Prevent getting a document with a presentation ID or some other wrong combination\n if($this->getType() != '') {\n $db->where('d.type', $db->escape($this->getType()));\n }\n $result = $db->getOne('documents d', '*, d.id AS documentId, u.id AS userId');\n\n if($result) {\n $this->title = $result['title'];\n $this->type = $result['type'];\n $this->creationDate = $result['creationDate'];\n $this->modificationDate = $result['modificationDate'];\n $this->user = new \\Models\\User($result['userId'], $result['username'], $result['email'], $result['firstName'], $result['lastName'], $result['lastLogin']);\n $this->file = $result['file'];\n } else {\n throw new \\Exception('Document not found', 5);\n }\n }", "private function retrieveFields() {\n\n\t\t$params = array( ':user_id' => $this->user_id ); \n $level = ($_SESSION['pickme']); //print_r( $level );\n if( protectThis(\"3\") ){\n $sql = \" SELECT `user_id`, `username`, `user_level`,`name`, `lname`, `email`, `image`, dob, sex \";\n $stmt2 = parent::query( \"SELECT * FROM projects WHERE `uid` = :user_id\" , $params);\n \n if ($stmt2->rowCount() >= 1){\n $sql.= \" ,pname,pdescription,ptechnologies,pclient,pgroupmode,prole, p.uid \"; \n }\n \n $sql.= \" FROM login_users \";\n if ($stmt2->rowCount() >= 1){\n $sql.= \" , projects p \"; \n }\n \n $sql.= \" WHERE `user_id` = :user_id \";\n \n \n if ($stmt2->rowCount() >= 1){\n \n }\n \n $stmt = parent::query($sql, $params);\n \n// $stmt = parent::query(\"SELECT `user_id`, `username`, `user_level`,`name`, `lname`, `email`, pname,pdescription,ptechnologies,pclient,pgroupmode,prole, \n// programing, networking,webapplication,business,professional\n// FROM `login_users`, `projects`, `skills`\n// WHERE `user_id` = :user_id;\", $params);\n \n }else{\n \n $stmt = parent::query(\"SELECT `user_id`, `username`, `user_level`,`name`, `lname`, dob, sex, description, `email`, `image`, qualification, position, field, type, city\n FROM `login_users`\n WHERE `user_id` = :user_id;\", $params);\n \n }\n \n\t\tif ( $stmt->rowCount() < 1 ) {\n\t\t\t$this->error = sprintf('<div class=\"alert alert-warning\">%s</div>', _('Sorry, that user does not exist.') );\n\t\t\tparent::displayMessage($this->error, true);\n\t\t\treturn false;\n\t\t}\n\n\t\tforeach ($stmt->fetch(PDO::FETCH_ASSOC) as $field => $value) :\n\t\t\t$this->settings[$field] = parent::secure($value);\n\t\tendforeach;\n\n\t}", "public function loadProfileInformation() {\n\t\t\t$procedure = \"get\" . $this->mode_ . \"Information\"; \n\t\t\t$this->profileInformation_ = $this->dbHandler_->call($procedure, \"%d\", array($this->id_));\n\t\t}", "public function loadOnlinePlayers() {\n\t\t$this -> template = TemplateManager::load(\"StyledTable\");\n\t\t$this -> template -> insert(\"title\", \"All Online Players\");\n\t\t$players = $this -> database -> query(\"SELECT * FROM \" . GLOBAL_DB . \".members WHERE online=1 AND lastWorld !=-1\");\n\t\t$table = \"\";\n\t\twhile ($playerData = $players -> fetch(PDO::FETCH_ASSOC)) {\n\t\t\t$user = User::getUser($playerData['UID']);\n\t\t\t$table .= \"<tr class=\\\"online\\\">\n\t\t\t<td class=\\\"name\\\"><span class='username' style=''>\" . $user -> getModule(\"UserTools\") -> getFormatUsername(true) . \"</span></td>\n\t\t\t<td class=\\\"world\\\">World \" . $user -> getLastWorld() . \"</td>\n\t\t\t</tr>\";\n\t\t}\n\t\tif ($table == \"\") {\n\t\t\t$table = \"There are currently no online players.\";\n\t\t}\n\t\t$this -> template ->insert(\"icon\", \"globe\");\n\t\t$this -> template -> insert(\"table\", $table);\n\t\t$this -> display();\n\t}", "function search_connected_users() {\n global $DB;\n $sql = \"SELECT CURRENT_TIMESTAMP() AS fecha, COUNT(*) AS usuarios_conectados FROM {user}\n WHERE lastaccess > UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 1 MINUTE));\";\n $connecteduser = $DB->get_records_sql($sql);\n foreach ($connecteduser as $connection) {\n $actualdate = new DateTime($connection->fecha);\n $timestamp = $actualdate->getTimestamp();\n $connection->fecha = $timestamp;\n }\n return $connecteduser;\n}", "public function fetch()\n {\n return $this->info;\n }", "public function allupgraders(){\n // SQL statement\n $sql = \"SELECT * FROM user WHERE special = 1 AND (role = 'account' OR role = 'administrator') \";\n $result = $this->con->query($sql);\n\n // check if there is a user\n $count = $result->num_rows;\n if ($count != 0) {\n while ($row = $result->fetch_assoc()){\n $array[] = $row;\n }\n return $array;\n }\n }", "public function getOnlineUserList(){\n $query = \"select * from $this->onlineUser_tableName\";\n $result = $this->dbh->query($query);\n if($result->rowCount() > 0 ){\n return $result->fetchAll();\n }\n return null;\n }", "abstract public function getCruser();", "function get_connected_users() {\n global $DB;\n $users = $DB->get_records('report_user_statistics');\n return $users;\n}", "function show_lost_record($dbc) {\n\t#Create a query to get the id, item name, and status\n\t$query = 'SELECT owner, item_name, create_date FROM stuff WHERE status=\"lost\"' ;\n\t\n\t#Execute the query\n\t$results = mysqli_query( $dbc, $query ) ;\n\tcheck_results($results);\n\t\n\t#Show results\n\tif( $results ) {\n\t#Initializes the table before executing the query.\n\techo '<TABLE border = \"1\" float=\"left\" cellpadding=\"5px\" cellspacing=5px border = \"1\">' ;\n\techo '<TR>' ;\n\techo '<TH>Owner</TH>' ;\n\techo '<TH>Item Name</TH>' ;\n\techo '<TH>Created</TH>' ;\n\techo '</TR>' ;\n\t\n\t#For each row result, generate a table row\n\twhile ( $row = mysqli_fetch_array( $results, MYSQLI_ASSOC ) ) {\n\t\techo '<TR>' ;\n\t\techo '<TD>' . $row['owner'] . '</TD>' ;\n\t echo '<TD>' . $row['item_name'] . '</TD>' ;\n\t\techo '<TD>' . $row['create_date'] . '</TD>' ;\n echo '</TR>' ;\n\t}\n\t#End the table\n\techo '</TABLE>' ;\n\t\n\t#Free up the results in memory\n\tmysqli_free_result ( $results ) ;\n\t}\n}", "function _read_user_session()\n {\t\t\n\t\tif($this->sh_Options['keeping_logic'] == 'db'){\n\t\t\t$this->is_present = $this->_read_user_session_db();\n\t\t} else {\n\t\t\t$this->is_present = $this->_read_user_session_ss();\n\t\t}\n\t}", "public function read(){\n try {\n // query to get all users\n $this->_query = \"SELECT * FROM \" . $this->_dbtable;\n\n //preparing query\n $statement = $this->_conn->prepare($this->_query);\n\n // executing query\n $statement->execute();\n\n return $statement;\n }\n catch(PDOException $ex){\n echo \"Error\" . $ex->getMessage();\n }\n }", "function search_connected_usersfive() {\n global $DB;\n $sql = \"SELECT COUNT(*) AS usuarios_conectados\n FROM {user}\n WHERE lastaccess > UNIX_TIMESTAMP(DATE_SUB(NOW(), INTERVAL 5 MINUTE));\";\n $connecteduser = $DB->get_record_sql($sql);\n return $connecteduser->usuarios_conectados;\n}", "function retrieve_info() {\n // Execute the query, assigning the result to $result\n $result = mysqli_query($this->connection, $this->query);\n // If the query failed, $result will be \"false\", so we test for this, and exit if it is\n if ($result === false) {\n $error = \"Error retrieving records from database: mysqli_error($this->connection)\";\n header('Location:index.php?message=' . $error);\n }\n // Check if the query returned anything\n else if (mysqli_num_rows($result) > 0) {\n // Make result into array of JSON objects\n $row = mysqli_fetch_assoc($result);\n include_once('web_service.class.php');\n $service = new web_service($row);\n $service->server();\n $structure = $service->outcome();\n //garbage collection\n unset($service);\n } else {\n $structure = 'No images oin the database';\n }\n return $structure;\n }", "function LoadCurrent()\n {\n $this->user = null;\n $userID = null;\n if (isset($_SESSION[self::$sessionParam]))\n $userID = $_SESSION[self::$sessionParam];\n \n if ($userID)\n {\n $user = new User($userID);\n if ($user->Exists())\n $this->user = $user;\n }\n return $this->user !== null;\n }", "private function refreshLockInformation()\n {\n $result = self::$db->fetchOne(\n 'SELECT lock, locktime FROM jukebox.playlists WHERE playlistid=$1',\n [$this->getID()]\n );\n $this->lock = empty($result['lock']) ? null : MyRadio_User::getInstance($result['lock']);\n $this->locktime = (int) $result['locktime'];\n }", "function projectStatus($userid,$projectid)\n{\n\t$addprojectquery=\"SELECT relation FROM projectmembers WHERE userid = '$userid' AND projectid = '$projectid'\"; \n\t$addprojectresult=mysql_query($addprojectquery);\n\t\n\t$row = mysql_fetch_assoc($addprojectresult);\n\t\n\t$relationNum = $row['relation'];\n\t\n\tif(!mysql_num_rows($addprojectresult))\n {\n\t\treturn 0;//not a member, send request\n\t\t\techo \"No Relation\";\n\t\t\texit(); \n\t\n\t}\n\telse\n\t{\n\t\tswitch ($relationNum)\n\t\t\t{\t\n\t\t\t\tcase 3:\n\t\t\t\t\treturn 3; //pending view request\n\t\t\t\t\tbreak;\n\t\t\t\tcase 1:\n \t\t\t\t\treturn 1; //already a member\n \t\t\t\t\tbreak;\t\t\t\n\t\t\t\tcase 0:\n\t\t\t\t\treturn 2; //pending request\n\t\t\t\t\tbreak;\n\t\t\t\tcase 4: \n\t\t\t\t return 4; //description is open to user\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\n\t\n\t}\n\t\n\t\n\n\t\n\n\n}", "function __construct() {\n $query = \"SELECT * FROM agents where agentOnline=1\";\n if ($result = $this->queryDatabase($query))\n $this->online_count = mysql_numrows($result);\n\n // Get unique count\n $last = time() - 2592000;\n $query=\"SELECT * FROM agents where loginTime >= $last OR logoutTime >= $last\";\n if ($result = $this->queryDatabase($query))\n $this->unique_count = mysql_numrows($result);\n\n // Get Total user count\n $query=\"SELECT * FROM users\";\n if ($result = $this->queryDatabase($query))\n $this->user_count = mysql_numrows($result);\n\n // Get Region count\n $query=\"SELECT * FROM regions\";\n if ($result = $this->queryDatabase($query))\n $this->region_count = mysql_numrows($result);\n\n }", "function FetchTableContent($i)\r\n{\r\n\r\n/*\r\nFetchtable content List\r\n\r\n1. fetch all users for dashboard\r\n2. fetch all admins for dahsboard\r\n3. total all sub-admins for dahsboard\r\n4. total count of all registered users\r\n5. total count of all admin users\r\n6. fetch all users\r\n17. Fetch General Settings\r\n*/ \r\n\tglobal $connect;\r\n\t$crud = new Crud($connect);\r\n\r\n\tswitch ($i) {\r\n\r\n\t\t//select all users\r\n\t\tcase 1:\r\n\t\t\t$data = $crud->select(\"users\",\"*\",\"\", \"ID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//select all row from admin 1st level\r\n\t\tcase 2:\r\n\t\t\t$data = $crud->select(\"admin\",\"*\", \"\", \"ID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//select all row from admin 2nd level\r\n\t\tcase 3:\r\n\t\t\t$data = $crud->select(\"sub_admin\",\"*\", \"\", \"ID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//select all row from guest\r\n\t\tcase 4:\r\n\t\t\t$data = $crud->select(\"guest\",\"*\", \"\", \"ID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//fetch audit trail messages for dashboard\r\n\t\tcase 8:\r\n\t\t\t$data = $crud->select(\"gallery p\",\r\n\t\t\t\t\t\"p.*, k.Album, k.ID \",\r\n\t\t\t\t\t\"\",\r\n\t\t\t\t\t\" p.ID DESC \", \r\n\t\t\t\t\t\" LEFT JOIN album k on p.Album = k.ID \");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//select all row from advert\r\n\t\tcase 9:\r\n\t\t\t$data = $crud->select(\"advert\",\"*\", \"\", \"ID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//select total unique users from general_log table\r\n\t\tcase 10:\r\n\t\t\t$data = $crud->select(\"general_log\",\"COUNT(ID) as Total\", \"\", \"ID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\t\t\r\n\t\t//select total clicks from general_log table\r\n\t\tcase 11:\r\n\t\t\t$data = $crud->select(\"general_log\",\"SUM(Visit) as Total\", \"\", \"ID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\r\n\t\t//select total unique user clicks from general_log table(For Individual Dashboards)\r\n\t\tcase 12:\r\n\t\t\t$data = $crud->select(\"general_log\",\"COUNT(Visit) as Total\", \"\", \"ID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\r\n\t\t//select all row from Audit Log\r\n\t\tcase 13:\r\n\t\t\t$data = $crud->select(\"audit_log\",\"*\", \"\", \"COUNT(ID) DESC\", \"UserID\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\t\t//select total unique users from general_log table\r\n\t\tcase 14:\r\n\t\t\t$data = $crud->select(\"users\",\"COUNT(ID) as Total\", \"\", \"ID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\t\t\r\n\t\t//fetch general settings - used\r\n\t\tcase 17:\r\n\t\t\t$data = $crud->select(\"general_settings\", \"*\");\r\n\r\n\t\t\treturn $data;\r\n\t\tbreak;\r\n\r\n\t\t//count schools\r\n\t\tcase 18:\r\n\t\t\t$data = $crud->select(\"school\",\"COUNT(SchoolID) as Total\", \"\", \"SchoolID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\r\n\t\t//count teachers \r\n\t\tcase 19:\r\n\t\t\t$data = $crud->select(\"teacher\",\"COUNT(TID) as Total\", \"\", \"TID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\r\n\t\t//count student\r\n\t\tcase 20:\r\n\t\t\t$data = $crud->select(\"student\",\"COUNT(StdID) as Total\", \"\", \"StdID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\r\n\t\t//count parent\r\n\t\tcase 21:\r\n\t\t\t$data = $crud->select(\"parent\",\"COUNT(ParID) as Total\", \"\", \"ParID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\r\n\t\t//count non-academic\r\n\t\tcase 22:\r\n\t\t\t$data = $crud->select(\"non_academic\",\"COUNT(ID) as Total\", \"\", \"ID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\r\n\t\t//count sub-admin\r\n\t\tcase 23:\r\n\t\t\t$data = $crud->select(\"sub_admin\",\"COUNT(ID) as Total\", \"\", \"ID DESC\");\r\n\t\t\treturn $data[0][\"Total\"];\r\n\t\t\tbreak;\r\n\t\t//select all school\r\n\t\tcase 24:\r\n\t\t\t$data = $crud->select(\"school\",\"*\",\"\", \"SchoolID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\t\t//select all teacher\r\n\t\tcase 25:\r\n\t\t\t$data = $crud->select(\"teacher\",\"*\",\"\", \"TID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\t\t//select all student\r\n\t\tcase 26:\r\n\t\t\t$data = $crud->select(\"student\",\"*\",\"\", \"StdID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\t\t//select all parent\r\n\t\tcase 27:\r\n\t\t\t$data = $crud->select(\"parent\",\"*\",\"\", \"ParID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\t\t//select all non-academic\r\n\t\tcase 28:\r\n\t\t\t$data = $crud->select(\"non_academic\",\"*\",\"\", \"ID DESC\");\r\n\t\t\treturn $data;\r\n\t\t\tbreak;\r\n\r\n\r\n\r\n\r\n\r\n\t\t\r\n\t\tdefault:\r\n\t\t\t# code...\r\n\t\t\tbreak;\r\n\t}\r\n}", "public function get_stats()\n\t{\n\t\tglobal $_game;\n\t\t\n\t\t$expire = time() - 604800; // tell kun spillere som har vært pålogget siste uken\n\t\t$result = \\Kofradia\\DB::get()->query(\"SELECT up_b_id, COUNT(up_id) AS ant, SUM(up_cash) AS money FROM users_players WHERE up_access_level != 0 AND up_access_level < {$_game['access_noplay']} AND up_last_online > $expire GROUP BY up_b_id\");\n\t\twhile ($row = $result->fetch())\n\t\t{\n\t\t\tif (!isset($this->bydeler[$row['up_b_id']])) continue;\n\t\t\t\n\t\t\t$this->bydeler[$row['up_b_id']]['num_players'] = $row['ant'];\n\t\t\t$this->bydeler[$row['up_b_id']]['sum_money'] = $row['money'];\n\t\t}\n\t}", "function refreshInfo()\n {\n if (! $this->isLoggedIn())\n return false;\n \n $id = trim($this->getUserSession('id'));\n $row = $this->_user->get($id);\n \n $info['pass'] = $row[$this->passField];\n $info['user'] = $row[$this->userNameField];\n \n $fields = explode(',',$this->miscFields);\n foreach ($fields as $k=>$v)\n {\n\t\t\t$info[$v] = $row[$v];//$query->getSingle($v);\n }\n \n //The following variables are used to determine wether or not to\n //set the cookies on the users computer. If $origUser matches the\n //cookie value 'user' it means the user had cookies stored on his \n //browser, so the cookies would be re-written with the new value of the\n //username.\n $origUser = $this->getUserSession('user');\n $origPass = $this->getUserSession('pass');\n \n foreach ($info as $k=>$v)\n {\n \t$this->setUserSession($k,$v);\n }\n \n // Check is group admin\n// $this->setUserSession('is_admin',$this->_user->isAdmin($row['group_id']));\n \n $objGroup = new Group();\n // $arrAcl = $objGroup->getAclFromGroup(\"2,3\");\n $arrAcl = $objGroup->getAclFromGroup($row['group_id']);\n $this->setUserSession('acl_resources', $arrAcl);\n $this->_permission = $arrAcl; \n\n if (array_key_exists('user',$_COOKIE) && array_key_exists('pass',$_COOKIE))\n {\n if ($_COOKIE['user'] == $origUser && $_COOKIE['pass'] == $origPass)\n \t$this->setCookies();\n }\n return true;\n }", "public function getDataByDatabase()\n {\n $condition = [\n ['user_id', '>', '39454']\n ];\n db()->table('tp_users')->where($condition)->cache('userList', 60)->select();\n $data = Cache::get('userList');\n dump($data);die;\n }", "function afficherclient()\r\n\t{\r\n\t\t$sql=\"SElECT * From user\";\r\n\t\t$db = config::getConnexion();\r\n\t\ttry\r\n\t\t{\r\n\t\t$liste=$db->query($sql);\r\n\t\treturn $liste;\r\n\t\t}\r\n catch (Exception $e)\r\n {\r\n die('Erreur: '.$e->getMessage());\r\n }\r\n\t}", "private function ifoCadUser()\n {\n $infoCadUser = new AdmsRead();\n $infoCadUser->fullRead(\"SELECT env_email_conf, adms_niveis_acesso_id, adms_sits_usuario_id FROM adms_cads_usuarios WHERE id =:id LIMIT :limit\", \"id=1&limit=1\");\n $this->IfoCadUser = $infoCadUser->getResultado();\n\n }", "public function userStories() {\n require_once('connectvars.php');\n \n $dbc = mysqli_connect(DB_HOST, DB_USER, DB_PASSWORD, DB_NAME)\n or die('Error connecting to MySQL server.');\n \n //Retrieve user stories \n $querySelect = \"SELECT * FROM mad_lib_data ORDER BY story_id desc\";\n \n $result = mysqli_query($dbc, $querySelect)\n or die('Error querying database.');\n \n return $result;\n \n mysqli_close($dbc);\n \t}", "function user_details ()\n\t\t{\n\t\t $query = \"select * from user_details\" ; \n\t\t\t$data = mysql_query($query) ;\n\t\t\treturn $data ; \n\t\t}", "function fetch_user_desig_type() //get all records from database \n\t{ \n\t\t//mandatory requirements for pages loading nav and sidebar\n\t\tif($this->session->userdata('logged_in')==\"\")\n\t\t\theader(\"Location: \".$this->config->base_url().\"Login\");\n\t\t$this->cache_update();\n\t\t$this->check_privilege(11);\n\t\t$this->load->driver('cache',array('adapter' => 'file'));\n\t\t$u_type = array('var'=>$this->cache->get('Active_status'.$this->session->userdata('loginid'))['user_type_id_fk']);\n\t\t$this->load->model('profile_model');\n\t\t$noti = array('meeting'=>$this->profile_model->meeting_notification());\n\t\t$u_type['notification'] = $noti;\n\t\t$u_type['noti1']=$this->profile_model->custom_notification();\n\t\t$this->load->view('dashboard/navbar',$u_type);\n\t\t$da = $this->profile_model->get_profile_info($this->session->userdata('uid'));\n\t\t$this->load->view('dashboard/sidebar',$da);\n\t\t//mandatory requirements end\n\n\t\t$this->load->model('Sup_admin');\n\t \t$query=$this->Sup_admin->fetch_user_desig_type();\n\t\t$data['records']=$query->result();\n\n\t\t$this->load->model('Crud_model');\n\t\t$this->db->trans_off();\n $this->db->trans_strict(FALSE);\n $this->db->trans_start();\n\t\t$this->Crud_model->audit_upload($this->session->userdata('loginid'),\n\t\t\t\t\t\t\tcurrent_url(),\n\t\t\t\t\t\t\t'User type active page visited',\n\t\t\t\t\t\t\t'Custom message here');\n\t\t$this->db->trans_complete();\n\t\t$this->load->view('view_user_type',$data); \n\t\t$this->load->view('dashboard/footer');\n \t}", "public function preRetrieve();", "function getBuildingInfo() {\n return getOne(\"SELECT * FROM building WHERE id = ?\",[getLogin()['bid']]);\n}", "public function load() {\n\t\tglobal $config;\n\t\n\t\tif($this->exists()){ // User exists\n\t\t\tif(!empty($this->data['id']))\n\t\t\t\t$where = 'id = '.$this->data['id'];\n\t\t\telseif(!empty($this->data['fbid']))\n\t\t\t\t$where = 'fbid = '.$this->data['fbid'];\n\t\t\t\t\n\t\t\t$result = $config['database']->query(\"\n\t\t\t\tSELECT *\n\t\t\t\tFROM nuusers\n\t\t\t\tWHERE $where\n\t\t\t\tLIMIT 1\n\t\t\t\");\n\t\t\t$row = $result->fetch_assoc();\n\t\t\t\n\t\t\tforeach($row as $key => $val){\n\t\t\t\tif($key == 'options'){\n\t\t\t\t\t$this->data['options'] = json_decode($val, true);\n\t\t\t\t}else if(is_string($val)){\n\t\t\t\t\tif(!get_magic_quotes_gpc())\n\t\t\t\t\t\t$this->data[$key] = stripslashes($val);\n\t\t\t\t\telse\n\t\t\t\t\t\t$this->data[$key] = $val;\n\t\t\t\t}else{\n\t\t\t\t\t$this->data[$key] = $val;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tif(empty($this->data['photo'])){\n\t\t\t\tglobal $config;\n\t\t\t\t\n\t\t\t\tif($this->data['faculty'])\n\t\t\t\t\t$this->data['photo'] = $config['imagesurl'].'/faculty.jpg';\n\t\t\t\telse\n\t\t\t\t\t$this->data['photo'] = $config['imagesurl'].'/anonymous.gif';\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t$this->data['level'] = $this->loadLevel();\n\t\t\t$this->data['levelProgress'] = $this->loadLevelProgress();\n\t\t\t$this->data['rank'] = $this->loadRank();\n\t\t\t$this->data['achievements'] = $this->loadAchievements();\n\t\t\t$this->data['post_counts'] = $this->loadPostCounts();\n\t\t\t\n\t\t\treturn $result;\n\t\t}else{ // User does not exists\n\t\t\tif($this->data['fbid']){ // New user from facebook\n\t\t\t\tglobal $fbme;\n\t\t\t\t\n\t\t\t\t$y = substr($fbme['birthday'],6);\n\t\t\t\t$m = substr($fbme['birthday'],0,2);\n\t\t\t\t$d = substr($fbme['birthday'],3,2);\n\t\t\t\t$bday = $y.'-'.$m.'-'.$d;\n\t\t\t\t\n\t\t\t\t$create = $this->create(array(\n\t\t\t\t\t'first_name' => $fbme['first_name'],\n\t\t\t\t\t'last_name' => $fbme['last_name'],\n\t\t\t\t\t'email' => $fbme['email'],\n\t\t\t\t\t'birthday' => $bday,\n\t\t\t\t\t'gender' => $fbme['gender']\n\t\t\t\t));\n\t\t\t\t\n\t\t\t\treturn $create;\n\t\t\t}else{ // Invalid user id\n\t\t\t\t$this->data['id'] = null;\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\t}", "protected function setCreatorLookup()\n\t{\n\t\t$jevuser = JEVHelper::getAuthorisedUser();\n\t\t$user = JFactory::getUser();\n\n\t\tif (JVersion::isCompatible(\"1.6.0\"))\n\t\t{\n\t\t\t//$access = JAccess::check($user->id, \"core.deleteall\", \"com_jevents\");\n\t\t\t$access = $user->authorise('core.admin', 'com_jevents');\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// Get an ACL object\n\t\t\t$acl = & JFactory::getACL();\n\t\t\t$grp = $acl->getAroGroup($user->get('id'));\n\t\t\t// if no valid group (e.g. anon user) then skip this.\n\t\t\tif (!$grp)\n\t\t\t\treturn;\n\n\t\t\t$access = $acl->is_group_child_of($grp->name, 'Public Backend');\n\t\t}\n\n\n\t\t$db = JFactory::getDBO();\n\t\tif (($jevuser && $jevuser->candeleteall) || $access)\n\t\t{\n\n\t\t\tif (JVersion::isCompatible(\"1.6.0\"))\n\t\t\t{\n\t\t\t\t$params = & JComponentHelper::getParams(JEV_COM_COMPONENT);\n\t\t\t\t$authorisedonly = $params->get(\"authorisedonly\", 0);\n\t\t\t\t// if authorised only then load from database\n\t\t\t\tif ($authorisedonly)\n\t\t\t\t{\n\t\t\t\t\t$sql = \"SELECT tl.*, ju.* FROM #__jev_users AS tl \";\n\t\t\t\t\t$sql .= \" LEFT JOIN #__users as ju ON tl.user_id=ju.id \";\n\t\t\t\t\t$sql .= \" WHERE tl.cancreate=1\";\n\t\t\t\t\t$sql .= \" ORDER BY ju.name ASC\";\n\t\t\t\t\t$db->setQuery($sql);\n\t\t\t\t\t$users = $db->loadObjectList();\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$rules = JAccess::getAssetRules(\"com_jevents\", true);\n\t\t\t\t\t$creatorgroups = $rules->getData();\n\t\t\t\t\t// need to merge the arrays because of stupid way Joomla checks super user permissions\n\t\t\t\t\t//$creatorgroups = array_merge($creatorgroups[\"core.admin\"]->getData(), $creatorgroups[\"core.create\"]->getData());\n\t\t\t\t\t// use union orf arrays sincee getData no longer has string keys in the resultant array\n\t\t\t\t\t//$creatorgroups = $creatorgroups[\"core.admin\"]->getData()+ $creatorgroups[\"core.create\"]->getData();\n\t\t\t\t\t// use union orf arrays sincee getData no longer has string keys in the resultant array\n\t\t\t\t\t$creatorgroupsdata = $creatorgroups[\"core.admin\"]->getData();\n\t\t\t\t\t// take the higher permission setting\n\t\t\t\t\tforeach ($creatorgroups[\"core.create\"]->getData() as $creatorgroup => $permission)\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($permission){\n\t\t\t\t\t\t\t$creatorgroupsdata[$creatorgroup]=$permission;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t$users = array(0);\n\t\t\t\t\tforeach ($creatorgroupsdata as $creatorgroup => $permission)\n\t\t\t\t\t{\n\t\t\t\t\t\tif ($permission == 1)\n\t\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$users = array_merge(JAccess::getUsersByGroup($creatorgroup, true), $users);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t$sql = \"SELECT * FROM #__users where id IN (\" . implode(\",\", array_values($users)) . \") ORDER BY name asc\";\n\t\t\t\t\t$db->setQuery($sql);\n\t\t\t\t\t$users = $db->loadObjectList();\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$db = JFactory::getDBO();\n\n\t\t\t\t$params = & JComponentHelper::getParams(JEV_COM_COMPONENT);\n\t\t\t\t$authorisedonly = $params->get(\"authorisedonly\", 0);\n\t\t\t\t// if authorised only then load from database\n\t\t\t\tif ($authorisedonly)\n\t\t\t\t{\n\t\t\t\t\t$sql = \"SELECT tl.*, ju.* FROM #__jev_users AS tl \";\n\t\t\t\t\t$sql .= \" LEFT JOIN #__users as ju ON tl.user_id=ju.id \";\n\t\t\t\t\t$sql .= \" WHERE tl.cancreate=1\";\n\t\t\t\t\t$sql .= \" ORDER BY ju.name ASC\";\n\t\t\t\t\t$db->setQuery($sql);\n\t\t\t\t\t$users = $db->loadObjectList();\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$params = & JComponentHelper::getParams(JEV_COM_COMPONENT);\n\t\t\t\t\t$minaccess = $params->getValue(\"jevcreator_level\", 19);\n\t\t\t\t\t$sql = \"SELECT * FROM #__users where gid>=\" . $minaccess;\n\t\t\t\t\t$sql .= \" ORDER BY name ASC\";\n\t\t\t\t\t$db->setQuery($sql);\n\t\t\t\t\t$users = $db->loadObjectList();\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$userOptions[] = JHTML::_('select.option', '-1', JText::_('SELECT_USER'));\n\t\t\tforeach ($users as $user)\n\t\t\t{\n\t\t\t\t$userOptions[] = JHTML::_('select.option', $user->id, $user->name. \" ( \".$user->username.\" )\");\n\t\t\t}\n\t\t\t$creator = $this->row->created_by() > 0 ? $this->row->created_by() : (isset($jevuser) ? $jevuser->user_id : 0);\n\t\t\t$userlist = JHTML::_('select.genericlist', $userOptions, 'jev_creatorid', 'class=\"inputbox\" size=\"1\" ', 'value', 'text', $creator);\n\n\t\t\t$this->assignRef(\"users\", $userlist);\n\t\t}\n\n\t}", "public function getStatus()\n {\n \n return $this->_em->createQuery('SELECT s,u FROM TechCorpFrontBundle:Status s \n JOIN s.user u ORDER BY s.createdAt DESC');\n }", "public function fetch();", "public function fetch();", "public function fetch();", "public function fetch();", "public function fetch();", "public function fetch();", "public function fetch();", "public function fetch();", "public function fetch();", "protected function load(){\r\n\t\r\n\t$qq1 = Db::result(\"SELECT * FROM \"._SQLPREFIX_.$this->tableName.\" WHERE \".$this->fieldName.\" = \".(int)$this->id);\r\n\t$this->profileData = count($qq1)>0 ? $qq1[0]: null; \r\n\t\r\n\tif($this->metaUse){\r\n\t\t$qq2 = Db::result(\"SELECT * FROM \"._SQLPREFIX_.$this->metaTypesTableName.\" WHERE active = 1 ORDER BY public_ord, id\");\r\n\t\t$this->metaData = count($qq2)>0 ? $qq2: array(); \r\n\t}\r\n}", "protected function tryFetchLiveData() {\n $curr_user = \\Drupal::currentUser();\n\n // Make sure we have permission to do this.\n if (!$curr_user || !$curr_user->hasPermission('refresh cu hub reference')) {\n return;\n }\n\n $hub_uuid = $this->getHubUUID();\n $resource_type = $this->getResourceType();\n $is_live = \\Drupal::request()->query->get('live');\n\n // Make sure we have the params we need.\n if (!$hub_uuid || !$resource_type || !$is_live) {\n return;\n }\n\n if ($resource = $resource_type->fetchResource($hub_uuid)) {\n $this->unserializedHubJson = $resource->getJsonData();\n $this->resourceObject = $resource;\n }\n }", "public function fetchData() {\n \n $this->readMainDomain($this->base . \"/userdata/main\");\n $main[$this->mainDomain] = $this->mainDomain;\n\n $this->readAddOnDomains($this->base . \"/addons\");\n $this->readParkedDomains($this->base . \"/pds\");\n $this->readSubDomains($this->base . \"/sds2\");\n\n $this->allDomains = array_merge($this->addOnDomains, $this->subDomains);\n $this->allDomains = array_merge($this->allDomains, $this->parkedDomains);\n $this->allDomains = array_merge($this->allDomains, $main);\n\n $this->readMail($this->base . \"/homedir/.cpanel/email_accounts.yaml\");\n\n $this->readMySQL();\n $this->readUserConfig();\n $this->readHomeDir();\n }" ]
[ "0.57340926", "0.562462", "0.54674655", "0.5464439", "0.5411537", "0.53251415", "0.5314167", "0.530504", "0.52848315", "0.5253899", "0.5251109", "0.52351385", "0.52084786", "0.52075505", "0.5205091", "0.51926273", "0.5156472", "0.5127322", "0.5122057", "0.5119898", "0.5111413", "0.50856334", "0.5083979", "0.50769717", "0.5064712", "0.5060806", "0.50410813", "0.5038597", "0.50380355", "0.5036456", "0.5021009", "0.5011769", "0.5004108", "0.5001825", "0.49985304", "0.49950328", "0.49915037", "0.4989681", "0.49859172", "0.49715838", "0.49655128", "0.49608997", "0.49581566", "0.49491587", "0.49489203", "0.49467227", "0.49444416", "0.49374127", "0.49340394", "0.49254605", "0.49228862", "0.4920094", "0.49143702", "0.49093354", "0.49063116", "0.489904", "0.4893367", "0.4893336", "0.4892276", "0.48913983", "0.48912117", "0.48906082", "0.48903647", "0.48903143", "0.48901945", "0.4882349", "0.487844", "0.48751026", "0.48733324", "0.48670676", "0.48565", "0.48556998", "0.48553154", "0.48437354", "0.48430526", "0.48381022", "0.48372784", "0.48363972", "0.48266456", "0.48264086", "0.4826223", "0.48239982", "0.4823428", "0.48225772", "0.4815351", "0.48135823", "0.48132282", "0.4810212", "0.48063052", "0.48061737", "0.48061737", "0.48061737", "0.48061737", "0.48061737", "0.48061737", "0.48061737", "0.48061737", "0.48061737", "0.48047665", "0.4803305", "0.4802479" ]
0.0
-1
The ArrayAccess interface provides us with the ability to use an instance of this class as an array. The operations executed with that syntax, are redirected to these methods. I use this for the LVPPlayer class because then I can group all the getters, setters and unsetters into four methods. This method gets called when an isset () call has been performed on an array index of this class.
public function offsetExists($mKey) { return in_array($mKey, self::$s_aInfoKeys); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testOrderedQueueArrayAccess_implementation() {\n\t\t\t$this->assertTrue($this->oq InstanceOf \\ArrayAccess);\n\t\t}", "public function it_should_allow_storing_value_using_array_access_api() {\n\t\t$cache = $this->make_instance();\n\n\t\t$this->assertFalse( isset( $cache['foo'] ) );\n\n\t\t$cache['foo'] = 'bar';\n\n\t\t$this->assertTrue( isset( $cache['foo'] ) );\n\t\t$this->assertEquals( 'bar', $cache['foo'] );\n\t}", "public static function has_array_access($input)\n {\n }", "public static function accessible($array)\n {\n return is_array($array) || $array instanceof ArrayAccess;\n }", "public function testArrayAccess()\n\t{\n\t\t$book = R::dispense( 'book' );\n\t\t$book->isAwesome = TRUE;\n\t\tasrt( isset( $book->isAwesome ), TRUE );\n\t\t$book = R::dispense( 'book' );\n\t\t$book['isAwesome'] = TRUE;\n\t\tasrt( isset( $book->isAwesome ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['xownPageList'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['ownPageList'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['xownPage'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['ownPage'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['sharedTag'] = R::dispense( 'tag', 2 );\n\t\tasrt( isset( $book->sharedTag ), TRUE );\n\t\tasrt( isset( $book->sharedTagList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['sharedTagList'] = R::dispense( 'tag', 2 );\n\t\tasrt( isset( $book->sharedTag ), TRUE );\n\t\tasrt( isset( $book->sharedTagList ), TRUE );\n\n\t}", "public function testArrayAccess() {\n\t\t$session = $this->getSession();\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set for new empty session');\n\t\t$this->assertNull($session['test'], 'Not set key is not null');\n\t\t$session['test'] = 'testValue';\n\t\t$this->assertTrue(isset($session['test']), 'Test key is not set');\n\t\t$this->assertSame('testValue', $session['test'], 'Test key is not correctly set');\n\t\tunset($session['test']);\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set after deleting');\n\t\t$this->assertNull($session['test'], 'Deleted key is not null');\n\t}", "public function testSetAndRetrieveArray(): void\n {\n $obj = new \\stdClass;\n $obj->animal = \"Frog\";\n $obj->mineral = \"Quartz\";\n $obj->vegetable = \"Spinach\";\n $arr = array(\n \"testInt\" => 5,\n \"testFloat\" => 3.278,\n \"testString\" => \"WooHoo\",\n \"testBoolean\" => true,\n \"testNull\" => null,\n \"testArray\" => array(1, 2, 3, 4, 5),\n \"testObject\" => $obj\n );\n $key = \"TestArray\";\n $this->testNotStrict->set($key, $arr);\n $a = $this->testNotStrict->get($key);\n $bool = is_array($a);\n $this->assertTrue($bool);\n $this->assertEquals($arr['testInt'], $a['testInt']);\n $this->assertEquals($arr['testFloat'], $a['testFloat']);\n $this->assertEquals($arr['testString'], $a['testString']);\n $this->assertEquals($arr['testBoolean'], $a['testBoolean']);\n $this->assertNull($a['testNull']);\n $this->assertEquals($arr['testArray'], $a['testArray']);\n $this->assertEquals($arr['testObject'], $a['testObject']);\n }", "public static function accessible($value)\n {\n return is_array($value) || $value instanceof ArrayAccess;\n }", "function set(array $array, $pos = 0){\n foreach($this as $field => $valor){\n if(isset($array[$pos])){\n $this->$field = $array[$pos];\n }\n $pos++;\n }\n }", "public function __invoke() : array;", "public function __invoke() : array;", "function isArrayAccess($obj)\n {\n return $obj instanceof ArrayAccess;\n }", "public function test_get_array_values_from_carrier(): void\n {\n $carrier = [\n 'a' => 'alpha',\n 'b' => ['bravo'],\n ];\n $map = new ArrayAccessGetterSetter();\n $this->assertSame('alpha', $map->get($carrier, 'a'));\n $this->assertSame('bravo', $map->get($carrier, 'b'));\n $this->assertSame(['a', 'b'], $map->keys($carrier));\n }", "public function testArrayAccessMapsToCorrectMethods()\n {\n $c = new Container;\n\n $c['League\\Container\\Test\\Asset\\Baz'] = 'League\\Container\\Test\\Asset\\Baz';\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertTrue(isset($c['League\\Container\\Test\\Asset\\Baz']));\n\n unset($c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertFalse(isset($c['League\\Container\\Test\\Asset\\Baz']));\n }", "public function testOffsetGet()\n {\n $bag = new ArrayAttributeBag('foobar_storageKey');\n\n $bag['foo'] = 'bar';\n\n $this->assertSame('bar', $bag['foo']);\n }", "public static function accessible( $value ): bool {\n\t\t\treturn is_array( $value ) || $value instanceof ArrayAccess;\n\t\t}", "public static function accessible($value)\n {\n return is_array($value) || $value instanceof ArrayAccess;\n }", "public function testNoArrayMetaAccess()\n\t{\n\t\t$bean = R::dispense( 'bean' );\n\t\t$bean->setMeta( 'greet', 'hello' );\n\t\tasrt( isset( $bean['greet'] ), FALSE );\n\t\tasrt( isset( $bean['__info']['greet'] ), FALSE );\n\t\tasrt( isset( $bean['__info'] ), FALSE );\n\t\tasrt( isset( $bean['meta'] ), FALSE );\n\t\tasrt( count( $bean ), 1 );\n\t}", "function offsetGet(/*. mixed .*/ $object_){}", "public static function isAccessible($value) : bool\n\t{\n\t\treturn is_array($value) || $value instanceof ArrayAccess;\n\t}", "function arrayAccessible($value)\n {\n return is_array($value);\n }", "function offsetSet(/*. mixed .*/ $object_, /*. mixed .*/ $info){}", "public static function accessible($value)\n {\n return is_array($value) || $value instanceof \\ArrayAccess;\n }", "function offsetExists(/*. mixed .*/ $object_){}", "public function aArray() {}", "function setValues($array){\r\n\t\tforeach($array as $key => $val)\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t}", "public function offsetGet($offset) {}", "public function offsetGet($offset) {}", "public function offsetGet($offset) {}", "public function __get($name){\r\n\t\tif(array_key_exists($name,$this->array)){\r\n\t\t\treturn $array[$name];\r\n\t\t/* check property is available */\t\r\n\t\t}else if(property_exists($this, $name)){\r\n\t\t return $this->$name;\r\n\t\t}else{\r\n\t\t\treturn \"Trying to access not existing variable : $name<br/>\";\r\n\t\t}\r\n\t}", "public function offsetSet($key, $value) {}", "public function asExposedChangedIndexedArray(): array;", "public function testOffsetSet()\n {\n $bag = new ArrayAttributeBag('foobar_storageKey');\n\n $bag['foo'] = 'bar';\n\n $this->assertSame('bar', $bag->get('foo'));\n }", "function setArray( array $storearray ) {\n$this->array = $storearray;\n}", "public function testContainerAcceptsArrayAccess()\n {\n $config = $this->getMock('ArrayAccess', ['offsetGet', 'offsetSet', 'offsetUnset', 'offsetExists']);\n $config->expects($this->any())\n ->method('offsetGet')\n ->with($this->equalTo('di'))\n ->will($this->returnValue($this->configArray));\n\n $config->expects($this->any())\n ->method('offsetExists')\n ->with($this->equalTo('di'))\n ->will($this->returnValue(true));\n\n\n $c = new Container($config);\n\n $foo = $c->get('League\\Container\\Test\\Asset\\Foo');\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Foo', $foo);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Bar', $foo->bar);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $foo->bar->baz);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\BazInterface', $foo->bar->baz);\n\n $baz = $c->get('League\\Container\\Test\\Asset\\Baz');\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $foo->baz);\n }", "public function __isset($offset)\n {\n }", "public function __isset($name)\n { $method = 'isset' . ucfirst($name);\n if (method_exists($this, $method))\n {\n return $this->$method();\n }\n\n // step 2: just check on the data in the array\n return isset($this->__data[$name]);\n }", "public static function isArrayAccessible($value) : bool\n\t{\n\t\treturn $value instanceof \\ArrayAccess || is_array($value);\n\t}", "public function createObjectCanDoSetterInjectionWithArrays() {\n\t\t$someArray = array(\n\t\t\t'foo' => 'bar',\n\t\t\t199 => 837,\n\t\t\t'doo' => TRUE\n\t\t);\n\t\t$someConfigurationProperty = new \\F3\\FLOW3\\Object\\Configuration\\ConfigurationProperty('someProperty', $someArray, \\F3\\FLOW3\\Object\\Configuration\\ConfigurationProperty::PROPERTY_TYPES_STRAIGHTVALUE);\n\t\t$objectConfiguration = new \\F3\\FLOW3\\Object\\Configuration\\Configuration('F3\\FLOW3\\Tests\\Object\\Fixture\\BasicClass');\n\t\t$objectConfiguration->setProperty($someConfigurationProperty);\n\n\t\t$object = $this->objectBuilder->createObject('F3\\FLOW3\\Tests\\Object\\Fixture\\BasicClass', $objectConfiguration);\n\t\t$this->assertEquals($someArray, $object->getSomeProperty(), 'The array has not been setter-injected although it should have been.');\n\t}", "public function init()\n {\n parent::init();\n $this->storage = Instance::ensure($this->storage, '\\ArrayAccess');\n }", "public function offsetGet($offset)\n {\n }", "public function get() : array;", "public /*void*/ function offsetSet(/*scalar*/ $offset, /*mixed*/ $value){}", "function __isset ($key)\n {\n return isset ($this->A[$key]);\n }", "abstract public function getArray();", "public function offsetSet($offset, $value) \n {\n }", "function assignIfIsset($object, $property, $array, $key)\n{\n if (array_key_exists($key, $array)) {\n $object->$property = $array[$key];\n }\n}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "function set(array $array){\n foreach($this as $atributo => $valor){\n if(isset($array[$atributo])){\n $this->$atributo = $array[$atributo];\n }\n }\n }", "public function offsetSet($name, $value) {\n\t\treturn call_user_func_array(array('parent', __FUNCTION__), func_get_args()); \n\t}", "public function offsetGet($offset);", "public function offsetGet($offset);", "function test_getArrayById() {\r\n\t\t$rowset = array(array(\"memberClassId\" => 1, \"memberClassName\" => \"reader\"),\r\n\t\t\t\tarray(\"memberClassId\" => 2, \"memberClassName\" => \"nosher\"));\r\n\t\t$myArray = MemberClassesDB::getArray($rowset, \"memberClassId\", \"memberClassName\");\r\n\t\t$this->assertEqual($myArray['1'], \"reader\",\r\n\t\t\t\t\"Should return reader for key of 1 but returned \".$myArray['1']);\r\n\t\t$this->assertEqual($myArray['2'], 'nosher',\r\n\t\t\t\t\"Should return nosher for key of 2 but returned \".$myArray['2']);\r\n\t}", "public function get(): array;", "public function get(): array;", "public function offsetGet($key): mixed\n {\n if (is_array($this->_data)) {\n return $this->out($this->_data[$key], $key, 'array');\n } elseif ($this->_data instanceof \\ArrayAccess) {\n return $this->out($this->_data[$key], $key, 'array');\n } else {\n throw new \\Exception('Cannot use object of type ' . get_class($this->_data) . ' as array');\n }\n }", "public function offsetSet($key, $value): void\n {\n if (is_array($this->_data)) {\n $value = $this->in($value, $key, 'array');\n $this->_data[$key] = $value;\n } elseif ($this->_data instanceof \\ArrayAccess) {\n $value = $this->in($value, $key, 'array');\n $this->_data[$key] = $value;\n } else {\n throw new \\Exception('Cannot use object of type ' . get_class($this->_data) . ' as array');\n }\n }", "public function offsetGet( $key );", "public function offsetSet( $key, $value );", "public function __get($offset)\n {\n }", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function test_getArrayByName() {\r\n\t\t$rowset = array(array(\"memberClassId\" => 1, \"memberClassName\" => \"reader\"),\r\n\t\t\t\tarray(\"memberClassId\" => 2, \"memberClassName\" => \"nosher\"));\r\n\t\t$myArray = MemberClassesDB::getArray($rowset, \"memberClassName\", \"memberClassId\");\r\n\t\t$this->assertEqual($myArray['reader'], 1, \r\n\t\t \"Should return 1 for key of reader but returned \".$myArray['reader']);\r\n\t\t$this->assertEqual($myArray['nosher'], 2,\r\n\t\t\t\t\"Should return 2 for key of nosher but returned \".$myArray['nosher']);\r\n\t}", "public function setArray($array){\n $this->array=$array;\n }", "public function getInternalArray() {}", "function offsetGet(/*. mixed .*/ $offset){}", "public function offsetSet($offset, $value) { }", "public function __isset($key);", "public function __isset($key);", "public function testArrayKeyExists(): void\n { \n $ma = [\"Bee A\", \"Bee B\", \"Bee c\"];\n list($a, $b, $c) = $ma;\n \n $obj = new Points();\n $obj->setPoints($a, 10);\n $obj->setPoints($b, 77);\n $obj->setPoints($c, 2);\n \n $res = $obj->getPointsArr();\n \n $this->assertTrue(array_key_exists($a, $res));\n $this->assertTrue(array_key_exists($b, $res));\n $this->assertTrue(array_key_exists($c, $res));\n }", "public function testArrayAccess()\n {\n $this->assertEquals('RegularPrice', $this->pool['regular_price']);\n $this->assertEquals('SpecialPrice', $this->pool['special_price']);\n $this->pool['fake_price'] = 'FakePrice';\n $this->assertEquals('FakePrice', $this->pool['fake_price']);\n $this->assertTrue(isset($this->pool['fake_price']));\n unset($this->pool['fake_price']);\n $this->assertFalse(isset($this->pool['fake_price']));\n $this->assertNull($this->pool['fake_price']);\n }", "public function offsetGet($offset): mixed;", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "public function testAsArrayAccessArray()\n {\n $month = new Month();\n\n $month[] = \"Zahl 0\";\n $month[] = \"Zahl 1\";\n $month['Name'] = \"Tobias\";\n\n $this->assertArrayHasKey('0', $month);\n $this->assertArrayHasKey('Name', $month);\n\n $this->assertEquals(\"Zahl 0\", $month[0]);\n $this->assertEquals(\"Zahl 1\", $month[1]);\n $this->assertEquals($month['Name'], 'Tobias');\n\n $month[0] = \"Geaendert Zahl 0\";\n $this->assertEquals(\"Geaendert Zahl 0\", $month[0]);\n }", "protected function isObjectAccessorMode() {}", "public abstract function FetchArray();", "public function __isset($key)\n {\n }", "public function __isset($key)\n {\n }", "function getArrayProperty($object, $name) {\r\n\r\n\r\n\t}", "function __call($method, $args)//call adodb methods\n\t{\n\t\treturn call_user_func_array(array(self::$instance, $method),$args);\n\t}", "public function offsetGet($index)\n {\n }", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "public function offsetExists($offset) {}", "abstract protected function getDirectGetters();", "public function testOffsetExists()\n {\n $bag = new ArrayAttributeBag('foobar_storageKey');\n\n $bag['foo'] = 'bar';\n\n $this->assertTrue(isset($bag['foo']));\n }", "public function access();", "private function applyArray($arr)\n {\n foreach ($this as $key => $value)\n if (isset($arr[$key]))\n $this->$key = $arr[$key];\n }", "public function offsetSet($name, $value) {\n\t\treturn $this->__set($name, $value);\n\t}", "public static function __set_state(array $_array,$_className = __CLASS__)\n {\n return parent::__set_state($_array, $_className);\n }", "public static function __set_state(array $_array,$_className = __CLASS__)\n {\n return parent::__set_state($_array, $_className);\n }" ]
[ "0.6409956", "0.6113733", "0.5832726", "0.5830618", "0.5809201", "0.56325704", "0.55068314", "0.5501002", "0.5465608", "0.5363119", "0.5363119", "0.53427964", "0.53350675", "0.53321254", "0.5313194", "0.5308811", "0.52941895", "0.52619106", "0.52591", "0.52549654", "0.5221773", "0.5210032", "0.5172746", "0.51706636", "0.5137397", "0.51365685", "0.51349676", "0.51349676", "0.5133913", "0.5079741", "0.50428313", "0.50280285", "0.5025026", "0.50239456", "0.502258", "0.49728146", "0.49384758", "0.4912754", "0.49069038", "0.4906489", "0.49015945", "0.48929912", "0.48923337", "0.48908198", "0.48878497", "0.4876295", "0.4865549", "0.48493505", "0.48488364", "0.48488364", "0.48488364", "0.48252732", "0.48003054", "0.47989872", "0.47989872", "0.47926873", "0.47911736", "0.47911736", "0.47787178", "0.4776369", "0.4763891", "0.47584766", "0.4724459", "0.4721338", "0.4721338", "0.47138178", "0.4713619", "0.4706064", "0.46974182", "0.46759316", "0.46598384", "0.46598384", "0.46572992", "0.46540985", "0.4643084", "0.46416077", "0.46416077", "0.46409765", "0.46409765", "0.46409765", "0.46347675", "0.46208543", "0.46201003", "0.4615492", "0.4615492", "0.46006456", "0.45990562", "0.45982873", "0.45926428", "0.45926428", "0.45926428", "0.45926428", "0.45926428", "0.45926428", "0.45830512", "0.45720834", "0.45711643", "0.45575708", "0.4551312", "0.4540901", "0.4540901" ]
0.0
-1
The ArrayAccess interface provides us with the ability to use an instance of this class as an array. The operations executed with that syntax, are redirected to these methods. I use this for the LVPPlayer class because then I can group all the getters, setters and unsetters into four methods. Invokation of this method will occur when one wants to get a value from this class using the array syntax.
public function offsetGet($mKey) { switch ($mKey) { case 'ID': return $this->m_nId; case 'ProfileID': return $this->m_nProfileId; case 'Nickname': return $this->m_sNickname; case 'Level': return $this->m_nLevel; case 'TempLevel': return $this->m_nTempLevel; case 'IP': return $this->m_sIp; case 'JoinTime': return $this->m_nJoinTime; case 'LogInTime': return $this->m_nLogInTime; } return null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testOrderedQueueArrayAccess_implementation() {\n\t\t\t$this->assertTrue($this->oq InstanceOf \\ArrayAccess);\n\t\t}", "public function get() : array;", "public function get(): array;", "public function get(): array;", "abstract public function getArray();", "public function aArray() {}", "public function __invoke() : array;", "public function __invoke() : array;", "public function it_should_allow_storing_value_using_array_access_api() {\n\t\t$cache = $this->make_instance();\n\n\t\t$this->assertFalse( isset( $cache['foo'] ) );\n\n\t\t$cache['foo'] = 'bar';\n\n\t\t$this->assertTrue( isset( $cache['foo'] ) );\n\t\t$this->assertEquals( 'bar', $cache['foo'] );\n\t}", "public function getInternalArray() {}", "public function getAsArray();", "public function test_get_array_values_from_carrier(): void\n {\n $carrier = [\n 'a' => 'alpha',\n 'b' => ['bravo'],\n ];\n $map = new ArrayAccessGetterSetter();\n $this->assertSame('alpha', $map->get($carrier, 'a'));\n $this->assertSame('bravo', $map->get($carrier, 'b'));\n $this->assertSame(['a', 'b'], $map->keys($carrier));\n }", "public function get(): array\n {\n \n }", "function offsetGet(/*. mixed .*/ $object_){}", "public function offsetGet($offset) {}", "public function offsetGet($offset) {}", "public function offsetGet($offset) {}", "public function get()\n {\n return $this->arr;\n }", "public function getPlayers(): array;", "function get_array(){\n return $this->getArrayCopy();\n }", "function get_array(){\n return $this->getArrayCopy();\n }", "public function asArray()\n {\n }", "function getArray();", "public function asExposedChangedIndexedArray(): array;", "public function AsArray();", "public static function accessible($array)\n {\n return is_array($array) || $array instanceof ArrayAccess;\n }", "public static function accessible($value)\n {\n return is_array($value) || $value instanceof ArrayAccess;\n }", "public function getArray()\n {\n return $this->array;\n }", "public abstract function FetchArray();", "public function getArray(): array\n {\n return $this->array;\n }", "public function getArray(): array\n {\n return $this->array;\n }", "public function offsetGet($offset);", "public function offsetGet($offset);", "public function testSetAndRetrieveArray(): void\n {\n $obj = new \\stdClass;\n $obj->animal = \"Frog\";\n $obj->mineral = \"Quartz\";\n $obj->vegetable = \"Spinach\";\n $arr = array(\n \"testInt\" => 5,\n \"testFloat\" => 3.278,\n \"testString\" => \"WooHoo\",\n \"testBoolean\" => true,\n \"testNull\" => null,\n \"testArray\" => array(1, 2, 3, 4, 5),\n \"testObject\" => $obj\n );\n $key = \"TestArray\";\n $this->testNotStrict->set($key, $arr);\n $a = $this->testNotStrict->get($key);\n $bool = is_array($a);\n $this->assertTrue($bool);\n $this->assertEquals($arr['testInt'], $a['testInt']);\n $this->assertEquals($arr['testFloat'], $a['testFloat']);\n $this->assertEquals($arr['testString'], $a['testString']);\n $this->assertEquals($arr['testBoolean'], $a['testBoolean']);\n $this->assertNull($a['testNull']);\n $this->assertEquals($arr['testArray'], $a['testArray']);\n $this->assertEquals($arr['testObject'], $a['testObject']);\n }", "public function arr()\n {\n return $this->array;\n }", "function test_getArrayById() {\r\n\t\t$rowset = array(array(\"memberClassId\" => 1, \"memberClassName\" => \"reader\"),\r\n\t\t\t\tarray(\"memberClassId\" => 2, \"memberClassName\" => \"nosher\"));\r\n\t\t$myArray = MemberClassesDB::getArray($rowset, \"memberClassId\", \"memberClassName\");\r\n\t\t$this->assertEqual($myArray['1'], \"reader\",\r\n\t\t\t\t\"Should return reader for key of 1 but returned \".$myArray['1']);\r\n\t\t$this->assertEqual($myArray['2'], 'nosher',\r\n\t\t\t\t\"Should return nosher for key of 2 but returned \".$myArray['2']);\r\n\t}", "public function testArrayAccess()\n\t{\n\t\t$book = R::dispense( 'book' );\n\t\t$book->isAwesome = TRUE;\n\t\tasrt( isset( $book->isAwesome ), TRUE );\n\t\t$book = R::dispense( 'book' );\n\t\t$book['isAwesome'] = TRUE;\n\t\tasrt( isset( $book->isAwesome ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['xownPageList'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['ownPageList'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['xownPage'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['ownPage'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['sharedTag'] = R::dispense( 'tag', 2 );\n\t\tasrt( isset( $book->sharedTag ), TRUE );\n\t\tasrt( isset( $book->sharedTagList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['sharedTagList'] = R::dispense( 'tag', 2 );\n\t\tasrt( isset( $book->sharedTag ), TRUE );\n\t\tasrt( isset( $book->sharedTagList ), TRUE );\n\n\t}", "public function testContainerAcceptsArrayAccess()\n {\n $config = $this->getMock('ArrayAccess', ['offsetGet', 'offsetSet', 'offsetUnset', 'offsetExists']);\n $config->expects($this->any())\n ->method('offsetGet')\n ->with($this->equalTo('di'))\n ->will($this->returnValue($this->configArray));\n\n $config->expects($this->any())\n ->method('offsetExists')\n ->with($this->equalTo('di'))\n ->will($this->returnValue(true));\n\n\n $c = new Container($config);\n\n $foo = $c->get('League\\Container\\Test\\Asset\\Foo');\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Foo', $foo);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Bar', $foo->bar);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $foo->bar->baz);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\BazInterface', $foo->bar->baz);\n\n $baz = $c->get('League\\Container\\Test\\Asset\\Baz');\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $foo->baz);\n }", "public function & toArray()\n\t{\n\t\t$x = new ArrayObject($this->data);\n\t\treturn $x;\n\t}", "public function offsetGet($offset)\n {\n }", "public function offsetGet($key): mixed\n {\n if (is_array($this->_data)) {\n return $this->out($this->_data[$key], $key, 'array');\n } elseif ($this->_data instanceof \\ArrayAccess) {\n return $this->out($this->_data[$key], $key, 'array');\n } else {\n throw new \\Exception('Cannot use object of type ' . get_class($this->_data) . ' as array');\n }\n }", "public function asArray() : array\n {\n return $this->a;\n }", "function asArray(){\n\t\t\t$array = $this->toArray( $this );\n\t\t\treturn $array;\n\t\t}", "public function getArray()\n {\n return $this->get(self::_ARRAY);\n }", "abstract public function getAccessRights(): array;", "public function testArrayAccessMapsToCorrectMethods()\n {\n $c = new Container;\n\n $c['League\\Container\\Test\\Asset\\Baz'] = 'League\\Container\\Test\\Asset\\Baz';\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertTrue(isset($c['League\\Container\\Test\\Asset\\Baz']));\n\n unset($c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertFalse(isset($c['League\\Container\\Test\\Asset\\Baz']));\n }", "public function read(): array\n {\n }", "public function read(): array\n {\n }", "public function asArray();", "public function asArray();", "public function asArray();", "public function asArray();", "public function asArray();", "public function asArray();", "function getArrayProperty($object, $name) {\r\n\r\n\r\n\t}", "function set(array $array, $pos = 0){\n foreach($this as $field => $valor){\n if(isset($array[$pos])){\n $this->$field = $array[$pos];\n }\n $pos++;\n }\n }", "public function getArrayCopy() : array;", "function arrayAccessible($value)\n {\n return is_array($value);\n }", "public function offsetGet($offset): mixed;", "public function getAsArray(): array {\n\t\t$result = [];\n\t\tforeach ( self::FIELD_MAPPING as $field => $_ ) {\n\t\t\t$result[$field] = $this->$field;\n\t\t}\n\t\treturn $result;\n\t}", "public static function accessible($value)\n {\n return is_array($value) || $value instanceof ArrayAccess;\n }", "public function toArray() {\n return (array)$this;\n }", "public function offsetGet($offset)\n {\n return $this->$offset;\n }", "public static function isAccessible($value) : bool\n\t{\n\t\treturn is_array($value) || $value instanceof ArrayAccess;\n\t}", "public function getArray() : array {\n return $this->getArrayCopy();\n }", "public function testOffsetGet()\n {\n $bag = new ArrayAttributeBag('foobar_storageKey');\n\n $bag['foo'] = 'bar';\n\n $this->assertSame('bar', $bag['foo']);\n }", "public function get ($index) { return $this[$index]; }", "public static function instanceToArray() : array{\n\n if(!method_exists(self::class,'instance')):\n return [];\n endif;\n\n return self::instance()->toArray();\n }", "public function fetchArray(){\n $this->debugBacktrace();\n $this->fetchType = \"fetch_array\";\n return $this;\n }", "public function testAsArrayAccessArray()\n {\n $month = new Month();\n\n $month[] = \"Zahl 0\";\n $month[] = \"Zahl 1\";\n $month['Name'] = \"Tobias\";\n\n $this->assertArrayHasKey('0', $month);\n $this->assertArrayHasKey('Name', $month);\n\n $this->assertEquals(\"Zahl 0\", $month[0]);\n $this->assertEquals(\"Zahl 1\", $month[1]);\n $this->assertEquals($month['Name'], 'Tobias');\n\n $month[0] = \"Geaendert Zahl 0\";\n $this->assertEquals(\"Geaendert Zahl 0\", $month[0]);\n }", "function get(array $data) {\n\t\t$values = [];\n\t\tforeach ($data as $key) {\n\t\t\t$values[$key] = $this->$key ?? null;\n\t\t}\n\n\t\treturn $values;\n\t}", "public function getArray() {\n\t\treturn $this->data; \n\t}", "public function getArray() {\n\t\treturn $this->data; \n\t}", "public function fetchArray();", "public function fetchArray();", "public function __get($offset)\n {\n }", "abstract protected function getDirectGetters();", "public function get(): array\n {\n return Arr::map(\n $this->query->get(),\n fn($item) => call_user_func($this->class . \"::__createInstanceFromArray\", $item)\n );\n }", "public function testArrayAccess() {\n\t\t$session = $this->getSession();\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set for new empty session');\n\t\t$this->assertNull($session['test'], 'Not set key is not null');\n\t\t$session['test'] = 'testValue';\n\t\t$this->assertTrue(isset($session['test']), 'Test key is not set');\n\t\t$this->assertSame('testValue', $session['test'], 'Test key is not correctly set');\n\t\tunset($session['test']);\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set after deleting');\n\t\t$this->assertNull($session['test'], 'Deleted key is not null');\n\t}", "function offsetGet(/*. mixed .*/ $offset){}", "final public function offsetGet($offset)\n\t{\n\t\treturn $this->__get($offset);\n\t}", "public function as_array()\n {\n $this->return_as = 'array';\n return $this;\n }", "public static function accessible( $value ): bool {\n\t\t\treturn is_array( $value ) || $value instanceof ArrayAccess;\n\t\t}", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetGet($offset)\n {\n }", "function getArrayCopy() : array;", "public function offsetGet($offset)\n {\n return $this->$offset;\n\n }", "public static function accessible($value)\n {\n return is_array($value) || $value instanceof \\ArrayAccess;\n }", "public function read(): array;", "public function getArrayParameters(): array;", "public function asExposedIndexedArray(string ...$properties): array;", "public function __get($name){\r\n\t\tif(array_key_exists($name,$this->array)){\r\n\t\t\treturn $array[$name];\r\n\t\t/* check property is available */\t\r\n\t\t}else if(property_exists($this, $name)){\r\n\t\t return $this->$name;\r\n\t\t}else{\r\n\t\t\treturn \"Trying to access not existing variable : $name<br/>\";\r\n\t\t}\r\n\t}", "public function getArray()\n\t{\n\t\treturn $this->row;\n\t}", "function test_getArrayByName() {\r\n\t\t$rowset = array(array(\"memberClassId\" => 1, \"memberClassName\" => \"reader\"),\r\n\t\t\t\tarray(\"memberClassId\" => 2, \"memberClassName\" => \"nosher\"));\r\n\t\t$myArray = MemberClassesDB::getArray($rowset, \"memberClassName\", \"memberClassId\");\r\n\t\t$this->assertEqual($myArray['reader'], 1, \r\n\t\t \"Should return 1 for key of reader but returned \".$myArray['reader']);\r\n\t\t$this->assertEqual($myArray['nosher'], 2,\r\n\t\t\t\t\"Should return 2 for key of nosher but returned \".$myArray['nosher']);\r\n\t}", "public function &getArrayReference()\n {\n return $this->array;\n }", "public function offsetGet($name) {\n\t\treturn $this->__get($name);\n\t}", "public static function getters();", "protected function getDataArray() {\n trace('[METHOD] '.__METHOD__);\n\n\t\t$dataArray = array();\n\n\t\tforeach (get_class_vars( __CLASS__ ) as $propertyname => $pvalue) {\n\t\t\t$getter = 'get_'.$propertyname;\n\t\t\t$dataArray[$propertyname] = $this->$getter();\n\t\t}\n\n\t\treturn $dataArray;\n\t}" ]
[ "0.61570406", "0.6017318", "0.5950978", "0.5950978", "0.58923507", "0.58669084", "0.5779238", "0.5779238", "0.56780595", "0.56087697", "0.5581294", "0.556501", "0.55570287", "0.5553803", "0.55170715", "0.55170715", "0.5515122", "0.55145276", "0.547867", "0.54524046", "0.54524046", "0.5422309", "0.54082805", "0.5391884", "0.5383986", "0.53711545", "0.53674215", "0.5276923", "0.5274135", "0.5273682", "0.5273682", "0.5262601", "0.5262601", "0.5254658", "0.52502674", "0.5230032", "0.5219908", "0.52039915", "0.5203763", "0.5194917", "0.5187718", "0.51865166", "0.51725614", "0.5168641", "0.5153493", "0.5148532", "0.51409596", "0.51409596", "0.51389337", "0.51389337", "0.51389337", "0.51389337", "0.51389337", "0.51389337", "0.51302195", "0.51267344", "0.51121765", "0.51108676", "0.5105333", "0.5100179", "0.5088506", "0.508446", "0.50776887", "0.5055611", "0.5054381", "0.50436205", "0.50392574", "0.5036266", "0.50316364", "0.50167024", "0.50134206", "0.5005787", "0.5005787", "0.50038046", "0.50038046", "0.50027496", "0.5000596", "0.49963543", "0.49938926", "0.49930504", "0.49899304", "0.4985598", "0.4983553", "0.49824452", "0.49824452", "0.4981733", "0.4981733", "0.4981733", "0.49792483", "0.49778923", "0.49747425", "0.49721298", "0.49646473", "0.49575177", "0.4947347", "0.4945212", "0.49405512", "0.49404976", "0.49225503", "0.4919065", "0.49172837" ]
0.0
-1
The ArrayAccess interface provides us with the ability to use an instance of this class as an array. The operations executed with that syntax, are redirected to these methods. I use this for the LVPPlayer class because then I can group all the getters, setters and unsetters into four methods. This method will be invoked when an index on this class has been set using the array syntax.
public function offsetSet($mKey, $mValue) { switch ($mKey) { case 'ID': $this->m_nId = (int) $mValue; break; case 'ProfileID': $this->m_nProfileId = (int) $mValue; break; case 'Nickname': $this->m_sNickname = (string) $mValue; break; case 'Level': $this->m_nLevel = (int) $mValue; break; case 'TempLevel': $this->m_nTempLevel = (int) $mValue; break; case 'IP': $this->m_sIp = (string) $mValue; break; case 'JoinTime': $this->m_nJoinTime = (int) $mValue; break; case 'LogInTime': $this->m_nLogInTime = (int) $mValue; break; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testOrderedQueueArrayAccess_implementation() {\n\t\t\t$this->assertTrue($this->oq InstanceOf \\ArrayAccess);\n\t\t}", "function set(array $array, $pos = 0){\n foreach($this as $field => $valor){\n if(isset($array[$pos])){\n $this->$field = $array[$pos];\n }\n $pos++;\n }\n }", "public function asExposedChangedIndexedArray(): array;", "public function it_should_allow_storing_value_using_array_access_api() {\n\t\t$cache = $this->make_instance();\n\n\t\t$this->assertFalse( isset( $cache['foo'] ) );\n\n\t\t$cache['foo'] = 'bar';\n\n\t\t$this->assertTrue( isset( $cache['foo'] ) );\n\t\t$this->assertEquals( 'bar', $cache['foo'] );\n\t}", "public function aArray() {}", "public function __invoke() : array;", "public function __invoke() : array;", "function setArray( array $storearray ) {\n$this->array = $storearray;\n}", "public function test_get_array_values_from_carrier(): void\n {\n $carrier = [\n 'a' => 'alpha',\n 'b' => ['bravo'],\n ];\n $map = new ArrayAccessGetterSetter();\n $this->assertSame('alpha', $map->get($carrier, 'a'));\n $this->assertSame('bravo', $map->get($carrier, 'b'));\n $this->assertSame(['a', 'b'], $map->keys($carrier));\n }", "function offsetSet(/*. mixed .*/ $object_, /*. mixed .*/ $info){}", "public function testArrayAccessMapsToCorrectMethods()\n {\n $c = new Container;\n\n $c['League\\Container\\Test\\Asset\\Baz'] = 'League\\Container\\Test\\Asset\\Baz';\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertTrue(isset($c['League\\Container\\Test\\Asset\\Baz']));\n\n unset($c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertFalse(isset($c['League\\Container\\Test\\Asset\\Baz']));\n }", "public function offsetSet($offset, $value) \n {\n }", "public function testAsArrayAccessArray()\n {\n $month = new Month();\n\n $month[] = \"Zahl 0\";\n $month[] = \"Zahl 1\";\n $month['Name'] = \"Tobias\";\n\n $this->assertArrayHasKey('0', $month);\n $this->assertArrayHasKey('Name', $month);\n\n $this->assertEquals(\"Zahl 0\", $month[0]);\n $this->assertEquals(\"Zahl 1\", $month[1]);\n $this->assertEquals($month['Name'], 'Tobias');\n\n $month[0] = \"Geaendert Zahl 0\";\n $this->assertEquals(\"Geaendert Zahl 0\", $month[0]);\n }", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function offsetSet($offset, $value) {}", "public function testArrayAccess() {\n\t\t$session = $this->getSession();\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set for new empty session');\n\t\t$this->assertNull($session['test'], 'Not set key is not null');\n\t\t$session['test'] = 'testValue';\n\t\t$this->assertTrue(isset($session['test']), 'Test key is not set');\n\t\t$this->assertSame('testValue', $session['test'], 'Test key is not correctly set');\n\t\tunset($session['test']);\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set after deleting');\n\t\t$this->assertNull($session['test'], 'Deleted key is not null');\n\t}", "public static function accessible($array)\n {\n return is_array($array) || $array instanceof ArrayAccess;\n }", "public function asExposedIndexedArray(string ...$properties): array;", "public function testArrayAccess()\n\t{\n\t\t$book = R::dispense( 'book' );\n\t\t$book->isAwesome = TRUE;\n\t\tasrt( isset( $book->isAwesome ), TRUE );\n\t\t$book = R::dispense( 'book' );\n\t\t$book['isAwesome'] = TRUE;\n\t\tasrt( isset( $book->isAwesome ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['xownPageList'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['ownPageList'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['xownPage'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['ownPage'] = R::dispense( 'page', 2 );\n\t\tasrt( isset( $book->ownPage ), TRUE );\n\t\tasrt( isset( $book->xownPage ), TRUE );\n\t\tasrt( isset( $book->ownPageList ), TRUE );\n\t\tasrt( isset( $book->xownPageList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['sharedTag'] = R::dispense( 'tag', 2 );\n\t\tasrt( isset( $book->sharedTag ), TRUE );\n\t\tasrt( isset( $book->sharedTagList ), TRUE );\n\n\t\t$book = R::dispense( 'book' );\n\t\t$book['sharedTagList'] = R::dispense( 'tag', 2 );\n\t\tasrt( isset( $book->sharedTag ), TRUE );\n\t\tasrt( isset( $book->sharedTagList ), TRUE );\n\n\t}", "public function testSetAndRetrieveArray(): void\n {\n $obj = new \\stdClass;\n $obj->animal = \"Frog\";\n $obj->mineral = \"Quartz\";\n $obj->vegetable = \"Spinach\";\n $arr = array(\n \"testInt\" => 5,\n \"testFloat\" => 3.278,\n \"testString\" => \"WooHoo\",\n \"testBoolean\" => true,\n \"testNull\" => null,\n \"testArray\" => array(1, 2, 3, 4, 5),\n \"testObject\" => $obj\n );\n $key = \"TestArray\";\n $this->testNotStrict->set($key, $arr);\n $a = $this->testNotStrict->get($key);\n $bool = is_array($a);\n $this->assertTrue($bool);\n $this->assertEquals($arr['testInt'], $a['testInt']);\n $this->assertEquals($arr['testFloat'], $a['testFloat']);\n $this->assertEquals($arr['testString'], $a['testString']);\n $this->assertEquals($arr['testBoolean'], $a['testBoolean']);\n $this->assertNull($a['testNull']);\n $this->assertEquals($arr['testArray'], $a['testArray']);\n $this->assertEquals($arr['testObject'], $a['testObject']);\n }", "public function offsetGet($offset) {}", "public function offsetGet($offset) {}", "public function offsetGet($offset) {}", "function setValues($array){\r\n\t\tforeach($array as $key => $val)\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t}", "public function offsetSet($key, $value) {}", "abstract public function getArray();", "public function setArray($array){\n $this->array=$array;\n }", "public /*void*/ function offsetSet(/*scalar*/ $offset, /*mixed*/ $value){}", "function set(array $array){\n foreach($this as $atributo => $valor){\n if(isset($array[$atributo])){\n $this->$atributo = $array[$atributo];\n }\n }\n }", "public function offsetSet($name, $value) {\n\t\treturn call_user_func_array(array('parent', __FUNCTION__), func_get_args()); \n\t}", "public function testOffsetGet()\n {\n $bag = new ArrayAttributeBag('foobar_storageKey');\n\n $bag['foo'] = 'bar';\n\n $this->assertSame('bar', $bag['foo']);\n }", "public function offsetSet($offset, $value)\n {\n $this->$offset = $value;\n }", "public function offsetSet($offset, $value) { }", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "function setValues($array){\r\n\t\tforeach($array as $key => $val){\r\n\t\t\t$key = lcfirst(str_replace(\" \",\"\",ucwords(str_replace(\"_\",\" \",$key))));\r\n\t\t\tif(property_exists($this,$key))\r\n\t\t\t\t$this->$key = $val;\r\n\t\t}\r\n\t}", "public function testContainerAcceptsArrayAccess()\n {\n $config = $this->getMock('ArrayAccess', ['offsetGet', 'offsetSet', 'offsetUnset', 'offsetExists']);\n $config->expects($this->any())\n ->method('offsetGet')\n ->with($this->equalTo('di'))\n ->will($this->returnValue($this->configArray));\n\n $config->expects($this->any())\n ->method('offsetExists')\n ->with($this->equalTo('di'))\n ->will($this->returnValue(true));\n\n\n $c = new Container($config);\n\n $foo = $c->get('League\\Container\\Test\\Asset\\Foo');\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Foo', $foo);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Bar', $foo->bar);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $foo->bar->baz);\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\BazInterface', $foo->bar->baz);\n\n $baz = $c->get('League\\Container\\Test\\Asset\\Baz');\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $foo->baz);\n }", "public function getInternalArray() {}", "public function get() : array;", "function set(array $data) {\n\t\tforeach ($data as $key => $value) {\n\t\t\t$this->$key = $value;\n\t\t}\n\t}", "function offsetGet(/*. mixed .*/ $object_){}", "public function createObjectCanDoSetterInjectionWithArrays() {\n\t\t$someArray = array(\n\t\t\t'foo' => 'bar',\n\t\t\t199 => 837,\n\t\t\t'doo' => TRUE\n\t\t);\n\t\t$someConfigurationProperty = new \\F3\\FLOW3\\Object\\Configuration\\ConfigurationProperty('someProperty', $someArray, \\F3\\FLOW3\\Object\\Configuration\\ConfigurationProperty::PROPERTY_TYPES_STRAIGHTVALUE);\n\t\t$objectConfiguration = new \\F3\\FLOW3\\Object\\Configuration\\Configuration('F3\\FLOW3\\Tests\\Object\\Fixture\\BasicClass');\n\t\t$objectConfiguration->setProperty($someConfigurationProperty);\n\n\t\t$object = $this->objectBuilder->createObject('F3\\FLOW3\\Tests\\Object\\Fixture\\BasicClass', $objectConfiguration);\n\t\t$this->assertEquals($someArray, $object->getSomeProperty(), 'The array has not been setter-injected although it should have been.');\n\t}", "public function get(): array;", "public function get(): array;", "public function offsetSet($offset, $value);", "public function offsetSet($offset, $value);", "public static function __set_state(array $array)\r\n {\r\n return parent::__set_state($array);\r\n }", "public function exchangeArray(array $array)\n {\n $values = get_object_vars($this);\n\n foreach (array_keys($values) as $property) {\n if (array_key_exists($property, $array)) {\n $this->$property = $array[$property];\n }\n }\n }", "public function asArray()\n {\n }", "public static function has_array_access($input)\n {\n }", "public function offsetSet( $key, $value );", "static function __set_state(array $array) {\n\t\t$result = new Users_User();\n\t\tforeach($array as $k => $v)\n\t\t\t$result->$k = $v;\n\t\treturn $result;\n\t}", "public function offsetGet($offset)\n {\n }", "public function offsetGet($index)\n {\n }", "public function offsetSet( $offset, $value ) {\n\t\t// ...\n\t}", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }", "public static function __set_state(array $array)\n {\n return parent::__set_state($array);\n }" ]
[ "0.61857074", "0.5787419", "0.5681084", "0.5657641", "0.5519998", "0.5460095", "0.5460095", "0.54080003", "0.5346019", "0.5345352", "0.52771795", "0.52204114", "0.5209026", "0.520495", "0.52043", "0.52043", "0.52043", "0.519478", "0.5190594", "0.5183983", "0.51739216", "0.51471686", "0.5146775", "0.5146775", "0.5145736", "0.51412964", "0.51268893", "0.5114659", "0.5100412", "0.5096864", "0.50651824", "0.50618976", "0.5050951", "0.50359106", "0.50188917", "0.5007056", "0.5007056", "0.4991792", "0.4968028", "0.496731", "0.49612215", "0.4960809", "0.49475494", "0.49327374", "0.49327374", "0.49281594", "0.49281594", "0.49206406", "0.49178675", "0.49144", "0.4909418", "0.49076894", "0.48790196", "0.4873183", "0.486708", "0.48660463", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916", "0.48651916" ]
0.0
-1
The ArrayAccess interface provides us with the ability to use an instance of this class as an array. The operations executed with that syntax, are redirected to these methods. I use this for the LVPPlayer class because then I can group all the getters, setters and unsetters into four methods. This method gets called when an unset () call has been performed on an array index of this class.
public function offsetUnset($mKey) { switch ($mKey) { case 'ID': $this->m_nId = 0; break; case 'ProfileID': $this->m_nProfileId = 0; break; case 'Nickname': $this->m_sNickname = ''; break; case 'Level': $this->m_nLevel = 0; break; case 'TempLevel': $this->m_nTempLevel = 0; break; case 'IP': $this->m_sIp = ''; break; case 'JoinTime': $this->m_nJoinTime = 0; break; case 'LogInTime': $this->m_nLogInTime = 0; break; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function offsetUnset(/*. mixed .*/ $object_){}", "public /*void*/ function offsetUnset(/*scalar*/ $offset){}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function offsetUnset($offset) {}", "public function testOffsetUnset()\n\t{\n\t\tunset($this->instance[2]);\n\n\t\t$this->assertNull($this->instance[2]);\n\t}", "public function offsetUnset($offset)\n {\n }", "function offsetUnset(/*. mixed .*/ $offset)\n\t\t/*. throws BadMethodCallException .*/ {}", "public function testOrderedQueueArrayAccess_implementation() {\n\t\t\t$this->assertTrue($this->oq InstanceOf \\ArrayAccess);\n\t\t}", "public function offsetUnset($offset);", "public function offsetUnset($offset);", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n {\n unset($this->$offset);\n }", "public function offsetUnset($offset)\n\t{\n\t\tunset($this->$offset);\n\t}", "public function offsetUnset($key)\n {\n }", "public function offsetUnset($offset)\n {\n $method = 'set' . str_replace(\" \", \"\", ucwords(strtr($offset, \"_-\", \" \")));\n if(method_exists($this, $method)){\n $this->$method(null);\n }\n }", "public function testArrayAccessUnsetBadOffset()\r\n\t{\r\n\t\t$this->setExpectedException( 'InvalidArgumentException' );\r\n\t\tunset( $this->list['foo'] );\r\n\t}", "public function testOffsetUnset()\n {\n $bag = new ArrayAttributeBag('foobar_storageKey');\n $bag->set('foo', 'bar');\n\n unset($bag['foo']);\n\n $this->assertFalse($bag->has('foo'));\n }", "public function array_forget()\n {\n throw new Exception('Not implemented');\n }", "public function offsetUnset($index)\n {\n }", "public function offsetUnset(mixed $name) : void\n\t{\n\t\tthrow new Exception(\"Not implemented\");\t\t\n\t}", "public function offsetUnset( $offset ) {\n\t\t// ...\n\t}", "public function offsetUnset($offset)\n {\n parent::offsetUnset($offset);\n $this->performHook('modified');\n }", "public function testArrayAccess() {\n\t\t$session = $this->getSession();\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set for new empty session');\n\t\t$this->assertNull($session['test'], 'Not set key is not null');\n\t\t$session['test'] = 'testValue';\n\t\t$this->assertTrue(isset($session['test']), 'Test key is not set');\n\t\t$this->assertSame('testValue', $session['test'], 'Test key is not correctly set');\n\t\tunset($session['test']);\n\t\t$this->assertFalse(isset($session['test']), 'Test key is set after deleting');\n\t\t$this->assertNull($session['test'], 'Deleted key is not null');\n\t}", "public function offsetUnset($offset) {\n throw new Exception('Not implemented yet');\n }", "public function offsetUnset($offset): void;", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($offset)\n {\n }", "public function offsetUnset($offset)\n\t{\n\t\tunset($this->{$offset});\n\t}", "public function offsetUnset($offset): void\n {\n }", "public function offsetUnset( $key );", "public function testArrayAccessUnsetBadOffset()\r\n\t{\r\n\t\t$this->setExpectedException( 'OutOfBoundsException' );\r\n\t\tunset( $this->list['foo'] );\r\n\t}", "public function offsetUnset($index);", "public function offsetUnset($offset)\n {\n unset($this->getValue()[$offset]);\n }", "public function useArrayUnShift()\n {\n $this->push = false;\n return $this;\n }", "public function testArrayAccessMapsToCorrectMethods()\n {\n $c = new Container;\n\n $c['League\\Container\\Test\\Asset\\Baz'] = 'League\\Container\\Test\\Asset\\Baz';\n\n $this->assertInstanceOf('League\\Container\\Test\\Asset\\Baz', $c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertTrue(isset($c['League\\Container\\Test\\Asset\\Baz']));\n\n unset($c['League\\Container\\Test\\Asset\\Baz']);\n\n $this->assertFalse(isset($c['League\\Container\\Test\\Asset\\Baz']));\n }", "public function offsetUnset($offset) {\n return;\n }", "public function offsetUnset($key): void;", "public function offsetUnset($offset)\n {\n $this->__unset($offset);\n }", "public function offsetUnset($offset)\n {\n $this->__unset($offset);\n }", "public function offsetUnset($offset)\n {\n $this->__unset($offset);\n }", "function __unset ($key)\n {\n unset ($this->A[$key]);\n }", "public function offsetUnset($key)\n\t{\n\t\t$this->updating();\n\t\tunset($this->array[$key]);\n\t}", "public function testOffsetUnset()\n {\n $struct = $this->_newStruct();\n $this->assertTrue($struct->offsetExists('foo'));\n $struct->offsetUnset('foo');\n $this->assertFalse($struct->offsetExists('foo'));\n }", "public /*void*/ function offsetUnset(/*scalar*/ $offset)\n\t{\n\t\tif(isset($this->_data[$offset]))\n\t\t\tunset($this->_data[$offset]);\n\t}", "public function offsetUnset($name) {\n\t\treturn call_user_func_array(array('parent', __FUNCTION__), func_get_args()); \n\t}", "public function asExposedChangedIndexedArray(): array;", "public function offsetUnset(mixed $offset): void\n {\n if (Arr::accessible($this->value)) {\n unset($this->value[$offset]);\n }\n }", "public function offsetUnset($offset)\n\t{\n\t\t// TODO: Implement offsetUnset() method.\n\t}", "public function offsetUnset($offset)\n {\n $this->clear($offset);\n }", "function offsetUnset($offset) {\n $property = defined('static::$DOMAIN_PROPERTY') ? static::$DOMAIN_PROPERTY : 'data';\n \n unset($this->{$property}[$offset]);\n }", "public function offsetUnset($offset)\n\t{\n\t\tif(isset(self::$arrayMap[$offset])) {\n\t\t\t$this->{self::$arrayMap[$offset]} = null;\n\t\t}\n\t}", "public function test__unset()\n {\n $struct = $this->_newStruct();\n unset($struct->foo);\n $this->assertFalse(isset($struct->foo));\n try {\n $invalid = $struct->foo;\n $this->fail('Should have thrown a NO_SUCH_PROPERTY exception.');\n } catch (Solar_Exception_NoSuchProperty $e) {\n // pass\n }\n \n $struct = $this->_newStruct();\n unset($struct['foo']);\n $this->assertFalse(isset($struct['foo']));\n try {\n $invalid = $struct['foo'];\n $this->fail('Should have thrown a NO_SUCH_PROPERTY exception.');\n } catch (Solar_Exception_NoSuchProperty $e) {\n // pass\n }\n }", "public function offsetUnset($offset)\n {\n $this->unset($offset);\n }", "public function offsetUnset($offset)\n {\n $this->unset($offset);\n }", "public function offsetUnset($offset)\n\t{\n\t\t$this->remove($offset);\n\t}", "public function offsetUnset($offset)\n\t{\n\t\t$this->remove($offset);\n\t}", "public function offsetUnset ($offset)\n {\n unset($this->elements[$offset]);\n }", "public function offsetUnset($offset): void\n {\n unset($this->array[$offset]);\n }", "public function offsetUnset($name)\n\t{\n\t\t$this->remove ( $name );\n\t}", "public function offsetUnset($offset)\n {\n unset($this->channels[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->_data[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->_data[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->data[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->data[$offset]);\n }", "public function offsetUnset($offset) {\n $this->remove(array($offset));\n }", "public function offsetUnset($offset)\n {\n\n // unset gibt es nicht, nur set null\n if (isset($this->data[$offset])) {\n $this->synchronized = false;\n $this->data[$offset] = null;\n }\n\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($key)\n {\n unset($this->data[$key]);\n }", "public function offsetUnset($offset)\n\t{\n\t\tunset($this->properties[$offset]);\n\t}", "public function offsetUnset($offset)\n\t{\n\t\t$this->store()->offsetUnset($offset);\n\t}", "public function testNoArrayMetaAccess()\n\t{\n\t\t$bean = R::dispense( 'bean' );\n\t\t$bean->setMeta( 'greet', 'hello' );\n\t\tasrt( isset( $bean['greet'] ), FALSE );\n\t\tasrt( isset( $bean['__info']['greet'] ), FALSE );\n\t\tasrt( isset( $bean['__info'] ), FALSE );\n\t\tasrt( isset( $bean['meta'] ), FALSE );\n\t\tasrt( count( $bean ), 1 );\n\t}", "public function __destruct() {\n\t\tforeach ($this as $index => $value) unset($this->$index);\n\t}", "public function __invoke() : array;", "public function __invoke() : array;", "public function offsetUnset(mixed $name): void\n {\n $this->remove($name);\n }", "public /*void*/ function __unset(/*scalar*/ $key){}", "public function offsetUnset($name) {\n\t\tunset($this->session[$name]);\n\t\tunset($_SESSION[$name]);\n\t}", "public function offsetUnset($offset)\n {\n unset($this->container[$offset]);\n }", "public function offsetUnset($offset)\n {\n unset($this->item[$offset]);\n }", "public function offsetUnset($offset) {\n\t\tunset($this->pile[$offset]);\n\t}", "public function offsetUnset($name)\n {\n if (array_key_exists($name, $this->values)) {\n unset($this->values[$name], $this->raw[$name], $this->factories[$name]);\n }\n }", "public function offsetUnset($key)\n\t{\n\t\tthrow new \\RuntimeException('Unsupported operation');\n\t}", "public function offsetUnset($offset): void\n {\n throw new LogicException('Response data may not be mutated using array access.');\n }", "public function offsetUnset($key)\n {\n $this->propertyUnset($key);\n }", "public function offsetUnset($index):void {\n\tunset($this->_elArray[$index]);\n\t$this->_elArray = array_values($this->_elArray);\n}", "public function offsetUnset($offset){\n\t\t$this->set($offset, null);\n\t}", "public function offsetUnset($offset)\r\n {\r\n throw new \\BadMethodCallException(\"Immutable stack, cannot set element\");\r\n }", "#[\\ReturnTypeWillChange]\n public function offsetUnset($key)\n {\n $this->forget($key);\n }", "public function offsetUnset($offset)\n {\n unset($this->array[$offset]);\n return $this;\n }", "public function __unset($offset): void\n {\n $this->offsetUnset($offset);\n }" ]
[ "0.6390194", "0.607227", "0.5974607", "0.5974607", "0.5974353", "0.5974353", "0.5974353", "0.59048873", "0.5781954", "0.5769117", "0.56869286", "0.5686396", "0.5686396", "0.5677141", "0.5677141", "0.5677141", "0.5677141", "0.5677141", "0.5677141", "0.5677141", "0.5677141", "0.5657871", "0.5628912", "0.56003654", "0.55826503", "0.5569693", "0.5545292", "0.5525922", "0.55129313", "0.54798967", "0.5478441", "0.54647994", "0.5445053", "0.5401013", "0.5385059", "0.53846365", "0.53846365", "0.53846365", "0.53846365", "0.5383076", "0.5381543", "0.53743553", "0.53651005", "0.5359259", "0.53465873", "0.5344519", "0.533877", "0.532794", "0.5319683", "0.53154194", "0.53154194", "0.53154194", "0.53076947", "0.53035", "0.52863365", "0.52845895", "0.52612495", "0.52611965", "0.5254033", "0.5248318", "0.5211744", "0.5192199", "0.5190022", "0.5188149", "0.5184202", "0.5184202", "0.5183658", "0.5183658", "0.5181426", "0.5180157", "0.51659995", "0.5157461", "0.51545405", "0.51545405", "0.5148755", "0.5148755", "0.51431555", "0.5141822", "0.5141377", "0.5140205", "0.5133652", "0.51246023", "0.51197577", "0.5104807", "0.5104807", "0.5096558", "0.50962174", "0.5092972", "0.50905937", "0.50893754", "0.50885504", "0.5079307", "0.5076585", "0.5075665", "0.50755143", "0.50738", "0.50537825", "0.5034893", "0.5034558", "0.5033433", "0.50327325" ]
0.0
-1
Initialize the units post type
function __construct() { add_action( 'init', array( $this, 'init_post_type' ) ); // Setup the custom columns for the CPT add_filter( 'manage_edit-units_columns', array( $this, 'edit_units_columns' ) ); add_action( 'manage_units_posts_custom_column', array( $this, 'manage_units_columns' ) ); add_filter( 'manage_edit-units_sortable_columns', array( $this, 'units_sortable_columns' ) ); add_filter( 'request', array( $this, 'sort_units' ) ); // Setup metaboxes add_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) ); add_action( 'save_post', array( $this, 'save_unit_meta_boxes' ) ); // Add custom messages add_filter( 'post_updated_messages', array( $this, 'updated_messages' ) ); // Load default templates add_filter( 'template_include', array( $this, 'load_templates' ) ); // Load frontend styles/scripts add_action( 'init', array( $this, 'load_scripts') ); add_action( 'init', array( $this, 'load_styles' ) ); // Load backend styles/scripts add_action('admin_print_scripts', array( $this, 'load_admin_scripts' ) ); add_action('admin_print_styles', array( $this, 'load_admin_styles' ) ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function init_post_type() {\n\n\t\t$labels = array(\n\t\t\t'name' => _x( 'Unit', 'Post Type General Name', 'wppm' ),\n\t\t\t'singular_name' => _x( 'Unit', 'Post Type Singular Name', 'wppm' ),\n\t\t\t'menu_name' => __( 'Units', 'wppm' ),\n\t\t\t'parent_item_colon' => __( 'Parent Item:', 'wppm' ),\n\t\t\t'all_items' => __( 'All Units', 'wppm' ),\n\t\t\t'view_item' => __( 'View Unit', 'wppm' ),\n\t\t\t'add_new_item' => __( 'Add New Unit', 'wppm' ),\n\t\t\t'add_new' => __( 'Add New', 'wppm' ),\n\t\t\t'edit_item' => __( 'Edit Unit', 'wppm' ),\n\t\t\t'update_item' => __( 'Update Unit', 'wppm' ),\n\t\t\t'search_items' => __( 'Search Units', 'wppm' ),\n\t\t\t'not_found' => __( 'Not found', 'wppm' ),\n\t\t\t'not_found_in_trash' => __( 'Not found in Trash', 'wppm' ),\n\t\t);\n\t\t$args = array(\n\t\t\t'label' => __( 'units', 'wppm' ),\n\t\t\t'description' => __( 'Units', 'wppm' ),\n\t\t\t'labels' => $labels,\n\t\t\t'supports' => array( 'title', 'thumbnail', ),\n\t\t\t'hierarchical' => false,\n\t\t\t'public' => true,\n\t\t\t'show_ui' => true,\n\t\t\t'show_in_menu' => true,\n\t\t\t'show_in_nav_menus' => true,\n\t\t\t'show_in_admin_bar' => true,\n\t\t\t'menu_position' => 5,\n\t\t\t//'menu_icon' => '',\n\t\t\t'can_export' => true,\n\t\t\t'has_archive' => true,\n\t\t\t'exclude_from_search' => false,\n\t\t\t'publicly_queryable' => true,\n\t\t\t'capability_type' => 'post',\n\t\t);\n\t\tregister_post_type( 'units', $args );\n\t\tflush_rewrite_rules();\n\t\t\n\t\tadd_image_size( 'tiles-featured', 225, 225, true );\n\t\tadd_image_size( 'mini-tiles', 80, 55, true );\n\t}", "function register_post_type_unit(){\n\n\n\t\t$labels = array(\n\t\t\t\t\t\t'name' => _x('Unit', 'post type general name'),\n\t\t\t\t\t\t'singular_name' => _x('Unit', 'post type singular name'),\n\t\t\t\t\t\t'add_new' => _x('Add New', 'unit'),\n\t\t\t\t\t\t'add_new_item' => __('Add New '),\n\t\t\t\t\t\t'edit_item' => __('Edit '),\n\t\t\t\t\t\t'new_item' => __('New '),\n\t\t\t\t\t\t'all_items' => __('All Units'),\n\t\t\t\t\t\t'view_item' => __('View Unit'),\n\t\t\t\t\t\t'search_items' => __('Search Units'),\n\t\t\t\t\t\t'not_found' => __('No Units found'),\n\t\t\t\t\t\t'not_found_in_trash' => __('No Units found in Trash'),\n\t\t\t\t\t\t'parent_item_colon' => '',\n\t\t\t\t\t\t'menu_name' => __('Unit'),\n\t\t\t\t\t\t'has_archive' => false\n\n\t\t\t\t\t\t);\n\n\t$args = array(\n\t\t\t\t\t'labels' => $labels,\n\t\t\t\t\t'public' => true,\n\t\t\t\t\t'publicly_queryable' => true,\n\t\t\t\t\t'show_ui' => true,\n\t\t\t\t\t'show_in_menu' => true,\n\t\t\t\t\t'query_var' => true,\n\t\t\t\t\t'rewrite' => true,\n\t\t\t\t\t'capability_type' => 'post',\n\t\t\t\t\t'has_archive' => true,\n\t\t\t\t\t'hierarchical' => false,\n\t\t\t\t\t'menu_position' => null, \n\t\t\t\t\t'supports' => array( 'title', 'editor', 'thumbnail')\n\t\t\t\t);\n\n\n\tregister_post_type( 'unit', $args);\n\n\n\t\t// Add new taxonomy, make it hierarchical (like categories)\n\t$labels = array(\n\t\t\t\t\t'name' => _x( 'Unit Type', 'taxonomy general name' ),\n\t\t\t\t\t'singular_name' => _x( 'Unit Type', 'taxonomy singular name' ),\n\t\t\t\t\t'search_items' => __( 'Search Unit Types' ),\n\t\t\t\t\t'all_items' => __( 'All Unit Types' ),\n\t\t\t\t\t'parent_item' => __( 'Parent Unit Type' ),\n\t\t\t\t\t'parent_item_colon' => __( 'Parent Unit Type:' ),\n\t\t\t\t\t'edit_item' => __( 'Edit Unit Type' ),\n\t\t\t\t\t'update_item' => __( 'Update Unit Type' ),\n\t\t\t\t\t'add_new_item' => __( 'Add New Unit Type' ),\n\t\t\t\t\t'new_item_name' => __( 'New Unit Type Name' ),\n\t\t\t\t\t'menu_name' => __( 'Unit Type' ),\n\t\t\t\t\t);\n\n\tregister_taxonomy( 'unit_type',array('unit'), array(\n\t\t\t\t\t'hierarchical' => false,\n\t\t\t\t\t'labels' => $labels,\n\t\t\t\t\t'show_ui' => true,\n\t\t\t\t\t'query_var' => true,\n\t\t\t\t\t'rewrite' => array( 'slug' => 'unit'),\n\t\t\t\t\t));\n $labels = array(\n 'name' => _x( 'Building', 'taxonomy general name' ),\n 'singular_name' => _x( 'Building', 'taxonomy singular name' ),\n 'search_items' => __( 'Search Unit Buildings' ),\n 'all_items' => __( 'All Buildings' ),\n 'parent_item' => __( 'Parent Building' ),\n 'parent_item_colon' => __( 'Parent Building:' ),\n 'edit_item' => __( 'Edit Building' ),\n 'update_item' => __( 'Update Building' ),\n 'add_new_item' => __( 'Add New Building' ),\n 'new_item_name' => __( 'New Building Name' ),\n 'menu_name' => __( 'Building' ),\n );\n\n register_taxonomy( 'building',array('unit'), array(\n 'hierarchical' => true,\n 'labels' => $labels,\n 'show_ui' => true,\n 'query_var' => true,\n 'rewrite' => array( 'slug' => 'unit'),\n ));\n}", "function Units($args=array())\n {\n $this->Hash2Object($args);\n $this->AlwaysReadData=array(\"Name\");\n $this->Sort=array(\"Name\");\n $this->IDGETVar=\"Unit\";\n $this->UploadFilesHidden=FALSE;\n }", "public static function cpt_init() {\n\t\tforeach ( self::$types as $type ) {\n\t\t\tself::evo_custom_post_type( $type['type'] );\n\t\t}\n\t}", "public function slate_post_type_init() {\n\n new Slate_Post_Type('Characters', array(\n 'has_archive' => true,\n 'rewrite' => array(\n 'with_front' => false,\n 'slug' => 'characters'\n )\n ));\n\n new Slate_Post_Type('Items', array(\n 'has_archive' => true,\n 'rewrite' => array(\n 'with_front' => false,\n 'slug' => 'items'\n )\n ));\n\n new Slate_Post_Type('Games', array(\n 'has_archive' => true,\n 'rewrite' => array(\n 'with_front' => false,\n 'slug' => 'game-library'\n )\n ));\n\n }", "public function init()\n \t{\n \t\t// Initialize Post Type\n \t\t$this->create_post_type();\n \t\tadd_action('save_post', array($this, 'save_post'));\n \t}", "public function init()\n \t{\n \t\t// Initialize Post Type\n \t\t$this->create_post_type();\n \t\tadd_action('save_post', array(&$this, 'save_post'));\n \t}", "public function setUnits($units)\n {\n $this->units = $units;\n }", "public function __construct(){\n\n\t\tparent::setUnits($this->bytesUnits);\n\t}", "public function __construct()\n\t{\n\t\t$this->type('post');\n\t}", "public static function init() {\n\t\tadd_action( 'init', array( __CLASS__, 'register_post_type' ), 1 );\n\t}", "public static function __setUnits($units){\r\n self::$_units[] = $units;\r\n return $units;\r\n }", "public function __construct() {\n\t\t\tadd_action( 'init', array( &$this, 'register_post_type' ) );\n\t\t}", "public function initPostType(){\n\t\tforeach( $this->posttype as $pt ){\n\t\t\t$pt = WPO_FRAMEWORK_POSTTYPE.$pt.'.php';\n\t\t\tif( is_file($pt) ){\n\t\t\t\trequire_once($pt);\n\t\t\t}\n\t\t}\n\t}", "function __construct() {\n\n\t\t$this->ID = 'example';\n\n\t\t$this->singlename = 'Post Type';\n\t\t$this->pluralname = 'Post Types';\n\n\t\t$this->args = array(\n\t\t\t'taxonomies' => array('category')\n\t\t);\n\n\t\tparent::__construct();\n\n\t}", "public function __construct($unit = '') {\n $this->init();\n $this->exp = $this->unitExp($unit);\n }", "function initialize() {\n\t\t$this->number = 1;\n\t\t$this->post_types = array();\n\t\t$this->widget_form_fields = array();\n\n\t\tadd_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );\n\t\tadd_action( 'save_post', array( $this, 'save_widget_post_meta' ), 10, 3 );\n\t}", "public static function ppInit()\n\t{\n\t\tself::$definition['fields'] = array_merge(self::$definition['fields'], array(\n\t\t\t'minimal_quantity' => array('type' => self::TYPE_INT, 'shop' => true, 'validate' => 'validateProductQuantity'), \t\t\t'minimal_quantity_fractional' => array('type' => self::TYPE_FLOAT, 'shop' => true, 'validate' => 'isUnsignedFloat')\n\t\t));\n\t}", "function __construct(){\n\t\t\tadd_action( 'init' , array( $this, 'custom_post_type' ) );\n\t\t}", "private function initCustomPostType(){\n //Instantiate our custom post type object\n $this->cptWPDS = new PostType($this->wpdsPostType);\n \n //Set our custom post type properties\n $this->cptWPDS->setSingularName($this->wpdsPostTypeName);\n $this->cptWPDS->setPluralName($this->wpdsPostTypeNamePlural);\n $this->cptWPDS->setMenuName($this->wpdsPostTypeNamePlural);\n $this->cptWPDS->setLabels('Add New', 'Add New '.$this->wpdsPostTypeName, 'Edit '.$this->wpdsPostTypeName, 'New '.$this->wpdsPostTypeName, 'All '.$this->wpdsPostTypeNamePlural, 'View '.$this->wpdsPostTypeNamePlural, 'Search '.$this->wpdsPostTypeNamePlural, 'No '.strtolower($this->wpdsPostTypeNamePlural).' found', 'No '.strtolower($this->wpdsPostTypeNamePlural).' found in the trash');\n $this->cptWPDS->setMenuIcon('dashicons-welcome-write-blog');\n $this->cptWPDS->setSlug($this->wpdsPostType);\n $this->cptWPDS->setDescription('Writings from the universe');\n $this->cptWPDS->setShowInMenu(true);\n $this->cptWPDS->setPublic(true);\n $this->cptWPDS->setTaxonomies([$this->wpdsPostType]);\n $this->cptWPDS->removeSupports(['title']);\n \n //Register custom post type\n $this->cptWPDS->register();\n }", "public function init_post_type() {\n\t\t\t\n\t\t\t$labels = array(\n\t\t\t\t'name'\t\t\t\t=> 'Meetups',\n\t\t\t\t'new_item'\t\t\t=> 'Neues Meetup',\n\t\t\t\t'singular_name'\t\t=> 'Meetup',\n\t\t\t\t'view_item'\t\t\t=> 'Zeige Meetups',\n\t\t\t\t'edit_item'\t\t\t=> 'Editiere Meetup',\n\t\t\t\t'add_new_item'\t\t=> 'Meetup hinzuf&uuml;gen',\n\t\t\t\t'not_found'\t\t\t=> 'Kein Meetup gefunden',\n\t\t\t\t'search_items'\t\t=> 'Durchsuche Meetups',\n\t\t\t\t'parent_item_colon' => ''\n\t\t\t);\n\t\t\t\n\t\t\t$supports = array(\n\t\t\t\t'title',\n\t\t\t\t'editor',\n\t\t\t\t'comments',\n\t\t\t);\n\t\t\t\n\t\t\t$args = array(\n\t\t\t\t'public'\t\t\t\t=> TRUE,\n\t\t\t\t'publicly_queryable'\t=> TRUE,\n\t\t\t\t'show_ui'\t\t\t\t=> TRUE, \n\t\t\t\t'query_var'\t\t\t\t=> TRUE,\n\t\t\t\t'capability_type'\t\t=> 'post',\n\t\t\t\t'hierarchical'\t\t\t=> FALSE,\n\t\t\t\t'menu_position'\t\t\t=> NULL,\n\t\t\t\t'supports'\t\t\t\t=> $supports,\n\t\t\t\t'has_archive'\t\t\t=> TRUE,\n\t\t\t\t'rewrite'\t\t\t\t=> TRUE,\n\t\t\t\t'labels'\t\t\t\t=> $labels\n\t\t\t);\n\t\t\t\n\t\t\tregister_post_type( 'wpmeetups', $args );\n\t\t}", "public function __construct()\n {\n // Metres, Centimetres, Millimetres, Yards, Foot, Inches\n $conversions = array(\n 'Weight' => array(\n 'base' => 'kg',\n 'conv' => array(\n 'g' => 1000,\n 'mg' => 1000000,\n 't' => 0.001,\n 'oz' => 35.274,\n 'lb' => 2.2046,\n )\n ),\n 'Distance' => array(\n 'base' => 'km',\n 'conv' => array(\n 'm' => 1000,\n 'cm' => 100000,\n 'mm' => 1000000,\n 'in' => 39370,\n 'ft' => 3280.8,\n 'yd' => 1093.6\n )\n )\n );\n\n foreach ($conversions as $val) {\n $this->addConversion($val['base'], $val['conv']);\n }\n }", "function init() {\n\n\t\t// Create Post Type\n\t\tadd_action( 'init', array( $this, 'post_type' ) );\n\n\t\t// Post Type columns\n\t\tadd_filter( 'manage_edit-event_columns', array( $this, 'edit_event_columns' ), 20 );\n\t\tadd_action( 'manage_event_posts_custom_column', array( $this, 'manage_event_columns' ), 20, 2 );\n\n\t\t// Post Type sorting\n\t\tadd_filter( 'manage_edit-event_sortable_columns', array( $this, 'event_sortable_columns' ), 20 );\n\t\t//add_action( 'load-edit.php', array( $this, 'edit_event_load' ), 20 );\n\n\t\t// Post Type title placeholder\n\t\tadd_filter( 'enter_title_here', array( $this, 'title_placeholder' ) );\n\n\t\t// Create Metabox\n\t\t$metabox = apply_filters( 'be_events_manager_metabox_override', false );\n\t\tif ( false === $metabox ) {\n\t\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'metabox_styles' ) );\n\t\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'metabox_scripts' ) );\n\t\t\tadd_action( 'add_meta_boxes', array( $this, 'metabox_register' ) );\n\t\t\tadd_action( 'save_post', array( $this, 'metabox_save' ), 1, 2 );\n\t\t}\n\n\t\t// Generate Events\n\t\tadd_action( 'wp_insert_post', array( $this, 'generate_events' ) );\n\t\tadd_action( 'wp_insert_post', array( $this, 'regenerate_events' ) );\n\t}", "protected function _getUnitsPerEm() {}", "public function __construct() {\n\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts' ) );\n\n\t\tadd_shortcode( 'demo-test', array( $this, 'demo_shortcode' ) );\n\n\t\tadd_action( 'init', array( $this, 'register_post_type' ) );\n\n\t\tadd_action( 'init', array( $this, 'generate_custom_post_type' ) );\n\n\t\t//add_action( 'init', array( $this, 'rewrite_rules' ) );\n\n\t\tadd_action( 'template_include', array( $this, 'custom_post_type_archive' ) );\n\n\t\tadd_action( 'template_include', array( $this, 'custom_post_type_archive_template' ) );\n\n\t\tadd_filter( 'single_template', array( $this, 'get_custom_post_type_template' ) );\n\n\t\tadd_action( 'admin_menu', array( $this, 'custom_menu_page' ) );\n\n\t\tadd_action( 'admin_init', array( $this, 'add_options' ) );\n\n\t\tadd_action( 'init', array( $this, 'generate_post_type' ) );\n\n\t\tadd_filter( 'post_type_link', array( $this, 'update_permalinks' ), 10, 2 );\n\t\tadd_filter( 'post_type_link', array( $this, 'update_post_permalinks' ), 10, 2 );\n\n\t\tadd_filter('term_link', array( $this, 'update_term_link' ) );\n\n\t add_action( 'wp_footer', function() {\n\t\t\tglobal $wp_query;\n\t\t\t//print_r( $wp_query );\n\t\t\tprint_r($this->post_types);\n\t\t});\n\t}", "public function __construct() {\n\t\t\t$this->field_type = 'number';\n\n\t\t\tparent::__construct();\n\t\t}", "public function setup() {\n\t\t$data_structures = new Data_Structures();\n\t\t$data_structures->setup();\n\t\t$data_structures->add_post_type( $this->post_type, [\n\t\t\t'singular' => 'Customer',\n\t\t\t'supports' => [ 'title' ],\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'show_in_menu' => true,\n\t\t] );\n\t\tadd_action( \"fm_post_{$this->post_type}\", [ $this, 'init' ] );\n\t}", "public function __construct(){\n //Create our custom taxonomy\n $this->initCustomTaxonomy();\n \n //Create our custom post type\n $this->initCustomPostType();\n \n //Manage our columns for our admin page\n $this->initColumns();\n }", "public function run()\n {\n Type::create([\n 'name' => 'Prototype',\n 'speed' => 60,\n 'fuelUnits' => 10,\n 'milesPerUnit' => 10\n ]);\n Type::create([\n 'name' => 'Normal',\n 'speed' => 40,\n 'fuelUnits' => 20,\n 'milesPerUnit' => 5\n ]);\n Type::create([\n 'name' => 'TransContinental',\n 'speed' => 20,\n 'fuelUnits' => 50,\n 'milesPerUnit' => 30\n ]);\n }", "public function __construct() {\n\n // Register the post type\n add_action('init', [ $this, 'reg_post_type' ] );\n add_action('init', [ $this, 'add_taxonomy' ] );\n add_action('init', [ $this, 'add_tags' ] );\n\n add_action( 'add_meta_boxes', [ $this, 'add_metabox' ], 1 );\n add_action( 'save_post', [ $this, 'save_metabox' ], 10, 2 );\n\n }", "protected function setUp() {\n parent::setUp();\n\n // Get form data.\n $form = new temp_form_duration();\n $this->mform = $form->getform();\n $this->element = $this->mform->addElement('duration', 'duration');\n }", "public function __construct()\n {\n add_action('init', [__CLASS__, 'register_post_types']);\n }", "public function __construct($_quantity, $_productName, $_price, $_type, $_duty)\n {\n //variabili uguali all'input\n $this->quantity = $_quantity;\n $this->productName = $_productName;\n $this->price = $_price;\n\n //usando le funzioni del trait taxes mi trovo le tassazioni e i totali\n $this->salesTax = $this->findTax($_type);\n $this->dutyTax = $this->imported($_duty);\n $this->addNet($this->quantity * $this->price);\n $this->addTaxes($this->computeTaxes($this->quantity, $this->price, $this->salesTax, $this->dutyTax));\n $this->getTotal();\n\n \n }", "public static function init () : void\n {\n add_action(\"init\", function () {\n self::register_post_type();\n });\n }", "private function __construct(){\r\n $this->ttl_by_type = array(\r\n 'short' => 300 , // 5 minutes\r\n 'default' => 7200, // 2 hours\r\n 'halfday' => 43200, // 12 hours\r\n 'day' => 86400, // 24 hours\r\n 'week' => 604800, // 7 days\r\n 'month' => 2592000, // 30 days (1 month)\r\n 'longterm' => 15811200 // 183 days (6 months)\r\n );\r\n }", "public function load_units() {\n\n\t\t// Get our current master list of units.\n\t\t$master_units = $this->get_cahnrs_units();\n\n\t\t// Get our current list of top level units.\n\t\t$current_units = get_terms( $this->cahnrs_units, array( 'hide_empty' => false ) );\n\t\t$current_units = wp_list_pluck( $current_units, 'name' );\n\n\t\tforeach ( $master_units as $unit => $child_units ) {\n\n\t\t\t$parent_id = false;\n\n\t\t\t// If the parent unit is not a term yet, insert it.\n\t\t\tif ( ! in_array( $unit, $current_units ) ) {\n\t\t\t\t$new_term = wp_insert_term( $unit, $this->cahnrs_units, array( 'parent' => 0 ) );\n\t\t\t\t$parent_id = $new_term['term_id'];\n\t\t\t}\n\n\t\t\t// Loop through the parent's children to check term existence.\n\t\t\tforeach( $child_units as $child_unit ) {\n\t\t\t\tif ( ! in_array( $child_unit, $current_units ) ) {\n\t\t\t\t\tif ( ! $parent_id ) {\n\t\t\t\t\t\t$parent = get_term_by( 'name', $unit, $this->cahnrs_units );\n\t\t\t\t\t\tif ( isset( $parent->id ) ) {\n\t\t\t\t\t\t\t$parent_id = $parent->id;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t$parent_id = 0;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\twp_insert_term( $child_unit, $this->cahnrs_units, array( 'parent' => $parent_id ) );\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\n\t}", "public function run()\n\t{\n\t\tMeasurementunit::create(array(\n\t\t\t'name' \t\t\t=> 'unidad',\n\t\t\t'description' \t=> '',\n\t\t));\n\n\t\tMeasurementunit::create(array(\n\t\t\t'name' \t\t\t=> 'par',\n\t\t\t'description' \t=> '',\n\t\t));\n\n\t\tMeasurementunit::create(array(\n\t\t\t'name' \t\t\t=> 'decena',\n\t\t\t'description' \t=> '',\n\t\t));\n\n\t\tMeasurementunit::create(array(\n\t\t\t'name' \t\t\t=> 'docena',\n\t\t\t'description' \t=> '',\n\t\t));\n\n\t\tMeasurementunit::create(array(\n\t\t\t'name' \t\t\t=> 'centimetro cubico cm3',\n\t\t\t'description' \t=> '',\n\t\t));\n\n\t\tMeasurementunit::create(array(\n\t\t\t'name' \t\t\t=> 'metro cuadrado mt2',\n\t\t\t'description' \t=> '',\n\t\t));\n\n\t}", "public function __construct($postType,$name){\n\t\ttry{\n\t\t\t$this->postType = $postType;\n\t\t\t$this->setName( $name );\n\t\t\t$this->setNameMenuSingular();\n\t\t\t$this->setNameMenu();\n\t\t\t$this->setNameAll();\n\t\t\t$this->setNameAdd();\n\t\t\t$this->setNameEdit();\n\t\t\t$this->setNameNewItem();\n\t\t\t$this->setNameView();\n\t\t\t$this->setNameSearch();\n\t\t\t$this->setMsgNotFound();\n\t\t\t$this->setPublic();\n\t\t\t$this->setPubliclyQueryable();\n\t\t\t$this->setShowUi();\n\t\t\t$this->setShowInMenu();\n\t\t\t$this->setShowInAdminBar();\n\t\t\t$this->setMenuPosition();\n\t\t\t$this->setMenuIcon();\n\t\t\t$this->setCapabilityType();\n\t\t\t$this->setCapabilities();\n\t\t\t$this->setMapMetaCap();\n\t\t\t$this->setHierarchical();\n\t\t\t$this->setSupports();\n\t\t\t$this->setRegisterMetaBoxCb();\n\t\t\t$this->setTaxonomies();\n\t\t\t$this->setHasArchive();\n\t\t\t$this->setPermalinkEpmask();\n\t\t\t$this->setRewrite();\n\t\t\t$this->setQueryVar();\n\t\t\t$this->setCanExport();\n\t\t\t$this->setBuiltin();\n\t\t\tadd_action('init', array(&$this,'registerPostType'));\n\t\t}catch(Excerption $e){\n\t\t\techo 'Favor verificar o slug do post ( Precisa conter no maximo 20 caracter )';\n\t\t}\n\t}", "protected function init()\n {\n $this->totais = [\n 'liquidados' => 0,\n 'entradas' => 0,\n 'baixados' => 0,\n 'protestados' => 0,\n 'erros' => 0,\n 'alterados' => 0,\n ];\n }", "public function run()\n {\n $unitTypesMap = [\n UnitTypeCategory::VOLUME => [\n UnitType::TEASPOON,\n UnitType::TABLESPOON,\n UnitType::FLUID_OUNCE,\n UnitType::CUP,\n UnitType::ML,\n UnitType::L,\n UnitType::DL\n ],\n UnitTypeCategory::WEIGHT => [\n UnitType::POUND,\n UnitType::OUNCE,\n UnitType::MG,\n UnitType::GRAM,\n UnitType::KG\n ],\n UnitTypeCategory::LENGTH => [\n UnitType::MM,\n UnitType::CM,\n UnitType::M,\n UnitType::INCH\n ],\n UnitTypeCategory::TEMPERATURE => [\n UnitType::C,\n UnitType::F\n ],\n UnitTypeCategory::QUANTITY => [\n UnitType::BOTTLE,\n UnitType::CAN,\n UnitType::PACK,\n UnitType::PIECE\n ]\n ];\n\n foreach ($unitTypesMap as $category => $unitTypes) {\n foreach ($unitTypes as $unitType) {\n UnitType::create([\n 'shorthand' => $unitType,\n 'category' => $category\n ]);\n }\n }\n }", "private function instantiate_post_types() {\n // Iterate across the post types in post_type_defs\n foreach ( $this->post_type_defs as $post_type => $post_type_def ) {\n $this->post_type_objs[ $post_type ] = new HRHS_Post_type( $post_type_def );\n }\n }", "public function __construct($unit = null, $_ = null)\n {\n $this\n ->setUnit($unit)\n ->set_($_);\n }", "protected function init()\n {\n $this->totais = [\n 'liquidados' => 0,\n 'entradas' => 0,\n 'baixados' => 0,\n 'protestados' => 0,\n 'erros' => 0,\n 'alterados' => 0,\n ];\n }", "public function __construct()\n {\n $this->type = 'percentage';\n $this->amount = 20;\n $this->end_date = strtotime(\"+1 day\");\n $this->minimum_amount = 100;\n $this->free_shipping = false;\n $this->included_categories = [10, 20];\n $this->excluded_categories = [50];\n $this->included_products = [3];\n $this->excluded_products = [4, 1];\n }", "public function __construct()\n {\n $this->conversions = array(\n 'km' => 1.60934,\n 'm' => 1609.34,\n 'cm' => 160934,\n 'mm' => 1609340,\n 'yd' => 1760,\n 'ft' => 5280,\n 'in' => 63360,\n 'mi' => 1\n );\n }", "protected function setUp()\n {\n $this->type = new FloatType();\n }", "public function __construct() {\n\t\t\t// Load Custom Post Type\n\t\t\tadd_filter( 'init', array( $this, 'init_post_type' ) );\n\t\t\t\n\t\t\tif ( 'wpmeetups' == $_GET[ 'post_type' ] || 'wpmeetups' == get_post_type( $_GET[ 'post' ] ) ) {\n\t\t\t\t// Scripts\n\t\t\t\tadd_filter( 'admin_enqueue_scripts', array( $this, 'admin_scripts' ) );\n\t\t\t\t// Add Metaboxes on our pages\n\t\t\t\tadd_filter( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );\n\t\t\t}\n\t\t\t\n\t\t\t// Save Post-Meta\n\t\t\tadd_filter( 'save_post', array( $this, 'save_post' ) );\n\t\t\t\n\t\t\t// The Gallery\n\t\t\tadd_filter( 'init', array( $this, 'theme_support' ) );\n\t\t\tadd_filter( 'wp_ajax_photo_gallery_upload', array( $this, 'handle_file_upload' ) );\n\t\t\tadd_filter( 'wp_ajax_save_items_order', array( $this, 'save_items_order' ) );\n\t\t\tadd_filter( 'wp_ajax_delete_gallery_item', array( $this, 'delete_gallery_item' ) );\n\t\t\tadd_filter( 'wp_ajax_update_attachment', array( $this, 'update_attachment' ) );\n\t\t\tadd_filter( 'wp_ajax_refresh_gallery', array( $this, 'draw_gallery_items' ) );\n\t\t}", "private function init() {\r\n settype($this->id, \"int\");\r\n settype($this->name, \"string\");\r\n settype($this->max_players, \"int\");\r\n settype($this->is_over_yet, \"boolean\");\r\n settype($this->players, \"array\");\r\n }", "public function action_init() {\n\n\t\t$this->register_gallery_post_type();\n\n\t}", "public static function types_init( $types ) {\n\t\tforeach ( $types as $type ) {\n\t\t\tself::$types[ $type ] = self::build_cpt_info( $type );\n\t\t}\n\t}", "public function init() {\n\t\t$fm = new Fieldmanager_TextField( [\n\t\t\t'name' => DWSLGF_PREFIX . '_phone',\n\t\t] );\n\t\t$fm->add_meta_box( 'Customer Phone Number', [ $this->post_type ] );\n\n\t\t$fm = new Fieldmanager_TextField( [\n\t\t\t'name' => DWSLGF_PREFIX . '_email',\n\t\t] );\n\t\t$fm->add_meta_box( 'Customer Email Address', [ $this->post_type ] );\n\n\t\t$fm = new Fieldmanager_TextField( [\n\t\t\t'name' => DWSLGF_PREFIX . '_budget',\n\t\t] );\n\t\t$fm->add_meta_box( 'Customer Desired Budget', [ $this->post_type ] );\n\n\t\t$fm = new Fieldmanager_TextArea( [\n\t\t\t'name' => DWSLGF_PREFIX . '_message',\n\t\t] );\n\t\t$fm->add_meta_box( 'Customer Message', [ $this->post_type ] );\n\n\t\t$fm = new Fieldmanager_TextField( [\n\t\t\t'name' => DWSLGF_PREFIX . '_submission_datetime',\n\t\t] );\n\t\t$fm->add_meta_box( 'Customer Posted Date/Time', $this->post_type );\n\t}", "public function set_up() {\n\t\tparent::set_up();\n\n\t\t$this->registry = new WP_Block_Type_Registry();\n\t}", "public function __construct() {\n $this->Types;\n }", "public function unit()\n {\n $data = ['aktif' => 'unit',\n 'data_unit' => $this->M_prospektus->get_unit_menu()->result_array(),\n 'data_blok' => $this->M_prospektus->get_blok_kws()->result_array()\n ];\n\n $this->template->load('template','prospektus/V_data_unit', $data);\n }", "public function getNrOfUnits()\n {\n return $this->units;\n }", "protected function __constructor() {\n\t\t\n\t\t// Copy and process configuration\n\t\t$config = $this->getConfig();\n\t\t$this->post_type = $config['post_type'];\n\t\t$this->meta_box = $config['meta_box'];\n\t\t$this->nonce = $config['nonce'];\n\t\t$this->fields = $config['fields'];\n\t\tarray_walk( $this->fields, [$this, 'prepare_field_data'] );\n\t\t\n\t\t// Runs hooks\n\t\tadd_action( 'add_meta_boxes_'.$this->post_type, [$this, 'register_meta_box'] );\n\t\tadd_action( 'save_post', [$this, 'save_post_meta'] );\n\t\tadd_action( 'admin_enqueue_scripts', [$this, 'load_assets'] );\n\t}", "function __construct() {\n\t\tif ( class_exists( 'PremiseCPT' ) ) {\n\t\t\tnew PremiseCPT( self::$example_labels, $this->example_options );\n\t\t}\n\n\t\tpwp_add_metabox(\n\t\t\t'Example Meta',\n\t\t\tarray( self::$example_labels['post_type_name'] ),\n\t\t\tarray(\n\t\t\t\t'name_prefix' => 'example_meta',\n\t\t\t\tarray(\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'context' => 'post',\n\t\t\t\t\t'name' => '[tel]',\n\t\t\t\t\t'label' => 'Telephone',\n\t\t\t\t),\n\t\t\t\tarray(\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'context' => 'post',\n\t\t\t\t\t'name' => '[email]',\n\t\t\t\t\t'label' => 'Email',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'example_meta'\n\t\t);\n\t}", "protected function _construct()\n {\n $this->_init('mageworx_optiontemplates_group_option_type_value', 'option_type_id');\n }", "public function __construct()\n {\n $this->initIngredientsQuantityTrait();\n $this->initCreateDateAwareTrait();\n }", "public function getUnitsPerEm() {}", "private function _default_date_time_units()\n {\n $this->seconds = '00';\n $this->minutes = '00';\n $this->hours = '00';\n\n \n $this->days = date('d');\n $this->months = date('m');\n $this->years = date('Y');\n $this->ampm = 'am';\n }", "public function __construct( $post_type ) {\n\n\t\t$this->post_type = $post_type;\n\t\t$this->cpts = array();\n\t\t$this->cats = array();\n\t\t$cpt_name = ( isset( $this->cpts[ $this->post_type ] ) ? $this->cpts[ $this->post_type ] : null );\n\n\t\tif ( ! post_type_exists( $cpt_name ) ) {\n\n\t\t\t//Register CPTs\n\t\t\tadd_action( 'init', array( $this, 'cws_register_cpt' ) );\n\n\t\t\t//Register CPT categories\n\t\t\tadd_action( 'init', array( $this, 'cws_register_cats' ) );\n\n\t\t}\n\n\t}", "public function run()\n {\n PropertyType::create([\n 'name' => 'Allgemein',\n ]);\n\n PropertyType::create([\n 'name' => 'Vitalwerte',\n ]);\n\n PropertyType::create([\n 'name' => 'Medikamente',\n ]);\n }", "function unit_multi($unit) {\n\t\n\tif ($unit == \"Kb\") {\n\t\t$multi = 1000;\n\t} elseif ($unit == \"Gb\") {\n\t\t$multi = 1000000000;\n\t} elseif ($unit == \"Tb\") {\n\t\t$multi = 1000000000000;\n\t} else {\n\t\t/* Mb default */\n\t\t$multi = 1000000;\n\t}\n\n\treturn $multi;\n\n}", "function post_meta_setup(){\n\t\t$type_meta_array = array(\n\t\t\t'settings' => array(\n\t\t\t\t'type' => 'multi_option',\n\t\t\t\t'title' => __( 'Single '.$this->single_up.' Options', 'pagelines' ),\n\t\t\t\t'shortexp' => __( 'Parameters', 'pagelines' ),\n\t\t\t\t'exp' => __( '<strong>Single '.$this->single_up.' Options</strong><br>Add '.$this->single_up.' Metadata that will be used on the page.<br><strong>HEADS UP:<strong> Each template uses different set of metadata. Check out <a href=\"http://bestrag.net/'.$this->multiple.'-lud\" target=\"_blank\">demo page</a> for more information.', 'pagelines' ),\n\t\t\t\t'selectvalues' => array(\n\t\t\t\t\t'client_name' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Client Name', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'client_name_url' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Client Name URL (eg: http://www.client.co)', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'partner' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Partner Company Name', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'partner_url' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Partner Company URL', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'project_slogan' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Project Slogan', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'img1' => array(\n\t\t\t\t\t\t'inputlabel' => __( 'Associate an image with this '.$this->single, 'pagelines' ),\n\t\t\t\t\t\t'type' => 'thickbox_image'\n\t\t\t\t\t),\n\t\t\t\t\t'img2' => array(\n\t\t\t\t\t\t'inputlabel' => __( 'Associate an image with this '.$this->single, 'pagelines' ),\n\t\t\t\t\t\t'type' => 'thickbox_image'\n\t\t\t\t\t),\n\t\t\t\t\t'custom_text1' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Custom Text/HTML/Shortcode 1', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'custom_text2' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Custom Text/HTML/Shortcode 2', 'pagelines' )\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t)\n\t\t );\n\t\t$fields = $type_meta_array['settings']['selectvalues'];\n\t\t$figo = array(); $findex = 0;\n\n\t\tforeach ($fields as $key => $value) {\n\t\t\t$figo[$findex] = array(\n\t\t\t\t'name' => $value['inputlabel'],\n\t\t\t\t'id' => $key,\n\t\t\t\t'type' => $value['type'],\n\t\t\t\t'std' => '',\n\t\t\t\t'class' => 'custom-class',\n\t\t\t\t'clone' => false\n\t\t\t);\n\t\t\t$findex++;\n\t\t}\n\t\t$metabox = array(\n\t\t\t'id' => 'projectal',\n\t\t\t'title' => 'Projectal Information',\n\t\t\t'pages' => array( $this->multiple ),\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'high',\n\t\t\t'fields' => $figo\n\t\t);\n\t\t new RW_Meta_Box($metabox);\n\t}", "public function setUnit($value = false) {\n $this->_unit = $value;\n return $this;\n }", "public function setUnit($value = false) {\n $this->_unit = $value;\n return $this;\n }", "public function init() {\n\t\tregister_post_meta(\n\t\t\t'product',\n\t\t\tself::META_REVIEWS,\n\t\t\t[\n\t\t\t\t'type' => 'string',\n\t\t\t\t'single' => true,\n\t\t\t\t'show_in_rest' => true,\n\t\t\t]\n\t\t);\n\n\t\tregister_post_meta(\n\t\t\t'post',\n\t\t\tself::META_REVIEWS,\n\t\t\t[\n\t\t\t\t'type' => 'string',\n\t\t\t\t'single' => true,\n\t\t\t\t'show_in_rest' => true,\n\t\t\t]\n\t\t);\n\t}", "public function setup() {\n $this->min_level = apply_filters( 'brg/ptt/minimum_user_level', 'activate_plugins' );\n\n add_filter( 'brg/posts_with_templates', array( $this, 'post_types_with_templates' ), 10, 1 );\n\n $this->admin_controller = new BRG_PTT_Admin_Interface_Controller( $this->min_level );\n $this->template_loader = new BRG_Template_Loader(); \n\n // setup the template post type\n $this->setup_posttype();\n }", "public function getUnits(): int\n\t{\n\t\treturn $this->units;\n\t}", "private function __construct() {\n\n\t\t// Load plugin text domain\n\t\tadd_action( 'init', array( $this, 'load_plugin_textdomain' ) );\n\t\t\n\t\t// Event post type: Register post type\n\t\tadd_action( 'init', array( $this, 'register_post_type' ) );\n\t}", "public function setUnits(string $strUnits) : void\r\n {\r\n $this->strUnits = $strUnits;\r\n }", "public function setup_types()\n {\n }", "function yee_post_type_testimonial_init(){\n\t$labels =array(\n\t\t'name'=>'Testimonials',\n\t\t'sigular_name'=>'Testimonial',\n\t\t'add_new'=>__('Add New Testimonial','Storefront-Child'),\n\t\t'add_new_item'=>__('Add New Testimonial','Storefront-Child'),\n\t\t'edit_item'=>__('Edit Testimonial','Storefront-Child'),\n\t\t'new_item'=>__('New Testimonial','Storefront-Child'),\n\t\t'view_item'=>__('View Testimonial','Storefront-Child'),\n\t\t'view_items'=>__('View Testimonials','Storefront-Child'),\n\t\t'all_items'=>__('All Testimonials','Storefront-Child'),\n\t\t'search_items'=>__('Search Testimonials','Storefront-Child')\n\t);\n\t$args =array(\n\t\t'labels'=>$labels,\n\t\t'public'=>true,\n\t\t'menu_position'=>5,\n\t\t'menu_icon'=>'dashicons-visibility',\n\t\t'hierarchical'=>false,\n\t\t'has_archive'=>true,\n\t\t'supports'=>array('title','editor','thumbnail','excerpt'),\n\t\t'rewrite'=>array('slug'=>'testimonial')\n\t\t\n\t);\n\tregister_post_type('yee_testimonial',$args);\n}", "function initialize()\n\t{\n\t\t$this->strType = strtoupper($this->dom->getAttribute(\"type\"));\n\t\t$this->strValues = $this->dom->getAttribute(\"values\");\n\t\t\n\t\t$this->prepare();\n\t}", "public static function init(){\n self::items_needed_for_brands();\n self::brand_for_product_post_type_metabox();\n }", "public function __construct() {\n\t\t$this->post_type = static::$linked_post_type;\n\t}", "private function init(): void\n {\n $this->value_signs = [\n '+' => 'plus',\n '-' => 'minus',\n ];\n\n // init number formatter\n $formatter = new NumberFormatter($this->getValueLocale(), NumberFormatter::SPELLOUT);\n\n // generate number value array with translated labels per locale\n for ($index = $this->getValueRange()[0]; $index <= $this->getValueRange()[1]; $index++) {\n $this->value_numbers[$index] = $formatter->format($index);\n }\n }", "public static function init(){ \n\t\t\n\t\tadd_action( 'init', array( __CLASS__, 'definition' ) );\n\t\t//\n\t\tdefine( 'OPALMEDICAL_DEPARTMENT_PREFIX', 'opal_department_' );\n\t\tadd_action( 'cmb2_admin_init', array( __CLASS__, 'metaboxes' ) );\n\t\trequire_once OPALMEDICAL_PLUGIN_DIR . 'inc/vendors/cmb2/timetable.php';\n\t}", "public static function init() {\n\t\tadd_action( 'admin_init', array( static::class, 'admin_init' ) );\n\n\t\t// Register Setting\n\t\tregister_setting(\n\t\t\t'micropub',\n\t\t\t'micropub_default_post_status', // Setting Name\n\t\t\tarray(\n\t\t\t\t'type' => 'string',\n\t\t\t\t'description' => 'Default Post Status for Micropub Server',\n\t\t\t\t'sanitize_callback' => 'sanitize_text_field',\n\t\t\t\t'show_in_rest' => false,\n\t\t\t)\n\t\t);\n\t}", "public function __construct() {\n\n //d(dirname(dirname( __FILE__ )));\n\n \tadd_action( 'wp_enqueue_scripts', array($this, 'load_custom_wp_frontend_style') );\n \tadd_action( 'init', [$this, 'custom_post_type'] );\n add_action( 'wp_ajax_custom_survey_tracker', array($this, 'plugin_data_custom_survey_tracker_func') );\n\t add_action( 'wp_ajax_nopriv_custom_survey_tracker', array($this, 'plugin_data_custom_survey_tracker_func') );\n\n\t\tadd_action( 'add_meta_boxes', array($this, 'add_events_metaboxes') );\n\n }", "public function init()\n {\n $labels = array(\n 'name' => __('Stacks', 'lambda-admin-td'),\n 'singular_name' => __('Stack', 'lambda-admin-td'),\n 'add_new' => __('Add New', 'lambda-admin-td'),\n 'add_new_item' => __('Add New Stack', 'lambda-admin-td'),\n 'edit_item' => __('Edit Stack', 'lambda-admin-td'),\n 'new_item' => __('New Stack', 'lambda-admin-td'),\n 'all_items' => __('All Stacks', 'lambda-admin-td'),\n 'view_item' => __('View Stack', 'lambda-admin-td'),\n 'search_items' => __('Search Stack', 'lambda-admin-td'),\n 'not_found' => __('No Stack found', 'lambda-admin-td'),\n 'not_found_in_trash' => __('No Stack found in Trash', 'lambda-admin-td'),\n 'menu_name' => __('Stacks', 'lambda-admin-td')\n );\n\n $labels = apply_filters('oxy_stack_labels', $labels);\n\n $args = array(\n 'labels' => $labels,\n 'public' => true,\n 'publicly_queryable' => false,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'query_var' => false,\n 'capability_type' => 'post',\n 'menu_position' => null,\n 'menu_icon' => 'dashicons-art',\n 'supports' => array( 'title' )\n );\n register_post_type($this->post_type, $args);\n }", "public function admin_init() {\n\t\t$meta_type = papi_get_meta_type();\n\t\t$meta_type = ucfirst( $meta_type );\n\t\t$class_name = 'Papi_Admin_Entry_' . $meta_type;\n\n\t\t// A custom class is not required, e.g\n\t\t// options don't have one.\n\t\tif ( class_exists( $class_name ) ) {\n\t\t\t$class = call_user_func( [$class_name, 'instance'] );\n\n\t\t\tif ( ! $class->setup() ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\t// Setup entry type.\n\t\tif ( $entry_type = $this->get_entry_type() ) {\n\t\t\t$entry_type->setup();\n\t\t}\n\t}", "public function add_unit_property()\n\t {\n\t \t $data=(array)json_decode(file_get_contents(\"php://input\"));\n\t \t$query=$this->ApiModel->add_unit_property($data);\n\t $res=array('msg'=>'success','data'=>$query);\n\t echo json_encode($res);\n\t }", "public function setElUnit($elUnit) {\n $this->cElUnit = $elUnit;\n \n }", "public function __construct($post_type = '', $taxs = array(), $meta_data = array(), $localize = array()){\n $this->post_type = 'mjob_agreement';\n parent::__construct( $this->post_type, $taxs, $meta_data, $localize);\n $this->meta = array(\n 'is_consumer_right_statement',\n 'is_notice_cancellation'\n );\n $this->post_type_singular = 'Agreement';\n $this->post_type_regular = 'Agreements';\n $this->taxs = array(\n 'mjob_category'\n );\n }", "public function __construct() {\n\t\tparent::__construct(\n\t\t\t'postcountdown',\n\t\t\t__( 'Postcountdown', 'postcountdown' ),\n\t\t\tarray( 'description' => __( 'A countdown for the number of post in a category', 'postcountdown' ) )\n\t\t);\n\t}", "public function __construct(&$data, $post_type)\n\t{\n\t\t$this->post_type = $post_type;\n\t\t$this->parseIterable($data);\n\t}", "public function set_typeNum()\n {\n // init the map\n $this->initVarTypeNum();\n }", "function dark_urban_init() {\n register_taxonomy_for_object_type( 'category', 'attachment' );\n register_taxonomy_for_object_type( 'post_tag', 'attachment' );\n\n /*\n * Register custom post types. You can also move this code to a plugin.\n */\n /* Pinegrow generated Custom Post Types Begin */\n\n /* Pinegrow generated Custom Post Types End */\n \n /*\n * Register custom taxonomies. You can also move this code to a plugin.\n */\n /* Pinegrow generated Taxonomies Begin */\n\n /* Pinegrow generated Taxonomies End */\n\n}", "public function run()\n {\n $unities = [\n \"Pièce\",\n \"Paire\",\n \"Mètre\",\n \"Kg (rouleau)\",\n \"Kg\",\n \"FUTS\",\n \"Box\",\n ];\n\n foreach ($unities as $value) {\n factory(App\\Unit::class)->create([\"name\" => $value]);\n }\n\n\n }", "public function __construct()\n\t{\n\t\t$this->cssUrl = WPM_RESOURCES_URL . '/sortPostType/css';\n\t\t$this->imgUrl = WPM_RESOURCES_URL . '/sortPostType/img';\n\t\t$this->jsUrl = WPM_RESOURCES_URL . '/sortPostType/js';\n\t\t$this->viewDir = WPM_RESOURCES_DIR . '/sortPostType';\n\n\t\tif(is_admin()) {\n\t\t\tadd_action('wp_ajax_wpm_reorder', [&$this, 'ajaxReorderList']);\n\t\t\tadd_action('wp_ajax_wpm_reorder_toggle', [&$this, 'ajaxToggleId']);\n\t\t\tadd_filter('wp_list_pages_excludes', array(&$this, 'excludeFromListPages'));\n\t\t}\n\t}", "public function setUnits($value)\n {\n return $this->set('Units', $value);\n }", "public function setUnits($value)\n {\n return $this->set('Units', $value);\n }", "public function setUnits($value)\n {\n return $this->set('Units', $value);\n }", "public function setUnits($value)\n {\n return $this->set('Units', $value);\n }", "public function setUnits($value)\n {\n return $this->set('Units', $value);\n }", "public function setUnits($value)\n {\n return $this->set('Units', $value);\n }", "public function _construct()\r\n {\r\n $this->_init('quetions/quetions', 'quetions_id');\r\n }", "static function init()\n\t{\n\n\t\tself::$_metatype = self::create_type(MetaType::class);\n\n\t\tself::$_void = self::create_type(VoidType::class);\n\t\tself::$_none = self::create_type(NoneType::class);\n\t\tself::$_any = self::create_type(AnyType::class);\n\n\t\t// self::$_scalar = self::create_type(ScalarType::class);\n\t\tself::$_string = self::create_type(StringType::class);\n\t\tself::$_float = self::create_type(FloatType::class);\n\t\tself::$_int = self::create_type(IntType::class);\n\t\tself::$_uint = self::create_type(UIntType::class);\n\t\tself::$_bool = self::create_type(BoolType::class);\n\n\t\tself::$_iterable = self::create_type(IterableType::class);\n\t\tself::$_array = self::create_type(ArrayType::class);\n\t\tself::$_dict = self::create_type(DictType::class);\n\n\t\tself::$_xview = self::create_type(XViewType::class);\n\t\tself::$_regex = self::create_type(RegexType::class);\n\n\t\tself::$_callable = self::create_type(CallableType::class);\n\t\tself::$_namespace = self::create_type(NamespaceType::class);\n\t}" ]
[ "0.7033522", "0.6397466", "0.62332827", "0.6122542", "0.6092153", "0.59678835", "0.5914289", "0.5881884", "0.5808739", "0.5807038", "0.57591206", "0.57487965", "0.5719409", "0.57109785", "0.5696548", "0.5678446", "0.56705475", "0.5655557", "0.5639669", "0.55682725", "0.55647904", "0.5557075", "0.55021954", "0.5491711", "0.5485983", "0.5468135", "0.5461891", "0.5445995", "0.5434946", "0.5417894", "0.5413078", "0.5411475", "0.5400234", "0.53768504", "0.53690135", "0.5361031", "0.5350154", "0.5349605", "0.5342512", "0.5338826", "0.5323934", "0.5314079", "0.530974", "0.52956146", "0.52954215", "0.5291652", "0.5284904", "0.5275422", "0.52581465", "0.5255046", "0.5239476", "0.5222776", "0.52133274", "0.5191434", "0.51909673", "0.51739055", "0.5173443", "0.51555574", "0.5153651", "0.51516277", "0.51465", "0.51385975", "0.51381916", "0.5138092", "0.51335174", "0.5133023", "0.5133023", "0.5127139", "0.51244205", "0.5123138", "0.5123006", "0.51211256", "0.51102656", "0.509581", "0.50938034", "0.5090893", "0.50843436", "0.5083003", "0.50803465", "0.5076172", "0.50746787", "0.5065711", "0.5064778", "0.5064657", "0.5060929", "0.50606054", "0.50569355", "0.5051254", "0.5050694", "0.5049503", "0.5048722", "0.5047574", "0.50440204", "0.50440204", "0.50440204", "0.50440204", "0.5041171", "0.5041171", "0.5038169", "0.50358045" ]
0.6537973
1
Initializes the "Units" custom post type in WP. We also add the two additional image sizes for our templates.
function init_post_type() { $labels = array( 'name' => _x( 'Unit', 'Post Type General Name', 'wppm' ), 'singular_name' => _x( 'Unit', 'Post Type Singular Name', 'wppm' ), 'menu_name' => __( 'Units', 'wppm' ), 'parent_item_colon' => __( 'Parent Item:', 'wppm' ), 'all_items' => __( 'All Units', 'wppm' ), 'view_item' => __( 'View Unit', 'wppm' ), 'add_new_item' => __( 'Add New Unit', 'wppm' ), 'add_new' => __( 'Add New', 'wppm' ), 'edit_item' => __( 'Edit Unit', 'wppm' ), 'update_item' => __( 'Update Unit', 'wppm' ), 'search_items' => __( 'Search Units', 'wppm' ), 'not_found' => __( 'Not found', 'wppm' ), 'not_found_in_trash' => __( 'Not found in Trash', 'wppm' ), ); $args = array( 'label' => __( 'units', 'wppm' ), 'description' => __( 'Units', 'wppm' ), 'labels' => $labels, 'supports' => array( 'title', 'thumbnail', ), 'hierarchical' => false, 'public' => true, 'show_ui' => true, 'show_in_menu' => true, 'show_in_nav_menus' => true, 'show_in_admin_bar' => true, 'menu_position' => 5, //'menu_icon' => '', 'can_export' => true, 'has_archive' => true, 'exclude_from_search' => false, 'publicly_queryable' => true, 'capability_type' => 'post', ); register_post_type( 'units', $args ); flush_rewrite_rules(); add_image_size( 'tiles-featured', 225, 225, true ); add_image_size( 'mini-tiles', 80, 55, true ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function __construct() {\n\t\tadd_action( 'init', array( $this, 'init_post_type' ) );\n\n\t\t// Setup the custom columns for the CPT\n\t\tadd_filter( 'manage_edit-units_columns', array( $this, 'edit_units_columns' ) );\n\t\tadd_action( 'manage_units_posts_custom_column', array( $this, 'manage_units_columns' ) );\n\t\tadd_filter( 'manage_edit-units_sortable_columns', array( $this, 'units_sortable_columns' ) );\n\t\tadd_filter( 'request', array( $this, 'sort_units' ) );\n\n\t\t// Setup metaboxes\n\t\tadd_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );\n\t\tadd_action( 'save_post', array( $this, 'save_unit_meta_boxes' ) );\n\n\t\t// Add custom messages\n\t\tadd_filter( 'post_updated_messages', array( $this, 'updated_messages' ) );\n\n\t\t// Load default templates\n\t\tadd_filter( 'template_include', array( $this, 'load_templates' ) );\n\n\t\t// Load frontend styles/scripts\n\t\tadd_action( 'init', array( $this, 'load_scripts') );\n\t\tadd_action( 'init', array( $this, 'load_styles' ) );\n\n\t\t// Load backend styles/scripts\n\t\tadd_action('admin_print_scripts', array( $this, 'load_admin_scripts' ) );\n\t\tadd_action('admin_print_styles', array( $this, 'load_admin_styles' ) );\n\t}", "protected function init() {\n\t\t$this->load_image_sizes();\n\n\t\t// Set image size to WP\n\t\t$this->add_image_sizes();\n\t}", "function register_post_type_unit(){\n\n\n\t\t$labels = array(\n\t\t\t\t\t\t'name' => _x('Unit', 'post type general name'),\n\t\t\t\t\t\t'singular_name' => _x('Unit', 'post type singular name'),\n\t\t\t\t\t\t'add_new' => _x('Add New', 'unit'),\n\t\t\t\t\t\t'add_new_item' => __('Add New '),\n\t\t\t\t\t\t'edit_item' => __('Edit '),\n\t\t\t\t\t\t'new_item' => __('New '),\n\t\t\t\t\t\t'all_items' => __('All Units'),\n\t\t\t\t\t\t'view_item' => __('View Unit'),\n\t\t\t\t\t\t'search_items' => __('Search Units'),\n\t\t\t\t\t\t'not_found' => __('No Units found'),\n\t\t\t\t\t\t'not_found_in_trash' => __('No Units found in Trash'),\n\t\t\t\t\t\t'parent_item_colon' => '',\n\t\t\t\t\t\t'menu_name' => __('Unit'),\n\t\t\t\t\t\t'has_archive' => false\n\n\t\t\t\t\t\t);\n\n\t$args = array(\n\t\t\t\t\t'labels' => $labels,\n\t\t\t\t\t'public' => true,\n\t\t\t\t\t'publicly_queryable' => true,\n\t\t\t\t\t'show_ui' => true,\n\t\t\t\t\t'show_in_menu' => true,\n\t\t\t\t\t'query_var' => true,\n\t\t\t\t\t'rewrite' => true,\n\t\t\t\t\t'capability_type' => 'post',\n\t\t\t\t\t'has_archive' => true,\n\t\t\t\t\t'hierarchical' => false,\n\t\t\t\t\t'menu_position' => null, \n\t\t\t\t\t'supports' => array( 'title', 'editor', 'thumbnail')\n\t\t\t\t);\n\n\n\tregister_post_type( 'unit', $args);\n\n\n\t\t// Add new taxonomy, make it hierarchical (like categories)\n\t$labels = array(\n\t\t\t\t\t'name' => _x( 'Unit Type', 'taxonomy general name' ),\n\t\t\t\t\t'singular_name' => _x( 'Unit Type', 'taxonomy singular name' ),\n\t\t\t\t\t'search_items' => __( 'Search Unit Types' ),\n\t\t\t\t\t'all_items' => __( 'All Unit Types' ),\n\t\t\t\t\t'parent_item' => __( 'Parent Unit Type' ),\n\t\t\t\t\t'parent_item_colon' => __( 'Parent Unit Type:' ),\n\t\t\t\t\t'edit_item' => __( 'Edit Unit Type' ),\n\t\t\t\t\t'update_item' => __( 'Update Unit Type' ),\n\t\t\t\t\t'add_new_item' => __( 'Add New Unit Type' ),\n\t\t\t\t\t'new_item_name' => __( 'New Unit Type Name' ),\n\t\t\t\t\t'menu_name' => __( 'Unit Type' ),\n\t\t\t\t\t);\n\n\tregister_taxonomy( 'unit_type',array('unit'), array(\n\t\t\t\t\t'hierarchical' => false,\n\t\t\t\t\t'labels' => $labels,\n\t\t\t\t\t'show_ui' => true,\n\t\t\t\t\t'query_var' => true,\n\t\t\t\t\t'rewrite' => array( 'slug' => 'unit'),\n\t\t\t\t\t));\n $labels = array(\n 'name' => _x( 'Building', 'taxonomy general name' ),\n 'singular_name' => _x( 'Building', 'taxonomy singular name' ),\n 'search_items' => __( 'Search Unit Buildings' ),\n 'all_items' => __( 'All Buildings' ),\n 'parent_item' => __( 'Parent Building' ),\n 'parent_item_colon' => __( 'Parent Building:' ),\n 'edit_item' => __( 'Edit Building' ),\n 'update_item' => __( 'Update Building' ),\n 'add_new_item' => __( 'Add New Building' ),\n 'new_item_name' => __( 'New Building Name' ),\n 'menu_name' => __( 'Building' ),\n );\n\n register_taxonomy( 'building',array('unit'), array(\n 'hierarchical' => true,\n 'labels' => $labels,\n 'show_ui' => true,\n 'query_var' => true,\n 'rewrite' => array( 'slug' => 'unit'),\n ));\n}", "public function setup() {\n\n\t\t//add additional featured image sizes\n\t\t//NOTE: wordpress will allow hyphens in these names, but swig or the API(i'm not sure) will not\n\t\tif ( function_exists( 'add_image_size' ) ) {\n\n add_image_size('progressive', 32, 20, false); \n add_image_size('progressive_cropped', 32, 20, true); \n add_image_size('xs', 300, 187, false); //1.6:1\n add_image_size('sm', 768, 480, false); //1.6:1\n add_image_size('md', 1024, 640, false); //1.6:1\n\n\t\t\tadd_image_size( 'person', 500, 500, false );\n\t\t\t//add_image_size( 'news', 768, 413, true );//edited from 512x275 on 6-2-17 to test image blurriness\n\t\t\t//add_image_size( 'news', 512, 275, true );//original(pre-digital strategy)\n\t\t\tadd_image_size( 'news', 1280, 675, true );//edited from 512x275 on 6-6-17 to improve image quality\n\t\t\tadd_image_size( 'story', 400, 286, true );\n\t\t\tadd_image_size( 'story2', 500, 750, true );\t\t\t\t\t\t\t\t\t\n\t\t\tadd_image_size( 'testimonial', 1024, 550, true );\t\n\t\t\tadd_image_size( 'projectslideshow', 1680, 1680, false );\t\t\t\t\t\t\n\t\t\tadd_image_size( 'category', 1680, 600, true );\t\n\t\t\t//add_image_size( 'hero', 1680, 1050, false );\t\n\t\t\tadd_image_size( 'hero', 1900, 1180, false );\t\t\t\n\t\t\tadd_image_size( 'facebook', 1200, 630, false );\t\t\t\n\n\t\t}\n\n\t\tif ( function_exists( 'add_theme_support' ) ) {\n\t\t\tadd_theme_support( 'post-thumbnails' );\n\t\t}\n\n\n\t\t//register post types\n\t\t//optional - include a custom icon, list of icons available at https://developer.wordpress.org/resource/dashicons/\n\t\tregister_post_type( 'projects',\n\t\t\tarray(\n\t\t\t\t'labels' => array(\n\t\t\t\t\t'name' => 'Projects',\n\t\t\t\t\t'singular_name' =>'Project',\n\t\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t\t'add_new_item' => 'Add New Project',\n\t\t\t\t\t'edit_item' => 'Edit Project',\n\t\t\t\t\t'new_item' => 'New Project',\n\t\t\t\t\t'all_items' => 'All Projects',\n\t\t\t\t\t'view_item' => 'View Project',\n\t\t\t\t\t'search_items' => 'Search Projects',\n\t\t\t\t\t'not_found' => 'No Projects found',\n\t\t\t\t\t'not_found_in_trash' => 'No Projects found in Trash',\n\t\t\t\t),\n\t\t\t\t'public' => true,\n\t\t\t\t'has_archive' => true,\n\t\t\t\t'rewrite' => array('slug' => 'projects'),\n\t\t\t\t'show_in_rest' => true,\n\t\t\t\t'rest_base' => 'projects',\n\t\t\t\t'rest_controller_class' => 'WP_REST_Posts_Controller',\n\t\t\t\t'supports' => array( 'title', 'thumbnail', 'editor'),\n\t\t\t\t'menu_icon' => 'dashicons-building'\n\t\t\t));\n\n\t\tregister_taxonomy( \n\t\t\t'project_categories', \n\t\t\t'projects', \n\t\t\tarray( \n\t\t\t\t'hierarchical' => true, \n\t\t\t\t'label' => 'Project Categories', \n\t\t\t\t'query_var' => true, \n\t\t\t\t'rewrite' => array('slug' => 'project_categories'),\n\t\t\t\t'rest_base' => 'project_categories',\n\t\t\t\t'rest_controller_class' => 'WP_REST_Terms_Controller', \n\t\t\t) \n\t\t);\n\n\n\t\tglobal $wp_taxonomies;\n\t\t$taxonomy_name = 'project_categories';\n\n\t\tif ( isset( $wp_taxonomies[ $taxonomy_name ] ) ) {\n\t\t\t$wp_taxonomies[ $taxonomy_name ]->show_in_rest = true;\n\t\t\t$wp_taxonomies[ $taxonomy_name ]->rest_base = $taxonomy_name;\n\t\t\t$wp_taxonomies[ $taxonomy_name ]->rest_controller_class = 'WP_REST_Terms_Controller';\n\t\t}\t\n\n\t\tregister_post_type( 'people',\n\t\t\tarray(\n\t\t\t\t'labels' => array(\n\t\t\t\t\t'name' => 'People',\n\t\t\t\t\t'singular_name' =>'Person',\n\t\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t\t'add_new_item' => 'Add New Person',\n\t\t\t\t\t'edit_item' => 'Edit Person',\n\t\t\t\t\t'new_item' => 'New Person',\n\t\t\t\t\t'all_items' => 'All People',\n\t\t\t\t\t'view_item' => 'View Person',\n\t\t\t\t\t'search_items' => 'Search People',\n\t\t\t\t\t'not_found' => 'No People found',\n\t\t\t\t\t'not_found_in_trash' => 'No People found in Trash',\n\t\t\t\t),\n\t\t\t\t'public' => true,\n\t\t\t\t'has_archive' => true,\n\t\t\t\t'rewrite' => array('slug' => 'people'),\n\t\t\t\t'show_in_rest' => true,\n\t\t\t\t'rest_base' => 'people',\n\t\t\t\t'rest_controller_class' => 'WP_REST_Posts_Controller',\n\t\t\t\t'supports' => array( 'title', 'thumbnail', 'editor'),\n\t\t\t\t'menu_icon' => 'dashicons-id'\n\t\t\t));\n\n\t\tregister_post_type( 'news',\n\t\t\tarray(\n\t\t\t\t'labels' => array(\n\t\t\t\t\t'name' => 'News',\n\t\t\t\t\t'singular_name' =>'News Item',\n\t\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t\t'add_new_item' => 'Add New News Item',\n\t\t\t\t\t'edit_item' => 'Edit News Item',\n\t\t\t\t\t'new_item' => 'New News Item',\n\t\t\t\t\t'all_items' => 'All News Items',\n\t\t\t\t\t'view_item' => 'View News Item',\n\t\t\t\t\t'search_items' => 'Search News Items',\n\t\t\t\t\t'not_found' => 'No News Items found',\n\t\t\t\t\t'not_found_in_trash' => 'No News Items found in Trash',\n\t\t\t\t),\n\t\t\t\t'public' => true,\n\t\t\t\t'has_archive' => true,\n\t\t\t\t'rewrite' => array('slug' => 'news'),\n\t\t\t\t'show_in_rest' => true,\n\t\t\t\t'rest_base' => 'news',\n\t\t\t\t'rest_controller_class' => 'WP_REST_Posts_Controller',\n\t\t\t\t'supports' => array( 'title', 'thumbnail', 'editor'),\n\t\t\t\t'menu_icon'\t=>\t'dashicons-welcome-widgets-menus'\n\t\t\t));\n\n\t\tregister_post_type( 'about',\n\t\t\tarray(\n\t\t\t\t'labels' => array(\n\t\t\t\t\t'name' => 'Info Pages',\n\t\t\t\t\t'singular_name' => 'Info Page',\n\t\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t\t'add_new_item' => 'Add New Info Page',\n\t\t\t\t\t'edit_item' => 'Edit Info Page',\n\t\t\t\t\t'new_item' => 'New Info Page',\n\t\t\t\t\t'all_items' => 'All Info Pages',\n\t\t\t\t\t'view_item' => 'View Info Page',\n\t\t\t\t\t'search_items' => 'Search Info Pages',\n\t\t\t\t\t'not_found' => 'No Info Pages found',\n\t\t\t\t\t'not_found_in_trash' => 'No Info Pages found in Trash',\n\t\t\t\t),\n\t\t\t\t'public' => true,\n\t\t\t\t'has_archive' => true,\n\t\t\t\t'rewrite' => array('slug' => 'about'),\n\t\t\t\t'show_in_rest' => true,\n\t\t\t\t'rest_base' => 'about',\n\t\t\t\t'rest_controller_class' => 'WP_REST_Posts_Controller',\n\t\t\t\t'supports' => array( 'title', 'editor'),\n\t\t\t\t'menu_icon' => 'dashicons-admin-page'\t\t\t\t\n\t\t\t));\n\n\t\tregister_post_type( 'jobs',\n\t\t\tarray(\n\t\t\t\t'labels' => array(\n\t\t\t\t\t'name' => 'Jobs',\n\t\t\t\t\t'singular_name' => 'Job',\n\t\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t\t'add_new_item' => 'Add New Job',\n\t\t\t\t\t'edit_item' => 'Edit Job',\n\t\t\t\t\t'new_item' => 'New Job',\n\t\t\t\t\t'all_items' => 'All Jobs',\n\t\t\t\t\t'view_item' => 'View Job',\n\t\t\t\t\t'search_items' => 'Search Jobs',\n\t\t\t\t\t'not_found' => 'No Jobs found',\n\t\t\t\t\t'not_found_in_trash' => 'No Jobs found in Trash',\n\t\t\t\t),\n\t\t\t\t'public' => true,\n\t\t\t\t'has_archive' => true,\t\n\t\t\t\t'rewrite' => array('slug' => 'jobs'),\n\t\t\t\t'show_in_rest' => true,\n\t\t\t\t'rest_base' => 'jobs',\n\t\t\t\t'rest_controller_class' => 'WP_REST_Posts_Controller',\n\t\t\t\t'supports' => array( 'title', 'editor'),\n\t\t\t\t'menu_icon' => 'dashicons-clipboard'\t\t\t\t\n\t\t\t));\n\n\t\t//add ACF options pages\n\t\t//optional - include a custom icon, list of icons available at https://developer.wordpress.org/resource/dashicons/\n\t\tif( function_exists('acf_add_options_page') ) {\n\t\t\t$option_page = acf_add_options_page(array(\n\t\t\t\t'page_title' \t=> 'Home Page',\n\t\t\t\t'menu_title' \t=> 'Home Page',\n\t\t\t\t'menu_slug' \t=> 'home-page',\n\t\t\t\t'icon_url' => 'dashicons-admin-home',\n\t\t\t\t'position'\t\t=> '50.1',\t\t\t\t\n\t\t\t));\n\t\t\t$option_page = acf_add_options_page(array(\n\t\t\t\t'page_title' \t=> 'About Page',\n\t\t\t\t'menu_title' \t=> 'About Page',\n\t\t\t\t'menu_slug' \t=> 'about-page',\n\t\t\t\t'icon_url' => 'dashicons-index-card',\n\t\t\t\t'position'\t\t=> '50.3',\t\t\t\t\n\t\t\t));\t\t\t\n\t\t\t$option_page = acf_add_options_page(array(\n\t\t\t\t'page_title' \t=> 'Work Page',\n\t\t\t\t'menu_title' \t=> 'Work Page',\n\t\t\t\t'menu_slug' \t=> 'work-page',\n\t\t\t\t'icon_url' => 'dashicons-screenoptions',\n\t\t\t\t'position'\t\t=> '50.5'\n\t\t\t));\t\n\t\t\t$option_page = acf_add_options_page(array(\n\t\t\t\t'page_title' \t=> 'News Page',\n\t\t\t\t'menu_title' \t=> 'News Page',\n\t\t\t\t'menu_slug' \t=> 'news-page',\n\t\t\t\t'icon_url' => 'dashicons-welcome-widgets-menus',\n\t\t\t\t'position'\t\t=> '50.7'\n\t\t\t));\t\n\t\t\t$option_page = acf_add_options_page(array(\n\t\t\t\t'page_title' \t=> 'General Information',\n\t\t\t\t'menu_title' \t=> 'General Information',\n\t\t\t\t'menu_slug' \t=> 'general-information',\n\t\t\t\t'icon_url' => 'dashicons-location',\n\t\t\t\t'position'\t\t=> '50.9'\n\t\t\t));\t\t\t\t\t\t\t\n\t\t}\n\n\t}", "public function slate_post_type_init() {\n\n new Slate_Post_Type('Characters', array(\n 'has_archive' => true,\n 'rewrite' => array(\n 'with_front' => false,\n 'slug' => 'characters'\n )\n ));\n\n new Slate_Post_Type('Items', array(\n 'has_archive' => true,\n 'rewrite' => array(\n 'with_front' => false,\n 'slug' => 'items'\n )\n ));\n\n new Slate_Post_Type('Games', array(\n 'has_archive' => true,\n 'rewrite' => array(\n 'with_front' => false,\n 'slug' => 'game-library'\n )\n ));\n\n }", "function init(){\n\t\t$this->register_cpt_lumo_slides();\n\n\t\tadd_action( 'admin_head', array($this, 'plugin_header_image') );\n\t\tadd_action( 'admin_head', array($this, 'lumo_cpt_icons') );\n\n\t\tadd_action('admin_menu', array($this, 'admin_menus') );\n\n\t\tadd_action('wp_enqueue_scripts', array($this, 'enqueue') );\n\n\t\t/**\n\t\t *\tSet Custom Main Slider Image size\n\t\t */\n\t\tadd_image_size('home-slider-image', 1600, 600);\n\t\tadd_image_size('home-slider-image-lowrez', 1366, 512);\n\t}", "public function __construct() {\n\t\t\t// Load Custom Post Type\n\t\t\tadd_filter( 'init', array( $this, 'init_post_type' ) );\n\t\t\t\n\t\t\tif ( 'wpmeetups' == $_GET[ 'post_type' ] || 'wpmeetups' == get_post_type( $_GET[ 'post' ] ) ) {\n\t\t\t\t// Scripts\n\t\t\t\tadd_filter( 'admin_enqueue_scripts', array( $this, 'admin_scripts' ) );\n\t\t\t\t// Add Metaboxes on our pages\n\t\t\t\tadd_filter( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );\n\t\t\t}\n\t\t\t\n\t\t\t// Save Post-Meta\n\t\t\tadd_filter( 'save_post', array( $this, 'save_post' ) );\n\t\t\t\n\t\t\t// The Gallery\n\t\t\tadd_filter( 'init', array( $this, 'theme_support' ) );\n\t\t\tadd_filter( 'wp_ajax_photo_gallery_upload', array( $this, 'handle_file_upload' ) );\n\t\t\tadd_filter( 'wp_ajax_save_items_order', array( $this, 'save_items_order' ) );\n\t\t\tadd_filter( 'wp_ajax_delete_gallery_item', array( $this, 'delete_gallery_item' ) );\n\t\t\tadd_filter( 'wp_ajax_update_attachment', array( $this, 'update_attachment' ) );\n\t\t\tadd_filter( 'wp_ajax_refresh_gallery', array( $this, 'draw_gallery_items' ) );\n\t\t}", "function top_lot_init() {\n\tregister_post_type( 'top-lot', array(\n\t\t'labels' => array(\n\t\t\t'name' => __( 'Top Lots', 'wordplate' ),\n\t\t\t'singular_name' => __( 'Top Lot', 'wordplate' ),\n\t\t\t'all_items' => __( 'All Top Lots', 'wordplate' ),\n\t\t\t'archives' => __( 'Top Lot Archives', 'wordplate' ),\n\t\t\t'attributes' => __( 'Top Lot Attributes', 'wordplate' ),\n\t\t\t'insert_into_item' => __( 'Insert into Top Lot', 'wordplate' ),\n\t\t\t'uploaded_to_this_item' => __( 'Uploaded to this Top Lot', 'wordplate' ),\n\t\t\t'featured_image' => _x( 'Featured Image', 'top-lot', 'wordplate' ),\n\t\t\t'set_featured_image' => _x( 'Set featured image', 'top-lot', 'wordplate' ),\n\t\t\t'remove_featured_image' => _x( 'Remove featured image', 'top-lot', 'wordplate' ),\n\t\t\t'use_featured_image' => _x( 'Use as featured image', 'top-lot', 'wordplate' ),\n\t\t\t'filter_items_list' => __( 'Filter Top Lots list', 'wordplate' ),\n\t\t\t'items_list_navigation' => __( 'Top Lots list navigation', 'wordplate' ),\n\t\t\t'items_list' => __( 'Top Lots list', 'wordplate' ),\n\t\t\t'new_item' => __( 'New Top Lot', 'wordplate' ),\n\t\t\t'add_new' => __( 'Add New', 'wordplate' ),\n\t\t\t'add_new_item' => __( 'Add New Top Lot', 'wordplate' ),\n\t\t\t'edit_item' => __( 'Edit Top Lot', 'wordplate' ),\n\t\t\t'view_item' => __( 'View Top Lot', 'wordplate' ),\n\t\t\t'view_items' => __( 'View Top Lots', 'wordplate' ),\n\t\t\t'search_items' => __( 'Search Top Lots', 'wordplate' ),\n\t\t\t'not_found' => __( 'No Top Lots found', 'wordplate' ),\n\t\t\t'not_found_in_trash' => __( 'No Top Lots found in trash', 'wordplate' ),\n\t\t\t'parent_item_colon' => __( 'Parent Top Lot:', 'wordplate' ),\n\t\t\t'menu_name' => __( 'Top Lots', 'wordplate' ),\n\t\t),\n\t\t'public' => true,\n\t\t'hierarchical' => true,\n\t\t'show_ui' => true,\n\t\t'show_in_nav_menus' => true,\n\t\t'supports' => array( 'title','page-attributes' ),\n\t\t'has_archive' => false,\n\t\t'rewrite' => false,\n\t\t'query_var' => false,\n\t\t'menu_position' => null,\n\t\t'menu_icon' => 'dashicons-admin-post',\n\t\t'show_in_rest' => true,\n\t\t'rest_base' => 'top-lots',\n\t\t'rest_controller_class' => 'WP_REST_Posts_Controller',\n\t) );\n\n}", "function init() {\n\n\t\t// Create Post Type\n\t\tadd_action( 'init', array( $this, 'post_type' ) );\n\n\t\t// Post Type columns\n\t\tadd_filter( 'manage_edit-event_columns', array( $this, 'edit_event_columns' ), 20 );\n\t\tadd_action( 'manage_event_posts_custom_column', array( $this, 'manage_event_columns' ), 20, 2 );\n\n\t\t// Post Type sorting\n\t\tadd_filter( 'manage_edit-event_sortable_columns', array( $this, 'event_sortable_columns' ), 20 );\n\t\t//add_action( 'load-edit.php', array( $this, 'edit_event_load' ), 20 );\n\n\t\t// Post Type title placeholder\n\t\tadd_filter( 'enter_title_here', array( $this, 'title_placeholder' ) );\n\n\t\t// Create Metabox\n\t\t$metabox = apply_filters( 'be_events_manager_metabox_override', false );\n\t\tif ( false === $metabox ) {\n\t\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'metabox_styles' ) );\n\t\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'metabox_scripts' ) );\n\t\t\tadd_action( 'add_meta_boxes', array( $this, 'metabox_register' ) );\n\t\t\tadd_action( 'save_post', array( $this, 'metabox_save' ), 1, 2 );\n\t\t}\n\n\t\t// Generate Events\n\t\tadd_action( 'wp_insert_post', array( $this, 'generate_events' ) );\n\t\tadd_action( 'wp_insert_post', array( $this, 'regenerate_events' ) );\n\t}", "function roots_setup() {\n // Add post thumbnails\n // http://codex.wordpress.org/Post_Thumbnails\n // http://codex.wordpress.org/Function_Reference/set_post_thumbnail_size\n // http://codex.wordpress.org/Function_Reference/add_image_size\n add_theme_support('post-thumbnails');\n // Add custom slider sizes\n add_image_size('slider_large', 1680, 670, true); // desktop - tablet landscape\n add_image_size('slider_medium', 1024, 408, true); // tablet landscape - tablet portrait\n add_image_size('slider_small', 768, 306, true); // tablet portrait - mobile\n // Tell the TinyMCE editor to use a custom stylesheet\n add_editor_style('/assets/css/editor-style.css');\n}", "public function setup() {\n $this->min_level = apply_filters( 'brg/ptt/minimum_user_level', 'activate_plugins' );\n\n add_filter( 'brg/posts_with_templates', array( $this, 'post_types_with_templates' ), 10, 1 );\n\n $this->admin_controller = new BRG_PTT_Admin_Interface_Controller( $this->min_level );\n $this->template_loader = new BRG_Template_Loader(); \n\n // setup the template post type\n $this->setup_posttype();\n }", "public function init()\n \t{\n \t\t// Initialize Post Type\n \t\t$this->create_post_type();\n \t\tadd_action('save_post', array($this, 'save_post'));\n \t}", "function gallery_init() {\n $labels = array(\n 'name' => 'Imágenes de la galería',\n 'singular_name' => 'Imagen de la galería',\n 'add_new_item' => 'New Image de la galería',\n 'edit_item' => 'Editar Imagen de la galería',\n 'new_item' => 'Nueva Imagen de la galería',\n 'view_item' => 'Ver Imagen de la galería',\n 'search_items' => 'Buscar Imágenes de la galería',\n 'not_found' => 'Imágenes de la galería noencontradas',\n 'not_found_in_trash' => 'Ninguna Imagen de la galería en la papelera'\n );\n $args = array(\n 'labels' => $labels,\n 'public' => false,\n 'show_ui' => true,\n 'supports' => array('thumbnail')\n );\n\n register_post_type( 'gallery', $args );\n}", "function ks_create_post_type() {\n\tregister_post_type( 'image-entry',\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => __( 'Comp. Entries', 'kilpailusivu' ),\n\t\t\t\t'singular_name' => __( 'Entry', 'kilpailusivu' ),\n\t\t\t\t'add_new' => __( 'Add New', 'kilpailusivu' ),\n\t\t\t\t'add_new_item' => __( 'Add New Entry', 'kilpailusivu' ),\n\t\t\t\t'edit' => __( 'Edit', 'kilpailusivu' ),\n\t\t\t\t'edit_item' => __( 'Edit Entry', 'kilpailusivu' ),\n\t\t\t\t'new_item' => __( 'New Entry', 'kilpailusivu' ),\n\t\t\t\t'view' => __( 'View', 'kilpailusivu' ),\n\t\t\t\t'view_item' => __( 'View Entry', 'kilpailusivu' ),\n\t\t\t\t'search_items' => __( 'Search Entries', 'kilpailusivu' ),\n\t\t\t\t'not_found' => __( 'No Entries found', 'kilpailusivu' ),\n\t\t\t\t'not_found_in_trash' => __( 'No Entries found in Trash', 'kilpailusivu' )\n\t\t\t),\n\t\t\t'public' => true,\n\t\t\t'hierarchical' => true,\n\t\t\t'has_archive' => true,\n\t\t\t'supports' => array(\n\t\t\t\t'title',\n\t\t\t),\n\t\t\t'menu_icon' => 'dashicons-smiley',\n\t\t\t'can_export' => true,\n\t\t\t'taxonomies' => array()\n\t\t) );\n}", "public function __construct() {\n $this->shopTypeOriginalImageUploadPath = Config::get('constant.SHOP_TYPE_ORIGINAL_IMAGE_UPLOAD_PATH');\n $this->shopTypeThumbImageUploadPath = Config::get('constant.SHOP_TYPE_THUMB_IMAGE_UPLOAD_PATH');\n $this->shopTypeThumbImageHeight = Config::get('constant.SHOP_TYPE_THUMB_IMAGE_HEIGHT');\n $this->shopTypeThumbImageWidth = Config::get('constant.SHOP_TYPE_THUMB_IMAGE_WIDTH');\n }", "public function init()\n \t{\n \t\t// Initialize Post Type\n \t\t$this->create_post_type();\n \t\tadd_action('save_post', array(&$this, 'save_post'));\n \t}", "function setup_post_types() {\n\t\t//Default support for WP Pages\n\t\tadd_post_type_support('page','sliders');\n\t\t\n\t\t/**\n\t\t * @cpt Sliders\n\t\t */\n\t\t$labels = array(\n\t\t\t'name' => __('Sliders','tw-sliders'),\n\t\t\t'singular_name' => __('Slider','tw-sliders'),\n\t\t\t'add_new' => __('Add slider','tw-sliders'),\n\t\t\t'add_new_item' => __('Add new slider','tw-sliders')\n\t\t);\n\t\t\n\t\t$args = array(\n\t\t\t'labels' => $labels,\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'show_in_menu' => 'themes.php',\n\t\t\t'supports' => array('title','sliders')\n\t\t); \n\t\t\n\t\tregister_post_type('tw-sliders',$args);\n\t}", "function photos_post_type() {\n\t\t$labels = array(\n\t\t\t'name' => _x( 'User Photos', 'Post Type General Name', 'twodayssss' ),\n\t\t\t'singular_name' => _x( 'User Album', 'Post Type Singular Name', 'twodayssss' ),\n\t\t\t'menu_name' => __( 'User Photos', 'twodayssss' ),\n\t\t\t'name_admin_bar' => __( 'User Photos', 'twodayssss' ),\n\t\t\t'archives' => __( 'Item Archives', 'twodayssss' ),\n\t\t\t'attributes' => __( 'Item Attributes', 'twodayssss' ),\n\t\t\t'parent_item_colon' => __( 'Parent Item:', 'twodayssss' ),\n\t\t\t'all_items' => __( 'All Items', 'twodayssss' ),\n\t\t\t'add_new_item' => __( 'Add New Item', 'twodayssss' ),\n\t\t\t'add_new' => __( 'Add New', 'twodayssss' ),\n\t\t\t'new_item' => __( 'New Item', 'twodayssss' ),\n\t\t\t'edit_item' => __( 'Edit Item', 'twodayssss' ),\n\t\t\t'update_item' => __( 'Update Item', 'twodayssss' ),\n\t\t\t'view_item' => __( 'View Item', 'twodayssss' ),\n\t\t\t'view_items' => __( 'View Items', 'twodayssss' ),\n\t\t\t'search_items' => __( 'Search Item', 'twodayssss' ),\n\t\t\t'not_found' => __( 'Not found', 'twodayssss' ),\n\t\t\t'not_found_in_trash' => __( 'Not found in Trash', 'twodayssss' ),\n\t\t\t'featured_image' => __( 'Album Cover', 'twodayssss' ),\n\t\t\t'set_featured_image' => __( 'Set album cover', 'twodayssss' ),\n\t\t\t'remove_featured_image' => __( 'Remove album cover', 'twodayssss' ),\n\t\t\t'use_featured_image' => __( 'Use as album cover', 'twodayssss' ),\n\t\t\t'insert_into_item' => __( 'Insert into item', 'twodayssss' ),\n\t\t\t'uploaded_to_this_item' => __( 'Uploaded to this item', 'twodayssss' ),\n\t\t\t'items_list' => __( 'Items list', 'twodayssss' ),\n\t\t\t'items_list_navigation' => __( 'Items list navigation', 'twodayssss' ),\n\t\t\t'filter_items_list' => __( 'Filter items list', 'twodayssss' ),\n\t\t);\n\t\t$args = array(\n\t\t\t'label' => __( 'User Photos', 'twodayssss' ),\n\t\t\t'description' => __( 'Image gallery for Ultimate member Users', 'twodayssss' ),\n\t\t\t'labels' => $labels,\n\t\t\t'supports' => array( 'title','thumbnail','author'),\n\t\t\t'hierarchical' => false,\n\t\t\t'public' => false,\n\t\t\t'show_ui' => false,\n\t\t\t'show_in_menu' => false,\n\t\t\t'menu_position' => 5,\n\t\t\t'show_in_admin_bar' => true,\n\t\t\t'show_in_nav_menus' => false,\n\t\t\t'can_export' => true,\n\t\t\t'has_archive' => false,\n\t\t\t'exclude_from_search' => true,\n\t\t\t'publicly_queryable' => true,\n\t\t\t'capability_type' => 'page',\n\t\t);\n\t\tregister_post_type( 'um_user_photos', $args );\n\t}", "public function init_post_type() {\n\t\t\t\n\t\t\t$labels = array(\n\t\t\t\t'name'\t\t\t\t=> 'Meetups',\n\t\t\t\t'new_item'\t\t\t=> 'Neues Meetup',\n\t\t\t\t'singular_name'\t\t=> 'Meetup',\n\t\t\t\t'view_item'\t\t\t=> 'Zeige Meetups',\n\t\t\t\t'edit_item'\t\t\t=> 'Editiere Meetup',\n\t\t\t\t'add_new_item'\t\t=> 'Meetup hinzuf&uuml;gen',\n\t\t\t\t'not_found'\t\t\t=> 'Kein Meetup gefunden',\n\t\t\t\t'search_items'\t\t=> 'Durchsuche Meetups',\n\t\t\t\t'parent_item_colon' => ''\n\t\t\t);\n\t\t\t\n\t\t\t$supports = array(\n\t\t\t\t'title',\n\t\t\t\t'editor',\n\t\t\t\t'comments',\n\t\t\t);\n\t\t\t\n\t\t\t$args = array(\n\t\t\t\t'public'\t\t\t\t=> TRUE,\n\t\t\t\t'publicly_queryable'\t=> TRUE,\n\t\t\t\t'show_ui'\t\t\t\t=> TRUE, \n\t\t\t\t'query_var'\t\t\t\t=> TRUE,\n\t\t\t\t'capability_type'\t\t=> 'post',\n\t\t\t\t'hierarchical'\t\t\t=> FALSE,\n\t\t\t\t'menu_position'\t\t\t=> NULL,\n\t\t\t\t'supports'\t\t\t\t=> $supports,\n\t\t\t\t'has_archive'\t\t\t=> TRUE,\n\t\t\t\t'rewrite'\t\t\t\t=> TRUE,\n\t\t\t\t'labels'\t\t\t\t=> $labels\n\t\t\t);\n\t\t\t\n\t\t\tregister_post_type( 'wpmeetups', $args );\n\t\t}", "function neurovision_images() {\n \tregister_post_type( 'images', /* (http://codex.wordpress.org/Function_Reference/register_post_type) */\n \t \t// let's now add all the options for this post type\n \t\tarray('labels' => array(\n \t\t\t'name' => __('Images', 'neurovisiontheme'), /* This is the Title of the Group */\n \t\t\t'singular_name' => __('Image', 'neurovisiontheme'), /* This is the individual type */\n \t\t\t'all_items' => __('All Images', 'neurovisiontheme'), /* the all items menu item */\n \t\t\t'add_new' => __('Add New Image', 'neurovisiontheme'), /* The add new menu item */\n \t\t\t'add_new_item' => __('Add New Image', 'neurovisiontheme'), /* Add New Display Title */\n \t\t\t'edit' => __( 'Edit', 'neurovisiontheme' ), /* Edit Dialog */\n \t\t\t'edit_item' => __('Edit Image', 'neurovisiontheme'), /* Edit Display Title */\n \t\t\t'new_item' => __('New Image', 'neurovisiontheme'), /* New Display Title */\n \t\t\t'view_item' => __('View Image', 'neurovisiontheme'), /* View Display Title */\n \t\t\t'search_items' => __('Search Images', 'neurovisiontheme'), /* Search Custom Type Title */\n \t\t\t'not_found' => __('Nothing found in the Database.', 'neurovisiontheme'), /* This displays if there are no entries yet */\n \t\t\t'not_found_in_trash' => __('Nothing found in Trash', 'neurovisiontheme'), /* This displays if there is nothing in the trash */\n \t\t\t'parent_item_colon' => ''\n \t\t\t), /* end of arrays */\n \t\t\t'description' => __( 'neurovision Images', 'neurovisiontheme' ), /* Custom Type Description */\n\n \t\t\t'public' => true,\n \t\t\t'publicly_queryable' => true,\n \t\t\t'exclude_from_search' => false,\n \t\t\t'show_ui' => true,\n \t\t\t'query_var' => true,\n \t\t\t'menu_position' => 6, /* this is what order you want it to appear in on the left hand side menu */\n \t\t\t'menu_icon' => 'dashicons-format-image', /* the icon for the custom post type menu */\n \t\t\t'rewrite'\t=> array( 'slug' => 'images', 'with_front' => false ), /* you can specify its url slug */\n \t\t\t'has_archive' => true, /* you can rename the slug here */\n \t\t\t'capability_type' => 'post',\n \t\t\t'hierarchical' => false,\n \t\t\t/* the next one is important, it tells what's enabled in the post editor */\n \t\t\t'supports' => array( 'title', 'editor', 'page-attributes', 'thumbnail')\n \t \t) /* end of options */\n \t); /* end of register post type */\n\n }", "function initialize() {\n\t\t$this->number = 1;\n\t\t$this->post_types = array();\n\t\t$this->widget_form_fields = array();\n\n\t\tadd_action( 'add_meta_boxes', array( $this, 'add_meta_boxes' ) );\n\t\tadd_action( 'save_post', array( $this, 'save_widget_post_meta' ), 10, 3 );\n\t}", "function post_meta_setup(){\n\t\t$type_meta_array = array(\n\t\t\t'settings' => array(\n\t\t\t\t'type' => 'multi_option',\n\t\t\t\t'title' => __( 'Single '.$this->single_up.' Options', 'pagelines' ),\n\t\t\t\t'shortexp' => __( 'Parameters', 'pagelines' ),\n\t\t\t\t'exp' => __( '<strong>Single '.$this->single_up.' Options</strong><br>Add '.$this->single_up.' Metadata that will be used on the page.<br><strong>HEADS UP:<strong> Each template uses different set of metadata. Check out <a href=\"http://bestrag.net/'.$this->multiple.'-lud\" target=\"_blank\">demo page</a> for more information.', 'pagelines' ),\n\t\t\t\t'selectvalues' => array(\n\t\t\t\t\t'client_name' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Client Name', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'client_name_url' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Client Name URL (eg: http://www.client.co)', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'partner' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Partner Company Name', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'partner_url' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Partner Company URL', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'project_slogan' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Project Slogan', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'img1' => array(\n\t\t\t\t\t\t'inputlabel' => __( 'Associate an image with this '.$this->single, 'pagelines' ),\n\t\t\t\t\t\t'type' => 'thickbox_image'\n\t\t\t\t\t),\n\t\t\t\t\t'img2' => array(\n\t\t\t\t\t\t'inputlabel' => __( 'Associate an image with this '.$this->single, 'pagelines' ),\n\t\t\t\t\t\t'type' => 'thickbox_image'\n\t\t\t\t\t),\n\t\t\t\t\t'custom_text1' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Custom Text/HTML/Shortcode 1', 'pagelines' )\n\t\t\t\t\t),\n\t\t\t\t\t'custom_text2' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'inputlabel' => __( 'Custom Text/HTML/Shortcode 2', 'pagelines' )\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t)\n\t\t );\n\t\t$fields = $type_meta_array['settings']['selectvalues'];\n\t\t$figo = array(); $findex = 0;\n\n\t\tforeach ($fields as $key => $value) {\n\t\t\t$figo[$findex] = array(\n\t\t\t\t'name' => $value['inputlabel'],\n\t\t\t\t'id' => $key,\n\t\t\t\t'type' => $value['type'],\n\t\t\t\t'std' => '',\n\t\t\t\t'class' => 'custom-class',\n\t\t\t\t'clone' => false\n\t\t\t);\n\t\t\t$findex++;\n\t\t}\n\t\t$metabox = array(\n\t\t\t'id' => 'projectal',\n\t\t\t'title' => 'Projectal Information',\n\t\t\t'pages' => array( $this->multiple ),\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'high',\n\t\t\t'fields' => $figo\n\t\t);\n\t\t new RW_Meta_Box($metabox);\n\t}", "function thirdtheme_room_page()\n {\n add_theme_support('post-thumbnails');\n add_image_size('room_size',268,281); \n $args = array(\n 'labels' => array('name' =>__('room page'),\n 'add_new' =>__('add new room photo')),\n \n 'public' => true,\n 'menu_icon' =>'dashicons-art',\n 'show_in_menu' => true,\n 'has_archive' => true,\n 'supports' => array( 'title', 'editor', 'author', 'thumbnail','excerpt')); \n register_post_type('room',$args);\n }", "public static function init() {\n\t\tadd_action( 'init', array( __CLASS__, 'register_post_type' ), 1 );\n\t}", "private function initCustomPostType(){\n //Instantiate our custom post type object\n $this->cptWPDS = new PostType($this->wpdsPostType);\n \n //Set our custom post type properties\n $this->cptWPDS->setSingularName($this->wpdsPostTypeName);\n $this->cptWPDS->setPluralName($this->wpdsPostTypeNamePlural);\n $this->cptWPDS->setMenuName($this->wpdsPostTypeNamePlural);\n $this->cptWPDS->setLabels('Add New', 'Add New '.$this->wpdsPostTypeName, 'Edit '.$this->wpdsPostTypeName, 'New '.$this->wpdsPostTypeName, 'All '.$this->wpdsPostTypeNamePlural, 'View '.$this->wpdsPostTypeNamePlural, 'Search '.$this->wpdsPostTypeNamePlural, 'No '.strtolower($this->wpdsPostTypeNamePlural).' found', 'No '.strtolower($this->wpdsPostTypeNamePlural).' found in the trash');\n $this->cptWPDS->setMenuIcon('dashicons-welcome-write-blog');\n $this->cptWPDS->setSlug($this->wpdsPostType);\n $this->cptWPDS->setDescription('Writings from the universe');\n $this->cptWPDS->setShowInMenu(true);\n $this->cptWPDS->setPublic(true);\n $this->cptWPDS->setTaxonomies([$this->wpdsPostType]);\n $this->cptWPDS->removeSupports(['title']);\n \n //Register custom post type\n $this->cptWPDS->register();\n }", "public function __construct() {\n\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'enqueue_scripts' ) );\n\n\t\tadd_shortcode( 'demo-test', array( $this, 'demo_shortcode' ) );\n\n\t\tadd_action( 'init', array( $this, 'register_post_type' ) );\n\n\t\tadd_action( 'init', array( $this, 'generate_custom_post_type' ) );\n\n\t\t//add_action( 'init', array( $this, 'rewrite_rules' ) );\n\n\t\tadd_action( 'template_include', array( $this, 'custom_post_type_archive' ) );\n\n\t\tadd_action( 'template_include', array( $this, 'custom_post_type_archive_template' ) );\n\n\t\tadd_filter( 'single_template', array( $this, 'get_custom_post_type_template' ) );\n\n\t\tadd_action( 'admin_menu', array( $this, 'custom_menu_page' ) );\n\n\t\tadd_action( 'admin_init', array( $this, 'add_options' ) );\n\n\t\tadd_action( 'init', array( $this, 'generate_post_type' ) );\n\n\t\tadd_filter( 'post_type_link', array( $this, 'update_permalinks' ), 10, 2 );\n\t\tadd_filter( 'post_type_link', array( $this, 'update_post_permalinks' ), 10, 2 );\n\n\t\tadd_filter('term_link', array( $this, 'update_term_link' ) );\n\n\t add_action( 'wp_footer', function() {\n\t\t\tglobal $wp_query;\n\t\t\t//print_r( $wp_query );\n\t\t\tprint_r($this->post_types);\n\t\t});\n\t}", "function yee_post_type_testimonial_init(){\n\t$labels =array(\n\t\t'name'=>'Testimonials',\n\t\t'sigular_name'=>'Testimonial',\n\t\t'add_new'=>__('Add New Testimonial','Storefront-Child'),\n\t\t'add_new_item'=>__('Add New Testimonial','Storefront-Child'),\n\t\t'edit_item'=>__('Edit Testimonial','Storefront-Child'),\n\t\t'new_item'=>__('New Testimonial','Storefront-Child'),\n\t\t'view_item'=>__('View Testimonial','Storefront-Child'),\n\t\t'view_items'=>__('View Testimonials','Storefront-Child'),\n\t\t'all_items'=>__('All Testimonials','Storefront-Child'),\n\t\t'search_items'=>__('Search Testimonials','Storefront-Child')\n\t);\n\t$args =array(\n\t\t'labels'=>$labels,\n\t\t'public'=>true,\n\t\t'menu_position'=>5,\n\t\t'menu_icon'=>'dashicons-visibility',\n\t\t'hierarchical'=>false,\n\t\t'has_archive'=>true,\n\t\t'supports'=>array('title','editor','thumbnail','excerpt'),\n\t\t'rewrite'=>array('slug'=>'testimonial')\n\t\t\n\t);\n\tregister_post_type('yee_testimonial',$args);\n}", "function setup() {\n\tadd_filter( 'intermediate_image_sizes_advanced', __NAMESPACE__ . '\\\\disable_upload_sizes', 10, 2 );\n\tadd_filter( 'post_thumbnail_size', __NAMESPACE__ . '\\\\force_full_size_gifs', 10, 1 );\n}", "public function __construct(){\n //Create our custom taxonomy\n $this->initCustomTaxonomy();\n \n //Create our custom post type\n $this->initCustomPostType();\n \n //Manage our columns for our admin page\n $this->initColumns();\n }", "public static function cpt_init() {\n\t\tforeach ( self::$types as $type ) {\n\t\t\tself::evo_custom_post_type( $type['type'] );\n\t\t}\n\t}", "function dark_urban_init() {\n register_taxonomy_for_object_type( 'category', 'attachment' );\n register_taxonomy_for_object_type( 'post_tag', 'attachment' );\n\n /*\n * Register custom post types. You can also move this code to a plugin.\n */\n /* Pinegrow generated Custom Post Types Begin */\n\n /* Pinegrow generated Custom Post Types End */\n \n /*\n * Register custom taxonomies. You can also move this code to a plugin.\n */\n /* Pinegrow generated Taxonomies Begin */\n\n /* Pinegrow generated Taxonomies End */\n\n}", "function banner_images_init() {\n\n\t$args = array(\n\n\t\t'label' => 'Banner Image',\n\n\t\t'public' => true,\n\n\t\t'show_ui' => true,\n\n\t\t'capability_type' => 'post',\n\n\t\t'hierarchical' => false,\n\n\t\t'rewrite' => array('slug' => 'banner'),\n\n\t\t'query_var' => true,\n\n\t\t'menu_icon' => 'dashicons-format-gallery',\n\n\t\t'supports' => array(\n\n\t\t\t'title', \n\n\t\t\t'thumbnail',\n\n\t\t)\n\n\t);\n\n\tregister_post_type( 'banner', $args );\n\n}", "public function __construct() {\n\n\t\t// parent constructor must be called first\n\t\tparent::__construct();\n\n\t\t// override thumbnail dimensions of you want to\n\t\t$this->set('thumbWidth', 100);\n\t\t$this->set('thumbHeight', 100);\n\n\t\t// class substitutions for Zurb foundation styles\n\t\t$this->setClassAttr(array(\n\t\t\t'num-posts' => 'white label num-posts',\n\t\t\t'page-num' => 'white label page-num',\n\t\t\t'date' => 'white label date',\n\t\t\t'alert-success' => 'alert-box success',\n\t\t\t'alert-error' => 'alert-box error',\n\t\t\t'link-next-prev' => 'link-next-prev block-grid two-up',\n\t\t\t'pagination' => 'pagination',\n\t\t\t));\n\t\t\n\t}", "public function action_init() {\n\n\t\t$this->register_gallery_post_type();\n\n\t}", "private function setup_theme() {\n\n\t\tforeach( $this->get_image_sizes() as $image_size => $values ) {\n\t\t\tadd_image_size( $image_size, $values[0], $values[1] );\n\t\t}\n\n\t}", "function my_register_image_sizes() {\r\n\t// Add new image sizes\r\n\tadd_image_size('hero-full', 940, 460, true); // used for destination, library, home\r\n\tadd_image_size('hero-medium', 620, 300, true); // used for region\r\n\tadd_image_size('hero-review', 620, 413, true); // used for reviews - ie, hotel, restaurant, etc\r\n\tadd_image_size('thumb-large', 300, 200, true); // used for destination landing page, home page, special offer page\r\n\tadd_image_size('thumb-feature', 450, 375, true); // used for featured destination partners\r\n\tadd_image_size('thumb-medium', 220, 146, true); // used for related items, and listing pages for hotel, restaurant\r\n\tadd_image_size('thumb-small', 140, 95, true); // used for recent items\r\n}", "function prso_init_theme_post_types() {\n\t\n\t//Init vars\n\tglobal $prso_posttype_admin_icon;\n\t$file_path = plugin_dir_path( __FILE__ ) . \"theme-post-types\";\n\t\n\t$prso_posttype_admin_icon = get_stylesheet_directory_uri() . '/images/admin/custom_post_icon.png';\n\t\n\t//include_once( $file_path . '/cuztom-post-type_TEMPLATE.php' );\n\t\n}", "function __construct(){\n\t\t\tadd_action( 'init' , array( $this, 'custom_post_type' ) );\n\t\t}", "public function setup_posttype() {\n register_post_type( 'brg_post_templates',\n array(\n 'labels' => array(\n 'name' => 'Templates',\n 'singular_name' => 'Template'\n ),\n 'description' => 'Template for a post type single view',\n 'public' => false,\n 'show_ui' => true\n )\n );\n }", "function carouF_init(){\n\n $labels = array(\n \"name\" => \"Carrousel\",\n \"singular_name\" => \"Carrousel\",\n \"add_new\" => \"Ajouter un Carrousel\",\n \"add_new_item\" => \"Ajouter un nouveau Slide\",\n \"new_item\" => \"Nouveau Carrousel\",\n \"view_item\" => \"Voir Carrousel\",\n \"search_item\" => \"Rechercher un Carrousel\",\n \"not_found\" => \"aucun Carrousel\",\n \"not_found_in_trash\" => \"aucun Caroussel dans la corbeille\",\n \"parent_item_colon\" => \"\",\n \"menu_name\" => \"Carrousel\"\n\n );\n\n register_post_type(\"slide\", array(\n \"public\" => true,\n \"publicity_queryable\" => false,\n \"labels\" => $labels,\n \"menu_position\" => 8,\n \"capability_type\" => \"post\",\n \"supports\" => array(\"title\", \"thumbnail\")\n ));\n\n add_image_size(\"Caroussel\", 1000, 3000, true);\n}", "public function init()\n {\n $this->nameSingular = __('Image', 'modularity');\n $this->namePlural = __('Images', 'modularity');\n $this->description = __('Outputs an image', 'modularity');\n\n add_action('acf/load_field/name=mod_image_size', array($this, 'appendImageSizes'));\n }", "public function initPostType(){\n\t\tforeach( $this->posttype as $pt ){\n\t\t\t$pt = WPO_FRAMEWORK_POSTTYPE.$pt.'.php';\n\t\t\tif( is_file($pt) ){\n\t\t\t\trequire_once($pt);\n\t\t\t}\n\t\t}\n\t}", "public function set_up() {\n\t\tparent::set_up();\n\n\t\t$this->registry = new WP_Block_Type_Registry();\n\t}", "function create_post_type() {\n \n $lwa_feature_post_type = array(\n 'labels' => array(\n 'name' => __( 'Featured posts' ),\n 'singular_name' => __( 'Featured' ),\n ),\n 'description' => __( 'Featured articles are defined within this type' ),\n 'hierarchical' => true, \n 'show_ui' => true,\n 'public' => true,\n 'has_archive' => true,\n 'rewrite' => array('slug' => 'featured/%featured_tax%', 'with_front' => false),\n 'menu_position' => 5,\n 'supports' => array('title', 'editor', 'thumbnail', 'author', 'revisions' ),\n 'taxonomies' => array( 'featured_tax', 'subtitle', 'carousel' )\n );\n\n $lwa_news_post_type = array(\n 'labels' => array(\n 'name' => __( 'News posts' ),\n 'singular_name' => __( 'News' ),\n ),\n 'description' => __( 'News articles are defined within this type' ),\n 'hierarchical' => true,\n 'show_ui' => true,\n 'public' => true,\n 'has_archive' => true,\n 'rewrite' => array('slug' => 'news/%news_tax%', 'with_front' => false),\n 'menu_position' => 5,\n 'supports' => array('title', 'editor', 'thumbnail', 'author', 'revisions' ),\n 'taxonomies' => array( 'news_tax', 'subtitle', 'carousel' )\n );\n\n $lwa_shop_post_type = array(\n 'labels' => array(\n 'name' => __( 'Shop posts' ),\n 'singular_name' => __( 'Shop' ),\n ),\n 'description' => __( 'Shop articles are defined within this type' ),\n 'hierarchical' => true,\n 'show_ui' => true,\n 'public' => true,\n 'has_archive' => true,\n // 'rewrite' => array('slug' => 'news/%news_tax%', 'with_front' => false),\n 'menu_position' => 5,\n 'supports' => array('title', 'editor', 'thumbnail', 'author', 'revisions' ),\n 'taxonomies' => array( 'subtitle', 'carousel' )\n );\n\n register_post_type( 'lwa_feature', $lwa_feature_post_type );\n register_post_type( 'lwa_news', $lwa_news_post_type );\n register_post_type( 'lwa_shop', $lwa_shop_post_type );\n}", "public function admin_init()\n \t{\t\t\t\n \t\t// Add metaboxes\n \t\tadd_action('add_meta_boxes', array($this, 'add_meta_boxes'));\n\t\t\t\n\t\t\t// Add scripts\n\t\t\tadd_action( 'admin_enqueue_scripts', array($this, 'prfx_image_enqueue'));\n \t}", "public static function init() {\n\t\t\n \t\tadd_action( 'init', array(get_class(), 'init_tax'), 0 );\n\t\t// Template\n\t\tadd_filter('template_include', array( get_class(), 'override_template' ) );\n\t\t// Meta Boxes\n\t\tadd_action( 'add_meta_boxes', array(get_class(), 'add_meta_boxes'));\n\t\tadd_action( 'save_post', array( get_class(), 'save_meta_boxes' ), 10, 2 );\n\t\t\n\t}", "function custom_post_type() {\n $labels = array(\n 'name' => _x( 'Ort', 'Post Type General Name', 'twentythirteen' ),\n 'singular_name' => _x( 'Ort', 'Post Type Singular Name', 'twentythirteen' ),\n 'menu_name' => __( 'Orter', 'twentythirteen' ),\n 'all_items' => __( 'Alla Orter', 'twentythirteen' ),\n 'view_item' => __( 'View Ort', 'twentythirteen' ),\n 'add_new_item' => __( 'Skapa ny Ort', 'twentythirteen' ),\n 'add_new' => __( 'Skapa ny Ort', 'twentythirteen' ),\n 'edit_item' => __( 'Redigera Ort', 'twentythirteen' ),\n 'update_item' => __( 'Upddatera Ort', 'twentythirteen' ),\n 'search_items' => __( 'Sök Ort', 'twentythirteen' ),\n 'not_found' => __( 'Not Found', 'twentythirteen' ),\n 'not_found_in_trash' => __( 'Not found in Trash', 'twentythirteen' ),\n );\n \n $args = array(\n 'label' => __( 'cities', 'twentythirteen' ),\n 'description' => __( 'City Post Page', 'twentythirteen' ),\n 'labels' => $labels,\n 'supports' => array('title','thumbnail',),\n 'hierarchical' => false,\n 'public' => true,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'show_in_nav_menus' => true,\n 'show_in_admin_bar' => true,\n 'menu_position' => 5,\n 'can_export' => true,\n 'has_archive' => true,\n 'exclude_from_search' => false,\n 'publicly_queryable' => true,\n 'capability_type' => 'page',\n );\n \n register_post_type( 'cities', $args );\n\n }", "public function __construct() {\n\t\t\tadd_action( 'init', array( &$this, 'register_post_type' ) );\n\t\t}", "function urbanfitness_setup()\n{\n // Register new image size\n //add_image_size($name, $width, $height, $crop);\n add_image_size('square', 350, 350, true);\n add_image_size('portrait', 350, 724, true);\n add_image_size('box', 400, 375, true);\n //wordpress has a medium size for images but having a custom makes it safer if you decide to change themes\n add_image_size('mediumSize', 700, 400, true);\n add_image_size('blog', 966, 644, true);\n\n // Add featured image\n add_theme_support('post-thumbnails');\n\n //SEO Titles\n add_theme_support('title-tag');\n}", "function jacqueline_templates_theme_setup() {\n\t\tadd_filter( 'image_size_names_choose', 'jacqueline_show_thumb_sizes');\n\t}", "function wp_fathom_clean_setup() {\n\t\n\tadd_theme_support( 'post-formats',\n array( 'article' )\n );\n\n\tadd_theme_support( 'post-thumbnails' );\n\n // register_nav_menu( 'first', 'first' );\n \n\t// set_post_thumbnail_size( 505, 400, true );\n\t\n // add_image_size( 'square', 160, 160, true );\n \n\n}", "function tcf_init() {\n require_once( 'library/custom-post-type.php' );\n\n // launching operation cleanup\n add_action( 'init', 'tcf_head_cleanup' );\n // A better title\n add_filter( 'wp_title', 'rw_title', 10, 3 );\n // remove WP version from RSS\n add_filter( 'the_generator', 'tcf_rss_version' );\n // remove pesky injected css for recent comments widget\n add_filter( 'wp_head', 'remove_wp_widget_recent_comments_style', 1 );\n // clean up comment styles in the head\n add_action( 'wp_head', 'remove_recent_comments_style', 1 );\n // clean up gallery output in wp\n add_filter( 'gallery_style', 'tcf_gallery_style' );\n\n // enqueue base scripts and styles\n add_action( 'wp_enqueue_scripts', 'tcf_scripts_and_styles', 800 );\n add_action( 'wp_enqueue_scripts', 'template_scripts_and_styles', 999 );\n // ie conditional wrapper\n\n // launching this stuff after theme setup\n tcf_theme_support();\n\n // adding sidebars to Wordpress (these are created in functions.php)\n add_action( 'widgets_init', 'tcf_register_sidebars' );\n\n // cleaning up random code around images\n add_filter( 'the_content', 'filter_ptags_on_images' );\n // cleaning up excerpt\n add_filter( 'excerpt_more', 'tcf_excerpt_more' );\n\n}", "public function create_post_types() {\r\n register_post_type( 'cycloneslider',\r\n array(\r\n 'labels' => array(\r\n 'name' => __('Cyclone Slider', 'cyclone-slider-2'),\r\n 'singular_name' => __('Slideshow', 'cyclone-slider-2'),\r\n 'add_new' => __('Add Slideshow', 'cyclone-slider-2'),\r\n 'add_new_item' => __('Add New Slideshow', 'cyclone-slider-2'),\r\n 'edit_item' => __('Edit Slideshow', 'cyclone-slider-2'),\r\n 'new_item' => __('New Slideshow', 'cyclone-slider-2'),\r\n 'view_item' => __('View Slideshow', 'cyclone-slider-2'),\r\n 'search_items' => __('Search Slideshows', 'cyclone-slider-2'),\r\n 'not_found' => __('No slideshows found', 'cyclone-slider-2'),\r\n 'not_found_in_trash' => __('No slideshows found in Trash', 'cyclone-slider-2')\r\n ),\r\n 'supports' => array('title'),\r\n 'public' => false,\r\n 'exclude_from_search' => true,\r\n 'show_ui' => true,\r\n 'menu_position' => 100,\r\n 'can_export' => false // Exclude from export\r\n )\r\n );\r\n }", "public function admin_init() {\n\t\tif ( count( $this->get_gallery_types() ) < 2 ) {\n\t\t\treturn;\n\t\t}\n\n\t\tload_plugin_textdomain( 'gallery-types', false, plugin_basename( PLUGIN_DIR ) . '/languages' );\n\n\t\tadd_action( 'wp_enqueue_media', [ $this, 'enqueue_script' ] );\n\t\tadd_action( 'print_media_templates', [ $this, 'print_js_template' ] );\n\t\tadd_filter( 'media_view_settings', [ $this, 'gallery_default_shortcode_atts' ] );\n\t}", "private function initMetaBox(){\n\t\t$path = get_template_directory() . '/sub/customfield/';\n\t\tif(function_exists('of_get_option')){\n\t\t\tif(of_get_option('is-seo',true)){\n\t\t\t\tnew WPO_MetaBox(array(\n\t\t\t\t 'id' => 'wpo_seo',\n\t\t\t\t 'title' => $this->l('SEO Fields'),\n\t\t\t\t 'types' => array('page','portfolio','post','video'),\n\t\t\t\t 'priority' => 'high',\n\t\t\t\t 'template' => $path . 'seo.php',\n\t\t\t\t));\n\t\t\t}\n\t\t}\n\n\t\tnew WPO_MetaBox(array(\n\t\t 'id' => 'wpo_template',\n\t\t 'title' => $this->l('Advanced Configuration'),\n\t\t 'types' => array('page'),\n\t\t 'priority' => 'high',\n\t\t 'template' => $path . 'page-advanced.php'\n\t\t));\n\n\t\tnew WPO_MetaBox(array(\n\t\t 'id' => 'wpo_pageconfig',\n\t\t 'title' => $this->l('Page Configuration'),\n\t\t 'types' => array('page'),\n\t\t 'priority' => 'high',\n\t\t 'template' => $path . 'page.php',\n\t\t));\n\n\t\tnew WPO_MetaBox(array(\n\t\t 'id' => 'wpo_post',\n\t\t 'title' => $this->l('Embed Options'),\n\t\t 'types' => array('post','video'),\n\t\t 'priority' => 'high',\n\t\t 'template' => $path . 'post.php',\n\t\t));\n\t}", "function gs_theme_setup() {\r\n\r\n\t/**\r\n\t * Load the theme functions library\r\n\t */\r\n\trequire_once('inc/library.php');\r\n\r\n\t/**\r\n\t * Load custom post types\r\n\t */\r\n\trequire_once('inc/cpt.slides.php'); \r\n\r\n\t/**\r\n\t * Load custom widgets\r\n\t */\r\n\trequire_once('inc/widget.feature-box/widget.feature-box.php'); \r\n\trequire_once('inc/widget.gs-recent-posts/widget.gs-recent-posts.php'); \r\n\r\n\t/**\r\n\t * Load custom admin features\r\n\t */\r\n\trequire_once('inc/admin/admin-branding.php'); \r\n\trequire_once('inc/admin/admin-menu.php'); \r\n\trequire_once('inc/admin/dashboard.recent-drafts.php'); \r\n\trequire_once('inc/admin/remove-dashboard-widgets.php'); \r\n\trequire_once('inc/admin/remove-default-widgets.php'); \r\n\trequire_once('inc/admin/tinymce-editor.php'); \r\n\trequire_once('inc/admin/user-capabilities.php'); \r\n\r\n \t/**\r\n * Removes WordPress version number from the document head (for security).\r\n\t *\r\n */\t\r\n\tremove_action('wp_head', 'wp_generator');\r\n\r\n \t/**\r\n * Registers theme menus.\r\n */\t\r\n\tregister_nav_menu('main', 'Main Navigation Menu');\r\n\t//register_nav_menu('Your Menu Name', 'Your Menu Description');\r\n\r\n \t/**\r\n * Registers thumbnail and featured image sizes.\r\n */\t\r\n\tadd_theme_support( 'post-thumbnails' );\r\n\tset_post_thumbnail_size( 150, 150, true ); // Normal post thumbnails\r\n\tadd_image_size( 'slide', 960, 300, true );\r\n\t//add_image_size( 'custom-thumb-name', 150, 150, true ); \r\n\r\n}", "function themo_tour_custom_post_type() {\n\n $labels = array(\n 'name' => _x( 'Tours', 'Post Type General Name', 'th-widget-pack' ),\n 'singular_name' => _x( 'Tour', 'Post Type Singular Name', 'th-widget-pack' ),\n 'menu_name' => __( 'Tours', 'th-widget-pack' ),\n 'parent_item_colon' => __( 'Parent Tour:', 'th-widget-pack' ),\n 'all_items' => __( 'All Tours', 'th-widget-pack' ),\n 'view_item' => __( 'View Tour', 'th-widget-pack' ),\n 'add_new_item' => __( 'Add New Tours', 'th-widget-pack' ),\n 'add_new' => __( 'Add New', 'th-widget-pack' ),\n 'edit_item' => __( 'Edit Tour', 'th-widget-pack' ),\n 'update_item' => __( 'Update Tour', 'th-widget-pack' ),\n 'search_items' => __( 'Search Tour', 'th-widget-pack' ),\n 'not_found' => __( 'Not found', 'th-widget-pack' ),\n 'not_found_in_trash' => __( 'Not found in Trash', 'th-widget-pack' ),\n );\n\n if ( function_exists( 'get_theme_mod' ) ) {\n $custom_slug = get_theme_mod( 'themo_tour_rewrite_slug', 'tour' );\n } else {\n $custom_slug = 'tour';\n }\n\n $rewrite = array(\n 'slug' => $custom_slug,\n 'with_front' => false,\n 'pages' => true,\n 'feeds' => true,\n );\n $args = array(\n 'label' => __( 'themo_tour', 'th-widget-pack' ),\n 'description' => __( 'Tours', 'th-widget-pack' ),\n 'labels' => $labels,\n 'supports' => array( 'title', 'editor', 'excerpt', 'author', 'thumbnail', 'comments', 'trackbacks', 'revisions', 'custom-fields', 'page-attributes', 'post-formats', ),\n 'taxonomies' => array( 'themo_tour_type' ),\n 'hierarchical' => false,\n 'public' => true,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'show_in_nav_menus' => true,\n 'show_in_admin_bar' => true,\n 'menu_position' => 5,\n 'menu_icon' => 'dashicons-location-alt',\n 'can_export' => true,\n 'has_archive' => false,\n 'exclude_from_search' => false,\n 'publicly_queryable' => true,\n 'rewrite' => $rewrite,\n 'capability_type' => 'post',\n );\n register_post_type( 'themo_tour', $args );\n\n }", "public function init()\n {\n $labels = array(\n 'name' => __('Stacks', 'lambda-admin-td'),\n 'singular_name' => __('Stack', 'lambda-admin-td'),\n 'add_new' => __('Add New', 'lambda-admin-td'),\n 'add_new_item' => __('Add New Stack', 'lambda-admin-td'),\n 'edit_item' => __('Edit Stack', 'lambda-admin-td'),\n 'new_item' => __('New Stack', 'lambda-admin-td'),\n 'all_items' => __('All Stacks', 'lambda-admin-td'),\n 'view_item' => __('View Stack', 'lambda-admin-td'),\n 'search_items' => __('Search Stack', 'lambda-admin-td'),\n 'not_found' => __('No Stack found', 'lambda-admin-td'),\n 'not_found_in_trash' => __('No Stack found in Trash', 'lambda-admin-td'),\n 'menu_name' => __('Stacks', 'lambda-admin-td')\n );\n\n $labels = apply_filters('oxy_stack_labels', $labels);\n\n $args = array(\n 'labels' => $labels,\n 'public' => true,\n 'publicly_queryable' => false,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'query_var' => false,\n 'capability_type' => 'post',\n 'menu_position' => null,\n 'menu_icon' => 'dashicons-art',\n 'supports' => array( 'title' )\n );\n register_post_type($this->post_type, $args);\n }", "public function __construct() {\n\n // Register the post type\n add_action('init', [ $this, 'reg_post_type' ] );\n add_action('init', [ $this, 'add_taxonomy' ] );\n add_action('init', [ $this, 'add_tags' ] );\n\n add_action( 'add_meta_boxes', [ $this, 'add_metabox' ], 1 );\n add_action( 'save_post', [ $this, 'save_metabox' ], 10, 2 );\n\n }", "function rng_create_post_type() {\n\n\t$labels = array(\n\t\t'name' => _x( 'Post Types Plural', 'Post Type General Name', 'translate_name' ),\n\t\t'singular_name' => _x( 'Post Type Singular', 'Post Type Singular Name', 'translate_name' ),\n\t\t'menu_name' => __( 'Post Types', 'translate_name' ),\n\t\t'name_admin_bar' => __( 'Post Type', 'translate_name' ),\n\t\t'archives' => __( 'Item Archives', 'translate_name' ),\n\t\t'attributes' => __( 'Item Attributes', 'translate_name' ),\n\t\t'parent_item_colon' => __( 'Parent Item:', 'translate_name' ),\n\t\t'all_items' => __( 'All Items', 'translate_name' ),\n\t\t'add_new_item' => __( 'Add New Item', 'translate_name' ),\n\t\t'add_new' => __( 'Add New', 'translate_name' ),\n\t\t'new_item' => __( 'New Item', 'translate_name' ),\n\t\t'edit_item' => __( 'Edit Item', 'translate_name' ),\n\t\t'update_item' => __( 'Update Item', 'translate_name' ),\n\t\t'view_item' => __( 'View Item', 'translate_name' ),\n\t\t'view_items' => __( 'View Items', 'translate_name' ),\n\t\t'search_items' => __( 'Search Item', 'translate_name' ),\n\t\t'not_found' => __( 'Not found', 'translate_name' ),\n\t\t'not_found_in_trash' => __( 'Not found in Trash', 'translate_name' ),\n\t\t'featured_image' => __( 'Featured Image', 'translate_name' ),\n\t\t'set_featured_image' => __( 'Set featured image', 'translate_name' ),\n\t\t'remove_featured_image' => __( 'Remove featured image', 'translate_name' ),\n\t\t'use_featured_image' => __( 'Use as featured image', 'translate_name' ),\n\t\t'insert_into_item' => __( 'Insert into item', 'translate_name' ),\n\t\t'uploaded_to_this_item' => __( 'Uploaded to this item', 'translate_name' ),\n\t\t'items_list' => __( 'Items list', 'translate_name' ),\n\t\t'items_list_navigation' => __( 'Items list navigation', 'translate_name' ),\n\t\t'filter_items_list' => __( 'Filter items list', 'translate_name' ),\n\t);\n\t$args = array(\n 'public' => true,\n\t\t'label' => __( 'Post Type Singular', 'translate_name' ),\n\t\t'description' => __( 'Post Type Description', 'translate_name' ),\n 'labels' => $labels,\n 'exclude_from_search' => true,\n 'publicly_queryable' => true,\n 'show_ui' => true,\n\t\t'show_in_nav_menus' => true,\n\t\t'show_in_menu'\t\t\t=> true,\n\t\t'show_in_admin_bar'\t\t=> true,\n\t\t'menu_position'\t\t\t=> 5,\n\t\t// 'menu_icon' \t\t\t=> get_bloginfo('template_directory') . '/images/portfolio-icon.png',\n\t\t'menu_icon'\t\t\t\t=> 'dashicon-groups',\n\t\t'has_archive'\t\t\t=> true,\n\t\t'capability_type'\t\t=> array('book','books'),\n\t\t'capabilities' \t\t\t=> array(\n\t\t\t'edit_post' => 'edit_book', \n\t\t\t'read_post' => 'read_book', \n\t\t\t'delete_post' => 'delete_book', \n\t\t\t'edit_posts' => 'edit_books', \n\t\t\t'edit_others_posts' => 'edit_others_books', \n\t\t\t'publish_posts' => 'publish_books', \n\t\t\t'read_private_posts' => 'read_private_books', \n\t\t\t'create_posts' => 'edit_books', \n\t\t),\n\t\t'supports' => array( 'title', 'editor', 'thumbnail', 'page-attributes', 'post-formats' ),\n\t\t'taxonomies' => array( 'category', 'post_tag' ),\n\t\t'hierarchical' => true,\n\t);\n\tregister_post_type( 'book', $args );\n\n}", "function albums_post_type() {\n\n $labels = array(\n 'name' => _x( 'Albums', 'Post Type General Name', 'text_domain' ),\n 'singular_name' => _x( 'Album', 'Post Type Singular Name', 'text_domain' ),\n 'menu_name' => __( 'Albums', 'text_domain' ),\n 'name_admin_bar' => __( 'Album', 'text_domain' ),\n 'archives' => __( 'Album', 'text_domain' ),\n 'parent_item_colon' => __( 'Superior:', 'text_domain' ),\n 'all_items' => __( 'Todos', 'text_domain' ),\n 'add_new_item' => __( 'Agregar Album nuevo', 'text_domain' ),\n 'add_new' => __( 'Agregar nuevo', 'text_domain' ),\n 'new_item' => __( 'Nuevo Album', 'text_domain' ),\n 'edit_item' => __( 'Editar Album', 'text_domain' ),\n 'update_item' => __( 'Actualizar Album', 'text_domain' ),\n 'view_item' => __( 'Ver Album', 'text_domain' ),\n 'search_items' => __( 'Buscar Album', 'text_domain' ),\n 'not_found' => __( 'No encontrado', 'text_domain' ),\n 'not_found_in_trash' => __( 'No encontrado en la Papelera', 'text_domain' ),\n 'featured_image' => __( 'Carátula del disco', 'text_domain' ),\n 'set_featured_image' => __( 'Cargar carátula', 'text_domain' ),\n 'remove_featured_image' => __( 'Quitar carátula', 'text_domain' ),\n 'use_featured_image' => __( 'Usar como carátula', 'text_domain' ),\n 'insert_into_item' => __( 'Insertar en el Album', 'text_domain' ),\n 'uploaded_to_this_item' => __( 'Cargado en este Album', 'text_domain' ),\n 'items_list' => __( 'Lista de Albums', 'text_domain' ),\n 'items_list_navigation' => __( 'Navegar la lista de Albums', 'text_domain' ),\n 'filter_items_list' => __( 'Filtrar Albums', 'text_domain' ),\n );\n $args = array(\n 'label' => __( 'Album', 'text_domain' ),\n 'description' => __( 'Albums lanzados por Domus', 'text_domain' ),\n 'labels' => $labels,\n 'supports' => array( 'title', 'editor', 'thumbnail', 'excerpt' ),\n 'taxonomies' => array( 'artistas' ),\n 'hierarchical' => false,\n 'public' => true,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'menu_position' => 5,\n 'menu_icon' => 'dashicons-format-audio',\n 'show_in_admin_bar' => true,\n 'show_in_nav_menus' => true,\n 'can_export' => true,\n 'has_archive' => true, \n 'exclude_from_search' => false,\n 'publicly_queryable' => true,\n 'capability_type' => 'page',\n );\n register_post_type( 'albums', $args );\n\n}", "function create_post_type(){\n\n\t/*|>>>>>>>>>>>>>>>>>>>> SLIDER HOME <<<<<<<<<<<<<<<<<<<<|*/\n\t\n\t$labels = array(\n\t\t'name' => __('Slider Home'),\n\t\t'singular_name' => __('Slider'),\n\t\t'add_new' => __('Nuevo Slider'),\n\t\t'add_new_item' => __('Agregar nuevo Slider Principal'),\n\t\t'edit_item' => __('Editar Slider'),\n\t\t'view_item' => __('Ver Slider'),\n\t\t'search_items' => __('Buscar Slider'),\n\t\t'not_found' => __('Slider no encontrado'),\n\t\t'not_found_in_trash' => __('Slider no encontrado en la papelera'),\n\t);\n\n\t$args = array(\n\t\t'labels' => $labels,\n\t\t'has_archive' => true,\n\t\t'public' => true,\n\t\t'hierachical' => true,\n\t\t'supports' => array('title','editor','excerpt','custom-fields','thumbnail','page-attributes'),\n\t\t'taxonomies' => array('post-tag','banner_category'),\n\t\t'menu_icon' => 'dashicons-nametag',\n\t);\n\n\t/*|>>>>>>>>>>>>>>>>>>>> SERVICIOS <<<<<<<<<<<<<<<<<<<<|*/\n\t\n\t$labels2 = array(\n\t\t'name' => __('Servicios'),\n\t\t'singular_name' => __('Servicio'),\n\t\t'add_new' => __('Nuevo Servicio'),\n\t\t'add_new_item' => __('Agregar nuevo Servicio'),\n\t\t'edit_item' => __('Editar Servicio'),\n\t\t'view_item' => __('Ver Servicio'),\n\t\t'search_items' => __('Buscar Servicios'),\n\t\t'not_found' => __('Servicio no encontrado'),\n\t\t'not_found_in_trash' => __('Servicio no encontrado en la papelera'),\n\t);\n\n\t$args2 = array(\n\t\t'labels' => $labels2,\n\t\t'has_archive' => true,\n\t\t'public' => true,\n\t\t'hierachical' => false,\n\t\t'supports' => array('title','editor','excerpt','custom-fields','thumbnail','page-attributes' ),\n\t\t'taxonomies' => array( 'servicio_category' , 'post_tag' ),\n\t\t'menu_icon' => 'dashicons-exerpt-view',\n\t);\t\n\n\t/*|>>>>>>>>>>>>>>>>>>>> CLIENTES <<<<<<<<<<<<<<<<<<<<|*/\n\t\n\t$labels3 = array(\n\t\t'name' => __('Clientes'),\n\t\t'singular_name' => __('Sector o Categoría'),\n\t\t'add_new' => __('Nuevo Sector o Categoría'),\n\t\t'add_new_item' => __('Agregar nuevo Sector o Categoría'),\n\t\t'edit_item' => __('Editar Sector o Categoría'),\n\t\t'view_item' => __('Ver Sector o Categoría'),\n\t\t'search_items' => __('Buscar Sector o Categoría'),\n\t\t'not_found' => __('Sector o Categoría no encontrado'),\n\t\t'not_found_in_trash' => __('Sector o Categoría no encontrado en la papelera'),\n\t);\n\n\t$args3 = array(\n\t\t'labels' => $labels3,\n\t\t'has_archive' => true,\n\t\t'public' => true,\n\t\t'hierachical' => false,\n\t\t'supports' => array('title','editor','excerpt','custom-fields','thumbnail','page-attributes'),\n\t\t'taxonomies' => array('post-tag'),\n\t\t'menu_icon' => 'dashicons-money',\n\t);\t\n\n\t\n\t/*|>>>>>>>>>>>>>>>>>>>> GALERÍA IMAGENES <<<<<<<<<<<<<<<<<<<<|*/\n\t\n\t$labels4 = array(\n\t\t'name' => __('Gal. Imágenes'),\n\t\t'singular_name' => __('Galería'),\n\t\t'add_new' => __('Nueva Galería'),\n\t\t'add_new_item' => __('Agregar nueva Galería'),\n\t\t'edit_item' => __('Editar Galería'),\n\t\t'view_item' => __('Ver Galería'),\n\t\t'search_items' => __('Buscar Galería'),\n\t\t'not_found' => __('Galería no encontrada'),\n\t\t'not_found_in_trash' => __('Galería no encontrada en la papelera'),\n\t);\n\n\t$args4 = array(\n\t\t'labels' => $labels4,\n\t\t'has_archive' => true,\n\t\t'public' => true,\n\t\t'hierachical' => false,\n\t\t'supports' => array('title','editor','excerpt','custom-fields','thumbnail','page-attributes'),\n\t\t'taxonomies' => array('post-tag'),\n\t\t'menu_icon' => 'dashicons-images-alt2',\n\t);\t\n\n\t/*|>>>>>>>>>>>>>>>>>>>> GALERÍA VIDEOS <<<<<<<<<<<<<<<<<<<<|*/\n\t\n\t$labels5 = array(\n\t\t'name' => __('Gal. Videos'),\n\t\t'singular_name' => __('Video'),\n\t\t'add_new' => __('Nuevo Video'),\n\t\t'add_new_item' => __('Agregar nuevo Video'),\n\t\t'edit_item' => __('Editar Video'),\n\t\t'view_item' => __('Ver Video'),\n\t\t'search_items' => __('Buscar Video'),\n\t\t'not_found' => __('Video no encontrado'),\n\t\t'not_found_in_trash' => __('Video no encontrado en la papelera'),\n\t);\n\n\t$args5 = array(\n\t\t'labels' => $labels5,\n\t\t'has_archive' => true,\n\t\t'public' => true,\n\t\t'hierachical' => false,\n\t\t'supports' => array('title','editor','excerpt','custom-fields','thumbnail','page-attributes'),\n\t\t'taxonomies' => array('post-tag','category'),\n\t\t'menu_icon' => 'dashicons-video-alt',\n\t);\n\n\t/*|>>>>>>>>>>>>>>>>>>>> PRODUCTOS <<<<<<<<<<<<<<<<<<<<|*/\n\t\n\t$labels6 = array(\n\t\t'name' => __('Productos La Dorita'),\n\t\t'singular_name' => __('Producto'),\n\t\t'add_new' => __('Nuevo Producto'),\n\t\t'add_new_item' => __('Agregar nuevo Producto'),\n\t\t'edit_item' => __('Editar Producto'),\n\t\t'view_item' => __('Ver Producto'),\n\t\t'search_items' => __('Buscar Producto'),\n\t\t'not_found' => __('Producto no encontrado'),\n\t\t'not_found_in_trash' => __('Producto no encontrado en la papelera'),\n\t);\n\n\t$args6 = array(\n\t\t'labels' => $labels6,\n\t\t'has_archive' => true,\n\t\t'public' => true,\n\t\t'hierachical' => false,\n\t\t'supports' => array('title','editor','excerpt','custom-fields','thumbnail','page-attributes'),\n\t\t'taxonomies' => array('post-tag'),\n\t\t'menu_icon' => 'dashicons-cart',\n\t);\n\n\t/*|>>>>>>>>>>>>>>>>>>>> REGISTRAR <<<<<<<<<<<<<<<<<<<<|*/\n\tregister_post_type( 'slider-home' , $args );\n\tregister_post_type( 'servicio' , $args2 );\n\tregister_post_type( 'cliente' , $args3 );\n\tregister_post_type( 'galery-images' , $args4 );\n\tregister_post_type( 'galery-videos' , $args5 );\n\tregister_post_type( 'producto-dorita' , $args6 );\n\n\tflush_rewrite_rules();\n}", "public function setup() {\n\t\t$data_structures = new Data_Structures();\n\t\t$data_structures->setup();\n\t\t$data_structures->add_post_type( $this->post_type, [\n\t\t\t'singular' => 'Customer',\n\t\t\t'supports' => [ 'title' ],\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'show_in_menu' => true,\n\t\t] );\n\t\tadd_action( \"fm_post_{$this->post_type}\", [ $this, 'init' ] );\n\t}", "protected static function image_sizes() {\n\t\tif ( null === self::$image_sizes ) {\n\t\t\tglobal $_wp_additional_image_sizes;\n\n\t\t\t// Populate an array matching the data structure of $_wp_additional_image_sizes so we have a consistent structure for image sizes.\n\t\t\t$images = [\n\t\t\t\t'thumb' => [\n\t\t\t\t\t'width' => intval( get_option( 'thumbnail_size_w' ) ),\n\t\t\t\t\t'height' => intval( get_option( 'thumbnail_size_h' ) ),\n\t\t\t\t\t'crop' => (bool) get_option( 'thumbnail_crop' ),\n\t\t\t\t],\n\t\t\t\t'medium' => [\n\t\t\t\t\t'width' => intval( get_option( 'medium_size_w' ) ),\n\t\t\t\t\t'height' => intval( get_option( 'medium_size_h' ) ),\n\t\t\t\t\t'crop' => false,\n\t\t\t\t],\n\t\t\t\t'medium_large' => [\n\t\t\t\t\t'width' => intval( get_option( 'medium_large_size_w' ) ),\n\t\t\t\t\t'height' => intval( get_option( 'medium_large_size_h' ) ),\n\t\t\t\t\t'crop' => false,\n\t\t\t\t],\n\t\t\t\t'large' => [\n\t\t\t\t\t'width' => intval( get_option( 'large_size_w' ) ),\n\t\t\t\t\t'height' => intval( get_option( 'large_size_h' ) ),\n\t\t\t\t\t'crop' => false,\n\t\t\t\t],\n\t\t\t\t'full' => [\n\t\t\t\t\t'width' => null,\n\t\t\t\t\t'height' => null,\n\t\t\t\t\t'crop' => false,\n\t\t\t\t],\n\t\t\t];\n\n\t\t\t// Compatibility mapping as found in wp-includes/media.php.\n\t\t\t$images['thumbnail'] = $images['thumb'];\n\n\t\t\t// Update class variable, merging in $_wp_additional_image_sizes if any are set.\n\t\t\tif ( is_array( $_wp_additional_image_sizes ) && ! empty( $_wp_additional_image_sizes ) ) {\n\t\t\t\tself::$image_sizes = array_merge( $images, $_wp_additional_image_sizes );\n\t\t\t} else {\n\t\t\t\tself::$image_sizes = $images;\n\t\t\t}\n\t\t}\n\n\t\treturn is_array( self::$image_sizes ) ? self::$image_sizes : [];\n\t}", "function ccac_2020_new_init() {\n register_taxonomy_for_object_type( 'category', 'attachment' );\n register_taxonomy_for_object_type( 'post_tag', 'attachment' );\n\n /*\n * Register custom post types. You can also move this code to a plugin.\n */\n /* Pinegrow generated Custom Post Types Begin */\n\n /* Pinegrow generated Custom Post Types End */\n \n /*\n * Register custom taxonomies. You can also move this code to a plugin.\n */\n /* Pinegrow generated Taxonomies Begin */\n\n /* Pinegrow generated Taxonomies End */\n\n}", "function create_post_type(){\n register_post_type('recipes', [ \n 'labels' => [\n 'name' => 'Recipes', //Etikett i plural Etikett i singular\n 'singular_name' => 'Recipe', //Vad som ska stå i ”Lägg till...” knappen\n 'add_new' => 'New Recipe', //Vad som ska stå i ”Lägg till ny...” knappen\n 'add_new_item' => 'New Recipe', //Vad som ska stå i ”Ny...” länken\n 'edit_item' => 'Edit Recipe', //Vad som ska stå i ”Redigera...” länken\n 'new_item' => 'New Recipe', //Vad som ska stå i ”Ny...” länken\n 'search_items' => 'Search for Recipe', //Vad som ska stå i sökrutan i listningen\n 'not_found' => 'No Recipe Found', \n 'all_items' => 'All Recipes', //Vad som ska stå i ”Alla...” länken\n ],\n 'supports' => array( 'thumbnail' ),\n 'description' => 'The Big Tasty!', //En kort beskrivning av posttypen\n 'public' => true, //Om och hur posttypen ska visas för olika användare\n 'exclude_from_search' => false, //Om posttypens poster ska exkluderas vid sökning\n 'show_ui' => true, //Om posttypen ska kunna hanteras från admin\n 'show_in_nav_menus' => true, //Om poster av posttypen ska kunna läggas till i menyer\n 'show_in_menu' => true, //Vart posttypen ska listas i admin (vänster eller topp)\n 'show_in_admin_bar' => true, //Om posttypen ska visas i toppbar’en\n 'menu_position' => 10, //Vart i vänstermenyn posttypen ska visas\n 'hierarchical' => false, //Om poster i posttypen ska kunna ha föräldrar, likt Sidor\n 'menu_icon' => 'dashicons-food', //Ikon för posttypen\n 'supports' => array('title' , 'editor'), //Vad som ska synas när man skapar/redigerar en post \n 'taxonomies' => array('category'), //Vilka taxonomier som ska tillhöra posttypen\n 'has_archive' => true, //Om posttypen ska ha arkivsida\n 'rewrite' => [ //Hur posttypens rewrites ska hanteras...\n 'slug' => 'recipe', //Permalänkstrukturen för posttypen\n 'with_front' => true //Om permalänkarna ska låta föregås av sluggen\n ] \n ]);\n\n}", "function initializeImageProperties()\n\t{\n\t\tlist($this->width, $this->height, $iType, $this->htmlattributes) = getimagesize($this->sFileLocation);\n\n\t\tif (($this->width < 1) || ($this->height < 1)) {\n\t\t\t$this->printError('invalid imagesize');\n\t\t}\n\n\t\t$this->setImageOrientation();\n\t\t$this->setImageType($iType);\n\t}", "public function init() {\n extract($this->data);\n\n //Class list\n $this->data['classList'][] = \"c-image\"; \n\n //Add placeholder class\n if(!$src) {\n $this->data['classList'][] = $this->getBaseClass() . \"--is-placeholder\"; \n }\n\n //Make full width\n if($fullWidth) {\n $this->data['classList'][] = $this->getBaseClass() . \"--full-width\"; \n }\n\n //Inherit the alt text\n if(!$alt && $caption) {\n $this->data['alt'] = $this->data['caption'];\n }\n \n }", "public function register_image_sizes() {\n\n }", "function mount_testimonial_post_type()\n{\n $labels = array(\n 'name' => _x('Testimonials', 'Post Type General Name', 'mount'),\n 'singular_name' => _x('Testimonial', 'Post Type Singular Name', 'mount'),\n 'menu_name' => __('Testimonials', 'mount'),\n 'parent_item_colon' => __('Parent Testimonial', 'mount'),\n 'all_items' => __('All Testimonials', 'mount'),\n 'view_item' => __('View Testimonial', 'mount'),\n 'add_new_item' => __('Add New Testimonial', 'mount'),\n 'add_new' => __('Add New Testimonial', 'mount'),\n 'edit_item' => __('Edit Testimonial', 'mount'),\n 'update_item' => __('Update Testimonial', 'mount'),\n 'search_items' => __('Search Testimonial', 'mount'),\n 'not_found' => __('No testimonials found', 'mount'),\n 'not_found_in_trash' => __('Not found in trash', 'mount'),\n );\n // Another Customizations\n $args = array(\n 'label' => __('Testimonials', 'mount'),\n 'description' => __('Testimonials for Mount', 'mount'),\n 'labels' => $labels,\n 'supports' => array('title', 'thumbnail', 'editor'),\n 'hierarchical' => false,\n 'public' => true,\n 'show_ui' => true,\n 'show_in_menus' => true,\n 'show_in_nav_menus' => true,\n 'show_in_admin_bar' => true,\n 'menu_position' => 5,\n 'menu_icon' => 'dashicons-admin-comments',\n 'can_export' => true,\n 'has_archive' => true,\n 'exclude_from_search' => false,\n 'capability_type' => 'page',\n );\n // register the post Type\n register_post_type('testimonials', $args);\n}", "public function init()\n {\n parent::init();\n\n $this->size = $this->finalWidth;\n }", "function add_meta_boxes() {\n\t\tif( function_exists( 'add_meta_box' ) ) {\n\t\t\tadd_meta_box( 'unit-info', __('Unit Information'), array( $this, '_display_unitinfo_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'maps', __('Maps'), array( $this, '_display_maps_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'gallery', __('Gallery'), array( $this, '_display_gallery_meta'), 'units', 'normal', 'low');\n\t\t\tadd_meta_box( 'unit-status', __('Availability'), array( $this, '_display_status_meta'), 'units', 'side', 'high');\n\t\t}\n\t}", "public function define_image_sizes(){\n add_image_size('icon', 96, 96, true);\n add_image_size('item_details_featured', 600, 600, true);\n add_image_size('item_details_featured_sm', 480, 480, true);\n add_image_size('post_preview', 300, 300, true);\n\n }", "public function __construct() {\n\t\t\t$this->wpseo_asset_manager = new WPSEO_Admin_Asset_Manager();\n\t\t\t$this->asset_manager = new WPSEO_Local_Admin_Assets();\n\t\t\t$this->asset_manager->register_assets();\n\n\t\t\tadd_action( 'current_screen', [ $this, 'register_media_buttons' ] );\n\t\t\tadd_action( 'admin_enqueue_scripts', [ $this, 'enqueue_scripts' ] );\n\t\t\tadd_action( 'admin_enqueue_scripts', [ $this, 'enqueue_styles' ] );\n\n\t\t\t// Add scripts for buttons for adding shortcodes in RTE in front-end when using Beaver Builder.\n\t\t\tif ( isset( $_GET['fl_builder'] ) ) {\n\t\t\t\tadd_action( 'wp_footer', [ $this, 'add_mce_popup' ] );\n\t\t\t}\n\n\t\t\t/**\n\t\t\t * The rest is only applicable when using multiple locations.\n\t\t\t */\n\t\t\tif ( wpseo_has_multiple_locations() ) {\n\t\t\t\t$this->options = get_option( 'wpseo_local' );\n\t\t\t\t$this->get_timezone_repository();\n\t\t\t\t$this->get_locations_repositry();\n\n\t\t\t\t$this->api_repository = new WPSEO_Local_Api_Keys_Repository();\n\n\t\t\t\tadd_action( 'add_meta_boxes', [ $this, 'set_locations' ] );\n\t\t\t\tadd_action( 'add_meta_boxes', [ $this, 'set_current_location' ] );\n\t\t\t\tadd_action( 'add_meta_boxes', [ $this, 'set_location_select_options' ] );\n\t\t\t\tadd_action( 'add_meta_boxes', [ $this, 'set_tabs' ] );\n\n\t\t\t\t// Create custom post type functionality + meta boxes for Custom Post Type.\n\t\t\t\tadd_action( 'add_meta_boxes', [ $this, 'add_location_metaboxes' ] );\n\n\t\t\t\t// Add panels for each tab.\n\t\t\t\tadd_action( 'wpseo-local-panel-content-business_info', [ $this, 'business_info_panel_content' ] );\n\t\t\t\tadd_action( 'wpseo-local-panel-content-opening_hours', [ $this, 'opening_hours_panel_content' ] );\n\t\t\t\tadd_action( 'wpseo-local-panel-content-maps_settings', [ $this, 'maps_settings_panel_content' ] );\n\n\t\t\t\tadd_action( 'save_post', [ $this, 'wpseo_locations_save_meta' ], 10, 2 );\n\n\t\t\t\t// Only add the filter on Yoast SEO before 3.0, because 3.0 removed this filter. 2.3.5 was the last 2.x version.\n\t\t\t\tif ( version_compare( WPSEO_VERSION, '2.3.5', '<=' ) ) {\n\t\t\t\t\tadd_filter( 'wpseo_linkdex_results', [ $this, 'filter_linkdex_results' ], 10, 3 );\n\t\t\t\t}\n\t\t\t}\n\t\t}", "public function __construct()\n {\n \tglobal $kingdom;\n\n \t$this->the_theme = $kingdom;\n\t\t\t$this->module_folder = $this->the_theme->cfg['paths']['theme_dir_url'] . 'modules/partners/';\n\t\t\t\n\t\t\t$this->init_postType();\n\t\t\t\n\t\t\t/* use save_post action to handle data entered */\n\t\t\tadd_action( 'save_post', array( $this, 'meta_box_save_postdata' ) );\n\t\t\t\n\t\t\tif( isset($_GET['post_type']) && $_GET['post_type'] == 'partners') add_action('admin_head', array( $this, 'extra_css') );\n\t\t\t\n\t\t\t//add_image_size( 'partner-image', 150, 100, true );\n }", "function thirdtheme_photo_page()\n {\n add_theme_support('post-thumbnails');\n add_image_size('medium',400,400);\n $args = array(\n 'labels' => array('name' =>__('photo page'),\n 'add_new' =>__('add new photo')),\n \n 'public' => true,\n 'menu_icon' =>'dashicons-format-image',\n 'show_in_menu' => true,\n 'has_archive' => true,\n 'supports' => array( 'title','thumbnail')); \n register_post_type('photo',$args);\n }", "function derefe_admin_init(){\n\t// add_action( 'add_meta_boxes', string $post_type, WP_Post $post )\n\n\t// The hook will only run when editing a specific post type. \n\t// add_action( \"add_meta_boxes_{$post_type}\", WP_Post $post )\n\n\tadd_action( 'add_meta_boxes_cus_pot_type', 'derefe_create_metaboxes');\n\tinclude( 'create_metaboxes.php');\n\tinclude( 'custom-post-type-options.php');\n\n}", "public function themeSetup()\n\t{\n\n\t\t// This theme styles the visual editor with editor-style.css to match the theme style.\n\t\tadd_editor_style();\n\n\t\t// This theme uses a custom image size for featured images, displayed on \"standard\" posts.\n\t\tadd_theme_support( 'post-thumbnails' );\n\n\n\t\t\n\t\tadd_image_size('hero', 1920, 1080, true );\t\n\t\tadd_image_size('hero-news', 480, 250, true );\t\n\t\tadd_image_size('timeline', 768, 450, true );\t\t\n\t\t//add_image_size('660x400', 660, 400, true );\t\t\n\t\t//add_image_size('810x431', 810, 431, true );\t\t\t\n\n\t\t/**\n\t\t * Make theme available for translation\n\t\t * Translations can be filed in the /languages/ directory\n\t\t * If you're building a theme based on _s, use a find and replace\n\t\t * to change '_s' to the name of your theme in all the template files\n\t\t */\n\t\tload_theme_textdomain( DION_THEME_SLUG, get_template_directory() . '/languages' );\n\t\t\n\n\t\t/**\n\t\t * Add default posts and comments RSS feed links to head\n\t\t */\n\t\tadd_theme_support( 'automatic-feed-links' );\n\n\n\t\t/**\n\t\t * More menus can be added if necessary\n\t\t */\n\t\tregister_nav_menus( array(\n\t\t\t'primary' => __( 'Ana Menü', DION_THEME_SLUG ),\n\t\t\t'footer-section' => __( 'Alt Menü', DION_THEME_SLUG ),\n\t\t) );\n\n\n\t}", "function _wp_add_additional_image_sizes()\n {\n }", "function moustachedesign_theme_setup() {\n\n add_theme_support( 'post-thumbnails' );\n\n add_image_size( 'small', 600, 600, false );\n add_image_size( 'medium', 1024, 1024, false );\n add_image_size( 'large', 1920, 1920, false );\n add_image_size( 'ultra', 2048, 2048, false );\n add_image_size( '4k', 4096, 4096, false );\n\n}", "private function add_custom_thumbnails() {\n\n\t\tif( true === $this->disable_thumbnail_generation_on_upload ) {\n\t\t\tif( isset($_SERVER['REQUEST_URI']) && ($_SERVER['REQUEST_URI'] === '/wp-admin/async-upload.php') ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\n\t\t//Init vars\n\t\t$defaults = array(\n\t\t\t'width' \t=> NULL,\n\t\t\t'height'\t=> NULL,\n\t\t\t'crop'\t\t=> false,\n\t\t);\n\n\t\t//Check settings from config class\n\t\tif( isset($this->theme_thumbnail_settings) && is_array($this->theme_thumbnail_settings) ) {\n\n\t\t\t//Loop thumbnail sizes\n\t\t\tforeach( $this->theme_thumbnail_settings as $name => $args ) {\n\n\t\t\t\tif( !isset($args['config']) ) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t$image_config = wp_parse_args( $args['config'], $defaults );\n\n\t\t\t\textract($image_config);\n\n\t\t\t\tif( isset( $width, $height, $crop ) ) {\n\n\t\t\t\t\t//Check for requests to update WP default thumbnails\n\t\t\t\t\tswitch( $name ) {\n\t\t\t\t\t\tcase 'featured';\n\t\t\t\t\t\t\t//Add default thumb size\n\t\t\t\t\t\t\tset_post_thumbnail_size( $width, $height, $crop ); // default thumb size\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'thumbnail';\n\t\t\t\t\t\t\tif( is_admin() ) {\n\t\t\t\t\t\t\t\tupdate_option('thumbnail_size_w', $width);\n\t\t\t\t\t\t\t\tupdate_option('thumbnail_size_h', $height);\n\t\t\t\t\t\t\t\tupdate_option('thumbnail_crop', $crop);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'medium':\n\t\t\t\t\t\t\tif( is_admin() ) {\n\t\t\t\t\t\t\t\tupdate_option('medium_size_w', $width);\n\t\t\t\t\t\t\t\tupdate_option('medium_size_h', $height);\n\t\t\t\t\t\t\t\tupdate_option('medium_crop', $crop);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'large':\n\t\t\t\t\t\t\tif( is_admin() ) {\n\t\t\t\t\t\t\t\tupdate_option('large_size_w', $width);\n\t\t\t\t\t\t\t\tupdate_option('large_size_h', $height);\n\t\t\t\t\t\t\t\tupdate_option('large_crop', $crop);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tdefault:\n\n\t\t\t\t\t\t\t//Add custom thumbnail image size to wordpress\n\t\t\t\t\t\t\tadd_image_size( $name, $width, $height, $crop );\n\n//\t\t\t\t\t\t\t//High res version\n//\t\t\t\t\t\t\tif( is_int($width) ) {\n//\t\t\t\t\t\t\t\t$width = $width * 2;\n//\t\t\t\t\t\t\t}\n//\n//\t\t\t\t\t\t\tif( is_int($height) ) {\n//\t\t\t\t\t\t\t\t$height = $height * 2;\n//\t\t\t\t\t\t\t}\n//\t\t\t\t\t\t\tadd_image_size( \"{$name}--x2\", $width, $height, $crop );\n\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t\t//Set any custom srcset rules\n\t\t\t\tif( isset($args['srcset']) && is_array($args['srcset']) ) {\n\n\t\t\t\t\t$this->register_theme_custom_image_srcset( $name, $args['srcset'] );\n\n\t\t\t\t\t//\t\t\t\t\tforeach($args['srcset'] as $srcset_attribute) {\n\t\t\t\t\t//\t\t\t\t\t\t$this->register_theme_custom_image_srcset( $name, $srcset_attribute );\n\t\t\t\t\t//\t\t\t\t\t}\n\n\t\t\t\t}\n\n\t\t\t}\n\n\t\t}\n\n\t\t//Add custom image sizes to \"add media:\" option for edit post/page\n\t\tadd_filter( 'image_size_names_choose', array($this, 'insert_custom_image_sizes') );\n\n\t\t//Filter image srcset attributes\n\t\tadd_filter( 'wp_get_attachment_image_attributes', array($this, 'get_image_size_srcset_attr'), 900, 3 );\n\n\t\t//Filter sizes attribute added to images\n\t\tadd_filter( 'wp_calculate_image_sizes', array($this, 'default_image_srcset_sizes_attr'), 900, 2 );\n\n\t}", "public static function init () : void\n {\n add_action(\"init\", function () {\n self::register_post_type();\n });\n }", "function mount_slider_post_type()\n{\n $labels = array(\n 'name' => _x('Sliders', 'Post Type General Name', 'mount'),\n 'singular_name' => _x('Slider', 'Post Type Singular Name', 'mount'),\n 'menu_name' => __('Sliders', 'mount'),\n 'parent_item_colon' => __('Parent Slider', 'mount'),\n 'all_items' => __('All Sliders', 'mount'),\n 'view_item' => __('View Slider', 'mount'),\n 'add_new_item' => __('Add New Slider', 'mount'),\n 'add_new' => __('Add New Slider', 'mount'),\n 'edit_item' => __('Edit Slider', 'mount'),\n 'update_item' => __('Update Slider', 'mount'),\n 'search_items' => __('Search Slider', 'mount'),\n 'not_found' => __('No sliders found', 'mount'),\n 'not_found_in_trash' => __('Not found in trash', 'mount'),\n );\n // Another Customizations\n $args = array(\n 'label' => __('Sliders', 'mount'),\n 'description' => __('Sliders for Mount', 'mount'),\n 'labels' => $labels,\n 'supports' => array('title', 'thumbnail',),\n 'hierarchical' => false,\n 'public' => true,\n 'show_ui' => true,\n 'show_in_menus' => true,\n 'show_in_nav_menus' => true,\n 'show_in_admin_bar' => true,\n 'menu_position' => 5,\n 'menu_icon' => 'dashicons-images-alt2',\n 'can_export' => true,\n 'has_archive' => true,\n 'exclude_from_search' => false,\n 'capability_type' => 'page',\n );\n // register the post Type\n register_post_type('sliders', $args);\n}", "public function __construct()\n {\n add_action('init', [__CLASS__, 'register_post_types']);\n }", "function roots_setup() {\n // Make theme available for translation\n // Community translations can be found at https://github.com/roots/roots-translations\n load_theme_textdomain('roots', get_template_directory() . '/lang');\n\n // Register wp_nav_menu() menus\n // http://codex.wordpress.org/Function_Reference/register_nav_menus\n register_nav_menus(array(\n 'primary_navigation' => __('Primary Navigation', 'roots')\n ));\n\n // Add post thumbnails\n // http://codex.wordpress.org/Post_Thumbnails\n // http://codex.wordpress.org/Function_Reference/set_post_thumbnail_size\n // http://codex.wordpress.org/Function_Reference/add_image_size\n add_theme_support( 'post-thumbnails' );\n set_post_thumbnail_size( 180, 180, true );\n add_image_size( 'gallery-thumb-medup', 160, 160, true );\n add_image_size( 'gallery-thumb-small', 90, 90, true );\n add_image_size( 'image-main-small', 640, 0, false );\n add_image_size( 'image-main-medup', 720, 0, false );\n\n // Add post formats\n // http://codex.wordpress.org/Post_Formats\n add_theme_support(\n 'post-formats',\n array(\n 'status',\n 'link',\n 'image',\n 'gallery',\n 'video',\n 'audio',\n 'quote',\n )\n );\n // Adds support for formats UI\n add_theme_support(\n 'structured-post-formats',\n array(\n 'status',\n 'link',\n 'image',\n 'gallery',\n 'video',\n 'audio',\n 'quote',\n )\n );\n\n // Add HTML5 markup for captions\n // http://codex.wordpress.org/Function_Reference/add_theme_support#HTML5\n add_theme_support( 'html5', array( 'caption' ) );\n\n // Tell the TinyMCE editor to use a custom stylesheet\n add_editor_style('/assets/css/editor-style.css');\n\n register_post_meta('post', '_format_audio_embed', [\n 'type' => 'string',\n 'description' => 'Audio URL for audio formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_format_link_url', [\n 'type' => 'string',\n 'description' => 'Link URL for link formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_url_embedly_retrieved', [\n 'type' => 'boolean',\n 'description' => 'Whether the URL has been retrieved from Embedly',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_url_embedly_provider_url', [\n 'type' => 'string',\n 'description' => 'Provider URL for link formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_url_embedly_provider_name', [\n 'type' => 'string',\n 'description' => 'Provider name for link formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_url_embedly_description', [\n 'type' => 'string',\n 'description' => 'Link description for link formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_format_quote_source_url', [\n 'type' => 'string',\n 'description' => 'Quote source url for quote formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_format_quote_source_name', [\n 'type' => 'string',\n 'description' => 'Quote source name for quote formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n\n register_post_meta('post', '_format_video_embed', [\n 'type' => 'string',\n 'description' => 'Video URL for video formats',\n 'single' => true,\n 'show_in_rest' => true,\n ]);\n}", "function isf_create_custom_post_types() {\n\n\t// Maps.\n\tregister_post_type(\n\t\tMAP_POST_TYPE,\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => 'Maps',\n\t\t\t\t'singular_name' => 'Map',\n\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t'add_new_item' => 'Add New Map',\n\t\t\t\t'edit_item' => 'Edit Map',\n\t\t\t\t'new_item' => 'New Map',\n\t\t\t\t'view_item' => 'View Map',\n\t\t\t\t'view_items' => 'View Maps',\n\t\t\t\t'search_items' => 'Search Maps',\n\t\t\t\t'not_found' => 'No Maps Found',\n\t\t\t\t'not_found_in_trash' => 'No Maps found in Trash',\n\t\t\t\t'all_items' => 'All Maps',\n\t\t\t\t'archives' => 'Map Archives',\n\t\t\t\t'attributes' => 'Map Attributes',\n\t\t\t\t'insert_into_item' => 'Insert into Map',\n\t\t\t\t'uploaded_to_this_item' => 'Uploaded to this Map',\n\t\t\t),\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'menu_icon' => 'dashicons-location-alt',\n\t\t\t'supports' => array( 'title' ),\n\t\t)\n\t);\n\n\t// Map Groups.\n\tregister_post_type(\n\t\tMAP_GROUP_POST_TYPE,\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => 'Map Groups',\n\t\t\t\t'singular_name' => 'Map Group',\n\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t'add_new_item' => 'Add New Map Group',\n\t\t\t\t'edit_item' => 'Edit Map Group',\n\t\t\t\t'new_item' => 'New Map Group',\n\t\t\t\t'view_item' => 'View Map Group',\n\t\t\t\t'view_items' => 'View Map Groups',\n\t\t\t\t'search_items' => 'Search Map Groups',\n\t\t\t\t'not_found' => 'No Map Groups Found',\n\t\t\t\t'not_found_in_trash' => 'No Map Groups found in Trash',\n\t\t\t\t'all_items' => 'All Map Groups',\n\t\t\t\t'archives' => 'Map Group Archives',\n\t\t\t\t'attributes' => 'Map Group Attributes',\n\t\t\t\t'insert_into_item' => 'Insert into Map Group',\n\t\t\t\t'uploaded_to_this_item' => 'Uploaded to this Map Group',\n\t\t\t),\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'menu_icon' => 'dashicons-arrow-right',\n\t\t\t'supports' => array( 'title' ),\n\t\t)\n\t);\n\n\t// Proposal Eras.\n\tregister_post_type(\n\t\tPROPOSAL_ERA_POST_TYPE,\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => 'Proposal Eras',\n\t\t\t\t'singular_name' => 'Proposal Era',\n\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t'add_new_item' => 'Add New Proposal Era',\n\t\t\t\t'edit_item' => 'Edit Proposal Era',\n\t\t\t\t'new_item' => 'New Proposal Era',\n\t\t\t\t'view_item' => 'View Proposal Era',\n\t\t\t\t'view_items' => 'View Proposal Eras',\n\t\t\t\t'search_items' => 'Search Proposal Eras',\n\t\t\t\t'not_found' => 'No Proposal Eras Found',\n\t\t\t\t'not_found_in_trash' => 'No Proposal Eras found in Trash',\n\t\t\t\t'all_items' => 'All Proposal Eras',\n\t\t\t\t'archives' => 'Proposal Era Archives',\n\t\t\t\t'attributes' => 'Proposal Era Attributes',\n\t\t\t\t'insert_into_item' => 'Insert into Proposal Era',\n\t\t\t\t'uploaded_to_this_item' => 'Uploaded to this Proposal Era',\n\t\t\t),\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'menu_icon' => 'dashicons-menu-alt',\n\t\t\t'supports' => array( 'title' ),\n\t\t)\n\t);\n\n\t// Narratives.\n\tregister_post_type(\n\t\tNARRATIVE_POST_TYPE,\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => 'Narratives',\n\t\t\t\t'singular_name' => 'Narrative',\n\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t'add_new_item' => 'Add New Narrative',\n\t\t\t\t'edit_item' => 'Edit Narrative',\n\t\t\t\t'new_item' => 'New Narrative',\n\t\t\t\t'view_item' => 'View Narrative',\n\t\t\t\t'view_items' => 'View Narratives',\n\t\t\t\t'search_items' => 'Search Narratives',\n\t\t\t\t'not_found' => 'No Narratives Found',\n\t\t\t\t'not_found_in_trash' => 'No Narratives found in Trash',\n\t\t\t\t'all_items' => 'All Narratives',\n\t\t\t\t'archives' => 'Narrative Archives',\n\t\t\t\t'attributes' => 'Narrative Attributes',\n\t\t\t\t'insert_into_item' => 'Insert into Narrative',\n\t\t\t\t'uploaded_to_this_item' => 'Uploaded to this Narrative',\n\t\t\t),\n\t\t\t'public' => true,\n\t\t\t'menu_icon' => 'dashicons-book-alt',\n\t\t\t'rewrite' => array( 'slug' => 'narratives' ),\n\t\t)\n\t);\n\n\t// Feedback.\n\tregister_post_type(\n\t\tFEEDBACK_POST_TYPE,\n\t\tarray(\n\t\t\t'labels' => array(\n\t\t\t\t'name' => 'Feedback',\n\t\t\t\t'singular_name' => 'Feedback',\n\t\t\t\t'add_new' => 'Add New',\n\t\t\t\t'add_new_item' => 'Add New Feedback',\n\t\t\t\t'edit_item' => 'Feedback',\n\t\t\t\t'new_item' => 'New Feedback',\n\t\t\t\t'view_item' => 'View Feedback',\n\t\t\t\t'view_items' => 'View Feedback',\n\t\t\t\t'search_items' => 'Search Feedback',\n\t\t\t\t'not_found' => 'No Feedback Found',\n\t\t\t\t'not_found_in_trash' => 'No Feedback found in Trash',\n\t\t\t\t'all_items' => 'All Feedback',\n\t\t\t\t'archives' => 'Feedback Archives',\n\t\t\t\t'attributes' => 'Feedback Attributes',\n\t\t\t\t'insert_into_item' => 'Insert into Feedback',\n\t\t\t\t'uploaded_to_this_item' => 'Uploaded to this Feedback',\n\t\t\t),\n\t\t\t'public' => false,\n\t\t\t'show_ui' => true,\n\t\t\t'menu_icon' => 'dashicons-testimonial',\n\t\t\t'supports' => false,\n\t\t\t'map_meta_cap' => true,\n\t\t\t'capabilities' => array(\n\t\t\t\t'create_posts' => false,\n\t\t\t),\n\t\t)\n\t);\n\n}", "function register_image_sizes() {\n\t}", "function post_meta_boxes_setup() {\n\n\t\tadd_action( 'add_meta_boxes', array($this, 'add_post_meta_boxes') );\n\t}", "function __construct() {\n\n\t\t$this->ID = 'example';\n\n\t\t$this->singlename = 'Post Type';\n\t\t$this->pluralname = 'Post Types';\n\n\t\t$this->args = array(\n\t\t\t'taxonomies' => array('category')\n\t\t);\n\n\t\tparent::__construct();\n\n\t}", "private function registerPostType() {\n\t global $superfood_elated_global_Framework;\n\n\t $menuPosition = 5;\n\t $menuIcon = 'dashicons-admin-post';\n\n\t if(eltd_core_theme_installed()) {\n\t\t $menuPosition = $superfood_elated_global_Framework->getSkin()->getMenuItemPosition('masonry-gallery');\n\t\t $menuIcon = $superfood_elated_global_Framework->getSkin()->getMenuIcon('masonry-gallery');\n\t }\n\n register_post_type($this->base,\n array(\n 'labels' \t\t=> array(\n 'name' \t\t\t\t=> esc_html__('Masonry Gallery', 'eltdf-core' ),\n 'all_items'\t\t\t=> esc_html__('Masonry Gallery Items', 'eltdf-core'),\n 'singular_name' \t=> esc_html__('Masonry Gallery Item', 'eltdf-core' ),\n 'add_item'\t\t\t=> esc_html__('New Masonry Gallery Item', 'eltdf-core'),\n 'add_new_item' \t\t=> esc_html__('Add New Masonry Gallery Item', 'eltdf-core'),\n 'edit_item' \t\t=> esc_html__('Edit Masonry Gallery Item', 'eltdf-core')\n ),\n 'public'\t\t=>\tfalse,\n 'show_in_menu'\t=>\ttrue,\n 'rewrite' \t\t=> \tarray('slug' => 'masonry-gallery'),\n\t\t\t\t'menu_position' => \t$menuPosition,\n 'show_ui'\t\t=>\ttrue,\n 'has_archive'\t=>\tfalse,\n 'hierarchical'\t=>\tfalse,\n 'supports'\t\t=>\tarray('title', 'thumbnail'),\n\t\t\t\t'menu_icon' => $menuIcon\n )\n );\n }", "function qtgallery_register_type() {\n\n\t$labelsoption = array(\n 'name' => esc_attr__(\"Gallery\",\"qt-extensions-suite\"),\n 'singular_name' => esc_attr__(\"Gallery\",\"qt-extensions-suite\"),\n 'add_new' => esc_attr__(\"Add new\",\"qt-extensions-suite\"),\n 'add_new_item' => esc_attr__(\"Add new gallery\",\"qt-extensions-suite\"),\n 'edit_item' => esc_attr__(\"Edit gallery\",\"qt-extensions-suite\"),\n 'new_item' => esc_attr__(\"New gallery\",\"qt-extensions-suite\"),\n 'all_items' => esc_attr__(\"All galleries\",\"qt-extensions-suite\"),\n 'view_item' => esc_attr__(\"View gallery\",\"qt-extensions-suite\"),\n 'search_items' => esc_attr__(\"Search gallery\",\"qt-extensions-suite\"),\n 'not_found' => esc_attr__(\"No galleries found\",\"qt-extensions-suite\"),\n 'not_found_in_trash' => esc_attr__(\"No galleries found in trash\",\"qt-extensions-suite\"),\n 'menu_name' => esc_attr__(\"Galleries\",\"qt-extensions-suite\")\n );\n\n \t$args = array(\n 'labels' => $labelsoption,\n 'public' => true,\n 'publicly_queryable' => true,\n 'show_ui' => true, \n 'show_in_menu' => true, \n 'query_var' => true,\n 'rewrite' => true,\n 'capability_type' => 'page',\n 'has_archive' => true,\n 'hierarchical' => false,\n 'menu_position' => 40,\n 'menu_icon' => 'dashicons-format-gallery',\n \t'page-attributes' => false,\n \t'show_in_nav_menus' => true,\n \t'show_in_admin_bar' => true,\n \t'show_in_menu' => true,\n 'supports' => array('title','thumbnail','editor')\n \t); \n\n register_post_type( CUSTOMTYPE_GALLERY , $args );\n \n //add_theme_support( 'post-formats', array( 'gallery','status','video','audio' ) );\n\t\n\t$labels = array(\n\t\t'name' => esc_attr__( 'Gallery type',\"qt-extensions-suite\" ),\n\t\t'singular_name' => esc_attr__( 'Types',\"qt-extensions-suite\" ),\n\t\t'search_items' => esc_attr__( 'Search by type',\"qt-extensions-suite\" ),\n\t\t'popular_items' => esc_attr__( 'Popular type',\"qt-extensions-suite\" ),\n\t\t'all_items' => esc_attr__( 'All types',\"qt-extensions-suite\" ),\n\t\t'parent_item' => null,\n\t\t'parent_item_colon' => null,\n\t\t'edit_item' => esc_attr__( 'Edit Type',\"qt-extensions-suite\" ), \n\t\t'update_item' => esc_attr__( 'Update Type',\"qt-extensions-suite\" ),\n\t\t'add_new_item' => esc_attr__( 'Add New Type',\"qt-extensions-suite\" ),\n\t\t'new_item_name' => esc_attr__( 'New Type Name',\"qt-extensions-suite\" ),\n\t\t'separate_items_with_commas' => esc_attr__( 'Separate Types with commas',\"qt-extensions-suite\" ),\n\t\t'add_or_remove_items' => esc_attr__( 'Add or remove Types',\"qt-extensions-suite\" ),\n\t\t'choose_from_most_used' => esc_attr__( 'Choose from the most used Types',\"qt-extensions-suite\" ),\n\t\t'menu_name' => esc_attr__( 'Types',\"qt-extensions-suite\" ),\n\t); \n\n\t\n\n $fields = array(\n /* */ \n\t\tarray(\n\t\t\t'label' => 'Style',\n\t\t\t'class' => 'style',\n\t\t\t'id' => 'style',\n\t\t\t'type' => 'select',\n\t\t\t'options' => array(\n\t array('label' => 'Masonry','value' => 'masonry'),\n\t array('label' => 'Carousel','value' => 'carousel')\n\t )\n\t\t\t),\n\t\tarray( // Repeatable & Sortable Text inputs\n\t\t\t'label'\t=> 'Gallery', // <label>\n\t\t\t'id'\t=> 'galleryitem', // field id and name\n\t\t\t'type'\t=> 'repeatable', // type of field\n\t\t\t'sanitizer' => array( // array of sanitizers with matching kets to next array\n\t\t\t\t'featured' => 'meta_box_santitize_boolean',\n\t\t\t\t'title' => 'sanitize_text_field',\n\t\t\t\t'desc' => 'wp_kses_data'\n\t\t\t)\n\t\t\t,'repeatable_fields' => array ( // array of fields to be repeated\n\t\t\t\t'title' => array(\n\t\t\t\t\t'label' => 'Title',\n\t\t\t\t\t'id' => 'title',\n\t\t\t\t\t'type' => 'text'\n\t\t\t\t),\n\t\t\t\t'video' => array(\n\t\t\t\t\t'label' => 'Video',\n\t\t\t\t\t'id' => 'video',\n\t\t\t\t\t'description' => 'Youtube or Vimeo url',\n\t\t\t\t\t'type' => 'text'\n\t\t\t\t),\n\t\t\t\t'image' => array(\n\t\t\t\t\t'label' => 'Image',\n\t\t\t\t\t'id' => 'image',\n\t\t\t\t\t'type' => 'image'\n\t\t\t\t)\n\t\t\t)\n\t\t)\t \n );\n if(post_type_exists(CUSTOMTYPE_GALLERY)){\n if(function_exists('custom_meta_box_field')){\n $sample_box \t\t= new custom_add_meta_box(CUSTOMTYPE_GALLERY, 'Gallery details', $fields, CUSTOMTYPE_GALLERY, true );\n }\n }\n\t\n}", "protected function setUp() {\n $this->type = new Type('image', 'Image');\n $this->mimeType = new MimeType('image/jpg', $this->type);\n }", "public function setUp()\n {\n // We set the height & width directly.\n }", "public function __construct() {\n\n //d(dirname(dirname( __FILE__ )));\n\n \tadd_action( 'wp_enqueue_scripts', array($this, 'load_custom_wp_frontend_style') );\n \tadd_action( 'init', [$this, 'custom_post_type'] );\n add_action( 'wp_ajax_custom_survey_tracker', array($this, 'plugin_data_custom_survey_tracker_func') );\n\t add_action( 'wp_ajax_nopriv_custom_survey_tracker', array($this, 'plugin_data_custom_survey_tracker_func') );\n\n\t\tadd_action( 'add_meta_boxes', array($this, 'add_events_metaboxes') );\n\n }", "function medarbejder_custom_post_type() {\n $labels = array(\n 'name' => _x( 'Medarbejdere', 'Post Type General Name', 'webstarters' ),\n 'singular_name' => _x( 'Medarbejder', 'Post Type Singular Name', 'webstarters' ),\n 'menu_name' => __( 'Medarbejdere', 'webstarters' ),\n 'parent_item_colon' => __( 'Forældre medarbejder', 'webstarters' ),\n 'all_items' => __( 'Alle medarbejdere', 'webstarters' ),\n 'view_item' => __( 'Se medarbejder', 'webstarters' ),\n 'add_new_item' => __( 'Tilføj ny medarbejder', 'webstarters' ),\n 'add_new' => __( 'Tilføj ny medarbejder', 'webstarters' ),\n 'edit_item' => __( 'Redigere medarbejder', 'webstarters' ),\n 'update_item' => __( 'Opdatere medarbejder', 'webstarters' ),\n 'search_items' => __( 'Søg efter medarbejder', 'webstarters' ),\n 'not_found' => __( 'Not Found', 'webstarters' ),\n 'not_found_in_trash' => __( 'Not found in Trash', 'webstarters' ),\n );\n\n// Set other options for Custom Post Type\n\n $args = array(\n 'label' => __( 'medarbejder', 'webstarters' ),\n 'description' => __( 'Custom post type til byggegrunde', 'webstarters' ),\n 'labels' => $labels,\n // Features this CPT supports in Post Editor\n 'supports' => array( 'title', 'thumbnail', 'custom-fields', ),\n // You can associate this CPT with a taxonomy or custom taxonomy.\n 'taxonomies' => array(),\n /* A hierarchical CPT is like Pages and can have\n * Parent and child items. A non-hierarchical CPT\n * is like Posts.\n */\n 'hierarchical' => false,\n 'public' => false,\n 'show_ui' => true,\n 'show_in_menu' => true,\n 'show_in_nav_menus' => true,\n 'show_in_admin_bar' => true,\n 'menu_position' => 5,\n 'can_export' => true,\n 'has_archive' => false,\n 'exclude_from_search' => false,\n 'publicly_queryable' => false,\n 'capability_type' => 'page',\n );\n\n // Registering your Custom Post Type\n register_post_type( 'medarbejder', $args );\n\n}", "function jw_theme_setup(){\n\t\n\t\tglobal $domain; /* The unique string used for translation */\n\t\n\t\t/* Add theme-supported features. */\n\t\tadd_theme_support('automatic-feed-links');\n\t\tadd_theme_support('post-thumbnails');\n\t\t\n\t\t/* Add post thumbnail sizes */\n\t\tset_post_thumbnail_size(570, 194, true);\n\t\tadd_image_size('jw_full', 880, 303, true);\n\t\tadd_image_size('jw_third', 270, 170, true);\n\t\tadd_image_size('jw_half', 425, 232, true);\n\t\tadd_image_size('jw_portfolio_grid', 241, 180, true);\n\t\t\n\t\t/* Don't change the sizes bellow */\n\t\tadd_image_size('jw_58', 58, 43, true);\n\t\tadd_image_size('jw_100', 100, 100, true);\n\t\t\n\t\t/* Localization */\n\t\tload_theme_textdomain($domain, TEMPLATEPATH . '/lang');\n\t\t\n\t}", "protected function __constructor() {\n\t\t\n\t\t// Copy and process configuration\n\t\t$config = $this->getConfig();\n\t\t$this->post_type = $config['post_type'];\n\t\t$this->meta_box = $config['meta_box'];\n\t\t$this->nonce = $config['nonce'];\n\t\t$this->fields = $config['fields'];\n\t\tarray_walk( $this->fields, [$this, 'prepare_field_data'] );\n\t\t\n\t\t// Runs hooks\n\t\tadd_action( 'add_meta_boxes_'.$this->post_type, [$this, 'register_meta_box'] );\n\t\tadd_action( 'save_post', [$this, 'save_post_meta'] );\n\t\tadd_action( 'admin_enqueue_scripts', [$this, 'load_assets'] );\n\t}", "public function addImagesSizes() {\n\t\t// add_image_size( 'small', 225, 9999 );\n\t\t// add_image_size( 'hero', 1600, 9999 );\n\t}", "function mgc_setup() {\n\n // This theme styles the visual editor with editor-style.css to match the theme style.\n add_editor_style();\n\n // This theme uses post thumbnails\n add_theme_support( 'post-thumbnails' );\n\n // Add default posts and comments RSS feed links to head\n add_theme_support( 'automatic-feed-links' );\n\n // set post thumbnail sizes for various post types\n set_post_thumbnail_size( 160, 160, true );\n add_image_size( 'project-feature', 940, 310 ); \n add_image_size( 'large', 620, 9999 );\n add_image_size( 'medium', 340, 9999 );\n\n}", "function init() {\n global $slplus_plugin;\n \n //--------------------------------\n // Store Pages Is Licensed\n //\n if ($slplus_plugin->license->packages['Store Pages']->isenabled) {\n\n // Register Store Pages Custom Type\n register_post_type( 'store_page',\n array(\n 'labels' => array(\n 'name' => __( 'Store Pages',SLPLUS_PREFIX ),\n 'singular_name' => __( 'Store Page', SLPLUS_PREFIX ),\n 'add_new' => __('Add New Store Page', SLPLUS_PREFIX),\n ),\n 'public' => true,\n 'has_archive' => true,\n 'description' => __('Store Locator Plus location pages.',SLPLUS_PREFIX),\n 'menu_postion' => 20, \n 'menu_icon' => SLPLUS_COREURL . 'images/icon_from_jpg_16x16.png',\n 'capability_type' => 'page',\n )\n ); \n \n // Register Stores Taxonomy\n // \n register_taxonomy(\n 'stores',\n 'store_page',\n array (\n 'hierarchical' => true,\n 'labels' => \n array(\n 'menu_name' => __('Stores',SLPLUS_PREFIX),\n 'name' => __('Store Attributes',SLPLUS_PREFIX),\n )\n )\n ); \n } \n }" ]
[ "0.67513204", "0.6545008", "0.6347232", "0.63238263", "0.6217401", "0.61152697", "0.59754544", "0.59493995", "0.5939075", "0.59047425", "0.5881784", "0.5867256", "0.58649045", "0.5841264", "0.5829468", "0.5827468", "0.581845", "0.58076155", "0.58067876", "0.58053976", "0.5794639", "0.57882726", "0.57832015", "0.576904", "0.5762704", "0.5756354", "0.5732228", "0.57193816", "0.57011", "0.5693797", "0.5688222", "0.56720525", "0.5670151", "0.56623125", "0.5661199", "0.5656088", "0.56534785", "0.56426877", "0.56420577", "0.5635029", "0.5630797", "0.5618329", "0.561117", "0.56078285", "0.55934507", "0.55657756", "0.556295", "0.55557644", "0.5545282", "0.5542727", "0.5512837", "0.5509243", "0.5508787", "0.55086404", "0.54921633", "0.5492157", "0.5488916", "0.54889065", "0.5486281", "0.5484718", "0.5484322", "0.54841197", "0.5478102", "0.54778105", "0.547594", "0.5475247", "0.54736114", "0.5470373", "0.54642385", "0.5464002", "0.54625833", "0.5456668", "0.54549235", "0.5452698", "0.5447459", "0.5442001", "0.5433453", "0.5432078", "0.54256856", "0.5419396", "0.5418951", "0.54166585", "0.5416609", "0.54162705", "0.54153955", "0.54117304", "0.54038113", "0.5401245", "0.53936046", "0.53885317", "0.5388385", "0.53796273", "0.53720605", "0.53720134", "0.53715307", "0.53695846", "0.53684705", "0.5366512", "0.5364938", "0.53647214" ]
0.722265
0
Changes the columns to be displayed for the Units post type.
function edit_units_columns( $columns ) { $columns = array( 'cb' => '<input type="checkbox" />', 'title' => __( 'Address' ), 'rent' => __( 'Rent' ), 'status' => __( 'Status' ), 'date' => __( 'Date' ) ); return $columns; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 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 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 }", "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}", "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 wp_nav_menu_manage_columns()\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 }", "function manage_and_filter() {\r\n\t\tadd_filter( \"manage_edit-{$this->post_type}_columns\", array( $this, 'type_column_header' ), 10, 2 );\r\n\t\tadd_action( \"manage_{$this->post_type}_posts_custom_column\", array( $this, 'type_column' ), 10, 3 );\r\n\t\tglobal $typenow;\r\n\t\tif ( $typenow == $this->post_type ) {\r\n\t\t\tadd_action( 'load-edit.php', array( $this, 'filter_load' ) );\r\n\t\t\tadd_filter( 'post_row_actions', array( $this, 'remove_quick_edit' ), 10, 1 );\r\n\t\t}\r\n\t}", "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 }", "function es_managing_custom_product_columns( $columns, $post_type ) {\n if ( $post_type == 'product' )\n $columns[ 'member_price' ] = 'Member Price';\n return $columns;\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 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 wp_nav_menu_manage_columns()\n {\n }", "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 initialize_columns()\n {\n $this->add_column(new DataClassPropertyTableColumn(Right::class_name(), Right::PROPERTY_NAME));\n $this->add_column(new DataClassPropertyTableColumn(Right::class_name(), Right::PROPERTY_DESCRIPTION));\n }", "public function edit_knowledgebase_item_columns( $post_columns ) {\n\n\t\t$screen = get_current_screen();\n\t\t$post_type = $screen->post_type;\n\t\t$columns = array();\n\t\t$taxonomies = array();\n\n\t\t/* Adds the checkbox column. */\n\t\t$columns['cb'] = $post_columns['cb'];\n\n\t\t/* Add custom columns and overwrite the 'title' column. */\n\t\t$columns['title'] = __( 'Article', 'knowledgebase' );\n\n\t\t/* Get taxonomies that should appear in the manage posts table. */\n\t\t$taxonomies = get_object_taxonomies( $post_type, 'objects' );\n\t\t$taxonomies = wp_filter_object_list( $taxonomies, array( 'show_admin_column' => true ), 'and', 'name' );\n\n\t\t/* Allow devs to filter the taxonomy columns. */\n\t\t$taxonomies = apply_filters( \"manage_taxonomies_for_{$post_type}_columns\", $taxonomies, $post_type );\n\t\t$taxonomies = array_filter( $taxonomies, 'taxonomy_exists' );\n\n\t\t/* Loop through each taxonomy and add it as a column. */\n\t\tforeach ( $taxonomies as $taxonomy ) {\n\t\t\t$columns[ 'taxonomy-' . $taxonomy ] = get_taxonomy( $taxonomy )->labels->name;\n\t\t}\n\n\t\t/* Add the comments column. */\n\t\tif ( !empty( $post_columns['comments'] ) ) {\n\t\t\t$columns['comments'] = $post_columns['comments'];\n\t\t}\n\n\t\t$columns['order'] = __( 'Order', 'knowledgebase' );\n\n\t\t/* Return the columns. */\n\t\treturn $columns;\n\t}", "protected function _doColumns()\n {\n global $prefs;\n\n // Turba's columns pref\n $abooks = explode(\"\\n\", $prefs->getValue('columns'));\n if (is_array($abooks) && !empty($abooks[0])) {\n $new_prefs = array();\n $cnt = count($abooks);\n for ($i = 0; $i < $cnt; ++$i) {\n $colpref = explode(\"\\t\", $abooks[$i]);\n $colpref[0] = $this->_updateShareName($colpref[0]);\n $abooks[$i] = implode(\"\\t\", $colpref);\n }\n $prefs->setValue('columns', implode(\"\\n\", $abooks));\n }\n }", "function jeg_post_columns($columns)\n{\n\t$columns['posttype'] = 'Blog Post Type';\n\treturn $columns;\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}", "public function admin_table_columns($_columns)\n {\n }", "function manage_wp_posts_using_bulk_quick_edit_manage_posts_columns( $columns, $post_type ) {\n\t/*if ( $post_type == 'movies' ) {\n\t\t$columns[ 'release_date' ] = 'Release Date';\n\t\t$columns[ 'coming_soon' ] = 'Coming Soon';\n\t\t$columns[ 'film_rating' ] = 'Film Rating';\n\t}\n\t\t\n\treturn $columns;*/\n\t\n\t/**\n\t * The second example adds our new column after the “Title” column.\n\t * Notice that we're specifying a post type because our function covers ALL post types.\n\t */\n\tswitch ( $post_type ) {\n\t\n\t\tcase 'movies':\n\t\t\n\t\t\t// building a new array of column data\n\t\t\t$new_columns = array();\n\t\t\t\n\t\t\tforeach( $columns as $key => $value ) {\n\t\t\t\n\t\t\t\t// default-ly add every original column\n\t\t\t\t$new_columns[ $key ] = $value;\n\t\t\t\t\n\t\t\t\t/**\n\t\t\t\t * If currently adding the title column,\n\t\t\t\t * follow immediately with our custom columns.\n\t\t\t\t */\n\t\t\t\tif ( $key == 'title' ) {\n\t\t\t\t\t$new_columns[ 'release_date' ] = 'Release Date';\n\t\t\t\t\t$new_columns[ 'coming_soon' ] = 'Coming Soon';\n\t\t\t\t\t$new_columns[ 'film_rating' ] = 'Film Rating';\n\t\t\t\t}\n\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\treturn $new_columns;\n\t\t\t\n\t}\n\t\n\treturn $columns;\n\t\n}", "public function get_columns() {\n\t\treturn [\n\t\t\t'product' => __('Product', 'woocommerce'),\n\t\t\t'quantity' => __('Quantity', 'woocommerce'),\n\t\t\t'price' => __('Price', 'woocommerce'),\n\t\t\t'total' => __('Total', 'woocommerce')\n\t\t];\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 }", "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}", "protected function _prepareColumns() {\n /**\n * Add columa 'id','name'.\n */\n $this->addCustomColumn ( 'id' );\n $this->addCustomColumn ( 'name' );\n /**\n * Get the Collection of subscriptiontype\n */\n $subscriptionTitle = Mage::getModel ( 'airhotels/subscriptiontype' )->getCollection ();\n $data = $subscriptionTitle->getData ();\n $substitle = null;\n foreach ( $data as $value ) {\n $i = $value ['id'];\n $substitle [$i] = $value ['title'];\n }\n /**\n * When building a module always utilise the installation and\n * upgrade scripts so that any database additions or changes are automatically modified\n * on module installation.\n * There are a number of built in functions to these modules allowing you to add attributes,\n * create new tables etc.\n *\n * Add Column for subscription_type\n */\n $this->addColumn ( 'subscription_type', array (\n 'header' => Mage::helper ( 'airhotels' )->__ ( 'Subscription Type' ),\n 'align' => 'left',\n 'width' => '80px',\n 'index' => 'subscription_type',\n 'type' => 'options',\n 'options' => $substitle,\n 'renderer' => 'Apptha_Airhotels_Block_Adminhtml_Managesubscriptions_Grid_Renderer_Type' \n ) );\n /**\n * When building a module always utilise the installation and\n * upgrade scripts so that any database additions or changes are automatically modified\n * on module installation.\n * There are a number of built in functions to these modules allowing you to add attributes,\n * create new tables etc.\n *\n * Add Column for action\n */\n $this->addColumn ( 'action', array (\n 'header' => Mage::helper ( 'airhotels' )->__ ( 'Action' ),\n 'filter' => false,\n 'width' => '100',\n 'type' => 'action',\n 'getter' => 'getId', \n 'index' => 'stores',\n 'actions' => array (\n array (\n 'caption' => Mage::helper ( 'airhotels' )->__ ( 'Edit' ),\n 'url' => array (\n 'base' => '*/*/edit'\n ),\n 'field' => 'id'\n )\n ),\n 'sortable' => false,\n 'is_system' => true \n ) );\n /**\n * Calling the parent Construct Method.\n */\n return parent::_prepareColumns ();\n }", "public static function setup_column(int $gridType):void {\r\n\t\t\r\n\t\tif(is_admin()){\r\n\t\t\t// map column behavior to interface specific hooks\r\n\t\t\t$columnTypeMapper = [\r\n\t\t\t\tDrama_Grid_Column_Adaptor_Trait::$COLUMN_TYPE_POSTS => [\r\n\t\t\t\t\t'addColumnFilter' => 'manage_post_posts_columns',\r\n\t\t\t\t\t'addSortableColumnFilter' => 'manage_edit-post_sortable_columns',\r\n\t\t\t\t\t'sortColumnAction' => 'pre_get_posts',\r\n\t\t\t\t\t'getColumnValueAction' => 'manage_post_posts_custom_column',\r\n\t\t\t\t],\r\n\t\t\t\tDrama_Grid_Column_Adaptor_Trait::$COLUMN_TYPE_COMMENTS => [\r\n\t\t\t\t\t'addColumnFilter' => 'manage_edit-comments_columns',\r\n\t\t\t\t\t'addSortableColumnFilter' => 'manage_edit-comments_sortable_columns',\r\n\t\t\t\t\t'sortColumnAction' => 'pre_get_comments',\r\n\t\t\t\t\t'getColumnValueAction' => 'manage_comments_custom_column',\r\n\t\t\t\t],\r\n\t\t\t];\r\n\t\t\r\n\t\t\tif(isset($columnTypeMapper[$gridType])) {\r\n\r\n\t\t\t\t// filters to add columns to admin post grid\r\n\t\t\t\tadd_filter($columnTypeMapper[$gridType]['addColumnFilter'], __CLASS__ . '::add_column');\r\n\t\t\t\t// allow for sorting on drama level\r\n\t\t\t\tadd_filter($columnTypeMapper[$gridType]['addSortableColumnFilter'], __CLASS__ . '::sortable_drama_column');\r\n\t\t\t\t// perform sort logic\r\n\t\t\t\tadd_action($columnTypeMapper[$gridType]['sortColumnAction'], __CLASS__ . '::sort_drama_column');\r\n\t\t\t\t// show drama levels in grid\r\n\t\t\t\tadd_action($columnTypeMapper[$gridType]['getColumnValueAction'], __CLASS__ . '::show_drama_level', 10, 2);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "private function showColumn()\n\t{\n\t\techo '<thead>\n\t\t\t<th></th>';\n\t\t\t\n\t\t\tforeach ($this->col_show as $col)\n\t\t\t\techo '<th>' . $col . '</th>';\n\t\t\n\t\techo '</thead>';\n\t}", "public function register_column_labels() {\n\n\t\t// don't load this unless required by WPML\n\t\tif ( ! isset( $_GET['page'] ) || 'wpml-string-translation/menu/string-translation.php' !== $_GET['page'] ) {\n\t\t\treturn;\n\t\t}\n\n\t\tforeach ( cpac()->get_storage_models() as $storage_model ) {\n\t\t\tforeach ( $storage_model->get_stored_columns() as $column_name => $options ) {\n\t\t\t\ticl_register_string( 'Admin Columns', $storage_model->key . '_' . $column_name, stripslashes( $options['label'] ) );\n\t\t\t}\n\t\t}\n\t}", "function get_display_columns() {\n return $columns = array('id' => __('id', 'kkl-ligatool'), 'name' => __('name', 'kkl-ligatool'), 'club_id' => __('club', 'kkl-ligatool'), 'season_id' => __('season', 'kkl-ligatool'), 'short_name' => __('url_code', 'kkl-ligatool'),);\n }", "protected function _prepareColumns()\n\t{\n\t\t$this->addColumn('id',\n\t\t\t\tarray(\n\t\t\t\t\t\t'header'=> $this->__('ID'),\n\t\t\t\t\t\t'align' =>'right',\n\t\t\t\t\t\t'width' => '50px',\n\t\t\t\t\t\t'index' => 'id'\n\t\t\t\t)\n\t\t);\n\t\t \n\t\t$this->addColumn('name',\n\t\t\t\tarray(\n\t\t\t\t\t\t'header'=> $this->__('Name'),\n\t\t\t\t\t\t'index' => 'name'\n\t\t\t\t)\n\t\t);\n\t\t\n\t\t$this->addColumn('description',\n\t\t\t\tarray(\n\t\t\t\t\t\t'header'=> $this->__('Description'),\n\t\t\t\t\t\t'index' => 'description'\n\t\t\t\t)\n\t\t);\n\t\t\n\t\t$this->addColumn('percentage',\n\t\t\t\tarray(\n\t\t\t\t\t\t'header'=> $this->__('Percentage'),\n\t\t\t\t\t\t'index' => 'percentage'\n\t\t\t\t)\n\t\t);\n\t\t \n\t\treturn parent::_prepareColumns();\n\t}", "public function column_headers($columns) {\n\t\t$ent_list = get_option(str_replace(\"-\", \"_\", $this->textdomain) . '_ent_list');\n\t\tif (!empty($ent_list[$this->post_type]['featured_img'])) {\n\t\t\t$columns['featured_img'] = __('Featured Image', $this->textdomain);\n\t\t}\n\t\tforeach ($this->boxes as $mybox) {\n\t\t\tforeach ($mybox['fields'] as $fkey => $mybox_field) {\n\t\t\t\tif (!in_array($fkey, Array(\n\t\t\t\t\t'wpas_form_name',\n\t\t\t\t\t'wpas_form_submitted_by',\n\t\t\t\t\t'wpas_form_submitted_ip'\n\t\t\t\t)) && !in_array($mybox_field['type'], Array(\n\t\t\t\t\t'textarea',\n\t\t\t\t\t'wysiwyg'\n\t\t\t\t)) && $mybox_field['list_visible'] == 1) {\n\t\t\t\t\t$columns[$fkey] = $mybox_field['name'];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$taxonomies = get_object_taxonomies($this->post_type, 'objects');\n\t\tif (!empty($taxonomies)) {\n\t\t\t$tax_list = get_option(str_replace(\"-\", \"_\", $this->textdomain) . '_tax_list');\n\t\t\tforeach ($taxonomies as $taxonomy) {\n\t\t\t\tif (!empty($tax_list[$this->post_type][$taxonomy->name]) && $tax_list[$this->post_type][$taxonomy->name]['list_visible'] == 1) {\n\t\t\t\t\t$columns[$taxonomy->name] = $taxonomy->label;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$rel_list = get_option(str_replace(\"-\", \"_\", $this->textdomain) . '_rel_list');\n\t\tif (!empty($rel_list)) {\n\t\t\tforeach ($rel_list as $krel => $rel) {\n\t\t\t\tif ($rel['from'] == $this->post_type && in_array($rel['show'], Array(\n\t\t\t\t\t'any',\n\t\t\t\t\t'from'\n\t\t\t\t))) {\n\t\t\t\t\t$columns[$krel] = $rel['from_title'];\n\t\t\t\t} elseif ($rel['to'] == $this->post_type && in_array($rel['show'], Array(\n\t\t\t\t\t'any',\n\t\t\t\t\t'to'\n\t\t\t\t))) {\n\t\t\t\t\t$columns[$krel] = $rel['to_title'];\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn $columns;\n\t}", "public function render_list_table_columns_preferences()\n {\n }", "public function setColumns($settings = array())\n {\n if (!$settings) {\n $settings = $this->fields;\n }\n $this->Columns = array();\n foreach ($settings as $column => $options) {\n if (!is_string($column)) {\n $column = $options;\n $options = false;\n }\n if (!isset($options['display'])) {\n $options['display'] = true;\n }\n if (strpos($column, '.') === false && $column != 'actions') {\n $column = sprintf('%s.%s', $this->defaultModel, $column);\n }\n if (!isset($options['type'])) {\n if (isset($options['switch'])) {\n $options['type'] = 'switch';\n } else {\n $options['type'] = 'cell';\n }\n }\n $class = ucfirst($options['type']).'Column';\n $this->Columns[$column] = new $class($this, $column, $options);\n }\n }", "protected function _prepareColumns()\n {\n $this->addColumn('ID',\n array(\n 'header'=> $this->__('ID'),\n 'width' => '50px',\n 'index' => 'ID'\n )\n );\n\n\n $this->addColumn('browser',\n array(\n 'header'=> $this->__('Browser Data'),\n 'width' => '50px',\n 'index' => 'browser',\n 'renderer' => 'Mage_Osc_Block_Renderers_Browser'\n )\n );\n\n\n $this->addColumn('quote_id',\n array(\n 'header'=> $this->__('ID do Carrinho'),\n 'width' => '50px',\n 'index' => 'quote_id'\n )\n );\n\n\n $this->addColumn('order_id',\n array(\n 'header'=> $this->__('ID do Pedido'),\n 'width' => '50px',\n 'index' => 'order_id',\n 'renderer' => 'Mage_Osc_Block_Renderers_Order'\n )\n );\n\n\n $this->addColumn('customer_id',\n array(\n 'header'=> $this->__('Cliente'),\n 'width' => '50px',\n 'index' => 'customer_id',\n 'renderer' => 'Mage_Osc_Block_Renderers_Customer'\n )\n );\n\n\n $this->addColumn('clickedfo',\n array(\n 'header'=> $this->__('Quantidade de Cliques'),\n 'width' => '50px',\n 'index' => 'clickedfo'\n )\n );\n\n\n $this->addColumn('payment_method',\n array(\n 'header'=> $this->__('Método de Pagamento'),\n 'width' => '50px',\n 'index' => 'payment_method'\n )\n );\n\n\n return parent::_prepareColumns();\n }", "protected function get_sortable_columns()\n {\n }", "protected function get_sortable_columns()\n {\n }", "protected function get_sortable_columns()\n {\n }", "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 }", "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 my_custom_post_columns( $columns )\n\t{\n\t \n\t\t$naming = getTopicNaming();\t\t\n\t\t$sessionSingular = $naming[1];\n\t\t$sessionPlural = pluralize($sessionSingular);\t \n\t \n\n\t\tunset(\n\t\t\t$columns['date']\n\t\t);\t\n\n\t\t$columns['sessions'] = $sessionPlural;\n\t\t$columns['addSession'] = '';\t\n\n\t\t\n\t\t\t\n\t\t \n\t return $columns;\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 }", "protected function AdminRows_settings_columns() {\n\treturn array(\n\t 'ID' => 'ID',\n\t 'ID_Parent' \t=> 'Parent',\n\t 'NameSng'\t=> 'Singular',\n\t 'NamePlr'\t=> 'Plural',\n\t 'Descr'\t=> 'Description',\n\t 'Sort'\t=> 'Sort',\n\t 'isType'\t=> 'Type?'\n\t );\n }", "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}", "protected function initColumns()\n\t{\n\t\tif($this->columns===array())\n\t\t{\n\t\t\tif($this->dataProvider instanceof NActiveDataProvider)\n\t\t\t\t$this->columns=$this->dataProvider->model->attributeNames();\n\t\t\telse if($this->dataProvider instanceof IDataProvider)\n\t\t\t{\n\t\t\t\t// use the keys of the first row of data as the default columns\n\t\t\t\t$data=$this->dataProvider->getData();\n\t\t\t\tif(isset($data[0]) && is_array($data[0]))\n\t\t\t\t\t$this->columns=array_keys($data[0]);\n\t\t\t}\n\t\t}\n\t\t$id=$this->getId();\n\t\tforeach($this->columns as $i=>$column)\n\t\t{\n\t\t\tif ($column['name'] && (!isset($column['export']) || @$column['export']!=false)) {\n\t\t\t\tif(is_string($column))\n\t\t\t\t\t$column=$this->createDataColumn($column);\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\tif(!isset($column['class']))\n\t\t\t\t\t\t$column['class']='NDataColumn';\n\t\t\t\t\t$column=Yii::createComponent($column, $this);\n\t\t\t\t}\n\t\t\t\tif(!$column->visible)\n\t\t\t\t{\n\t\t\t\t\tunset($this->columns[$i]);\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\t\t\t\tif($column->id===null)\n\t\t\t\t\t$column->id=$id.'_c'.$i;\n\t\t\t\t$this->columns[$i]=$column;\n\t\t\t} else {\n\t\t\t\tunset($this->columns[$i]);\n\t\t\t\tcontinue;\n\t\t\t}\n\t\t}\n\n\t\tforeach($this->columns as $column)\n\t\t\t\t$column->init();\n\t}", "function units_sortable_columns( $columns ) {\n\n\t\t$columns['status'] = 'status';\n\n\t\treturn $columns;\n\t}", "public function initialize_columns()\n {\n $this->add_column(new DataClassPropertyTableColumn(User::class_name(), User::PROPERTY_LASTNAME));\n $this->add_column(new DataClassPropertyTableColumn(User::class_name(), User::PROPERTY_FIRSTNAME));\n\n $showEmail = Configuration::getInstance()->get_setting(array('Chamilo\\Core\\User', 'show_email_addresses'));\n\n if($showEmail)\n {\n $this->add_column(new DataClassPropertyTableColumn(User::class_name(), User::PROPERTY_EMAIL));\n }\n\n $this->add_column(new SortableStaticTableColumn('progress'));\n $this->add_column(new SortableStaticTableColumn('completed'));\n $this->add_column(new SortableStaticTableColumn('started'));\n\n if($this->getCurrentTreeNode()->supportsScore())\n {\n $this->add_column(new StaticTableColumn(self::COLUMN_LAST_SCORE));\n }\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 custom_columns( $column, $post_id ) {\n\tswitch ( $column ) {\n\t\tcase 'type':\n\t\t\t$terms = get_post_meta( $post_id, 'freeproductid', true );\n\t\t\tif ( $terms != '' ) {\n\t\t\t\t$freeproducter = wc_get_product( $terms );\n\t\t\t\techo $freeproducter->get_formatted_name( );\n\t\t\t\techo '<br />';\n\t\t\t} else {\n\t\t\t\t_e( 'No free product', 'woocommerce-freeproduct' );\n\t\t\t\techo '<br />';\n\t\t\t}\n\t\t\tbreak;\n\t}\n}", "public function initialize_columns()\n {\n $this->add_column(new DataClassPropertyTableColumn(User::class_name(), User::PROPERTY_LASTNAME));\n \n parent::initialize_columns();\n }", "protected function _prepareColumns()\n {\n if (!$this->getCategory()->getProductsReadonly()) {\n $this->addColumn('in_category', array(\n 'header_css_class' => 'a-center',\n 'type' => 'checkbox',\n 'name' => 'in_category',\n 'values' => $this->_getSelectedProducts(),\n 'align' => 'center',\n 'index' => 'entity_id',\n 'is_system' => true,\n ));\n }\n $this->addColumn('entity_id', array(\n 'header' => Mage::helper('catalog')->__('ID'),\n 'sortable' => true,\n 'width' => '60',\n 'index' => 'entity_id'\n ));\n $this->addColumn('name', array(\n 'header' => Mage::helper('catalog')->__('Name'),\n 'index' => 'name'\n ));\n $this->addColumn('sku', array(\n 'header' => Mage::helper('catalog')->__('SKU'),\n 'width' => '80',\n 'index' => 'sku'\n ));\n $this->addColumn('price', array(\n 'header' => Mage::helper('catalog')->__('Price'),\n 'type' => 'currency',\n 'width' => '1',\n 'currency_code' => (string) Mage::getStoreConfig(Mage_Directory_Model_Currency::XML_PATH_CURRENCY_BASE),\n 'index' => 'price'\n ));\n $this->addColumn('position', array(\n 'header' => Mage::helper('catalog')->__('Position'),\n 'width' => '1',\n 'type' => 'number',\n 'index' => 'position',\n 'editable' => !$this->getCategory()->getProductsReadonly(),\n //'renderer' => 'adminhtml/widget_grid_column_renderer_input'\n ));\n\n //Add export type for CSV\n $this->addExportType('*/*/exportCsv', Mage::helper('adminhtml')->__('CSV'));\n }", "function init_post_type() {\n\n\t\t$labels = array(\n\t\t\t'name' => _x( 'Unit', 'Post Type General Name', 'wppm' ),\n\t\t\t'singular_name' => _x( 'Unit', 'Post Type Singular Name', 'wppm' ),\n\t\t\t'menu_name' => __( 'Units', 'wppm' ),\n\t\t\t'parent_item_colon' => __( 'Parent Item:', 'wppm' ),\n\t\t\t'all_items' => __( 'All Units', 'wppm' ),\n\t\t\t'view_item' => __( 'View Unit', 'wppm' ),\n\t\t\t'add_new_item' => __( 'Add New Unit', 'wppm' ),\n\t\t\t'add_new' => __( 'Add New', 'wppm' ),\n\t\t\t'edit_item' => __( 'Edit Unit', 'wppm' ),\n\t\t\t'update_item' => __( 'Update Unit', 'wppm' ),\n\t\t\t'search_items' => __( 'Search Units', 'wppm' ),\n\t\t\t'not_found' => __( 'Not found', 'wppm' ),\n\t\t\t'not_found_in_trash' => __( 'Not found in Trash', 'wppm' ),\n\t\t);\n\t\t$args = array(\n\t\t\t'label' => __( 'units', 'wppm' ),\n\t\t\t'description' => __( 'Units', 'wppm' ),\n\t\t\t'labels' => $labels,\n\t\t\t'supports' => array( 'title', 'thumbnail', ),\n\t\t\t'hierarchical' => false,\n\t\t\t'public' => true,\n\t\t\t'show_ui' => true,\n\t\t\t'show_in_menu' => true,\n\t\t\t'show_in_nav_menus' => true,\n\t\t\t'show_in_admin_bar' => true,\n\t\t\t'menu_position' => 5,\n\t\t\t//'menu_icon' => '',\n\t\t\t'can_export' => true,\n\t\t\t'has_archive' => true,\n\t\t\t'exclude_from_search' => false,\n\t\t\t'publicly_queryable' => true,\n\t\t\t'capability_type' => 'post',\n\t\t);\n\t\tregister_post_type( 'units', $args );\n\t\tflush_rewrite_rules();\n\t\t\n\t\tadd_image_size( 'tiles-featured', 225, 225, true );\n\t\tadd_image_size( 'mini-tiles', 80, 55, true );\n\t}", "function get_columns() {\n return $columns= array(\n 'col_what'=>__('What','wpwt'),\n 'col_user'=>__('User Name','wpwt'),\n 'col_groupName'=>__('Group Name','wpwt'),\n 'col_application'=>__('Application','wpwt')\n );\n }", "function RGC_dashboard_columns() {\n add_screen_option(\n 'layout_columns',\n array(\n 'max' => 1,\n 'default' => 1\n )\n );\n}", "public function editColumns( $columns ) {\n \n unset($columns['author']); // Remove author, we normally dont need it\n unset($columns['date']); // Remove date, we normally dont need it\n unset($columns['categories']); \n \n foreach($this->fields_list as $field => $label):\n $columns[$field] = __( self::getLabel($field) );\n endforeach;\n return $columns;\n }", "function get_columns() {\r\n return $columns= array(\r\n 'col_created_on'=>__('Date'),\r\n 'col_type'=>__('Type'),\r\n 'col_ip'=>__('IP'),\r\n 'col_os'=>__('Operating System'),\r\n 'col_browser'=>__('Browser'),\r\n 'col_location'=>__('Location'),\r\n 'col_actions'=>__('Actions')\r\n );\r\n }", "public function datatablesUnitOfMeasurement()\n { \n DB::statement(DB::raw('set @rownum=0'));\n $tblUnitOfMeasurement = TblUnitOfMeasurement::select([DB::raw('@rownum := @rownum + 1 AS rownum'),\n 'id','unit4','unit3','unit2','description','eng_definition','ind_definition','created_at']);\n return Datatables::of($tblUnitOfMeasurement)\n ->addColumn('action', function ($tblUnitOfMeasurement) {\n return '<span class=\"pull-right\"><kbd class=\"kbd-primary cpointer edit-uom\" data-id=\"'.$tblUnitOfMeasurement->id.'\">EDIT</kbd>&nbsp;&nbsp;<kbd class=\"kbd-danger cpointer delete-uom\" data-id=\"'.$tblUnitOfMeasurement->id.'\">DELETE</kbd></span>';\n })\n ->setRowId('id')\n ->make(true);\n }", "protected function _prepareColumns()\n {\n $this->addColumn($this->_productIdField, array(\n 'header' => $this->_getHelper()->__('ID'),\n 'sortable' => true,\n 'index' => $this->_productIdField,\n 'width' => 60,\n ));\n\n $this->addColumn('title', array(\n 'header' => $this->_getHelper()->__('Title'),\n 'index' => 'title'\n ));\n\n $this->addColumn('set_title', array(\n 'header' => $this->_getHelper()->__('Attachments Set'),\n 'index' => 'set_title',\n 'width' => 150,\n 'frame_callback' => array($this, 'prepareSetUrl')\n ));\n\n $this->addColumn('file_url', array(\n 'header' => $this->_getHelper()->__('Download'),\n 'index' => 'download',\n 'sortable' => false,\n 'filter' => false,\n 'width' => 150,\n 'frame_callback' => array($this, 'prepareFileUrl')\n ));\n\n $this->addColumn('type', array(\n 'header' => $this->_getHelper()->__('Type'),\n 'index' => 'type',\n 'filter' => false,\n 'width' => 50,\n 'frame_callback' => array($this, 'prepareType')\n ));\n\n $this->addColumn('updated_at', array(\n 'header' => $this->_getHelper()->__('Updated'),\n 'type' => 'date',\n 'index' => 'updated_at',\n 'width' => 150,\n ));\n\n return Mage_Adminhtml_Block_Widget_Grid::_prepareColumns();\n }", "public function previewColumns();", "private function show_columns() {\n\t\tglobal $wpdb, $utils;\n\t\t$domain = $utils->text_domain;\n\t\t$tables = $wpdb->tables('all');\n\t\tif (!isset($_POST['table'])) {\n\t\t\t$message = __('Table name is not selected.', $domain);\n\t\t\treturn $message;\n\t\t} elseif (!in_array($_POST['table'], $tables)) {\n\t\t\t$message = __('There\\'s no such table.', $domain);\n\t\t\treturn $message;\n\t\t}\telse {\n\t\t\t$table_name = $_POST['table'];\n\t\t\t$results = $wpdb->get_results(\"SHOW COLUMNS FROM $table_name\");\n\t\t\treturn $results;\n\t\t}\n\t}", "public function getTableColumns()\n\t{\n\t}", "public static function add_columns( $columns ) {\n\t\n\t\tglobal $post_type;\n\t\n \t\t$columns_start = array_slice( $columns, 0, 1, true );\n \t\t$columns_end = array_slice( $columns, 1, null, true );\n\t\t\n\t\t// add logo coloumn in first\n \t\t$columns = array_merge(\n \t\t$columns_start,\n \t\tarray( 'logo' => __( '', self::$text_domain ) ),\n \t\t$columns_end\n \t\t);\n \t\t\n \t\t// append taxonomy columns on end\n\t\t$taxonomy_names = get_object_taxonomies( self::$post_type_name );\n\t\n\t\tforeach ( $taxonomy_names as $taxonomy_name ) {\n\t\n\t\t\t$taxonomy = get_taxonomy( $taxonomy_name );\n\t\n\t\t\tif ( $taxonomy->_builtin || !in_array( $post_type , $taxonomy->object_type ) )\n\t\t\t\tcontinue;\n\t\t\t\t\n\t\t\t$columns[ $taxonomy_name ] = $taxonomy->label;\n\t\t}\n\t\t\n\t\treturn $columns;\n\t\t\n\t}", "function column_display( $column ) {\n\t\tglobal $post;\n\t\tswitch ( $column ) {\n\t\tcase 'client_name':\n\t\t\tif ( get_post_meta( $post->ID, 'client_name', true ) )\n\t\t\t\techo get_post_meta( $post->ID, 'client_name', true );\n\t\t\tbreak;\n\t\tcase 'description':\n\t\t\techo the_excerpt();\n\t\t\tbreak;\n\t\tcase 'media':\n\t\tif ( has_post_thumbnail( $post->ID ) ){ echo get_the_post_thumbnail( $post->ID, array(80,80) ); }\n\t\t\tbreak;\n\t\tcase $this->taxID:\n\t\t\techo get_the_term_list( $post->ID, $this->taxID, '', ', ', '' );\n\t\t\tbreak;\n\t\t}\n\t}", "function get_columns() {\n\n\t\treturn $columns = array(\n\t\t\t'cb'\t\t=> '<input type=\"checkbox\" />', //Render a checkbox instead of text\n\t\t\t'title'\t\t=> 'Title',\n\t\t\t'rating'\t=> 'Rating',\n\t\t\t'director'\t=> 'Director'\n\t\t);\n\t}", "public static function columns()\n {\n return [\n 'id' => trans('persona.id.id'),\n 'module_name' => trans_title('modules'),\n 'module_key' => sections('modules.key'),\n 'module_description' => trans('system.description'),\n ];\n }", "public static function columns() {\n\n $controller = new page();\n \n $columns['id'] = new \\Gino\\IntegerField(array(\n\t\t\t'name'=>'id',\n\t\t\t'primary_key'=>true,\n\t\t\t'auto_increment'=>true,\n \t'max_lenght'=>11,\n\t\t));\n $columns['category_id'] = new \\Gino\\ForeignKeyField(array(\n 'name'=>'category_id',\n 'label'=>_(\"Categoria\"),\n 'required'=>false,\n \t'foreign'=>'\\Gino\\App\\Page\\PageCategory',\n \t'foreign_order'=>'name ASC',\n \t'add_related' => true,\n \t'add_related_url' => $controller->linkAdmin(array(), \"block=ctg&insert=1\"),\n ));\n\t\t$columns['author'] = new \\Gino\\ForeignKeyField(array(\n\t\t\t'name' => 'author',\n\t\t\t'label' => _(\"Autore\"),\n\t\t\t'required' => true,\n\t\t\t'foreign' => '\\Gino\\App\\Auth\\User',\n\t\t\t'foreign_order' => 'lastname ASC, firstname ASC',\n\t\t\t'add_related' => false,\n\t\t));\n\t\t$columns['creation_date'] = new \\Gino\\DatetimeField(array(\n\t\t\t'name' => 'creation_date',\n\t\t\t'label' => _('Inserimento'),\n\t\t\t'required' => true,\n\t\t\t'auto_now' => false,\n\t\t\t'auto_now_add' => true,\n\t\t));\n\t\t$columns['last_edit_date'] = new \\Gino\\DatetimeField(array(\n\t\t\t'name'=>'last_edit_date',\n\t\t\t'label'=>_('Ultima modifica'),\n\t\t\t'required'=>true,\n\t\t\t'auto_now'=>true,\n\t\t\t'auto_now_add'=>true,\n\t\t));\n\t\t$columns['title'] = new \\Gino\\CharField(array(\n\t\t\t'name'=>'title',\n\t\t\t'label'=>_(\"Titolo\"),\n\t\t\t'required'=>true,\n\t\t\t'max_lenght'=>200,\n\t\t));\n $columns['slug'] = new \\Gino\\SlugField(array(\n 'name'=>'slug',\n \t'unique_key'=>true,\n 'label'=>array(_(\"Slug\"), _('utilizzato per creare un permalink alla risorsa')),\n 'required'=>true,\n \t'max_lenght'=>200,\n \t'autofill'=>'title',\n ));\n $columns['image'] = new \\Gino\\ImageField(array(\n \t'name'=>'image',\n \t'label'=>_(\"Immagine\"),\n \t'max_lenght'=>100,\n \t'extensions'=>self::$_extension_img,\n \t'resize'=>false,\n \t'path'=>null,\n \t'add_path'=>null\n ));\n $columns['url_image'] = new \\Gino\\CharField(array(\n \t'name'=>'url_image',\n \t'label'=>array(_(\"Collegamento sull'immagine\"), _(\"indirizzo URL\")),\n \t'required'=>false,\n \t'max_lenght'=>200,\n ));\n $columns['text'] = new \\Gino\\TextField(array(\n \t'name' => 'text',\n \t'label' => _(\"Testo\"),\n \t'required' => true\n ));\n $columns['tags'] = new \\Gino\\TagField(array(\n \t'name' => 'tags',\n \t'label' => array(_('Tag'), _(\"elenco separato da virgola\")),\n \t'required' => false,\n \t'max_lenght' => 255,\n \t'model_controller_class' => 'page',\n \t'model_controller_instance' => 0,\n ));\n $columns['enable_comments'] = new \\Gino\\BooleanField(array(\n \t'name'=>'enable_comments',\n \t'label'=>_('Abilita commenti'),\n \t'required'=>true,\n \t'default' => 0\n ));\n\t\t$columns['published'] = new \\Gino\\BooleanField(array(\n 'name'=>'published',\n 'label'=>_('Pubblicato'),\n 'required'=>true,\n \t'default' => 0\n ));\n\t\t$columns['social'] = new \\Gino\\BooleanField(array(\n 'name'=>'social',\n 'label'=>_('Condivisioni social'),\n 'required'=>true,\n \t'default' => 0\n ));\n $columns['private'] = new \\Gino\\BooleanField(array(\n \t'name'=>'private',\n \t'label'=>array(_(\"Privata\"), _(\"pagina visualizzabile da utenti con il relativo permesso\")),\n \t'required'=>true,\n \t'default' => 0\n ));\n /*\n $ids = \\Gino\\App\\Auth\\User::getUsersWithDefinedPermissions(array('can_view_private'), $controller);\n if(count($ids)) {\n \t$where_mf = \"active='1' AND id IN (\".implode(',', $ids).\")\";\n }\n else {\n \t$where_mf = \"id=NULL\";\n }*/\n \n $columns['users'] = new \\Gino\\MulticheckField(array(\n \t'name' => 'users',\n \t'label' => _(\"Utenti che possono visualizzare la pagina\"),\n \t'max_lenght' => 255,\n \t'refmodel' => '\\Gino\\App\\Auth\\User',\n \t'refmodel_where' => \"active='1'\",\n \t'refmodel_order' => \"lastname ASC, firstname\",\n ));\n $columns['view_last_edit_date'] = new \\Gino\\BooleanField(array(\n \t'name' => 'view_last_edit_date',\n \t'label' => _(\"Visualizzare la data di aggiornamento della pagina\"),\n \t'required' => true,\n \t'default' => 0\n ));\n \n $ids = \\Gino\\App\\Auth\\User::getUsersWithDefinedPermissions(array('can_edit_single_page'), $controller);\n if(count($ids)) {\n \t$where_mf = \"active='1' AND id IN (\".implode(',', $ids).\")\";\n }\n else {\n \t$where_mf = \"id=NULL\";\n }\n \n $columns['users_edit'] = new \\Gino\\MulticheckField(array(\n \t'name' => 'users_edit',\n \t'label' => array(_(\"Utenti che possono editare la pagina\"), _(\"elenco degli utenti associati al permesso di redazione dei contenuti di singole pagine\")),\n \t'max_lenght' => 255,\n \t'refmodel' => '\\Gino\\App\\Auth\\User',\n \t'refmodel_where' => $where_mf,\n \t'refmodel_order' => \"lastname ASC, firstname\",\n ));\n $columns['read'] = new \\Gino\\IntegerField(array(\n \t'name'=>'read',\n \t'label'=>_('Visualizzazioni'),\n \t'required'=>true,\n \t'default'=>0,\n ));\n $columns['tpl_code'] = new \\Gino\\TextField(array(\n \t'name'=>'tpl_code',\n \t'label' => array(_(\"Template pagina intera\"), _(\"richiamato da URL (sovrascrive il template di default)\")),\n \t'required' => false,\n 'footnote' => page::explanationTemplate()\n ));\n $columns['box_tpl_code'] = new \\Gino\\TextField(array(\n \t'name'=>'box_tpl_code',\n \t'label' => array(_(\"Template box\"), _(\"richiamato nel template del layout (sovrascrive il template di default)\")),\n \t'required' => false\n ));\n\n return $columns;\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 testimonials_edit_columns( $columns ) {\n\t$columns = array(\n\t\t'cb' => '<input type=\"checkbox\" />',\n\t\t'title' => 'Title',\n\t\t'testimonial' => 'Testimonial',\n\t\t'author' => 'Author',\n\t\t'date' => 'Date'\n\t);\n\n\treturn $columns;\n}", "public function modify_column( $columns ) {\r\n\r\n\t\tunset($columns['taxonomy-market_reports_category']);\r\n\t unset($columns['date']);\r\n\t $columns['taxonomy-market_reports_category'] = __('Category');\r\n\t $columns['data-retention'] = __('Data Retention');\r\n\t $columns['date'] = __('Date');\r\n\r\n\t return $columns;\r\n\t}", "protected function _prepareColumns()\n\t{\n\t\t$this->addColumn('id',\n\t\t\tarray(\n\t\t\t\t'header'=> $this->__('ID'),\n\t\t\t\t'align' =>'right',\n\t\t\t\t'width' => '50px',\n\t\t\t\t'index' => 'id'\n\t\t\t)\n\t\t);\n\n\t\t$this->addColumn('product_id',\n\t\t\tarray(\n\t\t\t\t'header'=> $this->__('Product ID'),\n\t\t\t\t'index' => 'product_id'\n\t\t\t)\n\t\t);\n\n\t\t$this->addColumn('increment_id',\n\t\t\tarray(\n\t\t\t\t'header'=> $this->__('Order ID'),\n\t\t\t\t'index' => 'increment_id'\n\t\t\t)\n\t\t);\n\n $this->addColumn('sfo.order_id',\n array(\n 'header' => Mage::helper('core')->__('View Order'),\n 'width' => '100',\n 'type' => 'action',\n 'getter' => 'getOrderId',\n 'actions' => array(\n array(\n 'caption' => Mage::helper('core')->__('View'),\n 'url' => array('base'=> 'adminhtml/sales_order/view'),\n 'field' => 'order_id',\n 'target' => '_blank'\n )\n ),\n 'filter' => false,\n 'sortable' => false,\n 'index' => 'stores',\n 'is_system' => true\n )\n );\n\n $this->addColumn('email',\n array(\n 'header'=> $this->__('Customer Email'),\n 'index' => 'email'\n )\n );\n\n $statusOptions = array(\n '0' => 'Working',\n '1' => 'Requested',\n '2' => 'Collected'\n );\n $this->addColumn('status',\n array(\n 'header'=> $this->__('Status (WORKING=0,REQUESTED=1,COLLECTED=2)'),\n 'index' => 'status',\n 'filter_index' => '`main_table`.`status`',\n 'type' => 'options',\n 'options' => $statusOptions,\n )\n );\n\n $this->addColumn('collect_date',\n array(\n 'header'=> $this->__('Collect Date'),\n 'index' => 'collect_date'\n )\n );\n\n\t\treturn parent::_prepareColumns();\n\t}", "static function get_column_info( $page = '' ) {\n\n\t\t$columns = array(\n\t\t\t'posts' => array(\n\t\t\t\t'author' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-posts-author',\n\t\t\t\t\t\t'title' => _x( 'Author', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'categories' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-posts-categories',\n\t\t\t\t\t\t'title' => _x( 'Categories', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'tags' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-posts-tags',\n\t\t\t\t\t\t'title' => _x( 'Tags', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'comments' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-posts-comments',\n\t\t\t\t\t\t'title' => _x( 'Comments', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'date' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-posts-date',\n\t\t\t\t\t\t'title' => _x( 'Date', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0\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'pages' => array(\n\t\t\t\t'author' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-pages-author',\n\t\t\t\t\t\t'title' => _x( 'Author', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'comments' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-pages-comments',\n\t\t\t\t\t\t'title' => _x( 'Comments', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'date' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-pages-date',\n\t\t\t\t\t\t'title' => _x( 'Date', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0\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'media' => array(\n\t\t\t\t'icon' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-media-icon',\n\t\t\t\t\t\t'title' => _x( 'File icon / thumbnail preview', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'author' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-media-author',\n\t\t\t\t\t\t'title' => _x( 'Author', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'parent' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-media-parent',\n\t\t\t\t\t\t'title' => _x( 'Uploaded to', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'comments' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-media-comments',\n\t\t\t\t\t\t'title' => _x( 'Comments', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'date' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-media-date',\n\t\t\t\t\t\t'title' => _x( 'Date', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0\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'users' => array(\n\t\t\t\t'username' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-users-username',\n\t\t\t\t\t\t'help' => __( 'The user\\'s username and avatar', 'clientside' ),\n\t\t\t\t\t\t'title' => __( 'Username' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author',\n\t\t\t\t\t\t\t'editor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0,\n\t\t\t\t\t\t\t'editor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'name' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-users-name',\n\t\t\t\t\t\t'title' => _x( 'Name', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'help' => __( 'The user\\'s full name', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author',\n\t\t\t\t\t\t\t'editor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0,\n\t\t\t\t\t\t\t'editor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'email' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-users-email',\n\t\t\t\t\t\t'title' => _x( 'E-mail', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author',\n\t\t\t\t\t\t\t'editor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0,\n\t\t\t\t\t\t\t'editor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'role' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-users-role',\n\t\t\t\t\t\t'title' => _x( 'Role', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author',\n\t\t\t\t\t\t\t'editor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0,\n\t\t\t\t\t\t\t'editor' => 0\n\t\t\t\t\t\t)\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'posts' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-users-posts',\n\t\t\t\t\t\t'title' => _x( 'Posts', 'Admin column title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'help' => __( 'The user\\'s post count', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'disabled-for' => array(\n\t\t\t\t\t\t\t'subscriber',\n\t\t\t\t\t\t\t'contributor',\n\t\t\t\t\t\t\t'author',\n\t\t\t\t\t\t\t'editor'\n\t\t\t\t\t\t),\n\t\t\t\t\t\t'default' => array(\n\t\t\t\t\t\t\t'clientside-default' => 1,\n\t\t\t\t\t\t\t'subscriber' => 0,\n\t\t\t\t\t\t\t'contributor' => 0,\n\t\t\t\t\t\t\t'author' => 0,\n\t\t\t\t\t\t\t'editor' => 0\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// WooCommerce columns\n\t\tif ( class_exists( 'WooCommerce' ) ) {\n\t\t\t$columns['woocommerce-products'] = array(\n\t\t\t\t'thumb' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-thumb',\n\t\t\t\t\t\t'title' => __( 'Product image', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'name' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-name',\n\t\t\t\t\t\t'title' => __( 'Product title', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'sku' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-sku',\n\t\t\t\t\t\t'title' => __( 'SKU', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'is_in_stock' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-is_in_stock',\n\t\t\t\t\t\t'title' => __( 'Stock', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'price' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-price',\n\t\t\t\t\t\t'title' => __( 'Price', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'product_cat' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-product_cat',\n\t\t\t\t\t\t'title' => __( 'Categories', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'product_tag' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-product_tag',\n\t\t\t\t\t\t'title' => __( 'Tags', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'featured' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-featured',\n\t\t\t\t\t\t'title' => __( 'Featured product', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'product_type' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-product_type',\n\t\t\t\t\t\t'title' => __( 'Product type', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'date' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-products-date',\n\t\t\t\t\t\t'title' => __( 'Date', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['woocommerce-orders'] = array(\n\t\t\t\t'order_status' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_status',\n\t\t\t\t\t\t'title' => __( 'Order status', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'order_title' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_title',\n\t\t\t\t\t\t'title' => __( 'Order', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'order_items' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_items',\n\t\t\t\t\t\t'title' => __( 'Order items', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'billing_address' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-billing_address',\n\t\t\t\t\t\t'title' => __( 'Billing address', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'shipping_address' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-shipping_address',\n\t\t\t\t\t\t'title' => __( 'Shipping address', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'customer_message' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-customer_message',\n\t\t\t\t\t\t'title' => __( 'Customer message', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'order_notes' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_notes',\n\t\t\t\t\t\t'title' => __( 'Order notes', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'order_date' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_date',\n\t\t\t\t\t\t'title' => __( 'Order date', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'order_total' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_total',\n\t\t\t\t\t\t'title' => __( 'Order total', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'order_actions' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-orders-order_actions',\n\t\t\t\t\t\t'title' => __( 'Order actions', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['woocommerce-coupons'] = array(\n\t\t\t\t'coupon_code' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-coupon_code',\n\t\t\t\t\t\t'title' => __( 'Coupon code', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'type' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-type',\n\t\t\t\t\t\t'title' => __( 'Coupon type', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'amount' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-amount',\n\t\t\t\t\t\t'title' => __( 'Coupon value', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'description' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-description',\n\t\t\t\t\t\t'title' => __( 'Description', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'products' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-products',\n\t\t\t\t\t\t'title' => __( 'Product IDs', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'usage' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-usage',\n\t\t\t\t\t\t'title' => __( 'Usage / Limit', 'woocommerce' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t'expiry_date' => array(\n\t\t\t\t\t'field' => array(\n\t\t\t\t\t\t'name' => 'admin-column-manager-woocommerce-coupons-expiry_date',\n\t\t\t\t\t\t'title' => __( 'Expiry date', 'clientside' ),\n\t\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t\t'default' => 1\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t);\n\t\t}\n\n\t\t// Yoast columns\n\t\tif ( defined( 'WPSEO_FILE' ) ) {\n\n\t\t\t// Yoast: Posts\n\t\t\t$columns['posts']['wpseo-links'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-links',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Internal links', 'clientside' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['posts']['wpseo-score'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-score',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'SEO score', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['posts']['wpseo-score-readability'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-score-readability',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Readability score', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['posts']['wpseo-title'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-title',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'SEO Title', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['posts']['wpseo-metadesc'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-metadesc',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Meta Desc.', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['posts']['wpseo-focuskw'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-focuskw',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Focus KW', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['posts']['wpseo-links'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-posts-wpseo-links',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Internal links', 'clientside' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\n\t\t\t// Yoast: Pages\n\t\t\t$columns['pages']['wpseo-links'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-links',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Internal links', 'clientside' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['pages']['wpseo-score'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-score',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'SEO score', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['pages']['wpseo-score-readability'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-score-readability',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Readability score', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['pages']['wpseo-title'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-title',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'SEO Title', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['pages']['wpseo-metadesc'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-metadesc',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Meta Desc.', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['pages']['wpseo-focuskw'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-focuskw',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Focus KW', 'wordpress-seo' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\t\t\t$columns['pages']['wpseo-links'] = array(\n\t\t\t\t'field' => array(\n\t\t\t\t\t'name' => 'admin-column-manager-pages-wpseo-links',\n\t\t\t\t\t'title' => sprintf( __( 'Yoast SEO: %s', 'clientside' ), __( 'Internal links', 'clientside' ) ),\n\t\t\t\t\t'secondary-title' => __( 'Enable for %s', 'clientside' ),\n\t\t\t\t\t'type' => 'checkbox',\n\t\t\t\t\t'role-based' => true,\n\t\t\t\t\t'default' => 1\n\t\t\t\t)\n\t\t\t);\n\n\t\t}\n\n\t\t// Return\n\t\tif ( $page ) {\n\t\t\treturn isset( $columns[ $page ] ) ? $columns[ $page ] : array();\n\t\t}\n\t\treturn $columns;\n\n\t}", "function add_columns_to_mapping_screen($columns)\n {\n\n $columns[__($this->taxonomies_name, $this->tax_domain)] = $this->taxonomies_id;\n\n // Always add English mappings.\n $columns[$this->taxonomies_name] = $this->taxonomies_id;\n\n return $columns;\n }", "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 get_columns(){\n\n\t\t$columns = array(\n\t\t\t\t\t\t\t'code'\t\t\t=>\t__( 'Voucher Code', 'woovoucher' ),\n\t\t\t\t\t\t\t'product_info'\t=>\t__(\t'Product Information', 'woovoucher' ),\n\t\t\t\t\t\t\t'buyers_info'\t=>\t__(\t'Buyer\\'s Information', 'woovoucher' ),\n\t\t\t\t\t\t\t'order_info'\t=>\t__(\t'Order Information', 'woovoucher' ),\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t'redeem_by'\t\t=>\t__(\t'Redeem Information', 'woovoucher' ),\n\t\t\t\t\t);\n\n\t\treturn apply_filters( 'woo_vou_used_add_column', $columns );\n\t}", "public static function edit_post_columns( $columns ) {\n\t\t\n\t\t\t$columns = array(\n\t\t\t\t'cb' => '<input type=\"checkbox\" />',\n\t\t\t\t'title' => __( 'Dish' ),\n\t\t\t\t'category' => __( 'Category' ),\n\t\t\t\t'date' => __( 'Date' )\n\t\t\t);\n\t\t\n\t\t\treturn $columns;\n\t\t}", "public function define_columns( $columns ) {\n\t\tif ( empty( $columns ) && ! is_array( $columns ) ) {\n\t\t\t$columns = array();\n\t\t}\n\n\t\tunset( $columns['title'], $columns['comments'], $columns['date'] );\n\n\t\t$show_columns = array();\n\t\t$show_columns['cb'] = '<input type=\"checkbox\" />';\n\t\t$show_columns['thumb'] = '<span class=\"wc-image tips\" data-tip=\"' . esc_attr__( 'Image', 'woocommerce' ) . '\">' . __( 'Image', 'woocommerce' ) . '</span>';\n\t\t$show_columns['name'] = __( 'Name', 'woocommerce' );\n\n\t\tif ( wc_product_sku_enabled() ) {\n\t\t\t$show_columns['sku'] = __( 'SKU', 'woocommerce' );\n\t\t}\n\n\t\tif ( 'yes' === get_option( 'woocommerce_manage_stock' ) ) {\n\t\t\t$show_columns['is_in_stock'] = __( 'Stock', 'woocommerce' );\n\t\t}\n\n\t\t$show_columns['price'] = __( 'Price', 'woocommerce' );\n\t\t$show_columns['product_cat'] = __( 'Categories', 'woocommerce' );\n\t\t$show_columns['product_tag'] = __( 'Tags', 'woocommerce' );\n\t\t$show_columns['featured'] = '<span class=\"wc-featured parent-tips\" data-tip=\"' . esc_attr__( 'Featured', 'woocommerce' ) . '\">' . __( 'Featured', 'woocommerce' ) . '</span>';\n\t\t$show_columns['date'] = __( 'Date', 'woocommerce' );\n\n\t\treturn array_merge( $show_columns, $columns );\n\t}", "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 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 }", "public function set_custom_column( $columns )\n {\n /* We are going to rearrange the information */\n $title = $columns['title'];\n $date = $columns['date'];\n unset ( $columns['title'] , $columns['date'] );\n\n $columns['name'] = 'Author Name';\n $columns['title'] = $title;\n $columns['approved'] = 'Approved';\n $columns['featured'] = 'Featured';\n $columns['date'] = $date;\n return ( $columns );\n }", "public function add_posts_columns( $columns, $post_type ) {\n\n\t\t// Only for these post types.\n\t\tif ( ! in_array( $post_type, [ 'schedule', 'speakers' ] ) ) {\n\t\t\treturn $columns;\n\t\t}\n\n\t\t// Columns to add after title.\n\t\t$add_columns_after_title = [\n\t\t\t'schedule' => [\n\t\t\t\t'proposal' => __( 'Proposal', 'conf-schedule' ),\n\t\t\t\t'speakers' => __( 'Speaker(s)', 'conf-schedule' ),\n\t\t\t\t'date' => __( 'Date', 'conf-schedule' ),\n\t\t\t\t'location' => __( 'Location', 'conf-schedule' ),\n\t\t\t\t'featured-image' => __( 'Image', 'conf-schedule' ),\n\t\t\t],\n\t\t\t'speakers' => [\n\t\t\t\t'events' => __( 'Events', 'conf-schedule' ),\n\t\t\t],\n\t\t];\n\n\t\t// Store new columns.\n\t\t$new_columns = [];\n\n\t\tforeach ( $columns as $key => $value ) {\n\n\t\t\t// Add to new columns.\n\t\t\t$new_columns[ $key ] = $value;\n\n\t\t\t// Add custom columns after title.\n\t\t\tif ( 'title' == $key ) {\n\t\t\t\tforeach ( $add_columns_after_title[ $post_type ] as $column_key => $column_value ) {\n\t\t\t\t\t$new_columns[\"conf-sch-{$column_key}\"] = $column_value;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn $new_columns;\n\t}", "protected function _prepareColumns()\n {\n $this->addColumn('ticket_id', array(\n 'header' => Mage::helper('inchoo_supportticket')->__('ID'),\n 'width' => '80px',\n 'index' => 'ticket_id'\n ));\n $this->addColumn('subject', array(\n 'header'=> Mage::helper('inchoo_supportticket')->__('Subject'),\n 'type'=> 'text',\n 'width' => '300px',\n 'index' => 'subject',\n 'escape' => true\n ));\n $this->addColumn('content', array(\n 'header'=> Mage::helper('inchoo_supportticket')->__('Content'),\n 'type' => 'text',\n 'index' => 'content',\n 'escape' => true\n ));\n $this->addColumn('status', array(\n 'header'=> Mage::helper('inchoo_supportticket')->__('Status'),\n 'type'=> 'text',\n 'width' => '200px',\n 'index' => 'status',\n 'escape' => true\n ));\n $this->addColumn('created_at', array(\n 'header'=> Mage::helper('inchoo_supportticket')->__('Created at'),\n 'type' => 'text',\n 'width' => '170px',\n 'index' => 'created_at',\n ));\n return parent::_prepareColumns();\n }", "public function columnMap()\n {\n return array(\n 'id' => 'id',\n 'item_type'\t=> 'itemtype',\n 'name' => 'name',\n 'description' => 'description',\n 'cash'\t=> 'cashCost',\n 'diamond' => 'diamondCost',\n );\n }", "protected function _prepareColumns()\n {\n $this->addColumn('recipetype_id', array(\n 'header' => Mage::helper('recomiendo_recipes')->__('ID'),\n 'width' => '50px',\n 'index' => 'recipetype_id',\n ));\n\n $this->addColumn('name', array(\n 'header' => Mage::helper('recomiendo_recipes')->__('Nombre Clasificación'),\n 'index' => 'name',\n ));\n\n return parent::_prepareColumns();\n }", "function _1p21_dv_cust_col( $column, $post_id ) {\n\t\tglobal $post;\n\n\t\tswitch( $column ) {\n\n\t\t\t/* If displaying the 'duration' column. */\n\t\t\tcase 'id' :\n\t\t\techo '<b>'.$post->ID.'</b>';\n\t\t\tdefault :\n\t\t\t\tbreak;\n\t\t}\n\t}", "function industries_edit_columns( $columns ) {\n\t$columns = array(\n\t\t\"cb\" => \"<input type=\\\"checkbox\\\" />\",\n\t\t\"title\" => \"Industry Title\",\n\t);\n\n\treturn $columns;\n}", "protected function _prepareColumns()\n {\n $this->addColumn('increment_id', array(\n 'header' => Mage::helper('sales')->__('Shipment #'),\n 'index' => 'increment_id',\n 'filter_index' => 'main_table.increment_id',\n 'type' => 'text',\n ));\n $this->addColumn('shipment_id', array(\n 'header' => Mage::helper('sales')->__('Shipment #'),\n 'index' => 'entity_id',\n 'filter_index' => 'main_table.entity_id',\n 'type' => 'text',\n ));\n\n $this->addColumn('canpar_shipment_id', array(\n 'header' => Mage::helper('sales')->__('Canpar Shipment #'),\n 'index' => 'canpar_shipment_id',\n 'filter_index' => 'ch_shipment.shipment_id',\n 'type' => 'text',\n ));\n\n $this->addColumn('manifest_id', array(\n 'header' => Mage::helper('sales')->__('Canpar Manifest #'),\n 'index' => 'manifest_id',\n 'renderer' => 'canparmodule/adminhtml_canparshipment_renderer_manifestId',\n 'filter_index' => 'ch_shipment.manifest_id',\n ));\n\n $this->addColumn('created_at', array(\n 'header' => Mage::helper('sales')->__('Date Shipped'),\n 'index' => 'created_at',\n 'filter_index' =>'main_table.created_at',\n 'type' => 'datetime',\n ));\n\n $this->addColumn('order_increment_id', array(\n 'header' => Mage::helper('sales')->__('Order #'),\n 'index' => 'order_increment_id',\n 'filter_index'=> 'o.increment_id',\n 'type' => 'text',\n ));\n\n $this->addColumn('order_created_date', array(\n 'header' => Mage::helper('sales')->__('Order Date'),\n 'index' => 'order_created_date',\n 'filter_index' =>'o.created_at',\n 'type' => 'datetime',\n ));\n\n $this->addColumn('total_qty', array(\n 'header' => Mage::helper('sales')->__('Total Qty'),\n 'index' => 'total_qty',\n 'type' => 'number',\n ));\n\n $this->addColumn('action',\n array(\n 'header' => Mage::helper('sales')->__('Action'),\n 'width' => '50px',\n 'type' => 'action',\n 'getter' => 'getId',\n 'actions' => array(\n array(\n 'caption' => Mage::helper('sales')->__('View'),\n 'url' => array('base'=>'*/sales_shipment/view'),\n 'field' => 'shipment_id'\n )\n ),\n 'filter' => false,\n 'sortable' => false,\n 'is_system' => true\n ));\n\n $this->addExportType('*/*/exportCsv', Mage::helper('sales')->__('CSV'));\n $this->addExportType('*/*/exportExcel', Mage::helper('sales')->__('Excel XML'));\n\n return parent::_prepareColumns();\n }", "public function set_columns( $columns ) {\n\n\t\t$date_column = $columns['date'];\n\t\t$author_column = $columns['author'];\n\n\t\tunset( $columns['date'] );\n\t\tunset( $columns['author'] );\n\n\t\t$columns['type'] = esc_html__( 'Type', 'elementskit' );\n\t\t$columns['condition'] = esc_html__( 'Conditions', 'elementskit' );\n\t\t$columns['date'] = $date_column;\n\t\t$columns['author'] = $author_column;\n\n\t\treturn $columns;\n\t}", "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}", "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 }", "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 custom_event_columns( $columns ) {\n\t\tglobal $post;\n\t\tswitch ( $columns ) {\t\t\n\t\t\tcase 'calendar' :\n\t\t\t\techo get_the_term_list( $post->ID , 'calendar' );\n\t\t\tbreak;\n\t\t\t\n\t\t\tcase 'event_date' :\t\n\t\t\t\t$meta_date \t\t= get_post_meta( $post->ID , 'event_date' , true );\n\t\t\t\t$display_date \t= date('l, F j', strtotime( $meta_date ) );\n\t\t\t\techo $display_date;\n\t\t\tbreak;\n\t\t\t\n\t\t\tcase 'event_time' :\t\n\t\t\t\t$meta_time \t\t= get_post_meta( $post->ID , 'event_start' , true );\n\t\t\t\t$display_time \t= date('g:i a', strtotime( $meta_time ) );\n\t\t\t\techo $display_time;\n\t\t\tbreak;\n\t\t}\n\t}", "public function gridAction()\n {\n $this->getResponse()->setBody(\n $this->getLayout()->createBlock('googlebase/adminhtml_types_grid')->toHtml()\n );\n }", "function manage_posts_columns($columns) {\n\t$columns['recommend_post'] = __('Recommend post', 'tcd-w');\n\treturn $columns;\n}", "protected function _prepareColumns()\n {\n parent::_prepareColumns();\n\n $this->addColumn('attribute_code', array(\n 'header' => Mage::helper('eav')->__('Attribute Code'),\n 'sortable' => true,\n 'index' => 'attribute_code'\n ));\n\n $this->addColumn('frontend_label', array(\n 'header' => Mage::helper('eav')->__('Attribute Label'),\n 'sortable' => true,\n 'index' => 'frontend_label'\n ));\n }", "function map_columns($columns)\n {\n $columns[$this->taxonomies_id] = __($this->taxonomies_name, $this->tax_domain);\n return $columns;\n }", "function js_custom_project_admin_sortable_columns( $columns ) {\n\t$columns['project_post_id'] = 'ID';\n\treturn $columns;\n}", "protected function _prepareColumns()\n\t{\n\t\tparent::_prepareColumns();\n\t\t\n\t\t// remove old columns\n\t\t$this->removeColumn('gender'); // futureproof\n $this->removeColumn('lastname');\n $this->removeColumn('firstname');\n\t\t\n\t\t// add new columns\n\t\t$this->addColumnAfter('gender', array(\n\t\t\t'header' => Mage::helper('newsletter')->__('Gender'),\n 'index' => 'customer_gender',\n 'type' => 'options',\n 'options' => array(\n 1 => Mage::helper('newsletter')->__('Mr'),\n 2 => Mage::helper('newsletter')->__('Ms/Mrs')\n ),\n\t\t\t'renderer'\t=> 'Mediarocks_NewsletterExtended_Adminhtml_Block_Newsletter_Subscriber_Grid_Renderer_Gender'\n\t\t), 'type');\n\t\t\n\t\t$this->addColumnAfter('firstname', array(\n\t\t\t'header' => Mage::helper('newsletter')->__('Firstname'),\n 'index' => 'customer_firstname',\n\t\t\t'renderer'\t=> 'Mediarocks_NewsletterExtended_Adminhtml_Block_Newsletter_Subscriber_Grid_Renderer_Firstname'\n\t\t), 'gender');\n\t\t\n\t\t$this->addColumnAfter('lastname', array(\n\t\t\t'header' => Mage::helper('newsletter')->__('Lastname'),\n 'index' => 'customer_lastname',\n\t\t\t'renderer'\t=> 'Mediarocks_NewsletterExtended_Adminhtml_Block_Newsletter_Subscriber_Grid_Renderer_Lastname'\n\t\t), 'firstname');\n\n\t\t// manually sort again, that our custom order works\n\t\t$this->sortColumnsByOrder();\n\t\t\n return $this;\n }", "public function getColumns()\r\n {\r\n }", "public function get_columns()\n {\n }", "public function get_columns()\n {\n }", "public function run() {\n\t\tadd_action( 'init', array( $this, 'register_post_type' ) );\n\t\tadd_filter( 'manage_drsa_ad_posts_columns', array( $this, 'list_columns' ) );\n\t\tadd_action( 'manage_drsa_ad_posts_custom_column', array( $this, 'list_columns_content' ), 10, 2 );\n\t}" ]
[ "0.6635538", "0.65488625", "0.64081365", "0.6278333", "0.61570716", "0.61455965", "0.60919446", "0.6026718", "0.5932727", "0.5906783", "0.57813585", "0.57395846", "0.5713085", "0.57034844", "0.5686188", "0.567229", "0.56613094", "0.565526", "0.5645981", "0.56454396", "0.5644373", "0.5633798", "0.5628953", "0.56274015", "0.5620977", "0.56098646", "0.5601366", "0.55526346", "0.5545582", "0.55413014", "0.55346906", "0.5530601", "0.5529454", "0.55171245", "0.5511364", "0.5511047", "0.5511047", "0.55068815", "0.5505886", "0.54889005", "0.5480938", "0.54661417", "0.54487723", "0.54450035", "0.5444529", "0.54368776", "0.54215455", "0.54119384", "0.54073185", "0.540261", "0.53917503", "0.5377294", "0.5376585", "0.53759867", "0.5375819", "0.53739583", "0.5340417", "0.53385484", "0.53375924", "0.5335515", "0.53300405", "0.5329428", "0.5310031", "0.53048515", "0.5284618", "0.5267839", "0.5254436", "0.52439785", "0.52370346", "0.523638", "0.5236376", "0.5230385", "0.5228086", "0.5227389", "0.5226368", "0.52240705", "0.52239627", "0.52220845", "0.52195513", "0.5217844", "0.5215592", "0.5215047", "0.5214327", "0.52139705", "0.5208519", "0.52055186", "0.52050346", "0.51981413", "0.5197993", "0.51954514", "0.51946086", "0.5188735", "0.5188069", "0.5181158", "0.51791024", "0.5178429", "0.5174467", "0.5173824", "0.5173824", "0.5173696" ]
0.6498252
2
Takes the passed column name and grabs the column value for each unit.
function manage_units_columns( $column ) { global $post; switch( $column ) { case 'rent' : $rent = get_post_meta( $post->ID, 'rent', true ); if (!empty($rent)) { printf( __( '$%s' ), $rent ); } else { printf( '<i class="fa fa-exclamation-circle"></i>' ); } break; case 'status' : $status = get_post_meta( $post->ID, 'status', true ); printf( $status ); break; default : break; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function value($column)\r\n {\r\n $rs = (array) $this->first();\r\n return $rs[$column];\r\n }", "function get_data ($row, $column)\n {\n global $data_array;\n $column_array = array ();\n $column_array = explode (\"\\t\", $data_array[$row]);\n return ($column_array[$column]);\n }", "public function getValue($value, $column)\n {\n $val = '';\n if (isset($value[$column['name']])) {\n $val = $value[$column['name']];\n }\n return $val;\n }", "public function getData($order_id, $column_name)\r\n {\r\n $order_query = $this->db->query(\"SELECT \" . $column_name . \" FROM `\" . DB_PREFIX . self::$table_name . \"` WHERE order_id = \" . (int)$order_id . \" LIMIT 1\");\r\n return $this->getValueFromQuery($column_name, $order_query);\r\n }", "public function getData($order_id, $column_name)\r\n {\r\n $order_query = $this->db->query(\"SELECT \" . $column_name . \" FROM `\" . DB_PREFIX . self::$table_name . \"` WHERE order_id = \" . (int)$order_id . \" LIMIT 1\");\r\n return $this->getValueFromQuery($column_name, $order_query);\r\n }", "private function get_by_col($col_name, $col_value) {\n $return_val = array();\n foreach ($this->records as $tax_status_type_option) {\n if ($col_value == $tax_status_type_option[$col_name]) {\n $return_val = $tax_status_type_option;\n break;\n }\n }\n \n return $return_val;\n }", "function get_col($query=null,$x=0) {\n\n\t\t\t// If there is a query then perform it if not then use cached results..\n\t\t\tif ( $query ) {\n\t\t\t\t$this->query($query);\n\t\t\t}\n\n\t\t\t// Extract the column values\n\t\t\tfor ( $i=0; $i < count($this->last_result); $i++ ) {\n\t\t\t\t$new_array[$i] = $this->get_var(null,$x,$i);\n\t\t\t}\n\n\t\t\treturn $new_array;\n\t\t}", "public function getValueByColumnName($column){\n foreach (self::$excelLabelList as $attribute=>$labels) {\n\n if (in_array($column,$labels,false)){\n return $this->$attribute;\n }\n }\n\n return null;\n }", "function GetColVal($col_name) {\n\t\treturn $this->$col_name;\n\t}", "public static function get_column_value_for_id($user_id, $id, $table, $column_name)\n {\n $database = Database::instance();\n $sql = \"SELECT \" . $column_name . \" FROM \" . $table . \" WHERE active = 1 AND user_id = \" . $user_id . \" AND id = \" . $id;\n $query = $database->prepare($sql);\n $query->execute();\n $result = $query->fetch(\\PDO::FETCH_ASSOC);\n $query->closeCursor();\n if($result === false || $result === null) {\n $http_response = HttpFailCodes::http_response_fail()->get_single_column_value;\n $http_response->message = \"There was a problem getting the \" . $column_name . \".\";\n APIService::response_fail($http_response);\n }else{\n return $result[$column_name];\n }\n }", "public static function getWaist($column){\n $units = array();\n\n\t\ttry{\n \t\n \t$units = UserWaistUnitOptions::orderBy('id')->pluck($column, 'id')->toArray();\n\n \tif(isset($units) && count($units) > 0 ){\n\t return $units;\n\t }\n }catch(\\Exception $e){\n \tLog::error($e->getMessage());\n \treturn $units = [];\n }\n\n return $units = [];\n }", "function get_col($query=null,$x=0)\n\t\t{\n\n\t\t\t$new_array = array();\n\n\t\t\t// If there is a query then perform it if not then use cached results..\n\t\t\tif ( $query )\n\t\t\t{\n\t\t\t\t$this->query($query);\n\t\t\t}\n\n\t\t\t// Extract the column values\n\t\t\tfor ( $i=0; is_array($this->last_result) && $i < count($this->last_result); $i++ )\n\t\t\t{\n\t\t\t\t$new_array[$i] = $this->get_var(null,$x,$i);\n\t\t\t}\n\n\t\t\treturn $new_array;\n\t\t}", "function get_col( $query = null , $x = 0 ) {\n\t\tif ( $query )\n\t\t\t$this->dbcr_query( $query );\n\n\t\t$new_array = array();\n\t\t// Extract the column values\n\t\tfor ( $i = 0, $j = count( $this->dbcr_wpdb->last_result ); $i < $j; $i++ ) {\n\t\t\t$new_array[$i] = $this->get_var( null, $x, $i );\n\t\t}\n\t\treturn $new_array;\n\t}", "public static function getChest($column){\n $units = array();\n\n\t\ttry{\n \t\n \t$units = UserChestUnitOptions::orderBy('id')->pluck($column, 'id')->toArray();\n\n \tif(isset($units) && count($units) > 0 ){\n\t return $units;\n\t }\n }catch(\\Exception $e){\n \tLog::error($e->getMessage());\n \treturn $units = [];\n }\n\n return $units = [];\n }", "public function getColumnDetails( $tablename, $columnname );", "public function fetchCol($columnName);", "public static function get_column($col)\n\t{\n\t\ttry\n\t\t{\n\t\t\t$devices = DB::table('devices')->get($col);\n\t\t\treturn $devices;\n\t\t}\n\n\t\tcatch (Exception $e)\n\t\t{\n\t\t\tLog::write('error', $e->getMessage());\n\t\t\tthrow $e;\t\t\t\n\t\t}\n\t}", "public static function columns_data($table, $column) {\n $columns = static ::columns($table);\n foreach($columns as $_column) {\n if (strtolower($_column['Field']) == strtolower($column)) {\n return $_column;\n }\n }\n throw new Exception(\"No Column Found\");\n }", "public static function getWeight($column){\n $units = array();\n try{\n \t\n \t$units = UserWeightUnitsOptions::pluck($column, 'id')->toArray();\n\n \tif(isset($units) && count($units) > 0 ){\n\t return $units;\n\t }\n }catch(\\Exception $e){\n \tLog::error($e->getMessage());\n \treturn $units = [];\n }\n\n return $units = [];\n }", "function getValue($table_name, $key_column_name, $key_value, $column_name)\n {\n\n }", "protected function getValue( $sql, $column, $name = 'db' )\n\t{\n\t\t$result = $this->getConnection( $name )->create( $sql )->execute();\n\n\t\tif( ( $row = $result->fetch() ) === false ) {\n\t\t\tthrow new \\Aimeos\\MW\\Setup\\Exception( sprintf( 'No rows found: %1$s', $sql ) );\n\t\t}\n\n\t\tif( array_key_exists( $column, $row ) === false ) {\n\t\t\tthrow new \\Aimeos\\MW\\Setup\\Exception( sprintf( 'No column \"%1$s\" found: %2$s', $column, $sql ) );\n\t\t}\n\n\t\t$result->finish();\n\n\t\treturn $row[$column];\n\t}", "function get_col($query=null,$x=0, $use_prepare=false)\n\t\t{\n\n\t\t\t$new_array = array();\n\n\t\t\t// If there is a query then perform it if not then use cached results..\n\t\t\tif ( $query )\n\t\t\t{\n\t\t\t\t$this->query($query, $use_prepare);\n\t\t\t}\n\n\t\t\t// Extract the column values\n\t\t\t$j = count($this->last_result);\n\t\t\tfor ( $i=0; $i < $j; $i++ )\n\t\t\t{\n\t\t\t\t$new_array[$i] = $this->get_var(null,$x,$i);\n\t\t\t}\n\n\t\t\treturn $new_array;\n\t\t}", "function one_col_value($conn,$col_name,$table_name,$user_id,$return_col)\r\n\t{\r\n\t\t$qry=\"select * from $table_name where $col_name='$user_id'\";\r\n\t\t//echo $qry;\r\n\t\t$res=mysql_query($qry);\r\n\t\tif($res){\r\n\t\t\t $result=mysql_fetch_array($res);\r\n\t\t\t return $result[$return_col];\r\n\t\t}\r\n\t\telse\r\n\t\t\treturn \"0\";\r\n\t\r\n\t}", "public function getJobsValuesByColumnName($columnName) {\n\t\treturn $this->getParamountProjectJob()->getValueByColumnName($columnName);\n\t}", "public static function queryCol($sql)\n\t{\n\t\t$tempResults = self::$link->query($sql);\n\t\t\n\t\tif(!$tempResults)\n\t\t{\n\t\t\tself::handleError($sql);\n //TODO should probably return here\n\t\t}\n\t\t\n\t\t$column = array();\n\t\t\n\t\twhile(!is_null($row = $tempResults->fetch_row()))\n\t\t{\n\t\t\t$column[] = $row[0];\n\t\t}\n\t\t\n\t\t$tempResults->close();\n\t\t\n\t\t//return $tempResults->fetchCol();\n\t\treturn $column;\n\t}", "public function value($column)\n {\n $result = (array) $this->first([$column => 1]);\n\n return count($result) > 0 ? $result[$column] : null;\n }", "function getValue($column1,$table,$column2,$id)\n{\n\t\t$str9=\"select \".$column1.\" from \".$table.\" where \".$column2.\"=\".$id;\n\t\t$result9=mysql_query($str9) or die(mysql_error());\n\t\t$row9=mysql_fetch_array($result9);\n\t\t$t=$row9[$column1]; \n\t\tmysql_free_result($result9);\n\t\treturn $t;\n\t\t//return $str9;\n}", "function get_column_type ($table_name, $column_name) { \n\n\t$column_row_arr = NULL;\n\t\n\t// Get the array of meta data for the table\n\tlist($errArr, $columns_arr) = show_columns($table_name);\n if ( count($columns_arr) > 0) {\n \t// Loop through metadata\n \tforeach ($columns_arr as $columns_row)\n \t{\n \t\tif ($columns_row[DFT_FIELD] == $column_name) {\n \t\t\t$column_row_arr = $columns_row;\n \t\t\tbreak; // column name is found in meta data \n \t\t}\n \t}\n }\n\treturn $column_row_arr;\n}", "public function getColumn($column)\n {\n return $this->allColumns[$column];\n }", "public function getColumn($name)\n {\n $columnValues = array();\n foreach ($this->getRows() as $row) {\n $columnValues[] = $row->getColumn($name);\n }\n return $columnValues;\n }", "public function get_col($query=null, $x=0) {\n\n\t\t// If there is a query then perform it if not then use cached results..\n\t\tif ($query)\n\t\t\t$this->query($query);\n\n\t\t// Extract the column values\n\t\tfor ($i=0; $i < count($this->last_result); $i++)\n\t\t\t$new_array[$i] = $this->get_var(null, $x, $i);\n\n\t\treturn $new_array;\n\t}", "function selectRowByColumnValue($table_name, $column_name, $column_value)\n {\n $sql = sprintf(\n \"SELECT * FROM %s WHERE %s=\\\"%s\\\"\",\n $table_name,\n $column_name,\n SQLite3::escapeString($column_value));\n //echo $sql;\n $query_result = $this->query($sql);\n //echo count($query_result->fetchArray());\n $num_columns = $query_result->numColumns();\n // echo \"<br>num columns: \".$num_columns;\n // echo \"<br>column 0 type: \".$query_result->columnType(0);\n // echo \"<br>SQLITE3_NULL: \".SQLITE3_NULL.\"<br>\";\n return $query_result->fetchArray(SQLITE3_ASSOC);\n }", "function getValue( $colValueName, $tblName, $whereColumn, $passingId) { // selected column name, table name, for where condition, passing id for where\n\t\n\tglobal $dbc;\n $sql_get = \"SELECT $colValueName FROM $tblName WHERE $whereColumn='\".$passingId.\"'\";\n\t\n\t$getValue = $dbc;\n\t$getValue->query($sql_get);\n\t$getValue->next_record();\n\n\t$rowValue = $getValue->rowdata();\n\t$theValue = $rowValue[$colValueName];\n\n\treturn $theValue;\n\n}", "function getSpecificValue($con, $table, $column1, $column2, $value1)\n{\n $result = mysqli_query($con, \"SELECT $column2 \"\n . \"FROM $table \"\n . \"WHERE $column1='$value1'\");\n $valueArray = mysqli_fetch_array($result);\n\n return $valueArray[0];\n}", "final public function getColumn($name, $rsq) {\n \n if (is_string($rsq)) {\n $rsq = $this->query($rsq);\n }\n \n if ($rsq) {\n $col = array ();\n while ($row = $this->getRow($rsq)) {\n $col[] = $row[$name];\n }\n return $col;\n }\n }", "function GetRowColumn($row,$column){\n\t\t\treturn @mysql_result($this->result,$row,\"$column\");\n\t\t}", "public function getColumn($query, $col = 0) {\n\t\t$return = array();\n\t\t$result = $this->query($query);\n\t\twhile ($row = $result->fetch_array()) {\n\t\t\t$return[] = $row[$col];\n\t\t}\n\t\t$result->free();\n\t\treturn $return;\n\t}", "public function __get($name)\n {\n return $this->columns_values[$name];\n }", "public function getSpecificColVal($table=null,$colName=null,$condition=null){\n $sql=\"SELECT \";\n if(!empty($colName)){\n $sql.=\" \".$colName.\" FROM \".$table.\" WHERE 1=1 \";\n if($condition != null && strlen($condition) > 0){\n $sql .= \" \".$condition.\" \";\n }\n $query=$this->db->query($sql);\n if($query->num_rows()>0){\n $result=$query->result()[0];\n $colval = $result->$colName;\n }else{\n $colval = \"\";\n }\n return $colval;\n }\n }", "private function fetchColumn($table, $column) {\n\t\t$sql = 'select ' .$column .' from ' .$table;\n\t\t$query = $this->getDB()->prepare($sql);\n\t\tif(!$query->execute()) {\n\t\t\t$info = $query->errorInfo();\n\t\t\tl($info[2]);\n\t\t\treturn false;\n\t\t}\n\t\treturn $query->fetchAll(PDO::FETCH_COLUMN);\n\t}", "public function getColumn($name)\n {\n return $this->columns[$name];\n }", "public function extractColumnName($column);", "function getValueSiso( $colValueName, $tblName, $whereColumn, $passingId) { // selected column name, table name, for where condition, passing id for where\n\t\n\tglobal $dbs;\n $sql_get = \"SELECT $colValueName FROM $tblName WHERE $whereColumn='\".$passingId.\"'\";\n\t\n\t$getValue = $dbs;\n\t$getValue->query($sql_get);\n\t$getValue->next_record();\n\n\t$rowValue = $getValue->rowdata();\n\t$theValue = $rowValue[$colValueName];\n\n\treturn $theValue;\n\n}", "public function col($columnname)\n\t{\n\t\n\treturn $this->res[$this->pos][$columnname];\n\t/*\n\t\t$type = 0;\n\t\t\n\t\t\n\t\tif($columnname == 'value')$type = 1;\t\n\t\n\t\tif($columnname == 'URI')\n\t\t{\n\t\t$add_SID = '';\n\t\tif(false)$add_SI = 'PHPSESSID=' . htmlspecialchars(session_id()) . '&';\n\t\t\n\t\tif(count($this->jump_address[$type]) > $this->pos)\n\t\treturn '?' . $add_SI . 'i=' . $this->jump_address[0][$this->pos];\n\t\telseif(count($this->jump_address[$type]) == $this->pos)\n\t\treturn '?' . $add_SI . 'i=' . $this->jump_address[$type + 2];\n\t\t}\n\t\t\n\n\t\t\n\t\tif(count($this->jump_address[$type]) > $this->pos)\n\t\t return $this->jump_address[$type][$this->pos];\n\t\telseif(count($this->jump_address[$type]) == $this->pos)\n\t\t return $this->jump_address[$type + 2];\n\t\n\t return null; */\n\t}", "public function getBy(string $column, $value)\r\n {\r\n $stmt = $this->conn->prepare(\"SELECT * FROM $this->table WHERE $column = '$value'\");\r\n return $stmt->fetchAll(PDO::FETCH_ASSOC);\r\n }", "public function fetchColumn(int $column = 0);", "public function getDataFromColumn($col)\n {\n return $this->attributes[app()->getLocale() == 'ar' ? 'ar_'.$col : $col] ?? $this->attributes[$col];\n }", "public function getColumnData($column = null)\n\t{\n\t\tif (!in_array($column, $this->productColumns)) return \"Request not a tablecolumn\";\n\t\n\t\t$results = [];\n\n\t\t$stmt = $this->pdo->prepare(\"SELECT DISTINCT $column FROM product LIMIT 10\");\n\n\t\ttry {\n\t\t\t$stmt->execute();\n\t\t\t$db_column_select = $stmt->fetchAll();\n\t\t\tforeach ($db_column_select as $k => $row) {\n\t\t\t\t$results['columnData'][] = $row[$column];\n\t\t\t}\n\t\t\treturn $results; \n\t\t} catch (PDOException $Exception) {\n\t\t\tthrow new MyDatabaseException( $Exception->getMessage(), (int)$Exception->getCode() );\n\t\t}\n\n\t}", "private function getColumn($columnName)\n {\n $columns = array_filter(\n $this->columns,\n function ($column) use ($columnName) {\n return $column->name == $columnName;\n } // end anonymous array filter function\n ); // end arrayfilter\n\n return array_shift(\n $columns\n ); // end array_shift\n }", "public static function pick($_name,$_col) {\n\t\t$_rows=F3::get($_name);\n\t\tif (!is_array($_rows)) {\n\t\t\tF3::$global['CONTEXT']=$_name;\n\t\t\ttrigger_error(self::TEXT_NotArray);\n\t\t\treturn FALSE;\n\t\t}\n\t\t$_result=array();\n\t\tforeach ($_rows as $_row)\n\t\t\t$_result[]=$_row[$_col];\n\t\treturn $_result;\n\t}", "public function fetchColumn() {\r\n\t\t$result = array();\r\n\r\n\t\twhile ($data = $this->fetch()) {\r\n\t\t\t$result[] = current($data);\r\n\t\t}\r\n\r\n\t\t$this->freeResult();\r\n\r\n\t\treturn $result;\r\n\t}", "public function column($colName = 'ID')\n {\n $result = array();\n foreach ($this->lists as $list) {\n $result = array_merge($result, $list->column($colName));\n }\n return $result;\n }", "public static function col($query = null , $x = 0) {\n $query && self::query($query);\n $new_array = array();\n // Extract the column values\n for ( $i=0; $i < count(self::$last_result); $i++ ) {\n $new_array[$i] = self::value(null, $x, $i);\n }\n return $new_array;\n }", "public function getColumn($name)\r\n {\r\n }", "public function getValues($column)\n\t{\n\t\t$arr = array();\n\t\tforeach($this as $item) {\n\t\t\tif($item->$column !== NULL) {\n\t\t\t\t$arr[(string)$item->$column] = $item->$column;\n\t\t\t}\n\t\t}\n\t\treturn array_values($arr);\n\t}", "public function findColumn(string $column);", "public static function getHips($column){\n $units = array();\n\n\t\ttry{\n \t\n \t$units = UserHipsUnitOptions::orderBy('id')->pluck($column, 'id')->toArray();\n\n \tif(isset($units) && count($units) > 0 ){\n\t return $units;\n\t }\n }catch(\\Exception $e){\n \tLog::error($e->getMessage());\n \treturn $units = [];\n }\n\n return $units = [];\n }", "public function result_column($column)\n {\n $output = array();\n\n if (is_bool($this->result))\n {\n return $output;\n }\n\n while ($row = $this->result->fetch_assoc())\n {\n $output[] = $row[$column];\n }\n\n $this->free_result();\n\n return $output;\n }", "function getByName($name) {\r\n\t\t$cond = new Criteria();\r\n\t\t$cond->add(MeasureUnitPeer::NAME, $name);\r\n\t\t$cond->setIgnoreCase(true);\r\n\t\t$alls = MeasureUnitPeer::doSelect($cond);\r\n\t\treturn $alls[0];\r\n }", "public function getData ($column) {\n\t\t$game_setting = GameSetting::where('name', $column)->firstOrFail();\n\n\t\treturn $game_setting->data;\n }", "protected function getValueFromQuery($column_name, $order_query)\r\n {\r\n if ($order_query->num_rows) {\r\n $order_row = current($order_query->rows);\r\n $value = isset($order_row[$column_name]) ? $order_row[$column_name] : null;\r\n if ($value) {\r\n $decoded_value = json_decode($value, true);\r\n if (!empty($decoded_value)) {\r\n return $decoded_value;\r\n } else {\r\n return $value;\r\n }\r\n } else if ($value == '0') {\r\n return 0;\r\n }\r\n }\r\n return null;\r\n }", "public function getProjectsValuesByColumnName($columnName) {\n\t\treturn $this->getParamountProject()->getValueByColumnName($columnName);\n\t}", "public function getColumn($name)\n {\n foreach ($this->getColumns() as $column) {\n if ($column->getName() === $name) {\n return $column;\n }\n }\n\n }", "function get($table,$col){\n $array=array();\n $conn=connectDB();\n $query=\"SELECT * FROM $table\";\n foreach ($conn->query($query)as $row){\n array_push($array,$row[$col]);\n }\n return $array;\n }", "public function column($query,$params = null)\n {\n $this->Init($query,$params);\n $Columns = $this->sQuery->fetchAll(PDO::FETCH_NUM);\n $column = null;\n foreach($Columns as $cells) {\n $column[] = $cells[0];\n }\n return $column;\n\n }", "function getValue_local( $colValueName, $tblName, $whereColumn, $passingId) { // selected column name, table name, for where condition, passing id for where\n\t\n\tglobal $db;\n if ($colValueName == 'user_last_login') {\n\t\t $sql_get = \"SELECT DATE_FORMAT($colValueName,'%d-%b-%Y %h:%i:%s %p') as colValueName FROM $tblName WHERE $whereColumn='\".$passingId.\"'\";\n\t}\n\telse {\n\t\t$sql_get = \"SELECT $colValueName as colValueName FROM $tblName WHERE $whereColumn='\".$passingId.\"'\";\n\t}\n\t\n\t$getValue = $db;\n\t$getValue->query($sql_get);\n\t$getValue->next_record();\n\n\t$rowValue = $getValue->rowdata();\n\t$theValue = $rowValue['colValueName'];\n\n\treturn $theValue;\n\n}", "public static function select_column($query)\n {\n $column = array();\n $rs = self::query($query);\n while (true)\n {\n $values = Db::fetch_row($rs);\n if ($values === false)\n break;\n array_push($column, $values[0]);\n }\n Db::free_result($rs);\n return $column;\n }", "function getColumn($arr, $x){\n\treturn array_map(function($y)use($x){ return $y[$x]; }, $arr);\n}", "public function getCol() : array\n\t{\n\t\treturn $this->fetchAllFromColumn();\n\t}", "public function getAttributeByColumn( $colname )\n {\n // Si esta con el mismo nombre, lo retorno (son la mayoria de los casos)\n if ( array_key_exists( $colname, $this->attributeTypes ) ) return $colname;\n \n // Si no esta por el nombre exacto, busco normalizando los nombres de\n // los atributos por la columna que le toca en el ORM.\n foreach ( $this->attributeTypes as $classAttr => $type )\n {\n if ( DatabaseNormalization::col($classAttr) == $colname ) return $classAttr;\n }\n \n // Si no encuentra, devuelve NULL\n return NULL;\n }", "public function findColumn(string $column)\n {\n $column = null;\n try {\n $column = $this->model->all()->pluck($column);\n } catch (PDOException $exception) {\n $this->handleException($exception);\n } finally {\n return $column;\n }\n }", "public function getColumn(): string;", "function Get($col)\n {\n return $this->row ? $this->row[$col] : NULL;\n }", "function getValue_lk( $colValueName, $tblName, $whereColumn, $passingId) { // selected column name, table name, for where condition, passing id for where\n\t\n\tglobal $dbc1;\n $sql_get = \"SELECT $colValueName FROM $tblName WHERE $whereColumn='\".$passingId.\"'\";\n\t\n\t$getValue = $dbc1;\n\t$getValue->query($sql_get);\n\t$getValue->next_record();\n\n\t$rowValue = $getValue->rowdata();\n\t$theValue = $rowValue[$colValueName];\n\n\treturn $theValue;\n\n}", "function convert_value1($var){\n\t\t//cd = column define\n\t\t//vd = value define\n\t\t//\n\n\t\tglobal $db,$f;\n\t\t$table =$var[\"table\"];\n\t\t$vd=strtolower($var[\"vd\"]);\n\t\t$cd=$var[\"cd\"];\n\t\t$cs=$var[\"cs\"];\n\n\t\t$sql = \"select $cs as x from $table where $cd ='$vd'\";\n\t\tif($var[print_query]==\"1\") echo $sql;\n\t\t$result = $db->Execute($sql);\n\t\tif (!$result) print $db->ErrorMsg();\n\t\t$row = $result->FetchRow();\n\t\t$new_value = $row[$f->fmtCase('x')];\n\t\treturn $new_value;\n\t}", "public function column($query, $params = NULL, $key = 0)\n\t{\n\t\tif($statement = $this->query($query, $params))\n\t\t\treturn $statement->fetchColumn($key);\n\t}", "abstract public function getIntervalColumnNameByIndex(int $columnIndex): string;", "public static function get_distinct_for_column($user_id, $table, $column_name)\n {\n $database = Database::instance();\n $sql = \"SELECT DISTINCT \" . $column_name . \" FROM \" . $table . \" WHERE active = 1 AND user_id = \" . $user_id . \" AND \" . $column_name . \" IS NOT NULL AND \" . $column_name . \" <> ''\" . \" ORDER BY \" . $column_name;\n $query = $database->prepare($sql);\n $query->execute();\n $result = $query->fetchAll(\\PDO::FETCH_ASSOC);\n $query->closeCursor();\n if($result === false || $result === null) {\n $http_response = HttpFailCodes::http_response_fail()->get_column_values;\n $http_response->message = \"There was a problem getting the \" . $column_name . \"s.\";\n APIService::response_fail($http_response);\n }else{\n return $result;\n }\n }", "public static function getHeight($column){\n $units = array();\n\n\t\ttry{\n \t\n \t$units = UserHeightUnitOptions::pluck($column, 'id')->toArray();\n\n \tif(isset($units) && count($units) > 0 ){\n\t return $units;\n\t }\n }catch(\\Exception $e){\n \tLog::error($e->getMessage());\n \treturn $units = [];\n }\n\n return $units = [];\n }", "public function result_cell($column)\n {\n if (is_bool($this->result))\n {\n return NULL;\n }\n\n $line = $this->result->fetch_assoc();\n\n $this->free_result();\n\n return isset($line[$column]) ? $line[$column] : NULL;\n }", "public function col($column)\n {\n $lang = config('app.locale');\n $column = \"$column\".\"_\".\"$lang\";\n return $this->$column;\n }", "public function pluck($column)\n {\n return $this->value($column);\n }", "public function getColumn( $sQuery ){\n $oQuery = $this->query( $sQuery );\n $this->checkQuery( $oQuery );\n return $oQuery->fetchColumn( );\n }", "private function getResult($name, $results) {\r\n $fields = array_column($results, \"Field\");\r\n\r\n foreach ($fields as $i => $field) {\r\n if ($field == $name) return $results[$i];\r\n }\r\n throw new ColumnNotFound(\"Column '$name' not found in table\");\r\n }", "function getUnits(){\n $sql = \"SELECT * FROM units\";\n return runQuery($sql);\n}", "function convert_value($var){\n\t\t//cd = column define\n\t\t//vd = value define\n\t\t//\n\n\t\tglobal $db,$f;\n\t\t$table =$var[\"table\"];\n\t\t$vd=strtolower($var[\"vd\"]);\n\t\t$cd=$var[\"cd\"];\n\t\t$cs=$var[\"cs\"];\n\t\t$print_query=$var[\"print_query\"];\n\n\t\t$sql = \"select $cs as x from $table where $cd ='$vd'\";\n\n\t\tif($print_query=='1') echo $sql;\n\n\t\t$result = $db->Execute($sql);\n\n\t\tif (!$result){\n\t\t\techo $sql;\n\t\t\tprint $db->ErrorMsg();\n\t\t}\n\t\t$row = $result->FetchRow();\n\t\t$new_value = $row[$f->fmtCase('x')];\n\t\treturn $new_value;\n\t}", "public function value($column)\n {\n return $this->callHook(__FUNCTION__, $this->packArgs(compact('column')));\n }", "public function column(string $sql, $params = null)\n\t{\n\t\t$columnValue = null;\n\t\t\n\t\ttry {\n\t\t\t$preparedStatement = $this->_instance->prepare($sql);\n\t\t\t$preparedStatement->execute($params);\n\t\t\t$resultSet = $preparedStatement->fetch(PDO::FETCH_ASSOC);\n\t\t\t$columnValue = $resultSet[0];\n\t\t} catch(PDOException $e) {\n\t\t\tthrow new Exception('Could not fetch a record:<br>' . $e->getMessage());\n\t\t}\n\t\t\n\t\treturn $columnValue;\n\t}", "public function fetchColumn(int $column = 0): array\n {\n $result = $this->_getResult()->fetchCol($column); // Returns an array on success and an \\PEAR_Error object on failure\n return is_array($result) ? $result : array();\n }", "public function getColumn() { return $this->column; }", "public static function getDressSize($column){\n $units = array();\n\n\t\ttry{\n \t\n \t$units = UserDressSizeOptions::whereNotNull($column)->pluck($column, 'id')->toArray();\n\n \tif(isset($units) && count($units) > 0 ){\n\t return $units;\n\t }\n }catch(\\Exception $e){\n \tLog::error($e->getMessage());\n \treturn $units = [];\n }\n\n return $units = [];\n }", "abstract public static function columnData();", "protected function getValueFromQuery($column_name, $order_query)\r\n {\r\n if ($order_query->num_rows) {\r\n $order_row = current($order_query->rows);\r\n\r\n $value = isset($order_row[$column_name]) ? $order_row[$column_name] : null;\r\n\r\n if ($value) {\r\n $decoded_value = json_decode($value, true);\r\n\r\n if (!empty($decoded_value)) {\r\n return $decoded_value;\r\n } else {\r\n return $value;\r\n }\r\n }\r\n }\r\n return null;\r\n }", "public function getColumnInfo($column)\n {\n $columnParams = explode(\".\", $column);\n return $columnParams[1];\n }", "function getValueFromField()\r\n\t{\r\n\t\treturn $this->row[ key( $this->mapping ) ];\r\n\t}", "function Get($col)\n {\n return isset($this->row) ? $this->row[$col] : null;\n }", "public static function getByColunm($colunm, $value, $flags = 0) {\n return self::getWhere([$colunm => $value], $flags);\n }", "function selectEqualTo($table_name, $column_name, $column_value)\n {\n $sql = sprintf(\n \"SELECT * FROM %s WHERE %s = \\\"%s\\\"\",\n $table_name,\n $column_name,\n $column_value);\n\n $rows = array();\n $result = $this->query($sql);\n while($row = $result->fetchArray(SQLITE3_ASSOC))\n {\n array_push($rows, $row);\n }\n return $rows;\n }", "public function get_col($query, $data = null, $format = null, $col = 0)\n {\n $data = $this->query($query, $data, $format);\n $output = array();\n foreach ($data as $row) {\n if (property_exists($row, $col)) {\n $output[] = $row->$col;\n } elseif (is_numeric($col)) {\n $vars = array_keys(get_object_vars($row));\n $varname = $vars[ $col ];\n $output[] = $row->$varname;\n }\n }\n $query->closeCursor();\n unset($query);\n return $output;\n }", "public function offsetGet($columnName)\n {\n $row = current($this->_rows);\n return $row !== false? $row[$columnName] : null;\n }" ]
[ "0.6349058", "0.63078475", "0.6266993", "0.6185814", "0.6185814", "0.6158265", "0.614574", "0.61402124", "0.61387074", "0.6121438", "0.6104407", "0.60514194", "0.6051184", "0.6027098", "0.59656876", "0.59510976", "0.59090066", "0.5906952", "0.58905596", "0.5882936", "0.58591354", "0.58491653", "0.58363926", "0.5832996", "0.58283097", "0.58280694", "0.5813654", "0.5802994", "0.579992", "0.5786865", "0.5779472", "0.57756716", "0.5761015", "0.575847", "0.5739881", "0.57390654", "0.5732644", "0.5716113", "0.56994444", "0.5696182", "0.5694834", "0.56900394", "0.5654585", "0.5653915", "0.56525403", "0.5652147", "0.5641144", "0.5618769", "0.56139517", "0.5594921", "0.558436", "0.55812293", "0.554903", "0.55185896", "0.55034", "0.5501505", "0.5499279", "0.54958075", "0.54876053", "0.5484395", "0.54805404", "0.547632", "0.54733604", "0.54693496", "0.5461678", "0.545396", "0.5452677", "0.54412484", "0.54331857", "0.54327387", "0.5426411", "0.5422326", "0.5415767", "0.5409421", "0.5401017", "0.5380207", "0.53730917", "0.5362883", "0.53593206", "0.5346577", "0.53425694", "0.53331876", "0.5328805", "0.5326466", "0.53235894", "0.5318567", "0.53111005", "0.53075397", "0.530747", "0.53067493", "0.5283289", "0.5281337", "0.5262095", "0.5259422", "0.52500325", "0.524435", "0.5243716", "0.5241876", "0.5240804", "0.52314717" ]
0.53589183
79
Set which columns are sortable
function units_sortable_columns( $columns ) { $columns['status'] = 'status'; return $columns; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function get_sortable_columns()\n {\n }", "protected function get_sortable_columns()\n {\n }", "protected function get_sortable_columns()\n {\n }", "public function get_sortable_columns() {\n return $sortable = array(\n \"col_user\"=>array(\"user_login\",false),\n \"col_groupName\"=>array(\"groupName\",false)\n );\n }", "function get_sortable_columns() {\n\n\t\treturn $sortable_columns = array(\n\t\t\t'title'\t \t=> array( 'title', false ),\t//true means it's already sorted\n\t\t\t'rating'\t=> array( 'rating', false ),\n\t\t\t'director'\t=> array( 'director', false )\n\t\t);\n\t}", "public function get_sortable_columns() {\n\n\t\treturn $sortable = array(\n\t\t\t// 'name' => array('name'),\n\t\t\t// 'user_id'=>array('user_id')\n\t\t);\n\t}", "public function get_sortable_columns()\r\n\t{\r\n\t\treturn [\r\n\t\t\t'name' => [ 'name', false ]\r\n\t\t];\r\n\t}", "public function get_sortable_columns() {\n\treturn $sortable = array(\n\t\t'channel' => array('channel',false),\n\t\t'source' => array('source',false),\n\t\t'status' => array('status',false),\n\t\t'title' => array('title',false),\n 'pubdate' => array('pubdate',false)\n\t);\n}", "public function get_sortable_columns() {\r\n return $sortable = array(\r\n 'col_created_on'=> array('created_on', false),\r\n 'col_type'=> array('type', false),\r\n );\r\n }", "public function get_sortable_columns() {\n\t\treturn array();\n\t}", "protected function get_sortable_columns() {\n\n\t\treturn array(\n\t\t\t'subject' => array( 'subject', false ),\n\t\t\t'date_sent' => array( 'date_sent', false ),\n\t\t);\n\t}", "public function get_sortable_columns()\n {\n return array('name' => array('name', false));\n }", "public function set_custom_columns_sortable ( $columns )\n {\n $columns['name'] = 'name';\n $columns['approved'] = 'approved';\n $columns['featured'] = 'featured';\n return ( $columns );\n }", "function set_custom_contact_sortable_columns( $columns ) {\n $columns['title'] = 'title';\n $columns['email'] = 'email';\n $columns['company'] = 'company';\n\n return $columns;\n}", "function get_sortable_columns() {\n $sortable_columns = array(\n 'name' => array('name',false), //true means it's already sorted\n 'job' => array('job',false),\n\t\t\t'linkedin' => array('linkedin',false),\n 'facebook' => array('facebook',false)\n );\n return $sortable_columns;\n }", "public function get_sortable_columns() {\n\t\treturn [\n\t\t\t'uri' => [ 'uri', false ],\n\t\t\t'times_accessed' => [ 'times_accessed', false ],\n\t\t\t'accessed' => [ 'accessed', false ],\n\t\t];\n\t}", "function get_sortable_columns( ) {\r\n\t\treturn apply_filters( 'mla_list_table_get_sortable_columns', self::$default_sortable_columns );\r\n\t}", "static function get_sortable_columns(): array {\r\n return [\r\n 'title' => 'Title',\r\n self::qcol('date_till') => self::qcol('date_till')];\r\n }", "public function get_sortable_columns() {\n\t\treturn array(\n\t\t\t'category' => 'category',\n\t\t\t'due' => 'due',\n\t\t\t'status' => 'status',\n\t\t\t'method' => 'method',\n\t\t);\n\t}", "public function get_sortable_columns()\r\n {\r\n return array(\r\n 'name' => array('name', false),\r\n 'sku' => array('sku', false),\r\n 'price' => array('price', false),\r\n 'date' => array('date', false)\r\n );\r\n }", "public function get_sortable_columns()\n {\n return array(\n 'ID' => array('ID', true),\n 'Orderno' => array('Orderno', true),\n 'Mtid' => array('Mtid', true),\n 'Userid' => array('Userid', true),\n 'UserName' => array('UserName', true)\n );\n }", "public function get_sortable_columns() {\n\t\treturn [\n\t\t\t'product' => ['product', false],\n\t\t\t'quantity' => ['quantity', false],\n\t\t\t'price' => ['price', false],\n\t\t\t'total' => ['total', false]\n\t\t];\n\t}", "function get_sortable_columns()\n {\n $sortable_columns = array(\n// 'id' => array('id',false), //true means it's already sorted\n// 'type' => array('type', false),\n// 'name' => array('name', false),\n 'tag' => array('tag', false),\n 'kind' => array('kind', false),\n );\n return $sortable_columns;\n }", "function allowColumnReorder($val){\n\t\t$this->headerSortable=$val;\n\t}", "public function get_sortable_columns()\n\t{\n\t\treturn array(\n\t\t\t'timestamp' => array( 'timestamp', true ),\n\t\t);\n\t}", "function get_sortable_columns() {\n $sortable_columns = array(\n 'title' => array('title',false), //true means it's already sorted\n 'contact_name' => array('contact_name',false),\n 'date_created' => array('date_created',false)\n );\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\t\t\n\t\t$sortable_columns = array();\n\t\t\n\t\treturn apply_filters('bdpp_style_sortable_columns', $sortable_columns);\n\t}", "function get_sortable_columns() {\n $sortable_columns = array(\n 'date_published' \t=> array('date_published',false), //true means its already sorted\n 'listing_title' => array('listing_title',false),\n 'quantity' => array('quantity',false),\n 'price' => array('price',false),\n 'status' => array('status',false)\n );\n return $sortable_columns;\n }", "function js_custom_project_admin_sortable_columns( $columns ) {\n\t$columns['project_post_id'] = 'ID';\n\treturn $columns;\n}", "public function get_sortable_columns() {\n\n\t\t// Build our array of sortable columns.\n\t\t$setup = array(\n\t\t\t'review_title' => array( 'review_title', false ),\n\t\t\t'review_product' => array( 'review_product', false ),\n\t\t\t'review_date' => array( 'review_date', true ),\n\t\t\t'review_score' => array( 'review_score', true ),\n\t\t\t'review_status' => array( 'review_status', true ),\n\t\t);\n\n\t\t// Return it, filtered.\n\t\treturn apply_filters( Core\\HOOK_PREFIX . 'review_table_sortable_columns', $setup );\n\t}", "public function get_sortable_columns() {\n return $sortable = array(\n 'template_id' => array( 'template_id', true ),\n 'template_name' => array( 'template_name', true ),\n 'create_date' => array( 'create_date', true )\n );\n }", "function payments_table_gateway_column_sortable( $columns ){\r\n //$columns['status'] = array('status', false);\r\n return $columns;\r\n}", "function get_sortable_columns()\n {\n $sortable_columns = array(\n \n 'timestamp' => array('timestamp', true),\n );\n\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'id' => array( 'id', false ),\n\t\t\t'date' => array( 'date', false ),\n\t\t\t'uploader' => array( 'uploader', false ),\n\t\t\t'uploader_group' => array( 'uploader_group', false ),\n\t\t\t'site' => array( 'site', false ),\n\t\t\t'assessment' => array( 'assessment', false ),\n\t\t);\n\t\treturn $sortable_columns;\n\t}", "protected function sortableColumns(): array\n {\n return [];\n }", "protected function get_sortable_columns() {\n\t\t$c = array(\n\t\t\t'username' => 'login',\n\t\t\t'email' => 'email',\n\t\t);\n\n\t\treturn $c;\n\t}", "function get_sortable_columns()\n {\n $sortable_columns = array(\n 'date_added' => array('date_added', false),\n// 'wp_username' => array('wp_username', false),\n// 'redirect_id' => array('redirect_id', false),\n// 'redirect_destination' => array('redirect_destination', false),\n );\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'id' => array('id', false),\n\t\t\t'company' => array('company', false),\n\t\t\t'transaction_id' => array('transaction_id', false),\n\t\t\t'email' => array('email', false),\n\t\t\t'expiration' => array('expiration', false),\n\t\t\t'accesstourlkey' => array('accesstourlkey', false),\n\t\t\t'webinarpass' => array('webinarpass', false),\n\t\t\t'total' => array('total', false)\n\t\t);\n\t\treturn $sortable_columns;\n\t}", "public function get_sortable_columns() {\r\n\t\t$sortable_columns = array(\r\n\t\t\t'name' => array( 'name', true ),\r\n\t\t\t'city' => array( 'city', false )\r\n\t\t);\r\n\r\n\t\treturn $sortable_columns;\r\n\t}", "public function admin_column_sortable( $sortable_columns ) {\n\t\t$sortable_columns[ 'location' ] = 'location';\n\t\treturn $sortable_columns;\n\t}", "public function loadSortColumns()\n {\n add_filter( 'request', array( $this, 'sortColumns' ) );\n }", "public static function manage_sortable_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['expiration'] = 'expiration';\n $columns['registrar'] = 'registrar';\n return $columns;\n }", "public function get_sortable_columns() {\n\n\t\t\t$sortable_columns = array(\n\n\t\t\t\t'topic_name' => array( 'topic_name', true )\n\n\t\t\t);\n\n\n\n\t\t\treturn $sortable_columns;\n\n\t\t}", "public function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t);\n\n\t\treturn $sortable_columns;\n\t}", "public function get_sortable_columns()\n {\n $sortable_columns = array();\n\n return $sortable_columns;\n }", "public function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'transaction_id' \t=> array( 'transaction_id', true ),\n\t\t\t'trade_date' \t\t=> array( 'trade_date', true ),\n\t\t\t'settlement_date' \t=> array( 'settlement_date', true ),\n\t\t\t'transaction_type' \t=> array( 'transaction_type', true ),\n\t\t\t'equity' \t\t\t=> array( 'equity', true ),\n\t\t\t'ticker_symbol' \t=> array( 'ticker_symbol', true ),\n\t\t\t'num_of_shares' \t=> array( 'num_of_shares', true ),\n\t\t\t'price' \t\t\t=> array( 'price', true ),\n\t\t\t'transaction_fees' \t=> array( 'transaction_fees', true ),\n\t\t\t'currency' \t\t\t=> array( 'currency', true ),\n\t\t\t'user_id' \t\t\t=> array( 'user_id', true ),\n\t\t\t'stock_id' \t\t\t=> array( 'stock_id', true ),\n\t\t\t'platform' \t\t\t=> array( 'platform', true ),\n\t\t\t'broker' \t\t\t=> array( 'broker', true ),\n\t\t\t'account_id' \t\t=> array( 'account_id', true ),\n\t\t\t'notes' \t\t\t=> array( 'notes', true ),\n\t\t\t//'exchange_name' => array( 'exchange_name', false )\n\t\t);\n\n\t\treturn $sortable_columns;\n\t}", "public function add_sortable( $columns ) {\n\t\t$columns[ 'wp_capabilities' ] = 'wp-custom-role';\n\t\t$columns[ 'blogname' ] = 'wp-custom-blog-name';\n\t\t$columns[ 'primary_blog' ] = 'primary_blog';\n\n\t\treturn $columns;\n\t}", "public function register_sortable_columns( $columns ) {\n $columns['username'] = 'username';\n return $columns;\n }", "protected function getSortableColumns()\n {\n if ($this->sortableColumns !== null) {\n return $this->sortableColumns;\n }\n\n $columns = $this->getColumns();\n $sortable = array_filter($columns, function ($column) {\n return $column->sortable;\n });\n\n return $this->sortableColumns = $sortable;\n }", "public function setSortable(bool $sortable=true): self;", "public function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'name' => array( 'name', true ),\n\t\t\t'jumlahsts' => array( 'jumlahsts', true ),\n\t\t\t'expired' => array( 'expired', true ),\n\t\t\t'status' => array( 'status', false )\n\t\t);\n\n\t\treturn $sortable_columns;\n\t}", "protected function get_sortable_columns() {\n\t\t/*\n\t\t * The initial sorting is by 'Requested' (post_date) and descending.\n\t\t * With initial sorting, the first click on 'Requested' should be ascending.\n\t\t * With 'Requester' sorting active, the next click on 'Requested' should be descending.\n\t\t */\n\t\t$desc_first = isset( $_GET['orderby'] );\n\n\t\treturn array(\n\t\t\t'email' => 'requester',\n\t\t\t'created_timestamp' => array( 'requested', $desc_first ),\n\t\t);\n\t}", "public function sortable($sortable_columns)\n {\n $sortable_columns[ $this->slug ] = $this->sortable;\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\n\t\t$sortable_columns = array(\n \t\t\t\t\t\t\t\t'code'\t\t\t=>\tarray( 'code', true ),\n\t\t\t\t\t\t //'product_title'\t=>\tarray( 'product_title', true ),\t\t\t\t\t\t \n\t\t\t\t\t\t 'order_date'\t=>\tarray( 'order_date', true ),\n\t\t\t\t\t\t 'order_id'\t\t=>\tarray( 'order_id', true ),\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t);\n\t\treturn apply_filters( 'woo_vou_used_add_sortable_column', $sortable_columns );\n\t}", "public function getSortColumn();", "public function get_default_sortables() {\n\t\t$columns = array(\n\t\t\t'author',\n\t\t\t'response',\n\t\t\t'date'\n\t\t);\n\t\treturn $columns;\n\t}", "function dhali_sort_order_column( $columns ) {\n\n\t$columns['sort_order_column'] = __( 'Sort Order', 'dhali' );\n\treturn $columns;\n\n}", "function sl_shortlink_sortable_columns( $columns ) {\n\t$columns['hits'] = 'shortlink_hits';\n\treturn $columns;\n}", "public function setSortableColumns($columns)\n {\n if (!empty($this->columns()->sortable)) {\n $columns = array_merge($columns, $this->columns()->sortable);\n }\n\n return $columns;\n }", "function TS_VCSC_Testimonials_Sort_CustomColumns($columns) {\r\n\t\t$columns['ids'] = 'ids'; \r\n\t\treturn $columns;\r\n\t}", "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 define_sortable_columns( $columns ) {\n\t\t$custom = array(\n\t\t\t'price' => 'price',\n\t\t\t'sku' => 'sku',\n\t\t\t'name' => 'title',\n\t\t);\n\t\treturn wp_parse_args( $custom, $columns );\n\t}", "public function getIsSortable()\n {\n return false;\n }", "function reOrderColumnHeaders() {\n\n }", "public function sortable_columns( $sortable_columns = array() ) {\n\t\t\t// No sortable columns if downloading talks\n\t\t\tif ( ! empty( $this->downloading_csv ) ) {\n\t\t\t\treturn array();\n\t\t\t}\n\n\t\t\t$sortable_columns['rates'] = array( 'rates_count', true );\n\n\t\t\treturn $sortable_columns;\n\t\t}", "public function getDefaultOrderByColumns();", "function SetSortable($bolSortable)\n\t{\n\t\t$this->_bolSortable = $bolSortable;\n\t}", "public function get_sortable_columns() {\n\n\t\t\t$columns = [];\n\n\t\t\t// Get column names from result set.\n\t\t\tif ( $this->items ) {\n\t\t\t\tforeach ( $this->items[0] as $key => $value ) {\n\n\t\t\t\t\t$columns[ $key ] = [ $key, false ];\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $columns;\n\n\t\t}", "public function getDefaultSortColumns()\n\t{ return MyRecord::getDefaultSortColumns(); }", "public function sortSortableColumns($query)\n {\n // don't modify the query if we're not in the post type admin\n if (!is_admin() || !in_array($this->name, $query->query_vars['taxonomy'])) {\n return;\n }\n\n // check the orderby is a custom ordering\n if (isset($_GET['orderby']) && array_key_exists($_GET['orderby'], $this->columns()->sortable)) {\n // get the custom sorting options\n $meta = $this->columns()->sortable[$_GET['orderby']];\n\n // check ordering is not numeric\n if (is_string($meta)) {\n $meta_key = $meta;\n $orderby = 'meta_value';\n } else {\n $meta_key = $meta[0];\n $orderby = 'meta_value_num';\n }\n\n // set the sort order\n $query->query_vars['orderby'] = $orderby;\n $query->query_vars['meta_key'] = $meta_key;\n }\n }", "function adleex_resource_list_column_sort($cols) {\nglobal $current_screen;\n\t\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\t$order = array(\n 'post_title' => true, );\n\tforeach($order\tas $k => $v) $cols[$k]=true;\n\treturn $cols;\n}", "public static function sortables()\n {\n return ['plot_ref', 'plot_active', 'plot_percent_cultivated_land', 'plot_real_area', 'plot_start_date'];\n }", "public function sortableColumns( $columns )\n {\n foreach($this->fields_list as $field => $label):\n $columns[$field] = $field;\n endforeach; \n \n return $columns;\n }", "public function prepareSortableFields()\n {\n if (!$this->getAvailableOrders()) {\n $this->setAvailableOrders($this->_getConfig()->getAttributeUsedForSortByArray());\n }\n $cedAvailableOrders = $this->getAvailableOrders();\n if (!$this->getSortBy()) {\n if ($defaultSortBy = $this->_getConfig()->getDefaultSortBy()) {\n if (isset($cedAvailableOrders[$defaultSortBy])) {\n $this->setSortBy($defaultSortBy);\n }\n }\n }\n return $this;\n }", "public function wp_nav_menu_manage_columns()\n {\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 getSortable()\n {\n return $this->sortable;\n }", "public function setSorting($arrSorting);", "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 }", "public function sortable()\n {\n $this->sortable = true;\n\n return $this;\n }", "function columns_none_sort($name, $column, $sortedBy, $options)\n\t{\n return sprintf('<th>%s</th>', $name);\n\n\t}", "public function getRealSorting()\n {\n return $this->realSortColumns;\n }", "protected function _setSortingParameters()\n {\n $sSortingParameters = $this->getViewParameter('sorting');\n if ($sSortingParameters) {\n list($sSortBy, $sSortDir) = explode('|', $sSortingParameters);\n $this->setItemSorting($this->getSortIdent(), $sSortBy, $sSortDir);\n }\n }", "function set_sortable_configuration_files($type = null){\n set_ui_common_configuration_files('sortable', $type);\n}", "public function custom_columns_sortable( $columns ) {\n\n\t\t$new = array();\n\t\t$fields = $this->get_custom_fields();\n\n\t\tforeach ( $fields as $field ) {\n\n\t\t\t/* If CF is a regular taxonomy we don't handle it, WordPress does */\n\t\t\tif ( 'taxonomy' == $field['args']['field_type'] && true === $field['args']['taxo_std'] ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif ( true === $field['args']['show_column'] && true === $field['args']['sortable_column'] ) {\n\t\t\t\t$id = $field['name'];\n\t\t\t\t$new[ $id ] = $id;\n\t\t\t}\n\n\t\t}\n\n\t\treturn array_merge( $columns, $new );\n\n\t}", "public function sortable($meta_key=null)\n {\n $this->sortable = true;\n\n if( $meta_key )\n {\n $old_slug = $this->slug;\n $this->column[$meta_key] = $this->column[$old_slug];\n\n unset($this->column[$old_slug]);\n\n $this->slug = $meta_key;\n }\n\n return $this;\n }", "public function sortFields()\n {\n return property_exists($this, 'sortable') ? $this->sortable : [];\n }", "public static function _prepareSortable() {\n $data = [];\n $sortableGroupField = static::getSortableGroupField();\n $sortableField = static::getSortableField();\n foreach(static::all() as $row) {\n $keyParts = [];\n foreach ($sortableGroupField as $sgf) {\n $keyParts[] = $row->{$sortableGroupField};\n }\n $key = implode('_',$keyParts);\n if ($sortableGroupField) {\n $data[$key][] = $row;\n } else {\n $data[0][$row];\n }\n }\n\n foreach ($data as $group => $groupData ) {\n $i = 0;\n foreach ($groupData as $row) {\n $row->{$sortableField} = ++$i;\n $row->save();\n echo sprintf(\"row %d was orderer<br>\\n\",$row->id);\n }\n }\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}", "public function setSortColumnName($value)\n {\n $this->sortColumnName = $value;\n }", "public static function sortables()\n {\n return ['id', 'module_name'];\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}", "public function isSortable()\n {\n return $this->field()->isSortable();\n }", "public function setSort($x) { $this->sort = $x; }", "public function is_sortable() {\n\t\treturn $this->is_listable() && isset( $this->data['sortable'] ) && $this->data['sortable'];\n\t}", "public function isSortable()\n {\n return $this->sortable;\n }", "public function order_by() {\r\n\t\t$fields = func_get_args();\r\n\r\n\t\t// Loop through the columns\r\n\t\tfor ( $i = 0; $i < intval( $_GET['iSortingCols'] ); $i++ ) {\r\n\t\t\t// Add the necessary comman\r\n\t\t\tif ( !empty( $this->order_by ) )\r\n\t\t\t\t$this->order_by .= ',';\r\n\t\t\t\r\n\t\t\t// Compile the fields\r\n\t\t\t$this->order_by .= $fields[$_GET['iSortCol_' . $i]] . ' ' . $_GET['sSortDir_' . $i];\r\n\t\t}\r\n\t\t\r\n\t\t// If it's not empty\r\n\t\tif ( !empty( $this->order_by ) )\r\n\t\t\t$this->order_by = ' ORDER BY ' . $this->order_by;\r\n\t}", "public function isSortable(): bool\n {\n return $this->isSortable;\n }" ]
[ "0.79582405", "0.7956727", "0.7956727", "0.76875633", "0.7513037", "0.73985726", "0.73508537", "0.734248", "0.7326062", "0.72987777", "0.72878045", "0.7244389", "0.7171175", "0.7156837", "0.7132634", "0.71187747", "0.7086453", "0.7083559", "0.7071704", "0.7071299", "0.70558846", "0.7050988", "0.70449543", "0.7031352", "0.7010033", "0.7001889", "0.6971507", "0.69489247", "0.68824315", "0.68697083", "0.685257", "0.6849183", "0.6843805", "0.6833214", "0.67697644", "0.676698", "0.6720786", "0.6702011", "0.6686371", "0.6608937", "0.66023785", "0.65913373", "0.6568738", "0.655087", "0.6518604", "0.6517626", "0.65074134", "0.64980936", "0.64921117", "0.648212", "0.6468224", "0.6460516", "0.64083123", "0.64054173", "0.63973093", "0.63805795", "0.6330067", "0.6328331", "0.6294139", "0.6270238", "0.623514", "0.6212398", "0.6206882", "0.61877346", "0.61535496", "0.6067442", "0.6028327", "0.5978849", "0.5958837", "0.5950899", "0.5947591", "0.5947429", "0.59425855", "0.5941534", "0.5934003", "0.59224755", "0.5918414", "0.5914834", "0.5902761", "0.5891582", "0.58286405", "0.57993877", "0.5764549", "0.57607627", "0.576061", "0.5734844", "0.5729957", "0.5717218", "0.5708652", "0.57078224", "0.5682929", "0.5682186", "0.5682186", "0.5682186", "0.56777346", "0.56742036", "0.5669483", "0.56669635", "0.5666897", "0.56512165" ]
0.672489
36
Set which columns are sortable
function sort_units( $vars ) { if ( isset( $vars['post_type'] ) && 'units' == $vars['post_type'] ) { if ( isset( $vars['orderby'] ) && 'status' == $vars['orderby'] ) { $vars = array_merge( $vars, array( 'meta_key' => 'status', 'orderby' => 'meta_value' ) ); } } return $vars; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function get_sortable_columns()\n {\n }", "protected function get_sortable_columns()\n {\n }", "protected function get_sortable_columns()\n {\n }", "public function get_sortable_columns() {\n return $sortable = array(\n \"col_user\"=>array(\"user_login\",false),\n \"col_groupName\"=>array(\"groupName\",false)\n );\n }", "function get_sortable_columns() {\n\n\t\treturn $sortable_columns = array(\n\t\t\t'title'\t \t=> array( 'title', false ),\t//true means it's already sorted\n\t\t\t'rating'\t=> array( 'rating', false ),\n\t\t\t'director'\t=> array( 'director', false )\n\t\t);\n\t}", "public function get_sortable_columns() {\n\n\t\treturn $sortable = array(\n\t\t\t// 'name' => array('name'),\n\t\t\t// 'user_id'=>array('user_id')\n\t\t);\n\t}", "public function get_sortable_columns()\r\n\t{\r\n\t\treturn [\r\n\t\t\t'name' => [ 'name', false ]\r\n\t\t];\r\n\t}", "public function get_sortable_columns() {\n\treturn $sortable = array(\n\t\t'channel' => array('channel',false),\n\t\t'source' => array('source',false),\n\t\t'status' => array('status',false),\n\t\t'title' => array('title',false),\n 'pubdate' => array('pubdate',false)\n\t);\n}", "public function get_sortable_columns() {\r\n return $sortable = array(\r\n 'col_created_on'=> array('created_on', false),\r\n 'col_type'=> array('type', false),\r\n );\r\n }", "public function get_sortable_columns() {\n\t\treturn array();\n\t}", "protected function get_sortable_columns() {\n\n\t\treturn array(\n\t\t\t'subject' => array( 'subject', false ),\n\t\t\t'date_sent' => array( 'date_sent', false ),\n\t\t);\n\t}", "public function get_sortable_columns()\n {\n return array('name' => array('name', false));\n }", "public function set_custom_columns_sortable ( $columns )\n {\n $columns['name'] = 'name';\n $columns['approved'] = 'approved';\n $columns['featured'] = 'featured';\n return ( $columns );\n }", "function set_custom_contact_sortable_columns( $columns ) {\n $columns['title'] = 'title';\n $columns['email'] = 'email';\n $columns['company'] = 'company';\n\n return $columns;\n}", "function get_sortable_columns() {\n $sortable_columns = array(\n 'name' => array('name',false), //true means it's already sorted\n 'job' => array('job',false),\n\t\t\t'linkedin' => array('linkedin',false),\n 'facebook' => array('facebook',false)\n );\n return $sortable_columns;\n }", "public function get_sortable_columns() {\n\t\treturn [\n\t\t\t'uri' => [ 'uri', false ],\n\t\t\t'times_accessed' => [ 'times_accessed', false ],\n\t\t\t'accessed' => [ 'accessed', false ],\n\t\t];\n\t}", "function get_sortable_columns( ) {\r\n\t\treturn apply_filters( 'mla_list_table_get_sortable_columns', self::$default_sortable_columns );\r\n\t}", "static function get_sortable_columns(): array {\r\n return [\r\n 'title' => 'Title',\r\n self::qcol('date_till') => self::qcol('date_till')];\r\n }", "public function get_sortable_columns() {\n\t\treturn array(\n\t\t\t'category' => 'category',\n\t\t\t'due' => 'due',\n\t\t\t'status' => 'status',\n\t\t\t'method' => 'method',\n\t\t);\n\t}", "public function get_sortable_columns()\r\n {\r\n return array(\r\n 'name' => array('name', false),\r\n 'sku' => array('sku', false),\r\n 'price' => array('price', false),\r\n 'date' => array('date', false)\r\n );\r\n }", "public function get_sortable_columns()\n {\n return array(\n 'ID' => array('ID', true),\n 'Orderno' => array('Orderno', true),\n 'Mtid' => array('Mtid', true),\n 'Userid' => array('Userid', true),\n 'UserName' => array('UserName', true)\n );\n }", "public function get_sortable_columns() {\n\t\treturn [\n\t\t\t'product' => ['product', false],\n\t\t\t'quantity' => ['quantity', false],\n\t\t\t'price' => ['price', false],\n\t\t\t'total' => ['total', false]\n\t\t];\n\t}", "function get_sortable_columns()\n {\n $sortable_columns = array(\n// 'id' => array('id',false), //true means it's already sorted\n// 'type' => array('type', false),\n// 'name' => array('name', false),\n 'tag' => array('tag', false),\n 'kind' => array('kind', false),\n );\n return $sortable_columns;\n }", "function allowColumnReorder($val){\n\t\t$this->headerSortable=$val;\n\t}", "public function get_sortable_columns()\n\t{\n\t\treturn array(\n\t\t\t'timestamp' => array( 'timestamp', true ),\n\t\t);\n\t}", "function get_sortable_columns() {\n $sortable_columns = array(\n 'title' => array('title',false), //true means it's already sorted\n 'contact_name' => array('contact_name',false),\n 'date_created' => array('date_created',false)\n );\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\t\t\n\t\t$sortable_columns = array();\n\t\t\n\t\treturn apply_filters('bdpp_style_sortable_columns', $sortable_columns);\n\t}", "function get_sortable_columns() {\n $sortable_columns = array(\n 'date_published' \t=> array('date_published',false), //true means its already sorted\n 'listing_title' => array('listing_title',false),\n 'quantity' => array('quantity',false),\n 'price' => array('price',false),\n 'status' => array('status',false)\n );\n return $sortable_columns;\n }", "function js_custom_project_admin_sortable_columns( $columns ) {\n\t$columns['project_post_id'] = 'ID';\n\treturn $columns;\n}", "public function get_sortable_columns() {\n\n\t\t// Build our array of sortable columns.\n\t\t$setup = array(\n\t\t\t'review_title' => array( 'review_title', false ),\n\t\t\t'review_product' => array( 'review_product', false ),\n\t\t\t'review_date' => array( 'review_date', true ),\n\t\t\t'review_score' => array( 'review_score', true ),\n\t\t\t'review_status' => array( 'review_status', true ),\n\t\t);\n\n\t\t// Return it, filtered.\n\t\treturn apply_filters( Core\\HOOK_PREFIX . 'review_table_sortable_columns', $setup );\n\t}", "public function get_sortable_columns() {\n return $sortable = array(\n 'template_id' => array( 'template_id', true ),\n 'template_name' => array( 'template_name', true ),\n 'create_date' => array( 'create_date', true )\n );\n }", "function payments_table_gateway_column_sortable( $columns ){\r\n //$columns['status'] = array('status', false);\r\n return $columns;\r\n}", "function get_sortable_columns()\n {\n $sortable_columns = array(\n \n 'timestamp' => array('timestamp', true),\n );\n\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'id' => array( 'id', false ),\n\t\t\t'date' => array( 'date', false ),\n\t\t\t'uploader' => array( 'uploader', false ),\n\t\t\t'uploader_group' => array( 'uploader_group', false ),\n\t\t\t'site' => array( 'site', false ),\n\t\t\t'assessment' => array( 'assessment', false ),\n\t\t);\n\t\treturn $sortable_columns;\n\t}", "protected function sortableColumns(): array\n {\n return [];\n }", "protected function get_sortable_columns() {\n\t\t$c = array(\n\t\t\t'username' => 'login',\n\t\t\t'email' => 'email',\n\t\t);\n\n\t\treturn $c;\n\t}", "function units_sortable_columns( $columns ) {\n\n\t\t$columns['status'] = 'status';\n\n\t\treturn $columns;\n\t}", "function get_sortable_columns()\n {\n $sortable_columns = array(\n 'date_added' => array('date_added', false),\n// 'wp_username' => array('wp_username', false),\n// 'redirect_id' => array('redirect_id', false),\n// 'redirect_destination' => array('redirect_destination', false),\n );\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'id' => array('id', false),\n\t\t\t'company' => array('company', false),\n\t\t\t'transaction_id' => array('transaction_id', false),\n\t\t\t'email' => array('email', false),\n\t\t\t'expiration' => array('expiration', false),\n\t\t\t'accesstourlkey' => array('accesstourlkey', false),\n\t\t\t'webinarpass' => array('webinarpass', false),\n\t\t\t'total' => array('total', false)\n\t\t);\n\t\treturn $sortable_columns;\n\t}", "public function get_sortable_columns() {\r\n\t\t$sortable_columns = array(\r\n\t\t\t'name' => array( 'name', true ),\r\n\t\t\t'city' => array( 'city', false )\r\n\t\t);\r\n\r\n\t\treturn $sortable_columns;\r\n\t}", "public function admin_column_sortable( $sortable_columns ) {\n\t\t$sortable_columns[ 'location' ] = 'location';\n\t\treturn $sortable_columns;\n\t}", "public function loadSortColumns()\n {\n add_filter( 'request', array( $this, 'sortColumns' ) );\n }", "public static function manage_sortable_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['expiration'] = 'expiration';\n $columns['registrar'] = 'registrar';\n return $columns;\n }", "public function get_sortable_columns() {\n\n\t\t\t$sortable_columns = array(\n\n\t\t\t\t'topic_name' => array( 'topic_name', true )\n\n\t\t\t);\n\n\n\n\t\t\treturn $sortable_columns;\n\n\t\t}", "public function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t);\n\n\t\treturn $sortable_columns;\n\t}", "public function get_sortable_columns()\n {\n $sortable_columns = array();\n\n return $sortable_columns;\n }", "public function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'transaction_id' \t=> array( 'transaction_id', true ),\n\t\t\t'trade_date' \t\t=> array( 'trade_date', true ),\n\t\t\t'settlement_date' \t=> array( 'settlement_date', true ),\n\t\t\t'transaction_type' \t=> array( 'transaction_type', true ),\n\t\t\t'equity' \t\t\t=> array( 'equity', true ),\n\t\t\t'ticker_symbol' \t=> array( 'ticker_symbol', true ),\n\t\t\t'num_of_shares' \t=> array( 'num_of_shares', true ),\n\t\t\t'price' \t\t\t=> array( 'price', true ),\n\t\t\t'transaction_fees' \t=> array( 'transaction_fees', true ),\n\t\t\t'currency' \t\t\t=> array( 'currency', true ),\n\t\t\t'user_id' \t\t\t=> array( 'user_id', true ),\n\t\t\t'stock_id' \t\t\t=> array( 'stock_id', true ),\n\t\t\t'platform' \t\t\t=> array( 'platform', true ),\n\t\t\t'broker' \t\t\t=> array( 'broker', true ),\n\t\t\t'account_id' \t\t=> array( 'account_id', true ),\n\t\t\t'notes' \t\t\t=> array( 'notes', true ),\n\t\t\t//'exchange_name' => array( 'exchange_name', false )\n\t\t);\n\n\t\treturn $sortable_columns;\n\t}", "public function add_sortable( $columns ) {\n\t\t$columns[ 'wp_capabilities' ] = 'wp-custom-role';\n\t\t$columns[ 'blogname' ] = 'wp-custom-blog-name';\n\t\t$columns[ 'primary_blog' ] = 'primary_blog';\n\n\t\treturn $columns;\n\t}", "public function register_sortable_columns( $columns ) {\n $columns['username'] = 'username';\n return $columns;\n }", "protected function getSortableColumns()\n {\n if ($this->sortableColumns !== null) {\n return $this->sortableColumns;\n }\n\n $columns = $this->getColumns();\n $sortable = array_filter($columns, function ($column) {\n return $column->sortable;\n });\n\n return $this->sortableColumns = $sortable;\n }", "public function setSortable(bool $sortable=true): self;", "public function get_sortable_columns() {\n\t\t$sortable_columns = array(\n\t\t\t'name' => array( 'name', true ),\n\t\t\t'jumlahsts' => array( 'jumlahsts', true ),\n\t\t\t'expired' => array( 'expired', true ),\n\t\t\t'status' => array( 'status', false )\n\t\t);\n\n\t\treturn $sortable_columns;\n\t}", "protected function get_sortable_columns() {\n\t\t/*\n\t\t * The initial sorting is by 'Requested' (post_date) and descending.\n\t\t * With initial sorting, the first click on 'Requested' should be ascending.\n\t\t * With 'Requester' sorting active, the next click on 'Requested' should be descending.\n\t\t */\n\t\t$desc_first = isset( $_GET['orderby'] );\n\n\t\treturn array(\n\t\t\t'email' => 'requester',\n\t\t\t'created_timestamp' => array( 'requested', $desc_first ),\n\t\t);\n\t}", "public function sortable($sortable_columns)\n {\n $sortable_columns[ $this->slug ] = $this->sortable;\n return $sortable_columns;\n }", "function get_sortable_columns() {\n\n\t\t$sortable_columns = array(\n \t\t\t\t\t\t\t\t'code'\t\t\t=>\tarray( 'code', true ),\n\t\t\t\t\t\t //'product_title'\t=>\tarray( 'product_title', true ),\t\t\t\t\t\t \n\t\t\t\t\t\t 'order_date'\t=>\tarray( 'order_date', true ),\n\t\t\t\t\t\t 'order_id'\t\t=>\tarray( 'order_id', true ),\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t);\n\t\treturn apply_filters( 'woo_vou_used_add_sortable_column', $sortable_columns );\n\t}", "public function getSortColumn();", "public function get_default_sortables() {\n\t\t$columns = array(\n\t\t\t'author',\n\t\t\t'response',\n\t\t\t'date'\n\t\t);\n\t\treturn $columns;\n\t}", "function dhali_sort_order_column( $columns ) {\n\n\t$columns['sort_order_column'] = __( 'Sort Order', 'dhali' );\n\treturn $columns;\n\n}", "function sl_shortlink_sortable_columns( $columns ) {\n\t$columns['hits'] = 'shortlink_hits';\n\treturn $columns;\n}", "public function setSortableColumns($columns)\n {\n if (!empty($this->columns()->sortable)) {\n $columns = array_merge($columns, $this->columns()->sortable);\n }\n\n return $columns;\n }", "function TS_VCSC_Testimonials_Sort_CustomColumns($columns) {\r\n\t\t$columns['ids'] = 'ids'; \r\n\t\treturn $columns;\r\n\t}", "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 define_sortable_columns( $columns ) {\n\t\t$custom = array(\n\t\t\t'price' => 'price',\n\t\t\t'sku' => 'sku',\n\t\t\t'name' => 'title',\n\t\t);\n\t\treturn wp_parse_args( $custom, $columns );\n\t}", "public function getIsSortable()\n {\n return false;\n }", "function reOrderColumnHeaders() {\n\n }", "public function sortable_columns( $sortable_columns = array() ) {\n\t\t\t// No sortable columns if downloading talks\n\t\t\tif ( ! empty( $this->downloading_csv ) ) {\n\t\t\t\treturn array();\n\t\t\t}\n\n\t\t\t$sortable_columns['rates'] = array( 'rates_count', true );\n\n\t\t\treturn $sortable_columns;\n\t\t}", "public function getDefaultOrderByColumns();", "function SetSortable($bolSortable)\n\t{\n\t\t$this->_bolSortable = $bolSortable;\n\t}", "public function get_sortable_columns() {\n\n\t\t\t$columns = [];\n\n\t\t\t// Get column names from result set.\n\t\t\tif ( $this->items ) {\n\t\t\t\tforeach ( $this->items[0] as $key => $value ) {\n\n\t\t\t\t\t$columns[ $key ] = [ $key, false ];\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\treturn $columns;\n\n\t\t}", "public function getDefaultSortColumns()\n\t{ return MyRecord::getDefaultSortColumns(); }", "public function sortSortableColumns($query)\n {\n // don't modify the query if we're not in the post type admin\n if (!is_admin() || !in_array($this->name, $query->query_vars['taxonomy'])) {\n return;\n }\n\n // check the orderby is a custom ordering\n if (isset($_GET['orderby']) && array_key_exists($_GET['orderby'], $this->columns()->sortable)) {\n // get the custom sorting options\n $meta = $this->columns()->sortable[$_GET['orderby']];\n\n // check ordering is not numeric\n if (is_string($meta)) {\n $meta_key = $meta;\n $orderby = 'meta_value';\n } else {\n $meta_key = $meta[0];\n $orderby = 'meta_value_num';\n }\n\n // set the sort order\n $query->query_vars['orderby'] = $orderby;\n $query->query_vars['meta_key'] = $meta_key;\n }\n }", "function adleex_resource_list_column_sort($cols) {\nglobal $current_screen;\n\t\n\tif ($current_screen->post_type!='resource') return $cols;\n\n\t$order = array(\n 'post_title' => true, );\n\tforeach($order\tas $k => $v) $cols[$k]=true;\n\treturn $cols;\n}", "public static function sortables()\n {\n return ['plot_ref', 'plot_active', 'plot_percent_cultivated_land', 'plot_real_area', 'plot_start_date'];\n }", "public function sortableColumns( $columns )\n {\n foreach($this->fields_list as $field => $label):\n $columns[$field] = $field;\n endforeach; \n \n return $columns;\n }", "public function prepareSortableFields()\n {\n if (!$this->getAvailableOrders()) {\n $this->setAvailableOrders($this->_getConfig()->getAttributeUsedForSortByArray());\n }\n $cedAvailableOrders = $this->getAvailableOrders();\n if (!$this->getSortBy()) {\n if ($defaultSortBy = $this->_getConfig()->getDefaultSortBy()) {\n if (isset($cedAvailableOrders[$defaultSortBy])) {\n $this->setSortBy($defaultSortBy);\n }\n }\n }\n return $this;\n }", "public function wp_nav_menu_manage_columns()\n {\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 getSortable()\n {\n return $this->sortable;\n }", "public function setSorting($arrSorting);", "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 }", "public function sortable()\n {\n $this->sortable = true;\n\n return $this;\n }", "function columns_none_sort($name, $column, $sortedBy, $options)\n\t{\n return sprintf('<th>%s</th>', $name);\n\n\t}", "public function getRealSorting()\n {\n return $this->realSortColumns;\n }", "protected function _setSortingParameters()\n {\n $sSortingParameters = $this->getViewParameter('sorting');\n if ($sSortingParameters) {\n list($sSortBy, $sSortDir) = explode('|', $sSortingParameters);\n $this->setItemSorting($this->getSortIdent(), $sSortBy, $sSortDir);\n }\n }", "function set_sortable_configuration_files($type = null){\n set_ui_common_configuration_files('sortable', $type);\n}", "public function custom_columns_sortable( $columns ) {\n\n\t\t$new = array();\n\t\t$fields = $this->get_custom_fields();\n\n\t\tforeach ( $fields as $field ) {\n\n\t\t\t/* If CF is a regular taxonomy we don't handle it, WordPress does */\n\t\t\tif ( 'taxonomy' == $field['args']['field_type'] && true === $field['args']['taxo_std'] ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tif ( true === $field['args']['show_column'] && true === $field['args']['sortable_column'] ) {\n\t\t\t\t$id = $field['name'];\n\t\t\t\t$new[ $id ] = $id;\n\t\t\t}\n\n\t\t}\n\n\t\treturn array_merge( $columns, $new );\n\n\t}", "public function sortable($meta_key=null)\n {\n $this->sortable = true;\n\n if( $meta_key )\n {\n $old_slug = $this->slug;\n $this->column[$meta_key] = $this->column[$old_slug];\n\n unset($this->column[$old_slug]);\n\n $this->slug = $meta_key;\n }\n\n return $this;\n }", "public function sortFields()\n {\n return property_exists($this, 'sortable') ? $this->sortable : [];\n }", "public static function _prepareSortable() {\n $data = [];\n $sortableGroupField = static::getSortableGroupField();\n $sortableField = static::getSortableField();\n foreach(static::all() as $row) {\n $keyParts = [];\n foreach ($sortableGroupField as $sgf) {\n $keyParts[] = $row->{$sortableGroupField};\n }\n $key = implode('_',$keyParts);\n if ($sortableGroupField) {\n $data[$key][] = $row;\n } else {\n $data[0][$row];\n }\n }\n\n foreach ($data as $group => $groupData ) {\n $i = 0;\n foreach ($groupData as $row) {\n $row->{$sortableField} = ++$i;\n $row->save();\n echo sprintf(\"row %d was orderer<br>\\n\",$row->id);\n }\n }\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}", "public function setSortColumnName($value)\n {\n $this->sortColumnName = $value;\n }", "public static function sortables()\n {\n return ['id', 'module_name'];\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}", "public function isSortable()\n {\n return $this->field()->isSortable();\n }", "public function setSort($x) { $this->sort = $x; }", "public function is_sortable() {\n\t\treturn $this->is_listable() && isset( $this->data['sortable'] ) && $this->data['sortable'];\n\t}", "public function isSortable()\n {\n return $this->sortable;\n }", "public function order_by() {\r\n\t\t$fields = func_get_args();\r\n\r\n\t\t// Loop through the columns\r\n\t\tfor ( $i = 0; $i < intval( $_GET['iSortingCols'] ); $i++ ) {\r\n\t\t\t// Add the necessary comman\r\n\t\t\tif ( !empty( $this->order_by ) )\r\n\t\t\t\t$this->order_by .= ',';\r\n\t\t\t\r\n\t\t\t// Compile the fields\r\n\t\t\t$this->order_by .= $fields[$_GET['iSortCol_' . $i]] . ' ' . $_GET['sSortDir_' . $i];\r\n\t\t}\r\n\t\t\r\n\t\t// If it's not empty\r\n\t\tif ( !empty( $this->order_by ) )\r\n\t\t\t$this->order_by = ' ORDER BY ' . $this->order_by;\r\n\t}", "public function isSortable(): bool\n {\n return $this->isSortable;\n }" ]
[ "0.79582405", "0.7956727", "0.7956727", "0.76875633", "0.7513037", "0.73985726", "0.73508537", "0.734248", "0.7326062", "0.72987777", "0.72878045", "0.7244389", "0.7171175", "0.7156837", "0.7132634", "0.71187747", "0.7086453", "0.7083559", "0.7071704", "0.7071299", "0.70558846", "0.7050988", "0.70449543", "0.7031352", "0.7010033", "0.7001889", "0.6971507", "0.69489247", "0.68824315", "0.68697083", "0.685257", "0.6849183", "0.6843805", "0.6833214", "0.67697644", "0.676698", "0.672489", "0.6720786", "0.6702011", "0.6686371", "0.6608937", "0.66023785", "0.65913373", "0.6568738", "0.655087", "0.6518604", "0.6517626", "0.65074134", "0.64980936", "0.64921117", "0.648212", "0.6468224", "0.6460516", "0.64083123", "0.64054173", "0.63973093", "0.63805795", "0.6330067", "0.6328331", "0.6294139", "0.6270238", "0.623514", "0.6212398", "0.6206882", "0.61877346", "0.61535496", "0.6067442", "0.6028327", "0.5978849", "0.5958837", "0.5950899", "0.5947591", "0.5947429", "0.59425855", "0.5941534", "0.5934003", "0.59224755", "0.5918414", "0.5914834", "0.5902761", "0.5891582", "0.58286405", "0.57993877", "0.5764549", "0.57607627", "0.576061", "0.5734844", "0.5729957", "0.5717218", "0.5708652", "0.57078224", "0.5682929", "0.5682186", "0.5682186", "0.5682186", "0.56777346", "0.56742036", "0.5669483", "0.56669635", "0.5666897", "0.56512165" ]
0.0
-1
Add meta boxes for the add/edit unit form.
function add_meta_boxes() { if( function_exists( 'add_meta_box' ) ) { add_meta_box( 'unit-info', __('Unit Information'), array( $this, '_display_unitinfo_meta'), 'units', 'normal', 'high'); add_meta_box( 'maps', __('Maps'), array( $this, '_display_maps_meta'), 'units', 'normal', 'high'); add_meta_box( 'gallery', __('Gallery'), array( $this, '_display_gallery_meta'), 'units', 'normal', 'low'); add_meta_box( 'unit-status', __('Availability'), array( $this, '_display_status_meta'), 'units', 'side', 'high'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function add_meta_boxes() {\n global $current_screen;\n\n $page_main = $this->_admin_pages['swpm'];\n\n if ($current_screen->id == $page_main && isset($_REQUEST['form'])) {\n add_meta_box('swpm_form_items_meta_box', __('Form Items', 'swpm-form-builder'), array(&$this, 'meta_box_form_items'), $page_main, 'side', 'high');\n }\n }", "public function add_meta_boxes() {\n\t\tglobal $current_screen;\n\n\t\t$page_main = $this->_admin_pages[ 'vfb-pro' ];\n\n\t\tif ( $current_screen->id == $page_main && isset( $_REQUEST['form'] ) ) {\n\t\t\tadd_meta_box( 'vfb_form_switcher', __( 'Quick Switch', 'visual-form-builder-pro' ), array( &$this, 'meta_box_switch_form' ), $page_main, 'side', 'high' );\n\t\t\tadd_meta_box( 'vfb_form_items_meta_box', __( 'Form Items', 'visual-form-builder-pro' ), array( &$this, 'meta_box_form_items' ), $page_main, 'side', 'high' );\n\t\t\tadd_meta_box( 'vfb_form_media_button_tip', __( 'Display Forms', 'visual-form-builder-pro' ), array( &$this, 'meta_box_display_forms' ), $page_main, 'side', 'low' );\n\t\t}\n\t}", "function formulize_meta_box() {\n\t\tadd_meta_box('formulize_sectionid',\n\t __('Formulize', 'formulize_textlabel'),\n\t 'formulize_inner_custom_box',\n\t 'page'\n\t\t);\n}", "public function add_meta_boxes()\n {\n /* Author Name */\n add_meta_box(\n 'testimonial_options',\n 'Testimonial Options',\n array ( $this , 'render_features_box'),\n 'testimonial',\n 'side',\n 'default'\n );\n /* Author email */\n /* approved [checkbox] */\n /* featured [checkbox] */\n }", "public function apb_add_meta_boxes() {\r\n\t}", "public function add_meta_boxes()\n \t{\n\n \t\t// Add this metabox to every selected post\n \t\tadd_meta_box( \n \t\t\tsprintf('WP_Custom_Login_Profile_%s_section', self::POST_TYPE),\n \t\t\tsprintf('%s Information', ucwords(str_replace(\"_\", \" \", self::POST_TYPE))),\n \t\t\tarray(&$this, 'add_inner_meta_boxes'),\n \t\t\tself::POST_TYPE\n \t );\t\n\n \t}", "public function add_meta_boxes()\n \t{\n \t\t// Add this metabox to every selected post\n \t\tadd_meta_box( \n \t\t\tsprintf('wp_plugin_template_%s_section', self::POST_TYPE),\n \t\t\tsprintf('%s Information', ucwords(str_replace(\"_\", \" \", self::POST_TYPE))),\n \t\t\tarray($this, 'add_inner_meta_boxes'),\n \t\t\tself::POST_TYPE\n \t );\t\t\t\t\t\n \t}", "function meta_boxes() {\n\t\tadd_meta_box( 'event-details', 'Event Details', array( $this , 'details_box' ), 'event', 'normal', 'high' );\n\t}", "function wck_settings_page_add_meta_boxes() {\r\n global $post;\r\n\t\tdo_action( 'add_meta_boxes', $this->hookname, $post );\r\n\t}", "public function add_metaboxes() {\n\t\tadd_meta_box(\n\t\t\t'pblw-requirements',\n\t\t\t__( 'Requirements', 'pblw_reqs' ),\n\t\t\tarray( $this, 'render_metabox' ),\n\t\t\t'download',\n\t\t\t'normal',\n\t\t\t'core'\n\t\t);\n\t}", "public function add_metaboxes() {\n\t\tadd_meta_box(\n\t\t\t'codes',\n\t\t\t__( 'Codes' ),\n\t\t\tarray( $this, 'render_codes_metabox' )\n\t\t);\n\n\t\tadd_meta_box(\n\t\t\t'edit-codes',\n\t\t\t__( 'Edit codes' ),\n\t\t\tarray( $this, 'render_edit_metabox' )\n\t\t);\n\t}", "public function add_meta_boxes()\n {\n\n $this->_add_bitly_meta_box();\n\n }", "public static function add_metaboxes(){}", "public function add_meta_boxes() {\n\t\tadd_meta_box(\n\t\t\t$this->plugin_slug . '-post-metabox',\n\t\t\tesc_html__( 'Review Settings', $this->plugin_slug ),\n\t\t\tarray( $this, 'review_settings_view' ),\n\t\t\t'post',\n\t\t\t'normal',\n\t\t\t'core'\n \t \t);\n\t}", "function cnew_custom_metabox_add() {\r\n add_meta_box(\r\n 'cnew_custom_metabox_workshop', \r\n __( 'Informações da Oficina', 'cnew' ), \r\n 'cnew_workshop_custom_metabox_callback', \r\n 'cnew_workshop', \r\n 'normal',\r\n 'high'\r\n );\r\n\r\n add_meta_box(\r\n 'cnew_custom_metabox_registration', \r\n __( 'Formulário de Inscrição', 'cnew' ), \r\n 'cnew_registration_custom_metabox_callback', \r\n 'cnew_registration', \r\n 'normal',\r\n 'high'\r\n );\r\n }", "public function register_meta() {\r\n\t\t\tforeach($this->customFields as $customField){\r\n\t\t\t\tadd_meta_box( 'ecf-'.$customField['name'], __( $customField['title'], 'exlist' ), $customField['callback'], $postTypes , 'advanced', 'high', $type = array($customField['name'], $customField['title'], $customField['type']) );\r\n\t\t\t}\r\n }", "public function setup_meta_box() {\n\t\t\tadd_meta_box( 'add-shortcode-section', __( 'Shortcode', IFLANG ), array( $this, 'meta_box' ), 'nav-menus', 'side', 'high' );\n\t\t}", "public function add_metabox() {\n add_meta_box(\n 'customer_info',\n __( 'Customer Info', 'textdomain' ),\n array( $this, 'render_metabox' ),\n 'customer',\n 'advanced',\n 'default'\n );\n\n }", "function add_meta_boxes()\n {\n }", "public function add_meta_boxes() {\n\t\t\t// Address\n\t\t\tadd_meta_box(\n\t\t\t\t'wpmeetup_address', \n\t\t\t\t'Adresse',\n\t\t\t\tarray( $this, 'meta_box_address' ),\n\t\t\t\t'wpmeetups', 'side', 'default'\n\t\t\t);\n\t\t\t\n\t\t\t// Location\n\t\t\tadd_meta_box(\n\t\t\t\t'wpmeetup_location', \n\t\t\t\t'Location',\n\t\t\t\tarray( $this, 'meta_box_location' ),\n\t\t\t\t'wpmeetups', 'side', 'default'\n\t\t\t);\n\t\t\t\n\t\t\t// Geodata\n\t\t\tadd_meta_box(\n\t\t\t\t'wpmeetup_geodata', \n\t\t\t\t'Geodaten',\n\t\t\t\tarray( $this, 'meta_box_geodata' ),\n\t\t\t\t'wpmeetups', 'side', 'default'\n\t\t\t);\n\t\t\t\n\t\t\t// Date\n\t\t\tadd_meta_box(\n\t\t\t\t'wpmeetup_dates', \n\t\t\t\t'Datum und Zeit der Meetups',\n\t\t\t\tarray( $this, 'meta_box_date' ),\n\t\t\t\t'wpmeetups', 'advanced', 'default'\n\t\t\t);\n\t\t\t\n\t\t\t// Gallery\n\t\t\tadd_meta_box(\n\t\t\t\t'meetup_gallery',\n\t\t\t\t'Gallerie',\n\t\t\t\tarray( $this, 'meta_box_gallery' ),\n\t\t\t\t'wpmeetups', 'advanced', 'default'\n\t\t\t);\n\t\t}", "public function addMetaFieldsToAddForm()\n\t{\n\t\t$interval = $this->getMetaFields('interval');\n\t\t$animation = $this->getMetaFields('animation');\n\n\t\t?>\n\t\t\t<div class=\"form-field\">\n\t\t\t\t<label for=\"interval\">Tijd tussen slides</label>\n\t\t\t\t<input name=\"interval\" id=\"interval\" type=\"text\" value=\"<?php echo $interval;?>\" size=\"40\">\n\t\t\t\t<p class=\"description\">De tijd tussen slides in milliseconden (1000ms = 1s).</p>\n\t\t\t</div>\n\t\t\t<div class=\"form-field\">\n\t\t\t\t<label for=\"animation\">Animatie</label>\n\t\t\t\t<select name=\"animation\" id=\"animation\">\n\t\t\t\t\t<option <?php selected($animation, 'slide'); ?> value=\"slide\">Slide</option>\n\t\t\t\t\t<option <?php selected($animation, 'fade'); ?> value=\"fade\">Fade</option>\n\t\t\t\t</select>\n\t\t\t\t<p class=\"description\">Selecteer de animatie die gebruikt wordt door de slideshow.</p>\n\t\t\t</div>\n\t\t<?php\n\t}", "public function add_meta_boxes() {\n\t\t// init tooltips here since at this time the meta-box pre-registration is done,\n\t\t// we already know the current screen and the 'condition()' has been checked\n\t\t$this->init_tooltips();\n\n\t\t// Avoid appearance own meta fields on the standard Custom Fields metabox.\n\t\tadd_filter( 'is_protected_meta', array( $this, 'is_protected_meta' ), 10, 2 );\n\t}", "public static function add_meta_box() {\n\t\tadd_meta_box( 'sponsor-meta', __( 'Sponsor Meta', self::$text_domain ), array( __CLASS__, 'do_meta_box' ), self::$post_type_name , 'normal', 'high' );\n\t}", "public function register_meta_boxes()\n {\n }", "public function registerMetaBoxes()\n\t {\n\t \t$dataMetas = self::getDataMetas();\n\n\t \tif ( !empty($dataMetas) ) {\n\t \t\tforeach ($dataMetas as $key => $meta) {\n\t \t\t\t/* CHECK IF HAS PAGES */\n\t \t\t\tif ( isset($meta[\"_pages\"]) && !empty($meta[\"_pages\"][0]) ) {\n\t \t\t\t\tself::createMetasPages($meta);\n\t \t\t\t}\n\n\t \t\t\t/* POSTS TYPES REGISTER METAS */\n\t \t\t\tif ( isset($meta[\"_posts_types\"]) && !empty($meta[\"_posts_types\"][0]) ) {\n\t \t\t\t\tself::createMetasPostTypes($meta);\n\t \t\t\t}\n\n\t \t\t\t/* CHECK IF ALL POSTS IS true */\n\t \t\t\tif ( isset($meta[\"_all_posts\"]) && $meta['_all_posts'] == 'yes' ) {\n\t \t\t\t\tself::createMetasPosts($meta);\n\t \t\t\t}\n\t \t\t}\n\t \t}\n\n\t }", "public function add_metabox() {\r\n\t\tadd_meta_box(\r\n\t\t\t'stats', // ID\r\n\t\t\t'Stats', // Title\r\n\t\t\tarray(\r\n\t\t\t\t$this,\r\n\t\t\t\t'meta_box', // Callback to method to display HTML\r\n\t\t\t),\r\n\t\t\t'spam-stats', // Post type\r\n\t\t\t'normal', // Context, choose between 'normal', 'advanced', or 'side'\r\n\t\t\t'core' // Position, choose between 'high', 'core', 'default' or 'low'\r\n\t\t);\r\n\t}", "function add_meta_box() {\t\t\n\t\t\t/* Gets available public post types. */\n\t\t\t$post_types = get_post_types( array( 'public' => true ), 'objects' );\n\t\t\t\n\t\t\t$post_types = apply_filters( 'remove_youtube_white_label_meta_box', $post_types );\n\t\t\t\n\t\t\t/* For each available post type, create a meta box on its edit page if it supports '$prefix-post-settings'. */\n\t\t\tforeach ( $post_types as $type ) {\n\t\t\t\t/* Add the meta box. */\n\t\t\t\tadd_meta_box( self::DOMAIN . \"-{$type->name}-meta-box\", __( 'YouTube Embed Shortcode Creator (does not save meta)', self::DOMAIN ), array( $this, 'meta_box' ), $type->name, 'side', 'default' );\n\t\t\t}\n\t\t}", "public function add_meta_boxes() {\n\t\tforeach ( $this->screens as $screen ) {\n\t\t\tadd_meta_box(\n\t\t\t\t'event-settings',\n\t\t\t\t__( 'Event Settings', 'lps_wp' ),\n\t\t\t\tarray( $this, 'add_meta_box_callback' ),\n\t\t\t\t$screen,\n\t\t\t\t'advanced',\n\t\t\t\t'default'\n\t\t\t);\n\t\t}\n\t}", "function _display_unitinfo_meta( $post ) {\n\t\tinclude( 'includes/metaboxes/unit-info.php' );\n\t}", "public function addMetaboxes() {}", "public function add_metabox() {\n\t\tadd_meta_box(\n\t\t\t'Word linkages',\n\t\t\t'Word linkages',\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'linkages_meta_box',\n\t\t\t),\n\t\t\t'questions',\n\t\t\t'side',\n\t\t\t'high'\n\t\t);\n\n\t\tadd_meta_box(\n\t\t\t'Answers',\n\t\t\t'Answers',\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'answers_meta_box',\n\t\t\t),\n\t\t\t'questions',\n\t\t\t'side',\n\t\t\t'high'\n\t\t);\n\t}", "public function add_the_meta_boxes() {\n\t add_meta_box(\n\t 'spat_options_metabox'\t\t\t\t\t// ID\n\t , __( 'Subpages As Tabs Options' ) \t\t// Title\n\t , array( $this, 'plugin_options_form' ) // Render Code function\n\t , $this->pagehook\t\t\t\t\t\t\t// Page hook\n\t , 'normal'\t\t\t\t\t\t\t\t// Context\n\t , 'core'\t\t\t\t\t\t\t\t// ??\n\t );\n\n\t add_meta_box(\n\t 'spat_demo_metabox'\t\t\t\t\t// ID\n\t , __( 'Preview' )\t\t\t\t\t\t\t// Title\n\t , array( $this, 'plugin_demo_page' ) \t// Render Code Function\n\t , $this->pagehook\t\t\t\t\t\t// Page hook\n\t , 'side'\t\t\t\t\t\t\t\t// Context\n\t , 'core'\t\t\t\t\t\t\t\t// ??\n\t );\n\t }", "public function add_meta_boxes() {\r\n\t\tadd_meta_box( 'zakra-page-setting', esc_html__( 'Page Settings', 'zakra' ), 'Zakra_Meta_Box_Page_Settings::render', array(\r\n\t\t\t'post',\r\n\t\t\t'page',\r\n\t\t) );\r\n\t}", "function registry_add_post_meta_boxes() {\n\n add_meta_box(\n 'registry-info', // Unique ID\n 'When did you complete the Cozmeena Shawl?', // Title\n 'registry_coz_info_meta_box', // Callback function\n 'coz_registry', // Admin page (or post type)\n 'side', // Context\n 'core' // Priority\n );\n\n global $current_user;\n if($current_user->roles[0] == 'administrator') {\n add_meta_box(\n\t\t'registry-num', // Unique ID\n\t\t'International Cozmeena Registration Number', // Title\n\t\t'registry_coz_num_meta_box', // Callback function\n\t\t'coz_registry', // Admin page (or post type)\n\t\t'normal', // Context\n\t\t'low' // Priority\n\t\t);\n }\n}", "function testimonials_meta_boxes() {\n\tadd_meta_box( 'testimonials_form', 'testimonials', 'normal', 'high' );\n}", "public function add_meta_boxes() {\n\t\t// Create the Slide Meta Boxes\n\t\tadd_meta_box( 'justart-slider-slide-settings-group', 'Slides', array( $this, 'create_slide_settings_meta_box' ), 'justart-slider', 'normal', 'default' );\n\t\tadd_filter( 'postbox_classes_justart-slider-slide-settings-group', array( $this, 'add_metabox_classes' ) );\n\t\t\n\t\t// Create the Shortcode Meta Box\n\t\tadd_meta_box( 'justart-slider-shortcode-group', 'Shortcode', array( $this, 'create_shortcode_meta_box' ), 'justart-slider', 'side', 'high' );\n\t\t\n\t\t// Create the Global Settings Meta Box\n\t\tadd_meta_box( 'justart-slider-global-settings-group', 'Global settings', array( $this, 'create_global_settings_meta_box' ), 'justart-slider', 'side', 'default' );\n\t}", "public function register_metaboxes(){\n\t\tif ($this->options('use_metabox')){\n\t\t\t$metabox = $this->metabox();\n\t\t\tadd_meta_box(\n\t\t\t\t$metabox['id'],\n\t\t\t\t$metabox['title'],\n\t\t\t\t'show_meta_boxes',\n\t\t\t\t$metabox['page'],\n\t\t\t\t$metabox['context'],\n\t\t\t\t$metabox['priority']\n\t\t\t);\n\t\t}\n\t}", "public function add_meta_boxes() {\n\t\tforeach ( $this->screens as $screen ) {\n\t\t\tadd_meta_box(\n\t\t\t\t'scheduled-course-settings',\n\t\t\t\t__( 'Scheduled Course Settings', 'Scheduled Course' ),\n\t\t\t\tarray( $this, 'add_meta_box_callback' ),\n\t\t\t\t$screen,\n\t\t\t\t'advanced',\n\t\t\t\t'default'\n\t\t\t);\n\t\t}\n\t}", "public function addCustomBox() {\n add_meta_box( \n $this->post_type . '_meta',\n __( self::getLabel($this->post_type) . ' Meta', $this->post_type . '_meta' ),\n array($this, 'innerCustomBox'),\n $this->post_type,\n $this->fields_location, \n $this->fields_priority\n ); \n }", "public function meta_box_form_items() {\n include_once (SWPM_FORM_BUILDER_PATH . 'views/button_palette_metabox.php');\n }", "public function add_meta() {\n\n\t\tglobal $woocommerce, $post;\n\t\t// Text Field\n\t\twoocommerce_wp_text_input(\n\t\t\tarray(\n\t\t\t\t'id' => 'author',\n\t\t\t\t'label' => __( 'Author(s)', 'woocommerce' ),\n\t\t\t\t'placeholder' => 'author(s)',\n\t\t\t\t'desc_tip' => 'true',\n\t\t\t\t'description' => __( 'Author Name(s)', 'woocommerce' )\n\t\t\t)\n\t\t);\n\t\twoocommerce_wp_text_input(\n\t\t\tarray(\n\t\t\t\t'id' => 'release_date',\n\t\t\t\t'label' => __( 'Release Date', 'woocommerce' ),\n\t\t\t\t'placeholder' => date( \"n/j/Y\" ),\n\t\t\t\t'desc_tip' => 'true',\n\t\t\t\t'description' => __( 'Release Date', 'woocommerce' )\n\t\t\t)\n\t\t);\n\t\twoocommerce_wp_text_input(\n\t\t\tarray(\n\t\t\t\t'id' => 'preview_file',\n\t\t\t\t'label' => __( 'Preview File (look inside)', 'woocommerce' ),\n\t\t\t\t'desc_tip' => 'true',\n\t\t\t\t'description' => __( 'Upload a PDF file sample', 'woocommerce' )\n\t\t\t)\n\t\t);\n\t\techo( '<input type=\"button\" class=\"button custom_media\" name=\"preview_file_button\" id=\"preview_file_button\" value=\"Upload/Browse\"/>' );\n\t\twoocommerce_wp_checkbox(\n\t\t\tarray(\n\t\t\t\t'id' => 'local_product',\n\t\t\t\t'label' => __( 'Local Product', 'woocommerce' ),\n\t\t\t\t'desc_tip' => 'true',\n\t\t\t\t'description' => __( '(not Longleaf)', 'woocommerce' ),\n\t\t\t\t'cbvalue' => '1'\n\t\t\t)\n\t\t);\n\t}", "function create_meta_box() {\n\tif ( function_exists('add_meta_box') ) {\n\t\tadd_meta_box( 'new-meta-boxes', '<div class=\"icon-small\"></div> '.PEXETO_THEMENAME.' PAGE SETTINGS', 'new_meta_boxes', 'page', 'normal', 'high' );\n\t}\n}", "public static function create_meta_box() {\n\t\t$content_types_array = self::_get_active_content_types();\n\t\tforeach ( $content_types_array as $content_type ) {\n\t\t\tadd_meta_box( 'custom-content-type-mgr-custom-fields'\n\t\t\t\t, __('Custom Fields', CCTM::txtdomain )\n\t\t\t\t, 'StandardizedCustomFields::print_custom_fields'\n\t\t\t\t, $content_type\n\t\t\t\t, 'normal'\n\t\t\t\t, 'high'\n\t\t\t\t, $content_type \n\t\t\t);\n\t\t}\n\t}", "public function addMetaFieldsToEditForm()\n\t{\n\t\t$interval = $this->getMetaFields('interval');\n\t\t$animation = $this->getMetaFields('animation');\n\n\t\t?>\n\t\t\t<tr class=\"form-field\">\n\t\t\t\t<th scope=\"row\">\n\t\t\t\t\t<label for=\"interval\">Tijd tussen slides</label>\n\t\t\t\t</th>\n\t\t\t\t<td>\n\t\t\t\t\t<input name=\"interval\" id=\"interval\" type=\"text\" value=\"<?php echo $interval;?>\" size=\"40\">\n\t\t\t\t\t<p class=\"description\">De tijd tussen slides in milliseconden (1000ms = 1s).</p>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t\t<tr class=\"form-field\">\n\t\t\t\t<th scope=\"row\">\n\t\t\t\t\t<label for=\"animation\">Animatie</label>\n\t\t\t\t</th>\n\t\t\t\t<td>\n\t\t\t\t\t<select name=\"animation\" id=\"animation\">\n\t\t\t\t\t\t<option <?php selected($animation, 'slide'); ?> value=\"slide\">Slide</option>\n\t\t\t\t\t\t<option <?php selected($animation, 'fade'); ?> value=\"fade\">Fade</option>\n\t\t\t\t\t</select>\n\t\t\t\t\t<p class=\"description\">Selecteer de animatie die gebruikt wordt door de slideshow.</p>\n\t\t\t\t</td>\n\t\t\t</tr>\n\t\t<?php\n\t}", "function caviar_add_meta_box() {\n\n\t$screens = array('page' );\n\n\tforeach ( $screens as $screen ) {\n\n\t\tadd_meta_box(\n\t\t\t'caviar_sectionid',\n\t\t\tesc_html__( 'Caviar Metabox Field Example', 'caviar_textdomain' ),\n\t\t\t'caviar_meta_box_callback',\n\t\t\t$screen\n\t\t);\n\n\t\tadd_meta_box(\n\t\t\t'caviar_2',\n\t\t\tesc_html__( 'Caviar Metabox 2', 'caviar_textdomain' ),\n\t\t\t'caviar_meta_box2_callback',\n\t\t\t$screen\n\t\t);\n\t}\n}", "public function add_metabox() {\n\t\tadd_meta_box(\n\t\t\t'Translation',\n\t\t\t'Translation',\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'meta_box',\n\t\t\t),\n\t\t\t'words',\n\t\t\t'side',\n\t\t\t'high'\n\t\t);\n\t}", "public function kiwip_add_meta_box(){\t\t\t\n\t\tadd_meta_box(\n\t\t\t$this->id,\n\t\t\t$this->title,\n\t\t\tarray(&$this, 'kiwip_metabox_callback'),\n\t\t\t$this->cpt_name,\n\t\t\t$this->context,\n\t\t\t$this->priority\n\t\t);\n\t}", "public function meta_boxes() {\n\n\t\t// Add TEAM Assignemtns meta box into Team custom post type.\n\t\tadd_meta_box(\n\t\t\t'wpcd_team_detail',\n\t\t\t__( 'Team Assignments', 'wpcd' ),\n\t\t\tarray( $this, 'render_team_details_meta_box' ),\n\t\t\t'wpcd_team',\n\t\t\t'advanced',\n\t\t\t'low'\n\t\t);\n\n\t}", "public function addMetaFields()\n\t{\n\t\tadd_action('slideshow_add_form_fields', [$this, 'addMetaFieldsToAddForm']);\n\t\tadd_action('slideshow_edit_form_fields', [$this, 'addMetaFieldsToEditForm']);\n\t}", "public function meta_box_setup()\n {\n add_meta_box($this->token . '-data', __('Chiro Quiz Details', $this->token), [\n $this,\n 'meta_box_content'\n ], $this->token, 'normal', 'high');\n\n do_action($this->token . '_meta_boxes');\n }", "public static function access_register_meta_boxes()\n\t{\n\t\t$self = new Access();\n\t\tadd_meta_box('access_data', __('Access data', SAPI_TEXT_DOMAIN), array(get_class($self), 'access_metabox_callback'), Access::$MACHINE_NAME);\n\n\t\tadd_action( 'edit_form_after_title', function($post) {\n\t\t\tif ($post->post_type == Access::$MACHINE_NAME) {\n\t\t\t\tprint '<div style=\"position: relative;top: 20px;z-index: 9999;padding: 5px 0;font-size: 20px;font-weight: 400\">Description:</div>';\n\t\t\t}\n\t\t} );\n\t}", "public function register_meta_box() {\n\n\t\t\tadd_meta_box($this->slug, $this->options['title'], array($this, 'setup_meta_box'), $this->screen, $this->options['context'], $this->options['priority']);\n\t\t\tremove_meta_box('postcustom', $this->screen, 'normal');\n\t\t}", "public function add_table_meta_boxes(){\n\t\tadd_meta_box(\n\t\t\t'wp_table_meta_box', //id\n\t\t\t'Horse Information', //name\n\t\t\tarray($this,'horse_meta_box_display'), //display function\n\t\t\t'wp_horse_tables', //post type\n\t\t\t'normal', //location\n\t\t\t'default' //priority\n );\n add_meta_box(\n\t\t\t'wp_fetch_form_meta_box', //id\n\t\t\t'Fetch Horse Information From Url', //name\n\t\t\tarray($this,'horse_fetch_form_meta_box_display'), //display function\n\t\t\t'wp_horse_tables', //post type\n\t\t\t'normal', //location\n\t\t\t'high' //priority\n\t\t);\n }", "public function register_metabox() {\n\t\t$fm = new Fieldmanager_Group( [\n\t\t\t'name' => 'hero_fields', // \"name\" id deceiving, used as the key/ID.\n\t\t\t'serialize_data' => false,\n\t\t\t'add_to_prefix' => false,\n\t\t\t'children' => [\n\t\t\t\t'_headline' => new Fieldmanager_RichTextArea( 'Main Headline', [\n\t\t\t\t\t'buttons_1' => [ 'bold', 'italic', 'strikethrough' ],\n\t\t\t\t\t'editor_settings' => [\n\t\t\t\t\t\t'media_buttons' => false,\n\t\t\t\t\t],\n\t\t\t\t] ),\n\t\t\t\t'_subheadline' => new Fieldmanager_RichTextArea( 'Sub Headline', [\n\t\t\t\t\t'buttons_1' => [ 'bold', 'italic', 'strikethrough' ],\n\t\t\t\t\t'editor_settings' => [\n\t\t\t\t\t\t'media_buttons' => false,\n\t\t\t\t\t],\n\t\t\t\t] ),\n\t\t\t],\n\t\t] );\n\n\t\t/**\n\t\t * Initiate the metabox\n\t\t */\n\t\t$fm->add_meta_box( 'Hero', 'page' );\n\t}", "function tower_register_meta_boxes() {\n foreach (TOWER_CUSTOM_POSTS as $key => $custom_type) {\n $meta = $custom_type['meta'];\n add_meta_box(\n $meta['handle'],\n $meta['title'],\n $meta['callback'],\n $key\n );\n }\n}", "public function add_meta_boxes() {\n add_meta_box( 'wc-product-label-gallery', __( 'Label gallery', 'wc-label-gallery' ), array( $this, 'gallery_output' ), 'product', 'side', 'low' );\n }", "public function registerMetaBox() {\n\n add_meta_box(\n 'post-clone',\n 'Clone',\n array($this, 'buildForm'),\n self::$post_types,\n 'side',\n 'low');\n }", "public static function registerMetaBoxes() {}", "public function setup_meta_box( $options ) {\n\t\t\n\t\t\t//add_meta_box\n\t\t\n\t\t}", "function add_metaboxes() \n {\n // add a metabox to the Event using the callback add_time_date_metabox \n add_meta_box( \n \"bbquotations-source\",\n __(\"Quote source url\", $this->localization_domain),\n array(&$this, \"add_source_metabox\"), $this->custom_post_type_name, \"normal\", \"high\"\n );\n\n add_meta_box( \n \"bbquotations-cheatsheet\",\n __(\"Quotes usage cheatsheet\", $this->localization_domain),\n array(&$this, \"add_cheatsheet_metabox\"), $this->custom_post_type_name, \"side\", \"high\"\n );\n }", "public function register_meta_box() {\r\n add_meta_box( self::POST_TYPE . '-meta', 'Downloadable Resource URL', array ($this, 'meta_box_html'), self::POST_TYPE, 'side', 'default', '');\r\n }", "function register_options_metabox($id,$title,$desc = '') {\r\n\t\tadd_settings_section(\r\n\t\t\t$id, \r\n\t\t\t'', \r\n\t\t\tarray(&$this, 'section_null'), \r\n\t\t\t$this->page \r\n\t\t);\r\n\t\tadd_meta_box(\r\n\t\t\t$id,\r\n\t\t\t$title, \r\n\t\t\tarray(&$this, 'admin_section_builder'), \r\n\t\t\t$this->page, \r\n\t\t\t'normal', \r\n\t\t\t'core',\r\n\t\t\tarray('section' => $id,'description'=>$desc)\r\n\t\t);\r\n\t}", "function add_your_fields_meta_box(){\r\nadd_meta_box(\r\n'your_fields_meta_box',// $id\r\n'Auteur',// $title\r\n'show_your_fields_meta_box',// $callback\r\n'Livre',// $screen\r\n'normal',// $context\r\n'high'// $priority\r\n);\r\n}", "function address_meta_box()\n{\n\n\tadd_meta_box('main_address', 'Address Real Estate' , 'address_input', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\n\tadd_meta_box('district_address', 'District Real Estate' , 'address_district_input', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\t\tadd_meta_box('rew_floor', 'Floor Number' , 'rew_floors', array('apartment', 'villa') , 'advanced' , 'high',null);\n\t\tadd_meta_box('rew_rooms', 'Rooms Number' , 'rew_rooms',array('apartment', 'villa') , 'advanced' , 'high',null);\n\t\tadd_meta_box('Apartment_area', 'Real Estate Area' , 'rew_area', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\tadd_meta_box('rew_price', 'Real Estat Price' , 'rew_price', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\n\t/// villa rew_garden\n\tadd_meta_box('rew_garden', 'Garden Real Estate' , 'rew_garden', array( 'villa') , 'advanced' , 'high',null);\n\n}", "public function add_meta_box() {\n\t\tif (count($post_types = $this->get_post_types())) {\n\t\t\t$this->load_textdomain();\n\t\t\tforeach ($post_types as $post_type)\n\t\t\t\tadd_meta_box('im8_additional_css_box', __(\"Additional CSS\", 'im8-additional-css'), array($this, 'print_meta_box'), $post_type, 'normal', 'high');\n\t\t}\n\t}", "public function add_to_menu_metabox()\n\t\t{\n\t\t\tadd_meta_box(\n\t\t\t\t$this->the_theme->alias . '_details', \n\t\t\t\t__('Partner Details', $this->the_theme->localizationName), \n\t\t\t\tarray($this, 'custom_metabox'), \n\t\t\t\t'partners', \n\t\t\t\t'normal'\n\t\t\t);\n\t\t}", "function sp_add_custom_box() {\n\tif( function_exists( 'add_meta_box' )) {\n\t\tadd_meta_box( 'sp_custom_box_1', __( 'General Property Info', 'sp' ), 'sp_inner_custom_box_1', 'post', 'normal', 'high' );\n\t\tadd_meta_box( 'sp_custom_box_2', __( 'Property Details', 'sp' ), 'sp_inner_custom_box_2', 'post', 'normal', 'high' );\n\t\tadd_meta_box( 'sp_custom_box_3', __( 'Property Photos', 'sp' ), 'sp_inner_custom_box_3', 'post', 'normal', 'high' );\n\t}\n}", "function show() {\n global $post;\n \t\t/**\n\t\t * Use nonce for verification.\n\t\t */\n echo '<input type=\"hidden\" name=\"weddingvendor_meta_box_nonce\" value=\"', wp_create_nonce(basename(__FILE__)), '\" />';\n echo '<table class=\"form-table\">';\n\t\t\n foreach ($this->_meta_box['fields'] as $field) { \n\t\t\t/**\n\t\t\t * get current post meta data.\n\t\t\t */\n $meta = get_post_meta($post->ID, $field['id'], true);\n\t\t\tif( isset( $field['desc'] ) ) {\n\t\t\t\t$meta_description = $field['desc'];\n\t\t\t}\n\t\t\t\n echo '<tr><th style=\"width:20%\"><label for=\"',esc_attr($field['id']), '\">', esc_html($field['name']), '</label></th><td>';\n\t\t\t\n switch ($field['type']) {\n\t\t\t /**\n\t\t\t\t * Meta-box Text Field.\n\t\t\t\t */\t\n case 'text':\n \t echo '<input type=\"text\" name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\" value=\"', $meta ? $meta : $field['std'], '\" size=\"30\" style=\"width:97%\" />',\n '<br /><small>', $meta_description.'</small>';\n break;\t\n\t\n\n\t\t\t /**\n\t\t\t\t * Meta-box date Field.\n\t\t\t\t */\t\n case 'date':\n \t echo '<input type=\"text\" name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\" value=\"', $meta ? $meta : $field['std'], '\" size=\"30\" style=\"width:97%\" class=\"check_date date\" />',\n '<br /><small>', $meta_description.'</small>';\n break;\t\t\t\t\t \t\t\t\t\n\t\t\t /**\n\t\t\t\t * Meta-box Color Field.\n\t\t\t\t */\t\n\t\t\t\tcase 'color':\n\t\t\t\t echo '<input class=\"color-field\" type=\"text\" name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\" value=\"', $meta ? $meta : $field['std'], '\" />',\n '<br /><small>', $meta_description.'</small>';\n\t\t\t\tbreak;\n\t\t\t /**\n\t\t\t\t * Meta-box Textarea Field.\n\t\t\t\t */\t\n case 'textarea':\n echo '<textarea name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\" cols=\"60\" rows=\"4\" style=\"width:97%\">', $meta ? $meta : $field['std'], '</textarea>',\n '<br /><small>', $meta_description.'</small>';\n break;\n\t\t\t /**\n\t\t\t\t * Meta-box Select Field.\n\t\t\t\t */\t\n\t\t\t\tcase 'select':\t\t\t\t\t\n\t\t\t\t\t echo '<select name=\"'.esc_attr($field['id']).'\" id=\"'.esc_attr($field['id']).'\">';\n\t\t\t\t\t\t foreach ($field['options'] as $option) {\n\t\t\t\t\t\t \t echo '<option', $meta == $option['value'] ? ' selected=\"selected\"' : '', ' value=\"'.$option['value'].'\">'.$option['label'].'</option>';\n\t\t\t\t\t \t } \n\t\t\t\t\t echo '</select><br /><span class=\"description\">'.$meta_description.'</span>';\n break;\n\t\t\t /**\n\t\t\t\t * Meta-box Radio Field.\n\t\t\t\t */\t\n\t\t\t\tcase 'radio':\n\t\t\t\t\t foreach ( $field['options'] as $option ) {\n\t\t\t\t\t\t echo '<input type=\"radio\" name=\"'.esc_attr($field['id']).'\" id=\"'.$option['value'].'\" \n\t\t\t\t\t\t\t value=\"'.$option['value'].'\" ',$meta == $option['value'] ? ' checked=\"checked\"' : '',' />\n\t\t\t\t\t\t\t <label for=\"'.$option['value'].'\">'.$option['name'].'</label><br />';\n\t\t\t\t\t }\n\t\t\t\t\t echo '<span class=\"description\">'.$meta_description.'</span>';\n\t\t\t\tbreak;\n\t\t\t /**\n\t\t\t\t * Meta-box Checkbox Field.\n\t\t\t\t */\t\n\t case 'checkbox':\n \t echo '<input type=\"checkbox\" name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\"', $meta ? ' checked=\"checked\"' : '', ' />';\n\t\t\t\t\t echo '<span class=\"description\">'.$meta_description.'</span>';\n break;\n\t\t\t /**\n\t\t\t\t * Meta-box Checkbox-group Field.\n\t\t\t\t */\t\n\t\t\t case 'checkbox_group':\n\t\t\t\t\t foreach ($field['options'] as $option) {\n\t\t\t\t\t echo '<input type=\"checkbox\" value=\"',$option['value'],'\" name=\"',esc_html($field['id']),'[]\" \n\t\t\t\t\t\t id=\"',$option['value'],'\"',$meta && in_array($option['value'], $meta) ? ' checked=\"checked\"' : '',' />\n\t\t\t\t\t\t <label for=\"'.$option['value'].'\">'.$option['name'].'</label><br />';\n\t\t\t\t\t }\n\t\t\t\t\t echo '<span class=\"description\">'.$meta_description.'</span>';\n\t\t\t\t\tbreak;\n\t\t\t /**\n\t\t\t\t * Meta-box Image Field.\n\t\t\t\t */\t\n\t\t\t\tcase 'image':\n\t\t\t\t\t echo '<span class=\"upload\">';\n\t\t\t\t\t if( $meta ) {\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t echo '<input type=\"hidden\" name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\" \n\t\t\t\t\t\t\t\t class=\"regular-text form-control text-upload\" value=\"',$meta,'\" />';\t\t\t\t\t\t\t\n\t\t\t\t\t\t echo '<img style=\"width:150px; display:block;\" src= \"'.$meta.'\" class=\"preview-upload\" />';\n\t\t\t\t\t\t echo '<input type=\"button\" class=\"button button-upload\" id=\"logo_upload\" value=\"'.esc_html__('Upload an image','weddingvendor').'\"/></br>';\t\t\n\t\t\t\t\t\t echo '<input type=\"button\" class=\"button-remove\" id=\"remove\" value=\"'.esc_html__('Remove','weddingvendor').'\" /> ';\n\t\t\t\t\t }else {\n\t\t\t\t\t\t echo '<input type=\"hidden\" name=\"',esc_html($field['id']), '\" id=\"', esc_attr($field['id']), '\" \n\t\t\t\t\t\t\t\t\tclass=\"regular-text form-control text-upload\" value=\"',$meta,'\" />';\t\t\t\t\t\t\t\n\t\t\t\t\t\t echo '<img style=\"\" src= \"'.$meta.'\" class=\"preview-upload\" />';\n\t\t\t\t\t\t echo '<input type=\"button\" class=\"button button-upload\" id=\"logo_upload\" value=\"'.esc_html__('Upload an image','weddingvendor').'\"/></br>';\t\t\n\t\t\t\t\t\t echo '<input type=\"button\" style=\"display:none;\" id=\"remove\" class=\"button-remove\" value=\"\" /> ';\n\t\t\t\t\t } echo '</span><span class=\"description\">'.$meta_description.'</span>';\t\t\n\t\t\t\tbreak;\n\t\t\t\t\t\n }\n echo '<td></tr>';\n }\n echo '</table>';\n }", "public function meta_box_form_items() {\n\t\t$vfb_post = '';\n\t\t// Run Create Post add-on\n\t\tif ( class_exists( 'VFB_Pro_Create_Post' ) )\n\t\t\t$vfb_post = new VFB_Pro_Create_Post();\n\t?>\n\t\t<div class=\"taxonomydiv\">\n\t\t\t<p><strong><?php _e( 'Click or Drag' , 'visual-form-builder-pro'); ?></strong> <?php _e( 'to Add a Field' , 'visual-form-builder-pro'); ?> <img id=\"add-to-form\" alt=\"\" src=\"<?php echo admin_url( '/images/wpspin_light.gif' ); ?>\" class=\"waiting spinner\" /></p>\n\t\t\t<ul class=\"posttype-tabs add-menu-item-tabs\" id=\"vfb-field-tabs\">\n\t\t\t\t<li class=\"tabs\"><a href=\"#standard-fields\" class=\"nav-tab-link vfb-field-types\"><?php _e( 'Standard' , 'visual-form-builder-pro'); ?></a></li>\n\t\t\t\t<li><a href=\"#advanced-fields\" class=\"nav-tab-link vfb-field-types\"><?php _e( 'Advanced' , 'visual-form-builder-pro'); ?></a></li>\n\t\t\t\t<?php\n\t\t\t\t\tif ( class_exists( 'VFB_Pro_Create_Post' ) && method_exists( $vfb_post, 'form_item_tab' ) )\n\t\t\t\t\t\t$vfb_post->form_item_tab();\n\t\t\t\t?>\n\t\t\t</ul>\n\t\t\t<div id=\"standard-fields\" class=\"tabs-panel tabs-panel-active\">\n\t\t\t\t<ul class=\"vfb-fields-col-1\">\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-fieldset\">Fieldset</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-text\"><b></b>Text</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-checkbox\"><b></b>Checkbox</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-select\"><b></b>Select</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-datepicker\"><b></b>Date</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-url\"><b></b>URL</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-digits\"><b></b>Number</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-phone\"><b></b>Phone</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-file\"><b></b>File Upload</a></li>\n\t\t\t\t</ul>\n\t\t\t\t<ul class=\"vfb-fields-col-2\">\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-section\">Section</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-textarea\"><b></b>Textarea</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-radio\"><b></b>Radio</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-address\"><b></b>Address</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-email\"><b></b>Email</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-currency\"><b></b>Currency</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-time\"><b></b>Time</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-html\"><b></b>HTML</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-instructions\"><b></b>Instructions</a></li>\n\t\t\t\t</ul>\n\t\t\t\t<div class=\"clear\"></div>\n\t\t\t</div> <!-- #standard-fields -->\n\t\t\t<div id=\"advanced-fields\"class=\"tabs-panel tabs-panel-inactive\">\n\t\t\t\t<ul class=\"vfb-fields-col-1\">\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-username\"><b></b>Username</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-hidden\"><b></b>Hidden</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-autocomplete\"><b></b>Autocomplete</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-min\"><b></b>Min</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-range\"><b></b>Range</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-name\"><b></b>Name</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-likert\"><b></b>Likert</a></li>\n\t\t\t\t</ul>\n\t\t\t\t<ul class=\"vfb-fields-col-2\">\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-password\"><b></b>Password</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-color\"><b></b>Color Picker</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-ip\"><b></b>IP Address</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-max\"><b></b>Max</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-pagebreak\"><b></b>Page Break</a></li>\n\t\t\t\t\t<li><a href=\"#\" class=\"vfb-draggable-form-items\" id=\"form-element-rating\"><b></b>Rating</a></li>\n\t\t\t\t</ul>\n\t\t\t\t<div class=\"clear\"></div>\n\t\t\t</div> <!-- #advanced-fields -->\n\t\t\t<?php\n\t\t\t\tif ( class_exists( 'VFB_Pro_Create_Post' ) && method_exists( $vfb_post, 'form_items' ) )\n\t\t\t\t\t$vfb_post->form_items();\n\t\t\t?>\n\t\t</div> <!-- .taxonomydiv -->\n\t\t<div class=\"clear\"></div>\n\t<?php\n\t}", "function add_meta_box() {\n\t\t \tadd_meta_box( 'woocommerce-product-addons', __('Product Add-ons', 'wc_product_addons'), array(&$this, 'meta_box'), 'product', 'side', 'default' );\n\t\t }", "public function addMetaBox()\r\n {\r\n add_meta_box($this->id, esc_html__($this->title, 'firalabs-tv-show'), array(\r\n $this,\r\n 'render'\r\n ), 'firalabs_tv_show', $this->context, 'default');\r\n }", "function pvplugin_add_meta_box() {\n\t\n\t$screens = array( 'policy' );\n\t\n\tforeach ( $screens as $screen ) {\n\t\n\t\tadd_meta_box(\n\t\t\t'myplugin_sectionid',\n\t\t\t__( 'Custom Meta Box', 'policy_library_plugin' ),\n\t\t\t array( &$this, 'pvplugin_meta_box_callback' ),\n\t\t\t$screen\n\t\t);\n\t\t\n\t\tadd_meta_box(\n\t\t\t'myplugin_side_sectionid',\n\t\t\t__( 'Policy Expire', 'policy_library_plugin' ),\n\t\t\t array( &$this, 'pvplugin_side_meta_box_callback' ),\n\t\t\t$screen,'side','high'\n\t\t);\n\t\t\n\t}\n\t}", "function wpdocs_register_meta_boxes() {\r\n\r\n\tif ( isset($_GET['action']) && $_GET['action'] === 'edit' )\r\n\t{\r\n\t\tadd_meta_box( 'acoes-acesso', __( 'Ações', 'textdomain' ), 'petty_render_box_acao_metabox', 'acesso_camera','side','high' );\r\n\t}\r\n \r\n}", "function pafd_action_add_metaboxes() {\n\n\tglobal $pafd_textdomain;\n\n\t// Add the file metabox\n\tadd_meta_box(\n\t\t'customdiv-pafd-file'\n\t\t, __( 'File', $pafd_textdomain )\n\t\t, 'pafd_metabox_file_cb'\n\t\t, 'pa_file'\n\t\t, 'normal'\n\t\t, 'core'\n\t);\n\n\t// Add the file status metabox\n\tadd_meta_box(\n\t\t'customdiv-pafd-status'\n\t\t, __( 'File Status', $pafd_textdomain )\n\t\t, 'pafd_metabox_status_cb'\n\t\t, 'pa_file'\n\t\t, 'side'\n\t\t, 'core'\n\t);\n}", "public function add_meta_box() {\r\n\r\n\t\tif( ! is_wp_error( $this->tax_obj ) && isset($this->tax_obj->object_type ) ) foreach ( $this->tax_obj->object_type as $post_type ):\r\n\t\t\t$label = $this->tax_obj->labels->name;\r\n\t\t\t$id = ! is_taxonomy_hierarchical( $this->taxonomy ) ? 'radio-tagsdiv-'.$this->taxonomy : 'radio-' .$this->taxonomy .'div' ;\r\n\t\t\tadd_meta_box( $id, $label ,array( $this,'metabox' ), $post_type ,'side','core', array( 'taxonomy'=>$this->taxonomy ) );\r\n\t\tendforeach;\r\n\t}", "function tabify_add_meta_boxes($post_type)\n {\n }", "public function add_admin_meta_boxes() {\n\t\tadd_meta_box(\n\t\t\t'content_directory_options',\n\t\t\t__( 'Change Content Directory', 'it-l10n-ithemes-security-pro' ),\n\t\t\tarray( $this, 'metabox_advanced_settings' ),\n\t\t\t'security_page_toplevel_page_itsec_advanced',\n\t\t\t'advanced',\n\t\t\t'core'\n\t\t);\n\t}", "function AP_Meta_Box_Setup() {\n\tadd_action('add_meta_boxes','AP_Meta_Box_Add');\n\n\tadd_action( 'save_post', 'AP_Meta_Box_Save', 10, 2 );\n}", "function create_add_form($fields, $meta, $post, $context = '' ){\r\n\t\t$nonce = wp_create_nonce( 'wck-add-meta' );\r\n\t\tif( !empty( $post->ID ) )\r\n\t\t\t$post_id = $post->ID;\r\n\t\telse\r\n\t\t\t$post_id = '';\r\n\r\n /* for single forms we need the values that are stored in the meta */\r\n if( $this->args['single'] == true ) {\r\n if ($this->args['context'] == 'post_meta')\r\n $results = get_post_meta($post_id, $meta, true);\r\n else if ($this->args['context'] == 'option')\r\n $results = get_option( apply_filters( 'wck_option_meta' , $meta ));\r\n\r\n /* Filter primary used for CFC/OPC fields in order to show/hide fields based on type */\r\n $wck_update_container_css_class = apply_filters(\"wck_add_form_class_{$meta}\", '', $meta, $results );\r\n }\r\n ?>\r\n\t\t<div id=\"<?php echo $meta ?>\" style=\"padding:10px 0;\" class=\"wck-add-form<?php if( $this->args['single'] ) echo ' single' ?> <?php if( !empty( $wck_update_container_css_class ) ) echo $wck_update_container_css_class; ?>\">\r\n\t\t\t<ul class=\"mb-list-entry-fields\">\r\n\t\t\t\t<?php\r\n\t\t\t\t$element_id = 0;\r\n\t\t\t\tif( !empty( $fields ) ){\r\n\t\t\t\t\tforeach( $fields as $details ){\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tdo_action( \"wck_before_add_form_{$meta}_element_{$element_id}\" );\r\n\r\n /* set values in the case of single forms */\r\n $value = '';\r\n if( $this->args['single'] == true ) {\r\n $value = null;\r\n if (isset($results[0][Wordpress_Creation_Kit_PB::wck_generate_slug($details['title'], $details )]))\r\n $value = $results[0][Wordpress_Creation_Kit_PB::wck_generate_slug($details['title'], $details )];\r\n }\r\n ?>\r\n\t\t\t\t\t\t\t<li class=\"row-<?php echo esc_attr( Wordpress_Creation_Kit_PB::wck_generate_slug( $details['title'], $details ) ) ?>\">\r\n <?php echo self::wck_output_form_field( $meta, $details, $value, $context, $post_id ); ?>\r\n\t\t\t\t\t\t\t</li>\r\n\t\t\t\t\t\t<?php\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tdo_action( \"wck_after_add_form_{$meta}_element_{$element_id}\" );\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t$element_id++;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t?>\r\n <?php if( ! $this->args['single'] || $this->args['context'] == 'option' ){ ?>\r\n <li style=\"overflow:visible;\" class=\"add-entry-button\">\r\n <a href=\"javascript:void(0)\" class=\"button-primary\" onclick=\"addMeta('<?php echo esc_js($meta); ?>', '<?php echo esc_js( $post_id ); ?>', '<?php echo esc_js($nonce); ?>')\"><span><?php if( $this->args['single'] ) echo apply_filters( 'wck_add_entry_button', __( 'Save', 'profile-builder' ), $meta, $post ); else echo apply_filters( 'wck_add_entry_button', __( 'Add Entry', 'wck' ), $meta, $post ); ?></span></a>\r\n </li>\r\n <?php }elseif($this->args['single'] && $this->args['context'] == 'post_meta' ){ ?>\r\n <input type=\"hidden\" name=\"_wckmetaname_<?php echo $meta ?>#wck\" value=\"true\">\r\n <?php } ?>\r\n </ul>\r\n\t\t</div>\r\n\t\t<script>wck_set_to_widest( '.field-label', '<?php echo $meta ?>' );</script>\r\n\t\t<?php\r\n\t}", "public static function register_meta_boxes() {\n\t\t// estimate specific\n\t\t$args = array(\n\t\t\t'pspsi' => array(\n\t\t\t\t'title' => __( 'Sprout Invoices Integration', 'sprout-invoices' ),\n\t\t\t\t'show_callback' => array( __CLASS__, 'show_pspsi_meta_box' ),\n\t\t\t\t'save_callback' => array( __CLASS__, 'save_meta_box_pspsi' ),\n\t\t\t\t'context' => 'normal',\n\t\t\t\t'priority' => 'low',\n\t\t\t\t'weight' => 0,\n\t\t\t\t'save_priority' => 0,\n\t\t\t),\n\t\t);\n\t\tdo_action( 'sprout_meta_box', $args, 'psp_projects' );\n\t}", "function coolRahulSoni_meta_box_add()\n{\n add_meta_box( 'my-meta-box-id', 'My First Meta Box', 'cd_meta_box_cb', 'post', 'normal', 'high' );\n}", "function add_ingredienten_metabox(){\n\tadd_meta_box(\n\t\t'ingredienten_metabox',//id\n\t\t'Ingrediënten',//title\n\t\t'content_ingredienten_metabox',//callback\n\t\t'smaak',//page\n\t\t'normal', //context\n\t\t'high'//priority\n\t\t);\n}", "public function display_meta_box() {\n\t\t\n\t\tinclude_once( 'views/q-and-a-admin.php' );\n }", "function add() {\n\t\tforeach ($this->_meta_box['pages'] as $page) {\n\t\t\tadd_meta_box($this->_meta_box['id'], $this->_meta_box['title'], array(&$this, 'show'), $page, $this->_meta_box['context'], $this->_meta_box['priority']);\n\t\t}\n\t}", "public function add_meta_box() {\n if ( ! function_exists( 'acf_add_local_field_group' ) ) {\n return;\n }\n\n acf_add_local_field_group( [\n 'key' => 'group_facilities',\n 'title' => __( 'Booking', 'bediq' ),\n 'fields' => [\n [\n 'key' => 'field_facility_booking',\n 'label' => __( 'Booking URL', 'bediq' ),\n 'name' => 'facility_booking_url',\n 'type' => 'text',\n ],\n [\n 'key' => 'field_5d0a11db36416',\n 'label' => __( 'Typical Pricing', 'bediq' ),\n 'name' => 'facility_typical_pricing',\n 'type' => 'select',\n 'choices' => [\n '$' => '$',\n '$$$' => '$$$',\n '$$$$' => '$$$$',\n ],\n ],\n ],\n 'location' => [\n [\n [\n 'param' => 'post_type',\n 'operator' => '==',\n 'value' => 'facility',\n ],\n ],\n ],\n 'menu_order' => 0,\n 'position' => 'side',\n 'style' => 'default',\n 'label_placement' => 'top',\n 'instruction_placement' => 'label',\n 'hide_on_screen' => '',\n 'active' => true,\n 'description' => '',\n ] );\n\n acf_add_local_field_group( [\n 'key' => 'group_facility_downloads',\n 'title' => __( 'Downloads', 'bediq' ),\n 'fields' => [\n [\n 'key' => 'field_5d0a12a89b3db',\n 'label' => '',\n 'name' => 'facility_download_file',\n 'type' => 'repeater',\n 'min' => 1,\n 'max' => 0,\n 'layout' => 'block',\n 'button_label' => __( 'Add new download', 'bediq' ),\n 'sub_fields' => [\n [\n 'key' => 'field_5d0a12cc9b3dc',\n 'label' => __( 'Download Name', 'bediq' ),\n 'name' => 'facility_download_name',\n 'type' => 'text',\n ],\n [\n 'key' => 'field_5d0a12eb9b3dd',\n 'label' => '',\n 'name' => 'facility_download_file',\n 'type' => 'file',\n 'return_format' => 'array',\n 'library' => 'all',\n 'min_size' => '',\n 'max_size' => '',\n 'mime_types' => '',\n ],\n ],\n ],\n ],\n 'location' => [\n [\n [\n 'param' => 'post_type',\n 'operator' => '==',\n 'value' => 'facility',\n ],\n ],\n ],\n 'menu_order' => 0,\n 'position' => 'side',\n 'style' => 'default',\n 'label_placement' => 'top',\n 'instruction_placement' => 'label',\n 'hide_on_screen' => '',\n 'active' => true,\n 'description' => '',\n ] );\n\n acf_add_local_field_group( [\n 'key' => 'group_facility_floor_plan_image',\n 'title' => __( 'Floor Plan Image', 'bediq' ),\n 'fields' => [\n [\n 'key' => 'field_5d0a13abdf555',\n 'label' => '',\n 'name' => 'facility_floor_plan_image',\n 'type' => 'image',\n 'return_format' => 'array',\n 'preview_size' => 'post-thumbnail',\n 'library' => 'all',\n 'min_width' => '',\n 'min_height' => '',\n 'min_size' => '',\n 'max_width' => '',\n 'max_height' => '',\n 'max_size' => '',\n 'mime_types' => '',\n ],\n ],\n 'location' => [\n [\n [\n 'param' => 'post_type',\n 'operator' => '==',\n 'value' => 'facility',\n ],\n ],\n ],\n 'menu_order' => 0,\n 'position' => 'side',\n 'style' => 'default',\n 'label_placement' => 'top',\n 'instruction_placement' => 'label',\n 'hide_on_screen' => '',\n 'active' => true,\n 'description' => '',\n ] );\n\n acf_add_local_field_group( [\n 'key' => 'group_facility_gallery_image',\n 'title' => __( 'Gallery Image', 'bediq' ),\n 'fields' => [\n [\n 'key' => 'gallery_images',\n // 'label' => 'Gallery Image',\n 'name' => 'gallery_image',\n 'type' => 'gallery',\n 'instructions' => '',\n 'required' => 0,\n 'conditional_logic' => 0,\n 'wrapper' => array(\n 'width' => '',\n 'class' => '',\n 'id' => '',\n ),\n 'return_format' => 'array',\n 'preview_size' => 'medium',\n 'insert' => 'append',\n 'library' => 'all',\n 'min' => '',\n 'max' => '',\n 'min_width' => '',\n 'min_height' => '',\n 'min_size' => '',\n 'max_width' => '',\n 'max_height' => '',\n 'max_size' => '',\n 'mime_types' => '',\n ],\n ],\n 'location' => [\n [\n [\n 'param' => 'post_type',\n 'operator' => '==',\n 'value' => 'facility',\n ],\n ],\n ],\n 'menu_order' => 0,\n 'position' => 'side',\n 'style' => 'default',\n 'label_placement' => 'top',\n 'instruction_placement' => 'label',\n 'hide_on_screen' => '',\n 'active' => true,\n 'description' => '',\n ] );\n\n acf_add_local_field_group( [\n 'key' => 'group_facility_available_offer',\n 'title' => __( 'Offers Available', 'bediq' ),\n 'fields' => [\n [\n 'key' => 'field_5d09fcc8daaf8',\n 'label' => __( 'Offers Available', 'bediq' ),\n 'name' => 'offers_available',\n 'type' => 'repeater',\n 'min' => 1,\n 'max' => 0,\n 'layout' => 'table',\n 'button_label' => __( 'Add new offer', 'bediq' ),\n 'sub_fields' => [\n [\n 'key' => 'field_5d09fd21daaf9',\n 'label' => '',\n 'name' => '',\n 'type' => 'select',\n 'choices' => [\n ],\n 'default_value' => [\n ],\n 'allow_null' => 0,\n 'multiple' => 1,\n 'ui' => 1,\n 'ajax' => 1,\n 'return_format' => 'value',\n 'placeholder' => '',\n ],\n ],\n ],\n [\n 'key' => 'floor_size',\n 'label' => __( 'Floor Size', 'bediq' ),\n 'name' => 'floor_size',\n 'type' => 'text',\n 'wrapper' => [\n 'width' => '50',\n ]\n ],\n [\n 'key' => 'floor_size_unit',\n 'label' => __( 'Unit', 'bediq' ),\n 'name' => 'floor_size_unit',\n 'type' => 'select',\n 'wrapper' => [\n 'width' => '30',\n ],\n 'choices' => [\n 'sqm' => __( 'SQM', 'bediq' ),\n 'sqft' => __( 'SQFT', 'bediq' ),\n ]\n ],\n [\n 'key' => 'field_5d09ff299e7ba',\n 'label' => __( 'Location', 'bediq' ),\n 'name' => 'facility_location',\n 'type' => 'text',\n ],\n [\n 'key' => 'field_5d09ff3d9e7bb',\n 'label' => __( 'Dress Code', 'bediq' ),\n 'name' => 'facility_dress_code',\n 'type' => 'text',\n ],\n [\n 'key' => 'field_5d09ff5f9e7bc',\n 'label' => 'Style',\n 'name' => 'facility_style',\n 'type' => 'text',\n ],\n [\n 'key' => 'field_5d09ff7c9e7bd',\n 'label' => '',\n 'name' => 'facility_capacity',\n 'type' => 'repeater',\n 'min' => 1,\n 'max' => 0,\n 'layout' => 'block',\n 'button_label' => __( 'Add Capacity', 'bediq' ),\n 'sub_fields' => [\n [\n 'key' => 'field_5d09ff939e7be',\n 'label' => 'Capacity',\n 'name' => 'capacity',\n 'type' => 'text',\n 'wrapper' => [\n 'width' => '50'\n ]\n ],\n [\n 'key' => 'field_5d09ffce9e7bf',\n 'label' => 'Adults',\n 'name' => 'adults',\n 'type' => 'select',\n 'wrapper' => [\n 'width' => '50',\n ],\n 'choices' => [\n 'boardroom' => __( 'Boardroom', 'bediq' ),\n 'classroom' => __( 'Classroom', 'bediq' ),\n 'cocktail' => __( 'Cocktail', 'bediq' ),\n 'theatre' => __( 'Theatre', 'bediq' ),\n 'u_Shape' => __( 'U-Shape', 'bediq' ),\n ],\n 'return_format' => 'value',\n ],\n ],\n ],\n [\n 'key' => 'field_5d0a00709e7c0',\n 'label' => __( 'Policy Name', 'bediq' ),\n 'name' => 'policy_name',\n 'type' => 'select',\n 'choices' => [\n 'pets_allowed' => __( 'Pets Allowed', 'bediq' ),\n 'smoking_allowed' => __( 'Smoking Allowed', 'bediq' ),\n ],\n 'allow_null' => 0,\n 'multiple' => 1,\n 'ui' => 1,\n 'ajax' => 1,\n 'return_format' => 'value',\n 'placeholder' => '',\n ],\n [\n 'key' => 'field_facility_shift',\n 'label' => __( 'Opening Hours', 'bediq' ),\n 'name' => 'facility_visibility',\n 'type' => 'repeater',\n 'min' => 1,\n 'max' => 0,\n 'layout' => 'table',\n 'button_label' => __( 'Add new shift', 'bediq' ),\n 'sub_fields' => [\n [\n 'key' => 'field_facility_opening_hours',\n 'label' => __( 'Opening Hours', 'bediq' ),\n 'name' => 'opening_hours',\n 'type' => 'group',\n 'wrapper' => [\n 'width' => '25',\n ],\n 'layout' => 'block',\n 'sub_fields' => [\n [\n 'key' => 'field_5d0a01539e7c2',\n 'label' => __( 'Shift Name', 'bediq' ),\n 'name' => 'shift_name',\n 'type' => 'text',\n ],\n [\n 'key' => 'field_5d0a01899e7c3',\n 'label' => '',\n 'name' => '24_hours',\n 'type' => 'checkbox',\n 'choices' => [\n '24 Hours' => '24 Hours',\n ],\n 'allow_custom' => 0,\n 'layout' => 'vertical',\n 'toggle' => 0,\n 'return_format' => 'value',\n 'save_custom' => 0,\n ],\n ],\n ],\n [\n 'key' => 'field_facility_opening_days',\n 'label' => __( 'Days', 'bediq' ),\n 'name' => 'facility_opening_days',\n 'type' => 'group',\n 'instructions' => '',\n 'wrapper' => [\n 'width' => '25',\n ],\n 'layout' => 'block',\n 'sub_fields' => [\n [\n 'key' => 'field_facility_opening_day',\n 'label' => '',\n 'name' => 'facility_opening_days',\n 'type' => 'checkbox',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-visiblity-days',\n 'id' => '',\n ],\n 'choices' => [\n 'monday' => __( 'Monday', 'bediq' ),\n 'tuesday' => __( 'Tuesday', 'bediq' ),\n 'wednesday' => __( 'Wednesday', 'bediq' ),\n 'thursday' => __( 'Thursday', 'bediq' ),\n 'friday' => __( 'Friday', 'bediq' ),\n 'saturday' => __( 'Saturday', 'bediq' ),\n 'sunday' => __( 'Sunday', 'bediq' ),\n ],\n 'layout' => 'vertical',\n 'toggle' => 0,\n 'return_format' => 'value',\n 'save_custom' => 0,\n ],\n ],\n ],\n [\n 'key' => 'field_5d0a02459e7c6',\n 'label' => __( 'From HH:mm', 'bediq' ),\n 'name' => 'facility_start_time',\n 'type' => 'group',\n 'wrapper' => [\n 'width' => '25',\n ],\n 'layout' => 'block',\n 'sub_fields' => [\n [\n 'key' => 'field_5d0a026a9e7c7',\n 'label' => '',\n 'name' => 'monday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a029e9e7c8',\n 'label' => '',\n 'name' => 'tuesday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a02b49e7c9',\n 'label' => '',\n 'name' => 'wednesday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a02cb9e7ca',\n 'label' => '',\n 'name' => 'thursday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a02dc9e7cb',\n 'label' => '',\n 'name' => 'friday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a02eb9e7cc',\n 'label' => '',\n 'name' => 'saturday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a02fa9e7cd',\n 'label' => '',\n 'name' => 'sunday_start',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n ],\n ],\n [\n 'key' => 'field_5d0a031d9e7ce',\n 'label' => __( 'To HH:mm', 'bediq' ),\n 'name' => 'outlet_end_time',\n 'type' => 'group',\n 'wrapper' => [\n 'width' => '25',\n ],\n 'layout' => 'block',\n 'sub_fields' => [\n [\n 'key' => 'field_5d0a031d9e7cf',\n 'label' => '',\n 'name' => 'monday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'class' => 'bediq-time-picker',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a031d9e7d0',\n 'label' => '',\n 'name' => 'tuesday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a031d9e7d1',\n 'label' => '',\n 'name' => 'wednesday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a031d9e7d2',\n 'label' => '',\n 'name' => 'thursday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a031d9e7d3',\n 'label' => '',\n 'name' => 'friday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a031d9e7d4',\n 'label' => '',\n 'name' => 'saturday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n [\n 'key' => 'field_5d0a031d9e7d5',\n 'label' => '',\n 'name' => 'sunday_end',\n 'type' => 'time_picker',\n 'wrapper' => [\n 'width' => '',\n 'class' => 'bediq-time-picker',\n 'id' => '',\n ],\n 'display_format' => 'g:i a',\n 'return_format' => 'g:i a',\n ],\n ],\n ],\n ]\n ],\n\n [\n 'key' => 'field_5d0a04c80f7ad',\n 'label' => __( 'Short Description', 'bediq' ),\n 'name' => 'short_description',\n 'type' => 'textarea',\n ],\n ],\n 'location' => [\n [\n [\n 'param' => 'post_type',\n 'operator' => '==',\n 'value' => 'facility',\n ],\n ],\n ],\n 'menu_order' => 0,\n 'position' => 'normal',\n 'style' => 'default',\n 'label_placement' => 'top',\n 'instruction_placement' => 'label',\n 'hide_on_screen' => '',\n 'active' => true,\n 'description' => '',\n ] );\n }", "function wpbootstrap_post_meta_boxes_setup() {\r\n\t\r\n\t/* Add meta boxes on the 'add_meta_boxes' hook. */\r\n\tadd_action( 'add_meta_boxes', 'wpbootstrap_add_post_meta_boxes' );\r\n\r\n\t/* Save the wpbootstrap_components meta on 'save_post' hook. */\r\n\tadd_action( 'save_post', 'wpbootstrap_components_save_meta', 10, 2 );\r\n}", "public function add_meta_boxes() {\n\t\tforeach ( $this->screens as $screen ) {\n\t\t\tadd_meta_box(\n\t\t\t\t'video-settings',\n\t\t\t\t__( 'Video Settings', 'lpw_wp' ),\n\t\t\t\tarray( $this, 'add_meta_box_callback' ),\n\t\t\t\t$screen,\n\t\t\t\t'advanced',\n\t\t\t\t'default'\n\t\t\t);\n\t\t}\n\t}", "function cspm_add_locations_metabox(){\r\n\t\t\t\r\n\t\t\t/**\r\n\t\t\t * Add Locations Metabox options */\r\n\t\t\t \r\n\t\t\t$cspm_add_locations_metabox_options = array(\r\n\t\t\t\t'id' => $this->metafield_prefix . '_add_locations_metabox',\r\n\t\t\t\t'title' => esc_attr__( 'Progress Map: Add locations', 'cspm' ),\r\n\t\t\t\t'object_types' => isset($this->plugin_settings['post_types']) ? $this->plugin_settings['post_types'] : array(), // Post types\r\n\t\t\t\t'priority' => 'high',\r\n\t\t\t\t//'context' => 'side',\r\n\t\t\t\t'show_names' => true, // Show field names on the left\t\t\r\n\t\t\t\t'closed' => false,\t\t\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\t\t/**\r\n\t\t\t\t * Create post type Metabox */\r\n\t\t\t\t \r\n\t\t\t\t$cspm_add_locations_metabox = new_cmb2_box( $cspm_add_locations_metabox_options );\r\n\r\n\t\t\t\t/**\r\n\t\t\t\t * Display Add Locations Metabox fields */\r\n\t\t\t\r\n\t\t\t\t$this->cspm_add_locations_tabs($cspm_add_locations_metabox, $cspm_add_locations_metabox_options);\r\n\t\t\t\r\n\t\t}", "private function initMetaBox(){\n\t\t$path = get_template_directory() . '/sub/customfield/';\n\t\tif(function_exists('of_get_option')){\n\t\t\tif(of_get_option('is-seo',true)){\n\t\t\t\tnew WPO_MetaBox(array(\n\t\t\t\t 'id' => 'wpo_seo',\n\t\t\t\t 'title' => $this->l('SEO Fields'),\n\t\t\t\t 'types' => array('page','portfolio','post','video'),\n\t\t\t\t 'priority' => 'high',\n\t\t\t\t 'template' => $path . 'seo.php',\n\t\t\t\t));\n\t\t\t}\n\t\t}\n\n\t\tnew WPO_MetaBox(array(\n\t\t 'id' => 'wpo_template',\n\t\t 'title' => $this->l('Advanced Configuration'),\n\t\t 'types' => array('page'),\n\t\t 'priority' => 'high',\n\t\t 'template' => $path . 'page-advanced.php'\n\t\t));\n\n\t\tnew WPO_MetaBox(array(\n\t\t 'id' => 'wpo_pageconfig',\n\t\t 'title' => $this->l('Page Configuration'),\n\t\t 'types' => array('page'),\n\t\t 'priority' => 'high',\n\t\t 'template' => $path . 'page.php',\n\t\t));\n\n\t\tnew WPO_MetaBox(array(\n\t\t 'id' => 'wpo_post',\n\t\t 'title' => $this->l('Embed Options'),\n\t\t 'types' => array('post','video'),\n\t\t 'priority' => 'high',\n\t\t 'template' => $path . 'post.php',\n\t\t));\n\t}", "function create_custom_fields() {\n // Get all components to be listed\n $this->get_components();\n // Add components meta box\n if ( function_exists( 'add_meta_box' ) ) {\n foreach ( $this->postTypes as $postType ) {\n add_meta_box( 'wpnext', 'WPNext Builder', array( &$this, 'display_custom_fields' ), $postType, 'normal', 'high' );\n }\n }\n }", "public static function add_meta_box() {\n add_meta_box( \"CBMTheme\", \"CBM Theme Meta Box\", \"CBMAdmin::posts_page\" );\n }", "function rs_meta_box()\n{\n add_meta_box('rs_focus', 'Destaque na home', 'rs_focus', 'post', 'side');\n add_meta_box('rs_author', 'Autor', 'rs_author', 'post', 'side');\n add_meta_box('rs_author', 'Autor', 'rs_author', 'post_region', 'side');\n add_meta_box('rs_author', 'Autor', 'rs_author', 'event', 'side');\n}", "public function create_meta_box() {\n\t\tadd_meta_box( 'slider_meta', 'Example metabox', array( $this, 'slider_meta_fields_callback' ), [ 'Page', 'post' ] );\n\n\t}", "function vulcan_page_meta_boxes() {\r\r\n $meta_boxes = array(\r\r\n \"short_desc\" => array(\r\r\n \"name\" => \"short_desc\",\r\r\n \"title\" => \"Short Description\",\r\r\n \"description\" => \"Add short description to your pages.\",\r\r\n \"type\" => \"textarea\"\r\r\n ),\r\r\n \"page_thumbnail_image\" => array(\r\r\n \"name\" => \"page_thumbnail_image\",\r\r\n \"title\" => \"Thumbnail Image\",\r\r\n \"description\" => \"Add thumbnail image url, will be use for your page thumbnail, for example in Services child pages list.\",\r\r\n \"type\" => \"text\"\r\r\n )\r\r\n );\r\r\n \r\r\n return $meta_boxes;\r\r\n}", "function ce_register_meta_boxes()\n{\n\t// Make sure there's no errors when the plugin is deactivated or during upgrade\n\tif ( !class_exists( 'RW_Meta_Box' ) )\n\t\treturn;\n\n\tglobal $meta_boxes;\n\tforeach ( $meta_boxes as $meta_box )\n\t{\n\t\tnew RW_Meta_Box( $meta_box );\n\t}\n}", "private function add_meta_boxes() {\n\t\t$post_types = $this->post->get_types();\n\n\t\tforeach ( $post_types as $post_type => $value ) {\n\t\t\tadd_meta_box( 'subway_comment_metabox',\n\t\t\t\tesc_html__( 'Memberships Discussion', 'subway' ),\n\t\t\t\tfunction ( $post ) {\n\t\t\t\t\t$this->discussion( $post );\n\t\t\t\t},\n\t\t\t\t$post_type, 'side', 'high'\n\t\t\t);\n\t\t\tadd_meta_box( 'subway_visibility_metabox',\n\t\t\t\tesc_html__( 'Memberships Access', 'subway' ),\n\t\t\t\tfunction ( $post ) {\n\t\t\t\t\t$this->visibility( $post );\n\t\t\t\t},\n\t\t\t\t$post_type, 'side', 'high'\n\t\t\t);\n\t\t}\n\n\t}", "public function uultra_load_wdiget_addition_form()\r\n\t{\r\n\t\t$html = '';\r\n\t\t$html .= '<div class=\"uultra-adm-widget-cont-add-new\" >';\r\n \r\n\t\t$html .= '<table width=\"100%\" border=\"0\" cellspacing=\"2\" cellpadding=\"3\">\r\n\t\t\t<tr>\r\n\t\t\t\t<td width=\"50%\"> '.__(\"Name: \",'xoousers').'</td>\r\n\t\t\t\t<td width=\"50%\"><input name=\"uultra_add_mod_widget_title\" type=\"text\" id=\"uultra_add_mod_widget_title\" style=\"width:120px\" /> \r\n\t\t </td>\r\n\t\t </tr>\r\n\t\t <tr>\r\n\t\t\t\t<td width=\"50%\"> '.__('Type:','xoousers').'</td>\r\n\t\t\t\t<td width=\"50%\">\r\n\t\t\t\t<select name=\"uultra_add_mod_widget_type\" id=\"uultra_add_mod_widget_type\" size=\"1\">\r\n\t\t\t\t <option value=\"\" selected=\"selected\">'.__(\"Select Type: \",'xoousers').'</option>\r\n\t\t\t\t <option value=\"1\">'.__(\"Text: \",'xoousers').'</option>\r\n\t\t\t\t <option value=\"2\">Shortcode</option>\r\n\t\t\t\t</select>\r\n\r\n\t\t </td>\r\n\t\t\t </tr>\r\n\t\t<tr>\r\n\t\t\t\t<td width=\"50%\"> '.__('Editable by user:','xoousers').'</td>\r\n\t\t\t\t<td width=\"50%\">\r\n\t\t\t\t<select name=\"uultra_add_mod_widget_editable\" id=\"uultra_add_mod_widget_editable\" size=\"1\">\r\n\t\t\t\t \r\n\t\t\t\t <option value=\"0\" selected=\"selected\">'.__(\"NO \",'xoousers').'</option>\r\n\t\t\t\t <option value=\"1\">'.__(\"YES\",'xoousers').'</option>\r\n\t\t\t\t</select>\r\n\r\n\t\t </td>\r\n\t\t\t </tr>\r\n\t\t\t \r\n\t\t\t <tr>\r\n\t\t\t\t<td>'.__('Content:','xoousers').'</td>\r\n\t\t\t\t<td>&nbsp;</textarea> \r\n\t\t\t </td>\r\n\t\t\t </tr>\r\n\t\t\t \r\n\t\t\t <tr>\r\n\t\t\t\t\r\n\t\t\t\t<td colspan=\"2\"><textarea name=\"uultra_add_mod_widget_content\" id=\"uultra_add_mod_widget_content\" style=\"width:98%;\" rows=\"5\"></textarea> \r\n\t\t\t </td>\r\n\t\t\t </tr> \r\n\t\t\t \r\n\t\t\t \r\n\t\t\t</table> '; \t\t\t\r\n\t\t\t \r\n\t\t\t$html .= ' <p class=\"submit\">\r\n\t\t\t\t\t<input type=\"button\" name=\"submit\" class=\"button uultra-widgets-add-new-close\" value=\"'.__('Close','xoousers').'\" /> <input type=\"button\" name=\"submit\" class=\"button button-primary uultra-widgets-add-new-confirm\" value=\"'.__('Submit','xoousers').'\" /> <span id=\"uultra-add-new-widget-m-w\" ></span>\r\n\t\t\t\t</p> ';\r\n\t\t\t\t\r\n\t\t\t$html .= '</div>';\r\n\t\t\t\t\r\n\t\t\techo $html;\r\n\t\t\tdie();\r\n\t\r\n\t}", "function custom_meta_boxes() {\r\n\t\tglobal $post_type;\r\n\r\n\t\tif( 'event' != $post_type )\r\n\t\t\treturn;\r\n\r\n\t\tadd_meta_box('event_start', __('Event Start', 'bp-simple-events'), array( $this, 'event_start' ), 'event', 'normal', 'default');\r\n\r\n\t\tadd_meta_box('event_stop', __('Event Stop', 'bp-simple-events'), array( $this, 'event_stop' ), 'event', 'normal', 'default');\r\n\r\n\t\tadd_meta_box('event_location', __('Location', 'bp-simple-events'), array( $this, 'location_show' ), 'event', 'normal', 'default');\r\n\r\n\t\tadd_meta_box('event_url', __('URL', 'bp-simple-events'), array( $this, 'url_show' ), 'event', 'normal', 'default');\r\n\r\n\t\tadd_meta_box('event_attending', __('Attending Options', 'bp-simple-events'), array( $this, 'attending_show' ), 'event', 'normal', 'default');\r\n\r\n\t\tadd_meta_box('event_groups', __('Groups', 'bp-simple-events'), array( $this, 'groups_show' ), 'event', 'normal', 'default');\r\n\t}", "public static function createMetaBox() {\r\n add_meta_box( \r\n \\WPDisablePage\\Setup::PLUGIN_ID, // Metabox ID\r\n \\WPDisablePage\\Setup::PLUGIN_NAME, // Metabox Name\r\n array( __CLASS__, 'createView' ), // Metabox Callback\r\n apply_filters( strtolower( \\WPDisablePage\\Setup::PLUGIN_ID ) . '__post_types', self::POST_TYPES ), // Metabox Post Types\r\n self::POSITION, // Metabox Position\r\n self::PRIORITY // Metabox Priority\r\n );\r\n }", "private function addElements(): void\n {\n // Add additional form fields\n $this->add([\n 'name' => 'masterFile',\n 'type' => Checkbox::class,\n 'attributes' => [\n 'id' => 'masterFile',\n 'class' => 'form-check-input',\n ],\n 'options' => [\n 'label' => 'Create master export file',\n 'label_attributes' => [\n 'class' => 'form-check-label',\n ],\n ],\n ]);\n\n $this->add([\n 'name' => 'debugTranslations',\n 'type' => Checkbox::class,\n 'attributes' => [\n 'id' => 'debugTranslations',\n 'class' => 'form-check-input',\n ],\n 'options' => [\n 'label' => 'Create debug translations',\n 'label_attributes' => [\n 'class' => 'form-check-label',\n ],\n ],\n ]);\n }" ]
[ "0.74768287", "0.72349536", "0.7183291", "0.71335405", "0.7076592", "0.7055092", "0.7054515", "0.7038045", "0.69603777", "0.6957431", "0.6908298", "0.6891041", "0.6876519", "0.685717", "0.68559784", "0.68356293", "0.68312013", "0.68237126", "0.6786773", "0.6740539", "0.67241555", "0.67239326", "0.6720341", "0.6707638", "0.66966766", "0.66931105", "0.6689773", "0.66886646", "0.6678695", "0.66781914", "0.66683984", "0.66539127", "0.66382366", "0.66207", "0.66188085", "0.6615058", "0.661346", "0.6610583", "0.6603485", "0.6595965", "0.6593634", "0.6593269", "0.6590469", "0.6585925", "0.6579006", "0.6573348", "0.6568746", "0.6555308", "0.6552597", "0.6540169", "0.65342706", "0.65204394", "0.6520109", "0.65199465", "0.65166557", "0.6516257", "0.64824915", "0.6477428", "0.6465689", "0.64608425", "0.6458456", "0.64519167", "0.6448691", "0.64477015", "0.6442571", "0.6442287", "0.64392555", "0.6434063", "0.6429346", "0.6426419", "0.6414392", "0.6412153", "0.6411076", "0.6405404", "0.64052474", "0.6403068", "0.6400394", "0.63962144", "0.6395598", "0.6389773", "0.63847613", "0.6360193", "0.6359618", "0.63537014", "0.635196", "0.6343959", "0.63405365", "0.6332425", "0.63300914", "0.6329228", "0.6325097", "0.6322285", "0.63074684", "0.6305833", "0.62951815", "0.62944937", "0.6294229", "0.62873703", "0.62835765", "0.6281553" ]
0.7976936
0
Includes the unit info metabox code.
function _display_unitinfo_meta( $post ) { include( 'includes/metaboxes/unit-info.php' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function render_info_box() {\n\t\tinclude_once 'views/estimate/info.php';\n\t}", "function add_meta_boxes() {\n\t\tif( function_exists( 'add_meta_box' ) ) {\n\t\t\tadd_meta_box( 'unit-info', __('Unit Information'), array( $this, '_display_unitinfo_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'maps', __('Maps'), array( $this, '_display_maps_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'gallery', __('Gallery'), array( $this, '_display_gallery_meta'), 'units', 'normal', 'low');\n\t\t\tadd_meta_box( 'unit-status', __('Availability'), array( $this, '_display_status_meta'), 'units', 'side', 'high');\n\t\t}\n\t}", "public function unit()\n {\n $data = ['aktif' => 'unit',\n 'data_unit' => $this->M_prospektus->get_unit_menu()->result_array(),\n 'data_blok' => $this->M_prospektus->get_blok_kws()->result_array()\n ];\n\n $this->template->load('template','prospektus/V_data_unit', $data);\n }", "protected function info()\n\t\t{\n\t\t}", "function _display_status_meta( $post ) {\n\t\tinclude( 'includes/metaboxes/unit-status.php' );\n\t}", "public function info()\n {\n return $this->type('info');\n }", "function info() {\n\t \treturn $this->description;\n\t }", "function display_custom_info_fields(){\n\t\n\tadd_settings_section(\"section\", \"Virksomhedsinformation\", null, \"theme-options\");\n\n add_settings_field(\"business_name\", \"Virksomhedsnavn\", \"display_business_name_element\", \"theme-options\", \"section\");\n\tadd_settings_field(\"support_phone\", \"Support Telefon\", \"display_support_phone_element\", \"theme-options\", \"section\");\n\tadd_settings_field(\"support_email\", \"Support Email\", \"display_support_email_element\", \"theme-options\", \"section\");\n\tadd_settings_field(\"street_address\", \"Gade\", \"display_street_address_element\", \"theme-options\", \"section\");\n\tadd_settings_field(\"city\", \"By og postnummer\", \"display_city_element\", \"theme-options\", \"section\");\n\n register_setting(\"section\", \"business_name\");\n\tregister_setting(\"section\", \"support_phone\");\n\tregister_setting(\"section\", \"support_email\");\n\tregister_setting(\"section\", \"street_address\");\n\tregister_setting(\"section\", \"city\");\n\t\n}", "Public function displayInfo(){ \r\n\t\t\techo \"The info about the dress.\"; \r\n\t\t\techo $this->color; \r\n\t\t\techo $this->fabric ; \r\n\t\t\techo $this->design;\r\n\t\t\techo self::MEDIUM;\r\n\t\t}", "public static function info_box() {\n\t\tglobal $hook_suffix;\n\n\t\tif ( 'post.php' !== $hook_suffix ) {\n\t\t\treturn;\n\t\t}\n\n\t\tadd_meta_box(\n\t\t\t'munim_estimate_info_box',\n\t\t\t'Quick Info',\n\t\t\t[ __CLASS__, 'render_info_box' ],\n\t\t\t'munim_estimate',\n\t\t\t'side'\n\t\t);\n\t}", "public function info() {\n foreach ($this->items as $item) {\n $item->info();\n }\n }", "public function show(Unit $unit)\n {\n //\n }", "public function show(Unit $unit)\n {\n //\n }", "public function show(Unit $unit)\n {\n //\n }", "public function show(Unit $unit)\n {\n //\n }", "public function getUnitName()\n {\n return $this->unit_name;\n }", "function info(){\n global $tpl, $ilTabs;\n\n $ilTabs->activateTab(\"info\");\n\n $my_tpl = new ilTemplate(\"tpl.info.html\", true, true,\n \"Customizing/global/plugins/Services/Repository/RepositoryObject/MobileQuiz\");\n\n // info text\n $my_tpl->setVariable(\"INFO_TEXT\", $this->txt(\"info_text\"));\n // mail to\n $my_tpl->setVariable(\"MAIL_TO\", $this->txt(\"info_mailto\"));\n // Instructions\n $my_tpl->setVariable(\"INSTRUCTIONS\",$this->txt(\"info_instructions\"));\n\n $html = $my_tpl->get();\n\n $tpl->setContent($html);\n }", "function infoScreenObject()\n\t{\n\t\t$this->ctrl->setCmd(\"showSummary\");\n\t\t$this->ctrl->setCmdClass(\"ilinfoscreengui\");\n\t\t$this->infoScreen();\n\t}", "public function getInfoHtml()\n {\n return $this->getInfoBlock()->toHtml();\n }", "public function info() {\n\t\treturn array (\n\t\t\t\t'text_type' => 'selection',\n\t\t\t\t'module' => 'ZSELEX',\n\t\t\t\t'text_type_long' => $this->__ ( 'Deal Of The Day (DOTD)' ),\n\t\t\t\t'allow_multiple' => true,\n\t\t\t\t'form_content' => false,\n\t\t\t\t'form_refresh' => false,\n\t\t\t\t'show_preview' => true,\n\t\t\t\t'admin_tableless' => true \n\t\t);\n\t}", "function field_details() \n { ?>\n <div class=\"field-details\">\n <?php if($this->setting['type'] != 'radio' && $this->setting['type'] != 'checkbox') : ?><label <?php $this->for_tag(\"inferno-concrete-setting-\"); ?>><?php endif; ?>\n <?php echo $this->setting['desc']; ?>\n <?php if($this->setting['type'] != 'radio' && $this->setting['type'] != 'checkbox') : ?></label><?php endif; ?>\n\n <?php if(isset($this->setting['more']) && $this->setting['more'] != '') : ?>\n <span class=\"more\"><?php echo $this->setting['more']; ?></span>\n <?php endif; ?>\n\n <?php if($this->setting['type'] == 'font') : ?>\n <div class=\"googlefont-desc\">\n <label <?php $this->for_tag(\"inferno-concrete-setting-\", \"-googlefont\"); ?>>\n <?php _e('Enter the Name of the Google Webfont You want to use, for example \"Droid Serif\" (without quotes). Leave blank to use a Font from the selector above.', 'inferno'); ?>\n </label>\n <span class=\"more\">\n <?php _e('You can view all Google fonts <a href=\"http://www.google.com/webfonts\">here</a>. Consider, that You have to respect case-sensitivity. If the font has been successfully recognized, the demo text will change to the entered font.', 'inferno'); ?>\n </span>\n </div>\n <?php endif; ?>\n </div>\n <?php\n }", "public function _info($info){\r\n return array('title'=>$info->full, 'block'=>false);\r\n }", "public function getEquipmentInfo(){\n \treturn array(\n \t\t'code' => 'CF8222', \n \t\t'name' => 'Celltac F Mek 8222', \n \t\t'description' => 'Automatic analyzer with 22 parameters and WBC 5 part diff Hematology Analyzer',\n \t\t'testTypes' => array(\"Full Haemogram\", \"WBC\")\n \t\t);\n }", "public function metabox_content() {\n\t\t\n\t\t\n\t\t\n\t}", "public static function metabox() {\n\t\techo SimpleTags_Admin::getDefaultContentBox();\n\t}", "public function add_metabox() {\n add_meta_box(\n 'customer_info',\n __( 'Customer Info', 'textdomain' ),\n array( $this, 'render_metabox' ),\n 'customer',\n 'advanced',\n 'default'\n );\n\n }", "public function metabox() {\n\n\t\t/**\n\t\t * Initialize the metabox\n\t\t */\n\t\t$cmb = new_cmb2_box( [\n\t\t\t'id' => 'expedia_hotel_data_metabox',\n\t\t\t'title' => __( 'Expedia Hotel Data', 'cmb2' ),\n\t\t\t'object_types' => [ 'hawaii-hotels' ], // Post type\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'low',\n\t\t\t'show_names' => false, // Show field names on the left\n\t\t\t'closed' => true, // Metabox is closed by default\n\t\t\t'show_on_cb' => [ $this, 'excludeFromPages' ],\n\t\t] );\n\t}", "public function getUnit();", "public function dmcinfo() {\n $dmcinfo = [\n 'System Information' => [\n 'Status' => $this->api_version() ? 'Active' : 'Down',\n 'SOAP URL' => $this->soap_url,\n 'API Version' => $this->api_version(),\n 'Build' => $this->ecm_version(),\n 'Available API Functions' => $this->functions(),\n ],\n ];\n\n echo \"<!DOCTYPE html PUBLIC \\\"-//W3C//DTD XHTML 1.0 Transitional//EN\\\" \\\"DTD/xhtml1-transitional.dtd\\\">\\n<html xmlns=\\\"http://www.w3.org/1999/xhtml\\\">\\n<head>\\n<style type=\\\"text/css\\\">\\nbody {background-color: #ffffff; color: #000000;}\\nbody, td, th, h1, h2 {font-family: sans-serif;}\\npre {margin: 0px; font-family: monospace;}\\na:link {color: #000099; text-decoration: none; background-color: #ffffff;}\\na:hover {text-decoration: underline;}\\ntable {border-collapse: collapse;}\\n.center {text-align: center;}\\n.center table { margin-left: auto; margin-right: auto; text-align: left;}\\n.center th { text-align: center !important; }\\ntd, th { border: 1px solid #000000; font-size: 75%; vertical-align:center;}\\nh1 {font-size: 150%;}\\nh2 {font-size: 125%;}\\n.p {text-align: left;}\\n.e {background-color: #000000; font-weight: bold; color: #ffcc00; text-align: right;}\\n.h {background-color: #000000; font-weight: bold; color: #ffcc00;}\\n.v {background-color: #cccccc; color: #000000;}\\n.vr {background-color: #cccccc; text-align: right; color: #000000;}\\nimg {float: right; border: 0px; margin-top: 7px;}\\nhr {width: 600px; background-color: #cccccc; border: 0px; height: 1px; color: #000000;}\\n</style>\\n<title>dmcinfo()</title><meta name=\\\"ROBOTS\\\" content=\\\"NOINDEX,NOFOLLOW,NOARCHIVE\\\" /></head>\\n<body><div class=\\\"center\\\"> <table border=\\\"0\\\" cellpadding=\\\"5\\\" width=\\\"600\\\">\\n<tr class=\\\"h\\\"><td>\\n<a href=\\\"http://api.ecircle.com/\\\"><img border=\\\"0\\\" src=\\\"http://api.ecircle.com/fileadmin/system/img/global/teradata_w137.png\\\" alt=\\\"Teradata Logo\\\" /></a><h1 class=\\\"p\\\">Digital Messaging Center</h1>\\n</td></tr></table><br />\";\n foreach ( $dmcinfo as $name => $section ) {\n echo \"<h3>$name</h3>\\n<table border=\\\"0\\\" cellpadding=\\\"5\\\" width=\\\"600\\\">\\n\";\n foreach ( $section as $key => $val ) {\n if ( is_array( $val ) ) {\n echo \"<tr><td class=\\\"e\\\" valign=\\\"top\\\">$key</td><td class=\\\"v\\\"><ul>\";\n foreach ( $val as $v ) {\n echo \"<li>$v</li>\";\n }\n echo \"</ul></td></tr>\\n\";\n } elseif ( is_string( $key ) ) {\n echo \"<tr><td class=\\\"e\\\">$key</td><td class=\\\"v\\\">$val</td></tr>\\n\";\n } else {\n echo \"<tr><td class=\\\"e\\\">$val</td></tr>\\n\";\n }\n }\n echo \"</table>\\n\";\n }\n echo \"</div></body>\";\n }", "public abstract function showInfo();", "function renderSpaceInfo() {\n\t\treturn \"<br><b>\" . t3lib_div::_GP('title') . \"</b> \" . $GLOBALS['LANG']->getLL('information');\n\t}", "public function getUM()\n {\n $UnitOfMeasure = UnitOfMeasure::find($this->um_id); \n \n return $UnitOfMeasure->description;\n }", "function infoScreenObject()\n\t{\n\t\t$this->checkPermission(\"visible\");\n\t\t$this->ctrl->setCmd(\"showSummary\");\n\t\t$this->ctrl->setCmdClass(\"ilinfoscreengui\");\n\t\t$this->infoScreen();\n\t}", "function wpbm_shortcode_usage_metabox(){\n add_meta_box( 'wpbm_shortcode_usage_option', __( 'WP Blog Manager Usage', WPBM_TD ), array( $this, 'wpbm_shortcode_usage' ), 'wpblogmanager', 'side', 'default' );\n }", "public function getCustomInfo() {\n\t\treturn $this->custom_info;\n\t}", "public function addMetaboxes() {}", "function theme_uom_event_information($variables) {\n $information = $variables['information'];\n $items = array();\n\n $title = t('Contact');\n $attributes = array('class' => array('uom-event-information'));\n $type = 'ul';\n\n if (!empty($information->email)) {\n\t\t$data = '<strong>'. t('Email: '). '</strong>'. l($information->email, 'mailto:' . $information->email);\n $items[] = array(\n 'data' => $data,\n 'class' => array('email'),\n );\n }\n if (!empty($information->phone)) {\n\t\t$data = '<strong>'. t('Phone: '). '</strong>'. ( (module_exists('unimelb_formatters')) ? unimelb_formatters_field_formatter_unimelb_html5_phone_link(array('safe_value' => $information->phone)) : $information->phone );\n $items[] = array(\n 'data' => $data, \n 'class' => array('phone'),\n );\n }\n if (!empty($information->url)) {\n\t\t$data = '<strong>'. t('URL: '). '</strong>'. l($information->url, $information->url); \n $items[] = array(\n 'data' => $data,\n 'class' => array('url'),\n );\n }\n\n return (empty($items)) ? '' : theme_item_list(array('items' => $items, 'title' => $title, 'type' => $type, 'attributes' => $attributes));\n}", "public function plugin_info()\n {\n }", "abstract public function information();", "abstract protected function setup_info();", "public function ms_info_dash() {\n\t\twp_add_dashboard_widget(\n\t\t\t'ms_info_widget', // Widget slug.\n\t\t\t'Multisite Info', // Title.\n\t\t\tarray( $this, 'ms_info_callback' ) // Display function.\n\t\t);\n\t}", "function video_cck_tudou_info() {\n $name = t('Tudou');\n $features = array(\n array(t('Autoplay'), t('No'), ''),\n array(t('RSS Attachment'), t('No'), ''),\n array(t('Thumbnails'), t('No'), t('')),\n );\n return array(\n 'provider' => 'tudou',\n 'name' => $name,\n 'url' => VIDEO_CCK_TUDOU_MAIN_URL,\n 'settings_description' => t('These settings specifically affect videos displayed from !tudou.', array('!tudou' => l($name, VIDEO_CCK_TUDOU_MAIN_URL, array('target' => '_blank')))),\n 'supported_features' => $features,\n );\n}", "public function getInfo()\n {\n $str = \"{$this->judul} | {$this->getLabel()} (Rp. {$this->harga})\";\n\n return $str;\n }", "function add_custom_info_menu_item(){\n\t\n\tadd_options_page(\"Virksomhedsinformation\", \"Virksomhedsinformation\", \"manage_options\", \"contact-info\", \"theme_settings_page\");\n\t\n}", "public function getUnitLabel()\n {\n return $this->unitLabel;\n }", "function faculty_settings_post_info() {\n faculty_setting_line(faculty_add_background_color_setting('post_info_background_color', __('Background', FACULTY_DOMAIN)));\n faculty_setting_line(faculty_add_color_setting('post_info_font_color', __('Font Color', FACULTY_DOMAIN)));\n faculty_setting_line(faculty_add_size_setting('post_info_font_size', __('Font Size', FACULTY_DOMAIN)));\n faculty_setting_line(faculty_add_select_setting('post_info_text_transform', __('Text Transform', FACULTY_DOMAIN), 'transform'));\n do_action('faculty_settings_post_info');\n}", "function thd_re_info_show_box() {\n\tthd_meta_box_callback(thd_re_meta_box_fields(), 'page');\n}", "public static function geoCart_other_detailsDisplay()\n {\n $cart = geoCart::getInstance();\n if (!$cart->item || $cart->item->getType() != self::type) {\n return '';\n }\n parent::$_type = self::type;\n $return = parent::geoCart_other_detailsDisplay();\n if (!$return) {\n //probably not supposed to show this item\n //but still need to set title and stuff if there\n //are others to display\n $return = array('entire_box' => ' ');\n }\n\n $return ['page_title1'] = $cart->site->messages[500419];\n $return ['page_title2'] = $cart->site->messages[500420];\n $return ['page_desc'] = $cart->site->messages[500421];\n $return ['submit_button_text'] = $cart->site->messages[500422];\n $return ['preview_button_txt'] = $cart->site->messages[502086];\n $return ['cancel_text'] = $cart->site->messages[500423];\n\n return $return;\n }", "public function form_field_info ( $args ) {\n\t\t$class = '';\n\t\tif ( isset( $args['data']['class'] ) ) {\n\t\t\t$class = ' ' . esc_attr( $args['data']['class'] );\n\t\t}\n\t\t$html = '<div id=\"' . $args['key'] . '\" class=\"info-box' . $class . '\">' . \"\\n\";\n\t\tif ( isset( $args['data']['name'] ) && ( $args['data']['name'] != '' ) ) {\n\t\t\t$html .= '<h3 class=\"title\">' . esc_html( $args['data']['name'] ) . '</h3>' . \"\\n\";\n\t\t}\n\t\tif ( isset( $args['data']['description'] ) && ( $args['data']['description'] != '' ) ) {\n\t\t\t$html .= '<p>' . esc_html( $args['data']['description'] ) . '</p>' . \"\\n\";\n\t\t}\n\t\t$html .= '</div>' . \"\\n\";\n\n\t\techo $html;\n\t}", "public function mostrarInfo()\n {\n // $datos.= \"Cuatrimestre\".$this->cuatrimestre;\n // return parent::mostrarInfo().\" \".$datos;\n }", "static function metabox($post){\n\t\twp_nonce_field( 'flat-options', 'flat-options_nonce' );\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\t\t\t\t\t\t\t\t\t\t\n\t\techo '<style>';\n\t\techo '.admin-meta-input{display:block; margin-top: 10px;}';\n\t\techo 'div.field-holder{display: block;float: left; margin: 10px 20px; height: 80px;}';\n\t\techo '.field-block{display: inline-block;clear: both;float: none;}';\n\t\techo '.postbox .inside .field-block h2{padding: 8px 12px;font-weight: 600;font-size: 18px;margin: 0;line-height: 1.4}';\n\t\techo '</style>';\n\t\t\t\t\t\n\t\t$fieldblocks = self::get_fields();\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Licitálással kapcsolatos adatok</h2>';\n\t\tforeach ($fieldblocks['licit'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Hely adatok</h2>';\n\t\tforeach ($fieldblocks['location'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Ingatlan adatok és településrendezési előírások</h2>';\n\t\tforeach ($fieldblocks['parameters'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Ingatlanjogi jellemzők</h2>';\n\t\tforeach ($fieldblocks['info'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Közművek, energiaellátás, telekommunikáció</h2>';\n\t\tforeach ($fieldblocks['sources'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\t\t\n\t\t\t\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Építmény (épület) jellemzői</h2>';\n\t\tforeach ($fieldblocks['building'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\techo \"\n\t\t\t<script>\n\t\t\t\tjQuery(document).ready(function(){\n\t\t\t\t\tjQuery('.datepicker').datepicker();\t\n\t\t\t\t});\t\n\t\t\t</script>\t\n\t\t\";\n\t\t\n\t\techo '<br clear=\"all\">';\n\t\t\n }", "function _register_manpower_meta_box_cb()\n{\n\tadd_meta_box(\"admin_manpower\", \"Worker Information\", \"WorkerController::admin_view\", MANPOWER);\n}", "private function showInfo()\n {\n $this->results = array('error' => '');\n $this->countMulticolumnElements();\n $this->findDifferentMCElementConfigs();\n $this->isGridelementsInstalled();\n return $this->returnResults();\n }", "public function info()\n {\n }", "function getInfo()\n {\n $info = parent::info();\n $info['name'] = 'GlossaryFilters';\n $info['class'] = 'org.minervaeurope.museoweb.GlossaryFilters';\n $info['package'] = 'Museo&Web CMS';\n $info['version'] = '1.0.0';\n $info['author'] = 'Daniele Ugoletti, Gruppo Meta';\n $info['author-email'] = '[email protected]';\n $info['url'] = 'http://www.minervaeurope.org';\n return $info;\n }", "public function adminDetails()\n {\n //not much to display for the \"item\" so just display icon\n $txt = DataAccess::getInstance()->get_text(true, 59);\n $title = \"<img src=\\\"../\" . geoTemplate::getUrl('', $txt[500952]) . \"\\\" alt=\\\"\\\" />\";\n return array(\n 'type' => 'Verify Account',\n 'title' => $title\n );\n }", "public static function pageInfoType()\n {\n }", "protected function renderInfo() {\n\t\t$ret = '';\n\t\t$ret .= $this->start( 'table' );\n\t\t$ret .= $this->element( 'caption', 'Elements ($info)' );\n\t\tksort( $this->def->info );\n\t\t$ret .= $this->heavyHeader( 'Allowed tags', 2 );\n\t\t$ret .= $this->start( 'tr' );\n\t\t$ret .= $this->element( 'td', $this->listifyTagLookup( $this->def->info ), array( 'colspan' => 2 ) );\n\t\t$ret .= $this->end( 'tr' );\n\t\tforeach ( $this->def->info as $name => $def ) {\n\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t$ret .= $this->element( 'th', \"<$name>\", array( 'class' => 'heavy', 'colspan' => 2 ) );\n\t\t\t$ret .= $this->end( 'tr' );\n\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t$ret .= $this->element( 'th', 'Inline content' );\n\t\t\t$ret .= $this->element( 'td', $def->descendants_are_inline ? 'Yes' : 'No' );\n\t\t\t$ret .= $this->end( 'tr' );\n\t\t\tif ( ! empty( $def->excludes ) ) {\n\t\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t\t$ret .= $this->element( 'th', 'Excludes' );\n\t\t\t\t$ret .= $this->element( 'td', $this->listifyTagLookup( $def->excludes ) );\n\t\t\t\t$ret .= $this->end( 'tr' );\n\t\t\t}\n\t\t\tif ( ! empty( $def->attr_transform_pre ) ) {\n\t\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t\t$ret .= $this->element( 'th', 'Pre-AttrTransform' );\n\t\t\t\t$ret .= $this->element( 'td', $this->listifyObjectList( $def->attr_transform_pre ) );\n\t\t\t\t$ret .= $this->end( 'tr' );\n\t\t\t}\n\t\t\tif ( ! empty( $def->attr_transform_post ) ) {\n\t\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t\t$ret .= $this->element( 'th', 'Post-AttrTransform' );\n\t\t\t\t$ret .= $this->element( 'td', $this->listifyObjectList( $def->attr_transform_post ) );\n\t\t\t\t$ret .= $this->end( 'tr' );\n\t\t\t}\n\t\t\tif ( ! empty( $def->auto_close ) ) {\n\t\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t\t$ret .= $this->element( 'th', 'Auto closed by' );\n\t\t\t\t$ret .= $this->element( 'td', $this->listifyTagLookup( $def->auto_close ) );\n\t\t\t\t$ret .= $this->end( 'tr' );\n\t\t\t}\n\t\t\t$ret .= $this->start( 'tr' );\n\t\t\t$ret .= $this->element( 'th', 'Allowed attributes' );\n\t\t\t$ret .= $this->element( 'td', $this->listifyAttr( $def->attr ), array(), 0 );\n\t\t\t$ret .= $this->end( 'tr' );\n\n\t\t\tif ( ! empty( $def->required_attr ) ) {\n\t\t\t\t$ret .= $this->row( 'Required attributes', $this->listify( $def->required_attr ) );\n\t\t\t}\n\n\t\t\t$ret .= $this->renderChildren( $def->child );\n\t\t}\n\t\t$ret .= $this->end( 'table' );\n\n\t\treturn $ret;\n\t}", "public function getBarUnit() {\n return $this->cBarUnit;\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}", "function Units($args=array())\n {\n $this->Hash2Object($args);\n $this->AlwaysReadData=array(\"Name\");\n $this->Sort=array(\"Name\");\n $this->IDGETVar=\"Unit\";\n $this->UploadFilesHidden=FALSE;\n }", "public function getInfo ()\n {\n return $this->info;\n }", "protected function getInfoScreenHTML()\n {\n require_once('./Services/InfoScreen/classes/class.ilInfoScreenGUI.php');\n $info = new ilInfoScreenGUI(null);\n $mappings = array_filter(MetadataService::getInstance()->getMappings($this->ctrl->getContextObjType()), function (ilObjectMapping $mapping) : bool {\n return MetadataService::getInstance()->canBeShow($this->getObject(), $mapping, MetadataService::SHOW_CONTEXT_SHOW_INFO_SCREEN);\n });\n if (!count($mappings)) {\n return '';\n }\n $query = new RecordQuery($this->getObject());\n foreach ($mappings as $mapping) {\n foreach ($mapping->getFieldGroups() as $group) {\n $records = array_map(function ($field_id) use ($query, $group) {\n $field = Field::find($field_id);\n\n return $query->getRecord($group, $field);\n }, $mapping->getShowInfoFieldIds($group->getId()));\n $records = array_filter($records, function ($record) { return $record !== null; });\n if (!count($records)) {\n continue;\n }\n $info->addSection($group->getTitle($this->user->getLanguage()));\n foreach ($records as $record) {\n $info->addProperty($record->getField()->getLabel($this->user->getLanguage()), $record->getFormattedValue());\n }\n }\n }\n\n return $info->getHtml();\n }", "public function getInfo()\n\t{\n\t\treturn $this->info;\n\t}", "public function getInfo()\n\t{\n\t\treturn $this->info;\n\t}", "function infoScreen()\n\t{\n\t\t$this->ctrl->setCmd(\"showSummary\");\n\t\t$this->ctrl->setCmdClass(\"ilinfoscreengui\");\n\t\t$this->infoScreenForward();\n\t}", "public function build_info_element($form_field, $data=null)\r\n\t\t{\r\n\t\t\t$res = '';\r\n\t\t\tswitch ($form_field->get_type()) {\r\n\t\t\t\tcase Column::$COLUMN_TYPE_TEXTAREA:\r\n\t\t\t\t\t$res = Component::base_info_column(\r\n\t\t\t\t\t\t$form_field->get_name(),\r\n\t\t\t\t\t\tisset(\t$data[$form_field->get_table_field_name()] ) ? $data[$form_field->get_table_field_name()]:'',\r\n\t\t\t\t\t\t$form_field->get_label()\r\n\t\t\t\t\t);\r\n\t\t\t\t\tbreak;\r\n\t\t\t\tcase Column::$COLUMN_TYPE_SELECT:\r\n\t\t\t\t\t$res = Component::base_info_column(\r\n\t\t\t\t\t\t$form_field->get_name(),\r\n\t\t\t\t\t\tisset(\t$data[$form_field->get_table_field_name()] ) ? $data[$form_field->get_table_field_name()]:'',\r\n\t\t\t\t\t\t$form_field->get_label()\r\n\t\t\t\t\t);\r\n\t\t\t\t\tbreak;\r\n\t\r\n\t\t\t\t// case Column::$COLUMN_TYPE_ICONPICKER:\r\n\t\t\t\t// \t$res = Component::icon_picker(\r\n\t\t\t\t// \t\t$form_field->get_name(),\r\n\t\t\t\t// \t\tisset(\t$data[$form_field->get_table_field_name()] ) ? $data[$form_field->get_table_field_name()]:'',\r\n\t\t\t\t// \t\t$form_field->get_label()\r\n\t\t\t\t// \t);\r\n\t\t\t\t// \tbreak;\r\n\t\t\t\tcase Column::$COLUMN_TYPE_PHOTO:\r\n\t\t\t\t\t$res = Component::show_image(\r\n\t\t\t\t\t\t$form_field->get_name(),\r\n\t\t\t\t\t\tisset(\t$data[$form_field->get_table_field_name()] ) ? $data[$form_field->get_table_field_name()]:''\r\n\t\t\t\t\t);\r\n\t\t\t\t\tbreak;\r\n\t\t\t\t\t// case Column::$COLUMN_TYPE_FILE:\r\n\t\t\t\t\t// $res = Component::file_upload(\r\n\t\t\t\t\t// \t$form_field->get_name(),\r\n\t\t\t\t\t// \tisset(\t$data[$form_field->get_table_field_name()] ) ? $data[$form_field->get_table_field_name()]:'',\r\n\t\t\t\t\t// \t$form_field->get_label(),\r\n\t\t\t\t\t// \t$form_field->get_file_type(),\r\n\t\t\t\t\t// \t$form_field->get_field_html()\r\n\t\t\t\t\t// );\r\n\t\t\t\t\t// break;\r\n\t\t\t\tcase Column::$COLUMN_TYPE_TEXT:\r\n\t\t\t\tcase Column::$COLUMN_TYPE_DATE:\r\n\t\t\t\tcase Column::$COLUMN_TYPE_EMAIL:\r\n\t\t\t\tcase Column::$COLUMN_TYPE_HIDDEN:\r\n\t\t\t\tcase Column::$COLUMN_TYPE_NUMBER:\r\n\t\t\t\tcase Column::$COLUMN_TYPE_PASS:\r\n\t\t\t\tdefault:\r\n\t\t\t\t\t$res = Component::base_info_column(\r\n\t\t\t\t\t\t$form_field->get_name(),\r\n\t\t\t\t\t\tisset(\t$data[$form_field->get_table_field_name()] ) ? $data[$form_field->get_table_field_name()]:'',\r\n\t\t\t\t\t\t$form_field->get_label()\r\n\t\t\t\t\t);\r\n\t\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t\treturn $res;\r\n\t\t}", "public function getInformation()\n {\n return $this->values[\"info\"];\n }", "public function info()\n {\n return array(\n 'module' => $this->name,\n 'text_type' => __('Show page'),\n 'text_type_long' => __('Show a page in a block'),\n 'allow_multiple' => true,\n 'form_content' => false,\n 'form_refresh' => false,\n 'show_preview' => true,\n 'admin_tableless' => true\n );\n }", "public function CltvoDisplayMetabox( $object ){ ?>\n <?php for ($i=0; $i < 2; $i++): ?>\n <div style=\"display: inline-block; width:48%; margin-right: 2%\">\n <p><label>Texto:</label></p>\n <textarea class=\"\" style=\"width:100%;\" name='<?php echo \"$this->meta_key[$i][texto]\";?>'><?php echo $this->meta_value[$i]['texto'];?></textarea>\n </div><div style=\"display: inline-block; width:48%; margin-right: 2%\">\n <p><label>Código de botón de PayPal:</label></p>\n <textarea class=\"\" style=\"width:100%;\" name='<?php echo \"$this->meta_key[$i][boton]\";?>'><?php echo $this->meta_value[$i]['boton'];?></textarea>\n </div>\n <?php endfor; ?>\n\n <?php\n\t}", "public function info();", "public function info();", "public function getElUnit() {\n return $this->cElUnit;\n }", "function viewInfo() {\n\t$view = new viewModel();\n\t$view->showInfo();\t\n}", "public function getInfo()\n {\n return $this->addAction(Flag::getInfo());\n }", "public function getUnit()\n\t{\n\t\treturn null;\n\t}", "public function component_info() {\n return array(\n 'name' => 'Accessibility Content Utility',\n 'description' => 'Add utility functions to Content for Accessibility',\n 'category' => 'accessibility',\n );\n }", "function metaboxes_output( $post, $metabox, $data ) {\n\n\t\tswitch ( $metabox ): case 'example-metabox': ?>\n\t\n\t\t\t<p>\n\t <label for=\"description\">Post Type Description:</label>\n\t <input id=\"description\" class=\"widefat\" type=\"text\" name=\"description\" value=\"<?php echo esc_attr( $data['description'] ); ?>\">\n\t </p>\n\n\t <p>\n\t <label for=\"date\">Post Type Date:</label>\n\t <input id=\"date\" class=\"widefat\" type=\"date\" name=\"date\" value=\"<?php echo esc_attr( $data['date'] ); ?>\">\n\t </p>\n\n\t\t<?php break;\n\n\t\tendswitch;\n\n\t}", "public function getCidSystemInfo() {}", "public function getInfo(){ \n return $this->title .' ('. $this->year . ')';\n }", "function render_currency_meta() {\n\n\t\t?>\n\t\t<p><label for=\"country_symbol\" style=\"width:145px; margin-top:6px; float:left; display: block\"><?php _e( 'Currency', 'countries' ); ?></label> <input class=\"regular-text\" name=\"country_currency\" value=\"<?php ?>\" /></p>\n\t<?php\n\t}", "abstract public function getUnitOfMaterial(): string;", "public function showSpecs()\n {\n return $this->name . \" includes a \" . $this->chipset . \" chipset and \" . $this->internalMemory . \"GB of internal memory\";\n }", "public function getMeternumber()\n {\n return $this->meternumber;\n }", "public function show(MeasureUnit $measureUnit)\n {\n //\n }", "function info() {\n global $_TABLE, $_ADMIN;\n if(!isset($_POST['window'])) exit();\n\n $_MODULE['output'] = '[';\n $_MODULE['output'] .= '{';\n $_MODULE['output'] .= 'run:\"getware.ui.content.info.add\",';\n $_MODULE['output'] .= 'window:\"'.$_POST['window'].'\",';\n\n $rows = 'rows:[';\n $data = 'data:[';\n for($i = $_ADMIN['ini']; $i < $_ADMIN['end']; $i++) {\n # GENERA LOS POST QUE NO EXISTEN\n if($this->restrict($i))\n $value = 1;\n else $value = 0;\n\n $rows .= '\"' . $i . '\"';\n $data .= '\"' . $value . '\"';\n if($i < $_ADMIN['end'] - 1) {\n $rows .= ',';\n $data .= ',';\n }\n }\n $rows .= '],';\n $data .= ']';\n\n $_MODULE['output'] .= $rows;\n $_MODULE['output'] .= $data;\n\n $_MODULE['output'] .= '}';\n $_MODULE['output'] .= ']';\n //exit($_MODULE['output']);\n if(preg_match('/\"0\"/', $_MODULE['output']))\n exit($_MODULE['output']);\n else return true;\n}", "public function renderInfoDevice()\n {\n $name = array();\n \n if ($this->device_family)\n {\n if ($this->device_version)\n {\n if ('-' == substr($this->device_version, 0, 1))\n {\n return $this->device_family . $this->device_version;\n }\n \n return $this->device_family . ' ' . $this->device_version;\n }\n \n return $this->device_family;\n }\n \n if ($this->device_version)\n {\n return $this->device_version;\n }\n \n return '';\n }", "protected function _getUnitsPerEm() {}", "protected function renderInformationContent() {}", "public function getInfo()\r\n {\r\n return $this->info;\r\n }", "function et_divi_post_meta() {\n\t\t$pages = array(\n\t\t\tintval( \\SermonManager::getOption( 'smp_archive_page', 0 ) ),\n\t\t\tintval( \\SermonManager::getOption( 'smp_tax_page', 0 ) ),\n\t\t);\n\t\tif ( in_array( get_the_ID(), $pages ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$postinfo = is_single() ? et_get_option( 'divi_postinfo2' ) : et_get_option( 'divi_postinfo1' );\n\n\t\tif ( $postinfo ) :\n\t\t\techo '<p class=\"post-meta\">';\n\t\t\techo et_pb_postinfo_meta( $postinfo, et_get_option( 'divi_date_format', 'M j, Y' ), esc_html__( '0 comments', 'Divi' ), esc_html__( '1 comment', 'Divi' ), '% ' . esc_html__( 'comments', 'Divi' ) );\n\t\t\techo '</p>';\n\t\tendif;\n\t}", "function onCustomInfo(&$man, &$file, $type, &$custom) {\r\n\t\treturn true;\r\n\t}", "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}", "function showBasicInfo($data){\n $sym = $data[\"Symbol\"];\n\n $symbol = getInfo($sym);\n\n return $symbol;\n}", "public function adminDetails()\n {\n //other items.\n return array(\n 'type' => 'Tokens Purchased',\n 'title' => $this->get('tokens') . ' Tokens Purchased.'\n );\n }", "public function display_meta_box() {\n\t\t\n\t\tinclude_once( 'views/q-and-a-admin.php' );\n }", "public static function displayUnitInformation($unitid, $user)\n {\n\n $unit = ArmyDB::retrieveUnit($unitid);\n\n //var_dump($unit);\n\n $unitname = $unit['name'];\n\n $unitqty = $unit['qty'];\n\n $unitpts = $unit['pts'];\n if ($unitpts == 1) {\n $pts = \"pt\";\n } else {\n $pts = \"pts\";\n }\n\n $unitstatus = $unit['status'];\n if ($unitstatus == 0) {\n $assembleStatus = 0;\n $baseStatus = 0;\n $paintStatus = 0;\n } else {\n $statusArray = str_split($unitstatus);\n $assembleStatus = $statusArray[0];\n $baseStatus = $statusArray[1];\n $paintStatus = $statusArray[2];\n }\n\n $unitprojectid = $unit['projectid'];\n\n $unitdateadded = $unit['date_added'];\n if (isset($unit['date_edited'])) {\n $unitdateedited = $unit['date_edited'];\n } else {\n $unitdateedited = null;\n }\n\n $unitnotes = $unit['notes'];\n if (empty($unitnotes)) {\n $unitnotes = \"No notes entered yet.\";\n }\n $unitnotes = preg_replace('/\\n(\\s*\\n)+/', '</p><p>', $unitnotes);\n $unitnotes = preg_replace('/\\n/', '<br>', $unitnotes);\n $unitnotes = '<p>' . $unitnotes . '</p>';\n\n $project = ArmyDB::retrieveProjectInfo($unitprojectid);\n $projectname = $project['projectname'];\n $battlegroup = $project['battlegroup'];\n $projectowner = $project['username'];\n\n echo \"<div class='row'>\";\n echo \"<div class='col-xs-12 col-md-6' id='unitinfo'>\";\n echo \"<h1>$unitqty $unitname ($unitpts\" . $pts . \")</h1>\";\n echo \"<h4><em><a href='project.php?id=\" . $unitprojectid . \"'>$projectname</a> - $battlegroup</em></h4>\";\n\n echo \"<p>$unitnotes</p>\";\n\n echo \"<h2>Status</h2>\";\n echo \"<ul>\";\n echo \"<li>Assembly: \" . ArmyDB::convertStatusToText($assembleStatus, \"assemble\") . \"</li>\";\n echo \"<li>Painting: \" . ArmyDB::convertStatusToText($paintStatus, \"paint\") . \"</li>\";\n echo \"<li>Basing : \" . ArmyDB::convertStatusToText($baseStatus, \"base\") . \"</li>\";\n echo \"<li>Date added: $unitdateadded</li>\";\n if (!is_null($unitdateedited)) {\n echo \"<li>Date added: $unitdateedited</li>\";\n }\n echo \"</ul>\";\n\n echo \"<div class='btn-group' role='group'>\";\n if ($projectowner == $user) {\n echo \"<button type='button' class='btn btn-warning btn-lg' data-toggle='modal' data-target='#editUnit'>Edit Unit</button>\";\n echo \"<button type='button' class='btn btn-danger btn-lg' data-toggle='modal' data-target='#deleteUnit'>Delete Unit</button>\";\n\n // edit Unit\n echo \"<div id='editUnit' class='modal fade' role='dialog'>\";\n echo \"<div class='modal-dialog'>\";\n\n echo \"<div class='modal-content'>\";\n echo \"<div class='modal-header'>\";\n echo \"<button type='button' class='close' data-dismiss='modal'>&times;</button>\";\n echo \"<h4 class='modal-title'>Edit Unit</h4>\";\n echo \"</div>\";\n echo \"<form role='form' method='post' action='action.php'>\";\n echo \"<div class='modal-body'>\";\n\n echo \"<div class='form-group'>\";\n echo \"<label for='qty'>Quantity:</label>\";\n echo \"<input type='text' class='form-control' id='qty' name='qty' value='\" . $unitqty . \"'>\";\n echo \"</div>\";\n\n echo \"<div class='form-group'>\";\n echo \"<label for='unitname'>Unit Name:</label>\";\n echo \"<input type='text' class='form-control' id='unitname' name='unitname' value='\" . $unitname . \"'>\";\n echo \"</div>\";\n\n echo \"<div class='form-group'>\";\n echo \"<label for='qty'>Points</label>\";\n echo \"<input type='text' class='form-control' id='pts' name='pts' value='\" . $unitpts . \"'>\";\n echo \"</div>\";\n echo \"<div class='form-group'>\";\n echo \"<label for='assembleStatus'>Assembly Status</label>\";\n echo \"<select id='assembleStatus' name='assembleStatus' class='form-control'>\";\n switch ($assembleStatus) {\n case 0:\n echo \"<option value='0' selected>Unassembled</option>\";\n echo \"<option value='1'>Partially Assembled</option>\";\n echo \"<option value='2'>Assembled</option>\";\n break;\n case 1:\n echo \"<option value='0'>Unassembled</option>\";\n echo \"<option value='1' selected>Partially Assembled</option>\";\n echo \"<option value='2'>Assembled</option>\";\n break;\n case 2:\n echo \"<option value='0'>Unassembled</option>\";\n echo \"<option value='1'>Partially Assembled</option>\";\n echo \"<option value='2' selected>Assembled</option>\";\n break;\n default:\n echo \"<option value='0'>Unassembled</option>\";\n echo \"<option value='1'>Partially Assembled</option>\";\n echo \"<option value='2'>Assembled</option>\";\n break;\n }\n echo \"</select>\";\n echo \"<label for='paintStatus'>Painting Status</label>\";\n echo \"<select id='paintStatus' name='paintStatus' class='form-control'>\";\n switch ($paintStatus) {\n case 0:\n echo \"<option value='0' selected>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 1:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1' selected>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 2:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2' selected>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 3:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3' selected>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 4:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4' selected>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n case 5:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5' selected>Detail Highlight</option>\";\n break;\n default:\n echo \"<option value='0'>Bare</option>\";\n echo \"<option value='1'>Primed</option>\";\n echo \"<option value='2'>Basecoat</option>\";\n echo \"<option value='3'>Shade / Washed</option>\";\n echo \"<option value='4'>Basic Highlight</option>\";\n echo \"<option value='5'>Detail Highlight</option>\";\n break;\n }\n echo \"</select>\";\n echo \"<label for='baseStatus'>Basing Status</label>\";\n echo \"<select id='baseStatus' name='baseStatus' class='form-control'>\";\n switch ($baseStatus) {\n case 0:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n case 1:\n echo \"<option value='0'>Not based</option>\";\n echo \"<option value='1' selected>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n case 2:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2' selected>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n case 3:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3' selected>Highlighted basing</option>\";\n break;\n default:\n echo \"<option value='0' selected>Not based</option>\";\n echo \"<option value='1'>Bare basing</option>\";\n echo \"<option value='2'>Painting basing</option>\";\n echo \"<option value='3'>Highlighted basing</option>\";\n break;\n }\n echo \"</select>\";\n echo \"</div>\";\n echo \"<div class='form-group'>\";\n echo \"<label for='unitnotes'>Unit Notes</label>\";\n echo \"<textarea class='form-control' rows='10' id='unitnotes' name='unitnotes'>$unitnotes</textarea>\";\n echo \"</div>\";\n echo \"<input type='hidden' name='action' value='editUnit'>\";\n echo \"<input type='hidden' name='unitid' value='\" . $unitid . \"'>\";\n\n\n echo \"</div>\";\n echo \"<div class='modal-footer'>\";\n echo \"<input type='submit' class='btn btn-warning' value='Submit Edits!'></td>\";\n echo \"</div>\";\n echo \"</form>\";\n echo \"</div>\";\n\n echo \"</div>\";\n echo \"</div>\";\n\n // modal form for deleting units! //\n\n echo \"<div id='deleteUnit' class='modal fade' role='dialog'>\";\n echo \"<div class='modal-dialog'>\";\n\n echo \"<div class='modal-content'>\";\n echo \"<div class='modal-header'>\";\n echo \"<button type='button' class='close' data-dismiss='modal'>&times;</button>\";\n echo \"<h4 class='modal-title'>Delete Unit</h4>\";\n echo \"</div>\";\n echo \"<form role='form' method='post' action='action.php'>\";\n echo \"<div class='modal-body'>\";\n echo \"<p>Are you sure?</p>\";\n echo \"</div>\";\n echo \"<div class='modal-footer'>\";\n echo \"<form role='form' id='deleteUnit' method='post' action='action.php'>\";\n echo \"<div class='btn-group' role='group' aria-label='...'>\";\n echo \"<button type='button' class='btn btn-default' data-dismiss='modal'>Close</button>\";\n echo \"<input type='submit' class='btn btn-danger' value='Delete Unit!'></td>\";\n echo \"<input type='hidden' name='action' value='deleteUnit'>\";\n echo \"<input type='hidden' name='id' value='\" . $unitid . \"'><input type='hidden' name='projectid' value='\" . $unitprojectid . \"'>\";\n echo \"</div>\";\n echo \"</form>\";\n echo \"</div>\";\n echo \"</div>\";\n echo \"</div>\";\n echo \"</div>\";\n } else {\n echo \"<button type='button' class='btn btn-default btn-lg' data-toggle='modal' data-target='#editUnit' disabled>Edit Unit</button>\";\n echo \"<button type='button' class='btn btn-default btn-lg' data-toggle='modal' data-target='#deleteUnit' disabled>Delete Unit</button>\";\n }\n\n echo \"</div><!-- buttongroup -->\";\n echo \"</div><!-- unitinfo -->\";\n\n echo \"<div class='col-xs-12 col-md-6' id='image'>\";\n echo \"<img src='http://placehold.it/480x320' class='img-responsive pull-right' alt='placeholder'>\";\n\n echo \"</div><!-- image -->\";\n\n echo \"</div><!-- row -->\";\n ArmyForm::displayNotes($unitprojectid, $unitid);\n\n\n }", "function fontunit($args) {\r\n\t\t$args['selections'] = array('px'=>'px','pt'=>'pt', 'em'=>'em');\r\n\t\t$args['multiple'] = false;\r\n\t\t$args['width'] = '60';\r\n\t\t$args['tooltip'] = 'Choose the units';\r\n\t\t$this->select($args);\r\n\t}", "function display_sku_as_meta_data( $item, $order ) {\n\t\t\t$product = BEWPI_WC_Order_Compatibility::get_product( $order, $item );\n\t\t\t$sku = $product && BEWPI_WC_Product_Compatibility::get_prop( $product, 'sku' ) ? BEWPI_WC_Product_Compatibility::get_prop( $product, 'sku' ) : '-';\n\t\t\t?>\n\t\t\t<br>\n\t\t\t<ul>\n\t\t\t\t<li>\n\t\t\t\t\t<strong><?php esc_html_e( 'SKU:', 'woocommerce-pdf-invoices' ); ?></strong> <?php echo esc_html( $sku ); ?>\n\t\t\t\t</li>\n\t\t\t</ul>\n\t\t\t<?php\n\t\t}", "function info()\n\t{\n\t\treturn array();\n\t}" ]
[ "0.5899533", "0.58829147", "0.580986", "0.5758899", "0.57541895", "0.57413524", "0.5710687", "0.5671115", "0.5655343", "0.5647553", "0.56285274", "0.5598593", "0.5598593", "0.5598593", "0.5598593", "0.55816936", "0.5529929", "0.5512613", "0.5510243", "0.5502074", "0.5479294", "0.5467951", "0.54258454", "0.54072815", "0.5391585", "0.53710496", "0.53674495", "0.5364608", "0.5350174", "0.53467125", "0.53402686", "0.5339707", "0.53364354", "0.5323747", "0.53121597", "0.5311921", "0.5309816", "0.529833", "0.52823865", "0.5266107", "0.5256692", "0.5255081", "0.52520335", "0.5238272", "0.5234287", "0.5229581", "0.5224829", "0.52164423", "0.52158827", "0.5215618", "0.5208065", "0.5205682", "0.52028525", "0.5199555", "0.5197453", "0.5194035", "0.51805574", "0.51744914", "0.51727986", "0.51665866", "0.5166471", "0.5165992", "0.5161768", "0.5160269", "0.5160269", "0.5160029", "0.5156523", "0.515434", "0.51541996", "0.514784", "0.5143118", "0.5143118", "0.5137378", "0.513311", "0.51300853", "0.51249933", "0.5113318", "0.51110744", "0.51103437", "0.511017", "0.5103104", "0.5101804", "0.5098142", "0.50968003", "0.50955826", "0.50904053", "0.5089338", "0.50836086", "0.50820035", "0.5076894", "0.5075764", "0.50738865", "0.5068179", "0.5064481", "0.5052236", "0.5046354", "0.50449103", "0.50347406", "0.503235", "0.5028883" ]
0.76001644
0
Includes the unit maps metabox code.
function _display_maps_meta( $post ) { include( 'includes/metaboxes/maps.php' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function _display_unitinfo_meta( $post ) {\n\t\tinclude( 'includes/metaboxes/unit-info.php' );\n\t}", "function add_meta_boxes() {\n\t\tif( function_exists( 'add_meta_box' ) ) {\n\t\t\tadd_meta_box( 'unit-info', __('Unit Information'), array( $this, '_display_unitinfo_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'maps', __('Maps'), array( $this, '_display_maps_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'gallery', __('Gallery'), array( $this, '_display_gallery_meta'), 'units', 'normal', 'low');\n\t\t\tadd_meta_box( 'unit-status', __('Availability'), array( $this, '_display_status_meta'), 'units', 'side', 'high');\n\t\t}\n\t}", "function section__map(){\n return array(\n 'content'=>\"<div style='width:300px; height:300px' style='\n margin-left:auto; margin-right:auto;' id='map'></div>\",\n 'class'=>'main',\n 'label'=>'Map',\n 'order'=>'1'\n );\n }", "function country_meta_boxes() {\n\t\t//add_meta_box( 'countries_meta', __( 'Quick link - All Countries', 'countries' ), array( $this, 'render_countries_meta' ), 'countries', 'side', 'low' );\n\t\tadd_meta_box( 'countrycode_meta', __( 'Country', 'countries' ), array( $this, 'render_countrycode_meta' ), 'countries', 'normal', 'low' );\n\t\t}", "public function addMetaboxes() {}", "function cspm_add_locations_metabox(){\r\n\t\t\t\r\n\t\t\t/**\r\n\t\t\t * Add Locations Metabox options */\r\n\t\t\t \r\n\t\t\t$cspm_add_locations_metabox_options = array(\r\n\t\t\t\t'id' => $this->metafield_prefix . '_add_locations_metabox',\r\n\t\t\t\t'title' => esc_attr__( 'Progress Map: Add locations', 'cspm' ),\r\n\t\t\t\t'object_types' => isset($this->plugin_settings['post_types']) ? $this->plugin_settings['post_types'] : array(), // Post types\r\n\t\t\t\t'priority' => 'high',\r\n\t\t\t\t//'context' => 'side',\r\n\t\t\t\t'show_names' => true, // Show field names on the left\t\t\r\n\t\t\t\t'closed' => false,\t\t\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\t\t/**\r\n\t\t\t\t * Create post type Metabox */\r\n\t\t\t\t \r\n\t\t\t\t$cspm_add_locations_metabox = new_cmb2_box( $cspm_add_locations_metabox_options );\r\n\r\n\t\t\t\t/**\r\n\t\t\t\t * Display Add Locations Metabox fields */\r\n\t\t\t\r\n\t\t\t\t$this->cspm_add_locations_tabs($cspm_add_locations_metabox, $cspm_add_locations_metabox_options);\r\n\t\t\t\r\n\t\t}", "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 function metabox() {\n\n\t\t/**\n\t\t * Initialize the metabox\n\t\t */\n\t\t$cmb = new_cmb2_box( [\n\t\t\t'id' => 'expedia_hotel_data_metabox',\n\t\t\t'title' => __( 'Expedia Hotel Data', 'cmb2' ),\n\t\t\t'object_types' => [ 'hawaii-hotels' ], // Post type\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'low',\n\t\t\t'show_names' => false, // Show field names on the left\n\t\t\t'closed' => true, // Metabox is closed by default\n\t\t\t'show_on_cb' => [ $this, 'excludeFromPages' ],\n\t\t] );\n\t}", "function rng_METANAME_metabox_init() {\n}", "public function getMap() {\n return [\n 'sku' => 'itemNo',\n 'shortDescription' => 'description',\n 'longDescription' => 'description2',\n 'measurementUnit' => 'unitOfMeasure',\n 'mpn' => 'vendorItemNo',\n 'ean' => 'eanNo',\n ];\n }", "function fiorello_mikado_meta_boxes_map_after_setup_theme() {\n\t\tdo_action( 'fiorello_mikado_action_before_meta_boxes_map' );\n\t\t\n\t\tforeach ( glob( MIKADO_FRAMEWORK_ROOT_DIR . '/admin/meta-boxes/*/map.php' ) as $meta_box_load ) {\n\t\t\tinclude_once $meta_box_load;\n\t\t}\n\t\t\n\t\tdo_action( 'fiorello_mikado_action_meta_boxes_map' );\n\t\t\n\t\tdo_action( 'fiorello_mikado_action_after_meta_boxes_map' );\n\t}", "function meta_box($post) {\r\n\t\t$map = get_post_meta($post->ID, '_mapp_map', true);\r\n\t\t$pois = get_post_meta($post->ID, '_mapp_pois', true);\r\n\r\n\t\t// Load the edit map\r\n\t\t// Note that mapTypes is hardcoded = TRUE (so user can change type, even if not displayed in blog)\r\n\t\t$map['maptypes'] = 1;\r\n\t\t$this->map($map, $pois, true);\r\n\r\n\t\t// The <div> will be filled in with the list of POIs\r\n\t\t//echo \"<div id='admin_poi_div'></div>\";\r\n\t}", "function shortcode_map() {\r\n\t\t\tif ( !function_exists( 'vc_map' ) ) {\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\r\n\t\t\t$base = array(\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_preset',\r\n\t\t\t\t\t'heading' => __( 'Main Preset', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'preset',\r\n\t\t\t\t\t'tooltip' => MPC_Helper::style_presets_desc(),\r\n\t\t\t\t\t'value' => '',\r\n\t\t\t\t\t'shortcode' => $this->shortcode,\r\n\t\t\t\t\t'description' => __( 'Choose preset or create new one.', 'mpc' ),\r\n\t\t\t\t),\r\n\t\t\t);\r\n\r\n\t\t\t/* Properties List */\r\n\t\t\t$properties = array(\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_divider',\r\n\t\t\t\t\t'title' => __( 'List of Properties', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'properties_divider',\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_split',\r\n\t\t\t\t\t'heading' => __( 'Properties', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'properties',\r\n\t\t\t\t\t'admin_label' => true,\r\n\t\t\t\t\t'tooltip' => __( 'Define properties values. Each new line will be a separate property.', 'mpc' ),\r\n\t\t\t\t\t'value' => '',\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'dropdown',\r\n\t\t\t\t\t'heading' => __( 'Transform', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'properties_font_transform',\r\n\t\t\t\t\t'tooltip' => __( 'Select properties transform style.', 'mpc' ),\r\n\t\t\t\t\t'value' => array(\r\n\t\t\t\t\t\t'' => '',\r\n\t\t\t\t\t\t__( 'Capitalize', 'mpc' ) => 'capitalize',\r\n\t\t\t\t\t\t__( 'Small Caps', 'mpc' ) => 'small-caps',\r\n\t\t\t\t\t\t__( 'Uppercase', 'mpc' ) => 'uppercase',\r\n\t\t\t\t\t\t__( 'Lowercase', 'mpc' ) => 'lowercase',\r\n\t\t\t\t\t\t__( 'None', 'mpc' ) => 'none',\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'std' => '',\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-6 vc_column mpc-advanced-field',\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'dropdown',\r\n\t\t\t\t\t'heading' => __( 'Alignment', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'properties_font_align',\r\n\t\t\t\t\t'tooltip' => __( 'Select properties alignment.', 'mpc' ),\r\n\t\t\t\t\t'value' => array(\r\n\t\t\t\t\t\t'' => '',\r\n\t\t\t\t\t\t__( 'Left', 'mpc' ) => 'left',\r\n\t\t\t\t\t\t__( 'Right', 'mpc' ) => 'right',\r\n\t\t\t\t\t\t__( 'Center', 'mpc' ) => 'center',\r\n\t\t\t\t\t\t__( 'Justify', 'mpc' ) => 'justify',\r\n\t\t\t\t\t\t__( 'Default', 'mpc' ) => 'inherit',\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'std' => '',\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-6 vc_column mpc-advanced-field',\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'colorpicker',\r\n\t\t\t\t\t'heading' => __( 'Color', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'properties_font_color',\r\n\t\t\t\t\t'tooltip' => __( 'Define properties color.', 'mpc' ),\r\n\t\t\t\t\t'value' => '',\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-4 vc_column',\r\n\t\t\t\t),\r\n\t\t\t);\r\n\r\n\t\t\t$properties_even_background = MPC_Snippets::vc_background( array( 'prefix' => 'prop_even', 'subtitle' => __( 'Even Properties', 'mpc' ) ) );\r\n\r\n\t\t\t$class = MPC_Snippets::vc_class();\r\n\r\n\t\t\t$params = array_merge(\r\n\t\t\t\t$base,\r\n\r\n\t\t\t\t$properties,\r\n\t\t\t\t$properties_even_background,\r\n\t\t\t\t$class\r\n\t\t\t);\r\n\r\n\t\t\treturn array(\r\n\t\t\t\t'name' => __( 'Pricing Legend', 'mpc' ),\r\n\t\t\t\t'description' => __( 'Pricing table legend', 'mpc' ),\r\n\t\t\t\t'base' => 'mpc_pricing_legend',\r\n\t\t\t\t'as_child' => array( 'only' => 'mpc_pricing_box' ),\r\n\t\t\t\t'content_element' => true,\r\n//\t\t\t\t'icon' => mpc_get_plugin_path( __FILE__ ) . '/assets/images/icons/mpc-pricing-box.png',\r\n\t\t\t\t'icon' => 'mpc-shicon-pricing-legend',\r\n\t\t\t\t'category' => __( 'MPC', 'mpc' ),\r\n\t\t\t\t'params' => $params,\r\n\t\t\t);\r\n\t\t}", "public function showMap()\n {\n return $this->maptype === 'Embed MAP' ? $this->showEmbedMap() : $this->showStaticMap();\n }", "function wp_nav_menu_locations_meta_box()\n {\n }", "function igv_cmb_metaboxes() {\n\t$prefix = '_igv_';\n\n\t/**\n\t * Metaboxes declarations here\n * Reference: https://github.com/WebDevStudios/CMB2/blob/master/example-functions.php\n\t */\n\n}", "public function processSymbols() {\r\n\t\t$layers = array ();\r\n\t\t$layers [] = array ('map' => 'amenazas', 'layer' => 'Comunas', 'clsprefix' => 'Comuna ', 'clsdisplay' => 'num_comuna', 'clsitem' => 'num_comuna' );\r\n\t\t$layers [] = array ('map' => 'amenazas', 'layer' => 'Areas Homogeneas', 'clsprefix' => '', 'clsdisplay' => 'nombre', 'clsitem' => 'id_area' );\r\n\t\t$layers [] = array ('map' => 'amenazas', 'layer' => 'Amenazas', 'clsprefix' => '', 'clsdisplay' => 'descripcion', 'clsitem' => 'codamenaza' );\r\n\t\t\r\n\t\t$this->addSymbols ( $layers );\r\n\t}", "function specialdisplaytypes() {\n return array (\"xy_coord\"=>1, \"latlong\"=>1, \"matrix\"=>1);\n }", "public function getMapTypeControl()\n {\n return $this->mapTypeControl;\n }", "function warquest_show_map() {\r\n\r\n\t/* input */\r\n\tglobal $player;\r\n\tglobal $mid;\r\n\tglobal $sid;\r\n\t\r\n\t/* output */\r\n\tglobal $page;\r\n\t\r\n\t$page .= '<div class=\"subparagraph\">'.t('GENERAL_PLANET_'.$player->planet).' '.t('HOME_MAP_TITLE').'</div>';\r\n\r\n\t$page .= '<div class=\"box\">';\r\n\t$page .= warquest_ui_map($player, $player->planet);\r\n\t\r\n\t$page .= '<div class=\"note\"><center>';\r\n\t$page .= t('HOME_MAP_NOTE');\r\n\t$page .= '</center></div>';\t\r\n\t\t\r\n\t$page .= '</div>';\r\n}", "function wpb_add_custom_meta_boxes() {\n\tglobal $post;\n\tif ('134' == $post -> ID) { \n\t\tadd_meta_box(\n\t\t\t'league_table',\n\t\t\t'League Table',\n\t\t\t'league_table_callback',\n\t\t\t'page'\n\t\t);\n\t}\n\n\tif ('136' == $post -> ID) { \n\t\tadd_meta_box(\n\t\t\t'league_table',\n\t\t\t'League Table',\n\t\t\t'league_table_callback',\n\t\t\t'page'\n\t\t);\n\t}\n\n\tif ('138' == $post -> ID) { \n\t\tadd_meta_box(\n\t\t\t'league_table',\n\t\t\t'League Table',\n\t\t\t'league_table_callback',\n\t\t\t'page'\n\t\t);\n\t}\n}", "protected function getMap()\n\t{\n\t\treturn array(\n\t\t\t'USE' => new Field\\Checkbox('USE', array(\n\t\t\t\t'title' => Loc::getMessage('LANDING_HOOK_HEADBLOCK_USE')\n\t\t\t)),\n\t\t\t'CODE' => new Field\\Textarea('CODE', array(\n\t\t\t\t'title' => Loc::getMessage('LANDING_HOOK_HEADBLOCK_CODE'),\n\t\t\t\t'help' => Loc::getMessage('LANDING_HOOK_HEADBLOCK_CODE_HELP2'),\n\t\t\t\t'placeholder' => '<script>\n\tvar googletag = googletag || {};\n\tgoogletag.cmd = googletag.cmd || [];\n</script>'\n\t\t\t))\n\t\t);\n\t}", "public function vcMap() {\n\t\tif(function_exists('vc_map')) {\n\n\t\t\tvc_map( array(\n\t\t\t\t\t'name' => esc_html__('Album', 'qode-music'),\n\t\t\t\t\t'base' => $this->base,\n\t\t\t\t\t'category' => esc_html__('by QODE MUSIC','qode-music'),\n\t\t\t\t\t'icon' => 'icon-wpb-album extended-custom-icon-qode',\n\t\t\t\t\t'allowed_container_element' => 'vc_row',\n\t\t\t\t\t'params' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type'\t\t\t=> 'dropdown',\n\t\t\t\t\t\t\t'heading'\t\t=> esc_html__('Album','qode-music'),\n\t\t\t\t\t\t\t'param_name' \t=> 'album',\n\t\t\t\t\t\t\t'value' \t\t=> $this->getAlbums(),\n\t\t\t\t\t\t\t'admin_label' \t=> true,\n\t\t\t\t\t\t\t'save_always' \t=> true\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type' => 'dropdown',\n\t\t\t\t\t\t\t'heading' => esc_html__('Album Skin','qode-music'),\n\t\t\t\t\t\t\t'param_name' => 'album_skin',\n\t\t\t\t\t\t\t'value' => array(\n\t\t\t\t\t\t\t\tesc_html__('Default','qode-music')\t\t=> '',\n\t\t\t\t\t\t\t\tesc_html__('Dark','qode-music') \t\t=> 'dark',\n\t\t\t\t\t\t\t\tesc_html__('Light','qode-music') \t\t=> 'light'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'admin_label' => true\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type' => 'dropdown',\n\t\t\t\t\t\t\t'heading' => esc_html__('Title Tag','qode-music'),\n\t\t\t\t\t\t\t'param_name' => 'title_tag',\n\t\t\t\t\t\t\t'value' => array(\n\t\t\t\t\t\t\t\t'' => '',\n\t\t\t\t\t\t\t\t'h2'\t=> 'h2',\n\t\t\t\t\t\t\t\t'h3'\t=> 'h3',\n\t\t\t\t\t\t\t\t'h4'\t=> 'h4',\n\t\t\t\t\t\t\t\t'h5'\t=> 'h5',\n\t\t\t\t\t\t\t\t'h6'\t=> 'h6'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'admin_label' => true\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}", "function rh_contact_page_meta_boxes( $meta_boxes ) {\n\n\t\t$classic_design = ( 'classic' == INSPIRY_DESIGN_VARIATION );\n\t\t$last_columns = 12;\n\t\t$icon_columns = 6;\n\n\t\t$fields = array(\n\n\t\t\t// Contact Map\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Map', 'framework' ),\n\t\t\t\t'id' => \"theme_show_contact_map\",\n\t\t\t\t'type' => 'radio',\n\t\t\t\t'std' => '1',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'1' => esc_html__( 'Show', 'framework' ),\n\t\t\t\t\t'0' => esc_html__( 'Hide', 'framework' ),\n\t\t\t\t),\n\t\t\t\t'columns' => 12,\n\t\t\t\t'tab' => 'map',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Map Latitude', 'framework' ),\n\t\t\t\t'desc' => 'You can use <a href=\"http://www.latlong.net/\" target=\"_blank\">latlong.net</a> OR <a href=\"http://itouchmap.com/latlong.html\" target=\"_blank\">itouchmap.com</a> to get Latitude and longitude of your desired location.',\n\t\t\t\t'id' => \"theme_map_lati\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '-37.817917',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'map',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Map Longitude', 'framework' ),\n\t\t\t\t'id' => \"theme_map_longi\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '144.965065',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'map',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Map Zoom Level', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'Provide Map Zoom Level.', 'framework' ),\n\t\t\t\t'id' => \"theme_map_zoom\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '17',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'map',\n\t\t\t),\n\t\t);\n\n\t\t$map_type = inspiry_get_maps_type();\n\t\tif ( 'google-maps' == $map_type ) {\n\n\t\t\t$fields = array_merge( $fields, array(\n\n\t\t\t\tarray(\n\t\t\t\t\t'name' => esc_html__( 'Map Type', 'framework' ),\n\t\t\t\t\t'desc' => esc_html__( 'Choose Google Map Type', 'framework' ),\n\t\t\t\t\t'id' => \"inspiry_contact_map_type\",\n\t\t\t\t\t'type' => 'select',\n\t\t\t\t\t'options' => array(\n\t\t\t\t\t\t'roadmap' => esc_html__( 'RoadMap', 'framework' ),\n\t\t\t\t\t\t'satellite' => esc_html__( 'Satellite', 'framework' ),\n\t\t\t\t\t\t'hybrid' => esc_html__( 'Hybrid', 'framework' ),\n\t\t\t\t\t\t'terrain' => esc_html__( 'Terrain', 'framework' ),\n\t\t\t\t\t),\n\t\t\t\t\t'std' => 'roadmap',\n\t\t\t\t\t'columns' => 6,\n\t\t\t\t\t'tab' => 'map',\n\t\t\t\t)\n\t\t\t) );\n\n\t\t\t$icon_columns = 12;\n\t\t}\n\n\t\t$fields = array_merge( $fields, array(\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Google Maps Marker', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'You may upload custom google maps marker for the contact page here. Image size should be around 50px by 50px.', 'framework' ),\n\t\t\t\t'id' => \"inspiry_contact_map_icon\",\n\t\t\t\t'type' => 'image_advanced',\n\t\t\t\t'max_file_uploads' => 1,\n\t\t\t\t'columns' => $icon_columns,\n\t\t\t\t'tab' => 'map',\n\t\t\t),\n\n\t\t\t// Contact Details\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Contact Detail', 'framework' ),\n\t\t\t\t'id' => \"theme_show_details\",\n\t\t\t\t'type' => 'radio',\n\t\t\t\t'std' => '1',\n\t\t\t\t'options' => array(\n\t\t\t\t\t'1' => esc_html__( 'Show', 'framework' ),\n\t\t\t\t\t'0' => esc_html__( 'Hide', 'framework' ),\n\t\t\t\t),\n\t\t\t\t'columns' => 12,\n\t\t\t\t'tab' => 'detail',\n\t\t\t),\n\t\t) );\n\n\t\tif ( $classic_design ) {\n\t\t\t$fields = array_merge( $fields, array(\n\t\t\t\tarray(\n\t\t\t\t\t'name' => esc_html__( 'Contact Details Title', 'framework' ),\n\t\t\t\t\t'id' => \"theme_contact_details_title\",\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'columns' => 6,\n\t\t\t\t\t'tab' => 'detail',\n\t\t\t\t)\n\t\t\t) );\n\n\t\t\t$last_columns = 6;\n\t\t}\n\n\t\t$fields = array_merge( $fields, array(\n\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Cell Number', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_cell\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'detail',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Phone Number', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_phone\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'detail',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Fax Number', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_fax\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'detail',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Display Email', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_display_email\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'detail',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Contact Address', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_address\",\n\t\t\t\t'type' => 'textarea',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => $last_columns,\n\t\t\t\t'tab' => 'detail',\n\t\t\t),\n\n\t\t) );\n\n\t\tif ( $classic_design ) {\n\t\t\t$fields = array_merge( $fields, array(\n\t\t\t\tarray(\n\t\t\t\t\t'name' => esc_html__( 'Contact Form Heading', 'framework' ),\n\t\t\t\t\t'id' => \"theme_contact_form_heading\",\n\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t'std' => '',\n\t\t\t\t\t'columns' => 6,\n\t\t\t\t\t'tab' => 'form',\n\t\t\t\t)\n\t\t\t) );\n\t\t}\n\n\t\t$fields = array_merge( $fields, array(\n\t\t\t// Contact Form\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Name Field Label', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_form_name_label\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Email Field Label', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_form_email_label\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Phone Number Field Label', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_form_number_label\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Message Field Label', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_form_message_label\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Contact Form Email', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'Provide email address that will get messages from contact form.', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_email\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => get_option( 'admin_email' ),\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Contact Form CC Email', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'You can add multiple comma separated cc email addresses, to get a carbon copy of contact form message.', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_cc_email\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Contact Form BCC Email', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'You can add multiple comma separated bcc email addresses, to get a blind carbon copy of contact form message.', 'framework' ),\n\t\t\t\t'id' => \"theme_contact_bcc_email\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Contact Form Shortcode ( To Replace Default Form )', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'If you want to replace default contact form with a plugin based form then provide its shortcode here.', 'framework' ),\n\t\t\t\t'id' => \"inspiry_contact_form_shortcode\",\n\t\t\t\t'type' => 'text',\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'name' => esc_html__( 'Select Page For Redirection', 'framework' ),\n\t\t\t\t'desc' => esc_html__( 'User will be redirected to the selected page after successful submission of the contact form.', 'framework' ),\n\t\t\t\t'id' => \"inspiry_contact_form_success_redirect_page\",\n\t\t\t\t'type' => 'select',\n\t\t\t\t'options' => inspiry_pages(),\n\t\t\t\t'std' => '',\n\t\t\t\t'columns' => 6,\n\t\t\t\t'tab' => 'form',\n\t\t\t),\n\t\t) );\n\n\t\t$meta_boxes[] = array(\n\t\t\t'id' => 'contact-page-meta-box',\n\t\t\t'title' => esc_html__( 'Contact Page Settings', 'framework' ),\n\t\t\t'post_types' => array( 'page' ),\n\t\t\t'show' => array(\n\t\t\t\t'template' => array(\n\t\t\t\t\t'templates/contact.php',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'low',\n\t\t\t'tabs' => array(\n\t\t\t\t'map' => array(\n\t\t\t\t\t'label' => esc_html__( 'Contact Map', 'framework' ),\n\t\t\t\t\t'icon' => 'fas fa-map-marker-alt',\n\t\t\t\t),\n\t\t\t\t'detail' => array(\n\t\t\t\t\t'label' => esc_html__( 'Contact Details', 'framework' ),\n\t\t\t\t\t'icon' => 'far fa-address-card',\n\t\t\t\t),\n\t\t\t\t'form' => array(\n\t\t\t\t\t'label' => esc_html__( 'Contact Form', 'framework' ),\n\t\t\t\t\t'icon' => 'far fa-envelope-open',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'tab_style' => 'left',\n\t\t\t'fields' => $fields,\n\t\t);\n\n\t\treturn $meta_boxes;\n\t}", "function htheme_map_shortcode( $atts ) {\r\n\r\n\t\t#SETUP CONTENT CLASS\r\n\t\t$htheme_data = $this->htheme_content->htheme_get_map($atts);\r\n\r\n\t\t#RETURN DATA/HTML\r\n\t\treturn $htheme_data;\r\n\r\n\t}", "public function metabox_content() {\n\t\t\n\t\t\n\t\t\n\t}", "public function add_metaboxes() {\n\t\tadd_meta_box(\n\t\t\t'codes',\n\t\t\t__( 'Codes' ),\n\t\t\tarray( $this, 'render_codes_metabox' )\n\t\t);\n\n\t\tadd_meta_box(\n\t\t\t'edit-codes',\n\t\t\t__( 'Edit codes' ),\n\t\t\tarray( $this, 'render_edit_metabox' )\n\t\t);\n\t}", "function opaljob_areasize_unit_format( $value='' ){\n return $value . ' ' . '<span>'.'m2'.'</span>';\n}", "static function metabox($post){\n\t\twp_nonce_field( 'flat-options', 'flat-options_nonce' );\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\t\t\t\t\t\t\t\t\t\t\n\t\techo '<style>';\n\t\techo '.admin-meta-input{display:block; margin-top: 10px;}';\n\t\techo 'div.field-holder{display: block;float: left; margin: 10px 20px; height: 80px;}';\n\t\techo '.field-block{display: inline-block;clear: both;float: none;}';\n\t\techo '.postbox .inside .field-block h2{padding: 8px 12px;font-weight: 600;font-size: 18px;margin: 0;line-height: 1.4}';\n\t\techo '</style>';\n\t\t\t\t\t\n\t\t$fieldblocks = self::get_fields();\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Licitálással kapcsolatos adatok</h2>';\n\t\tforeach ($fieldblocks['licit'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Hely adatok</h2>';\n\t\tforeach ($fieldblocks['location'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Ingatlan adatok és településrendezési előírások</h2>';\n\t\tforeach ($fieldblocks['parameters'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Ingatlanjogi jellemzők</h2>';\n\t\tforeach ($fieldblocks['info'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Közművek, energiaellátás, telekommunikáció</h2>';\n\t\tforeach ($fieldblocks['sources'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\t\t\n\t\t\t\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Építmény (épület) jellemzői</h2>';\n\t\tforeach ($fieldblocks['building'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\techo \"\n\t\t\t<script>\n\t\t\t\tjQuery(document).ready(function(){\n\t\t\t\t\tjQuery('.datepicker').datepicker();\t\n\t\t\t\t});\t\n\t\t\t</script>\t\n\t\t\";\n\t\t\n\t\techo '<br clear=\"all\">';\n\t\t\n }", "public function Bali_map()\n\t{\n\t\t$this->template = view::factory('templates/Gmap')\n\t\t\t->set('lang', url::lang())\n\t\t\t->set('website_name', Kohana::lang('website.name'))\n\t\t\t->set('website_slogan', Kohana::lang('website.slogan'))\n\t\t\t->set('webpage_title', Kohana::lang('nav.'.str_replace('_', ' ', url::current())))\n\t\t\t->set('map_options', Kohana::config('Gmap.maps.Bali'))\n\t\t\t->set('map_markers', Kohana::config('Gmap.markers.Bali'))\n\t\t\t->set('map_icon_path', url::base().skin::config('images.Gmap.path'));\n\t}", "function mpfy_shortcode_custom_mapping($atts, $content) {\n\tglobal $mpfy_footer_scripts;\n\tstatic $mpfy_instances = -1;\n\t$mpfy_instances ++;\n\n\tif (!defined('MPFY_LOAD_ASSETS')) {\n\t\tdefine('MPFY_LOAD_ASSETS', true);\n\t}\n\n\textract( shortcode_atts( array(\n\t\t'width'=>0,\n\t\t'height'=>300,\n\t\t'map_id'=>0,\n\t), $atts));\n\n\tif (!stristr($width, '%')) {\n\t\t$width = intval($width);\n\t\t$width = ($width < 1) ? 0 : $width . 'px';\n\t}\n\n\tif (!stristr($height, '%')) {\n\t\t$height = intval($height);\n\t\t$height = ($height < 1) ? 300 : $height . 'px';\n\t}\n\n\tif ($map_id == 0) {\n\t\t$map_id = Mpfy_Map::get_first_map_id();\n\t}\n\n\t$map = get_post(intval($map_id));\n\tif (!$map || is_wp_error($map) || $map->post_type != 'map') {\n\t\treturn 'Invalid or no map_id specified.';\n\t}\n\n\t$map = new Mpfy_Map($map->ID);\n\n\t$template = include('templates/map.php');\n\t$mpfy_footer_scripts .= $template['script'];\n\treturn $template['html'];\n}", "function add_meta_boxes() {\r\n\t\tglobal $post;\r\n\t\t$code = get_post_meta($post->ID, $this->meta_value_key, true);\r\n\t\tif (empty($code) && $this->check_genesis())\treturn false;\r\n\t\t\r\n\t\t$screens = array('page', 'post');\r\n\t\tforeach ($screens as $screen) {\r\n\t\t\tadd_meta_box('embed_js', 'Embed JS (eg, Adwords Conversion Code)', array($this,'metabox_embed_js'), $screen, 'normal', 'low');\r\n\t\t}\r\n\t}", "public function vcMap() {\n\t\tif(function_exists('vc_map')) {\n\n\t\t\tvc_map( array(\n\t\t\t\t\t'name' => esc_html__('Album Player', 'qode-music'),\n\t\t\t\t\t'base' => $this->base,\n\t\t\t\t\t'category' => esc_html__('by QODE MUSIC','qode-music'),\n\t\t\t\t\t'icon' => 'icon-wpb-album-player extended-custom-icon-qode',\n\t\t\t\t\t'allowed_container_element' => 'vc_row',\n\t\t\t\t\t'params' => array(\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type'\t\t\t=> 'dropdown',\n\t\t\t\t\t\t\t'heading'\t\t=> esc_html__('Type','qode-music'),\n\t\t\t\t\t\t\t'param_name' \t=> 'type',\n\t\t\t\t\t\t\t'value' => array(\n\t\t\t\t\t\t\t\tesc_html__('Standard','qode-music')\t=> 'standard',\n\t\t\t\t\t\t\t\tesc_html__('Compact','qode-music')\t=> 'compact',\n\t\t\t\t\t\t\t\tesc_html__('Simple','qode-music')\t=> 'simple'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'admin_label' \t=> true\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type'\t\t\t=> 'dropdown',\n\t\t\t\t\t\t\t'heading'\t\t=> esc_html__('Album','qode-music'),\n\t\t\t\t\t\t\t'param_name' \t=> 'album',\n\t\t\t\t\t\t\t'value' \t\t=> $this->getAlbums(),\n\t\t\t\t\t\t\t'admin_label' \t=> true,\n\t\t\t\t\t\t\t'save_always' \t=> true\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t 'type' => 'dropdown',\n\t 'heading' => esc_html__('Content In Grid','qode-music'),\n\t 'param_name' => 'full_width_bg',\n\t 'value' => array(\n\t esc_html__('Yes','qode-music') => 'yes',\n\t esc_html__('No','qode-music') => 'no'\n\t ),\n\t 'admin_label' => true,\n\t \t\t\t'save_always' => true\n\t ),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t\t\t'heading' => esc_html__('Player Background Color','qode-music'),\n\t\t\t\t\t\t\t'param_name' => 'bg_color',\n 'dependency' => array('element' => 'skin','value'=> 'transparent'),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t\t\t'heading' => esc_html__('Play Button Background Color','qode-music'),\n\t\t\t\t\t\t\t'param_name' => 'play_bg_color',\n 'dependency' => array('element' => 'skin','value'=> 'transparent'),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t\t\t'heading' => esc_html__('Navigation Buttons Background Color','qode-music'),\n\t\t\t\t\t\t\t'param_name' => 'nav_bg_color',\n 'dependency' => array('element' => 'skin','value'=> 'transparent'),\n\t\t\t\t\t\t),\n\t\t\t\t\t\tarray(\n\t\t\t\t\t\t\t'type'\t\t\t=> 'dropdown',\n\t\t\t\t\t\t\t'heading'\t\t=> esc_html__('Skin','qode-music'),\n\t\t\t\t\t\t\t'param_name' \t=> 'skin',\n\t\t\t\t\t\t\t'value' => array(\n\t\t\t\t\t\t\t\tesc_html__('Light','qode-music')\t=> 'light',\n\t\t\t\t\t\t\t\tesc_html__('Dark','qode-music') => 'dark',\n\t\t\t\t\t\t\t\tesc_html__('Transparent','qode-music') => 'transparent'\n\t\t\t\t\t\t\t),\n\t\t\t\t\t\t\t'admin_label' \t=> true,\n\t\t\t\t\t\t\t'save_always' \t=> true\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}", "public function pos_register_meta_boxes($meta_boxes) {\n\n\t\t// Start with an underscore to hide fields from custom fields list\n\t\t$prefix = '_pos_';\n\n\t\t/**\n\t\t * Sample metabox to demonstrate each field type included\n\t\t */\n\t\t$meta_boxes['pos_metabox'] = array(\n\t\t\t'id' => 'pos_details_metabox',\n\t\t\t'title' => __('Detalhes do Ponto de Venda', 'points_of_sale'),\n\t\t\t'pages' => $this->post_types_to_use, // Post type\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'high',\n\t\t\t'show_names' => true, // Show field names on the left\n\t\t\t// 'cmb_styles' => true, // Enqueue the CMB stylesheet on the frontend\n\t\t\t'validation' => array(\n\t\t\t\t'rules' => array(\n\t\t\t\t\t$prefix . 'latitude' => array(\n\t\t\t\t\t\t'required' => true,\n\t\t\t\t\t),\n\t\t\t\t\t$prefix . 'longitude' => array(\n\t\t\t\t\t\t'required' => true,\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t\t// Optional override of default error messages\n\t\t\t\t'messages' => array(\n\t\t\t\t\t$prefix . 'latitude' => array(\n\t\t\t\t\t\t'required' => __('É necessário informar a latitude do PDV.<br/>Posicione o pino corretamente no mapa para obter as coordenadas automaticamente.', 'points_of_sale'),\n\t\t\t\t\t),\n\t\t\t\t\t$prefix . 'longitude' => array(\n\t\t\t\t\t\t'required' => __('É necessário informar a longitude do PDV.<br/>Posicione o pino corretamente no mapa para obter as coordenadas automaticamente.', 'points_of_sale'),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t),\n\t\t\t'fields' => array(\n\t\t\t\tarray(\n\t\t\t\t\t'id' => $prefix . 'location_picker',\n\t\t\t\t\t'type' => 'poslocationpicker'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Estado', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'state',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Cidade', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'city',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Bairro', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'neighborhood',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Rua', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'street',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Número', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'number',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('CEP', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'postal_code',\n\t\t\t\t\t'type' => 'text'),\n\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('E-mail', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'email',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Telefone', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'phone',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Marcador', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'marker',\n\t\t\t\t\t'type' => 'image_advanced',\n\t\t\t\t\t'max_file_uploads' => 1),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Latitude', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'latitude',\n\t\t\t\t\t'type' => 'text'),\n\t\t\t\tarray(\n\t\t\t\t\t'name' => __('Longitude', 'points_of_sale'),\n\t\t\t\t\t'id' => $prefix . 'longitude',\n\t\t\t\t\t'type' => 'text'),\n\n\t\t\t),\n\t\t);\n\n\t\t// Add other metaboxes as needed\n\n\t\treturn $meta_boxes;\n\t}", "public function hasMapTypeControl()\n {\n return $this->mapTypeControl !== null;\n }", "function unit_map_function(&$data, $maps) {\n // idia symbash/paradoxh me to attendance_gradebook_activities_map_function()\n // des to ekei comment gia ta spasmena FKs\n list($document_map, $link_category_map, $link_map, $ebook_map, $section_map, $subsection_map, $video_map, $videolink_map, $video_category_map, $lp_learnPath_map, $wiki_map, $assignments_map, $exercise_map, $forum_map, $forum_topic_map, $poll_map) = $maps;\n if ($data['type'] == 'videolinks') {\n $data['type'] == 'videolink';\n }\n if (isset($data['course_weekly_view_id'])) {\n $data['unit_id'] = $data['course_weekly_view_id'];\n unset($data['unit_id']);\n }\n $type = $data['type'];\n if ($type == 'doc') {\n $data['res_id'] = @$document_map[$data['res_id']];\n } elseif ($type == 'linkcategory') {\n $data['res_id'] = @$link_category_map[$data['res_id']];\n } elseif ($type == 'link') {\n $data['res_id'] = @$link_map[$data['res_id']];\n } elseif ($type == 'ebook') {\n $data['res_id'] = @$ebook_map[$data['res_id']];\n } elseif ($type == 'section') {\n $data['res_id'] = @$section_map[$data['res_id']];\n } elseif ($type == 'subsection') {\n $data['res_id'] = @$subsection_map[$data['res_id']];\n } elseif ($type == 'description') {\n $data['res_id'] = intval($data['res_id']);\n } elseif ($type == 'video') {\n $data['res_id'] = @$video_map[$data['res_id']];\n } elseif ($type == 'videolink') {\n $data['res_id'] = @$videolink_map[$data['res_id']];\n } elseif ($type == 'videolinkcategory') {\n $data['res_id'] = @$video_category_map[$data['res_id']];\n } elseif ($type == 'lp') {\n $data['res_id'] = @$lp_learnPath_map[$data['res_id']];\n } elseif ($type == 'wiki') {\n $data['res_id'] = @$wiki_map[$data['res_id']];\n } elseif ($type == 'work') {\n if (isset($assignments_map[$data['res_id']])) {\n $data['res_id'] = @$assignments_map[$data['res_id']];\n } else {\n $data['res_id'] = $assignments_map[0];\n }\n } elseif ($type == 'exercise') {\n if (isset($exercise_map[$data['res_id']])) {\n $data['res_id'] = @$exercise_map[$data['res_id']];\n } else {\n $data['res_id'] = $exercise_map[0];\n }\n } elseif ($type == 'forum') {\n $data['res_id'] = @$forum_map[$data['res_id']];\n } elseif ($type == 'topic') {\n $data['res_id'] = @$forum_topic_map[$data['res_id']];\n } elseif ($type == 'poll') {\n $data['res_id'] = @$poll_map[$data['res_id']];\n }\n return true;\n}", "function ngng_position_wpseo_metabox() {\n\treturn 'low';\n}", "function shortcode_map() {\r\n\t\t\tif ( ! function_exists( 'vc_map' ) ) {\r\n\t\t\t\treturn '';\r\n\t\t\t}\r\n\r\n\t\t\t$base = array(\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_preset',\r\n\t\t\t\t\t'heading' => __( 'Style Preset', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'preset',\r\n\t\t\t\t\t'tooltip' => MPC_Helper::style_presets_desc(),\r\n\t\t\t\t\t'value' => '',\r\n\t\t\t\t\t'shortcode' => $this->shortcode,\r\n\t\t\t\t\t'wide_modal' => true,\r\n\t\t\t\t\t'description' => __( 'Choose preset or create new one.', 'mpc' ),\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_content',\r\n\t\t\t\t\t'heading' => __( 'Content Preset', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'content_preset',\r\n\t\t\t\t\t'tooltip' => MPC_Helper::content_presets_desc(),\r\n\t\t\t\t\t'value' => '',\r\n\t\t\t\t\t'shortcode' => $this->shortcode,\r\n\t\t\t\t\t'extended' => true,\r\n\t\t\t\t\t'description' => __( 'Choose preset or create new one.', 'mpc' ),\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'dropdown',\r\n\t\t\t\t\t'heading' => __( 'Style', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'style',\r\n\t\t\t\t\t'admin_label' => true,\r\n\t\t\t\t\t'tooltip' => __( 'Select buttons set style:<br><b>Horizontal</b>: horizontal buttons side by side;<br><b>Vertical</b>: vertical buttons one under the other.', 'mpc' ),\r\n\t\t\t\t\t'value' => array(\r\n\t\t\t\t\t\t__( 'Horizontal', 'mpc' ) => 'horizontal',\r\n\t\t\t\t\t\t__( 'Vertical', 'mpc' ) => 'vertical',\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'std' => 'horizontal',\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-4 vc_column mpc-advanced-field',\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_text',\r\n\t\t\t\t\t'heading' => __( 'Separator Space', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'space',\r\n\t\t\t\t\t'tooltip' => __( 'Define separator space between buttons. Adds additional space on sides of separator to prevent it from overlapping button content.', 'mpc' ),\r\n\t\t\t\t\t'value' => '',\r\n\t\t\t\t\t'addon' => array(\r\n\t\t\t\t\t\t'icon' => 'dashicons dashicons-leftright',\r\n\t\t\t\t\t\t'align' => 'prepend',\r\n\t\t\t\t\t),\r\n\t\t\t\t\t'label' => 'px',\r\n\t\t\t\t\t'validate' => true,\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-4 vc_column mpc-advanced-field',\r\n\t\t\t\t),\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'checkbox',\r\n\t\t\t\t\t'heading' => __( 'Full Width', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'fullwidth',\r\n\t\t\t\t\t'tooltip' => __( 'Check to stretch buttons to 100% width of their container.', 'mpc' ),\r\n\t\t\t\t\t'value' => array( __( 'Enable', 'mpc' ) => 'true' ),\r\n\t\t\t\t\t'std' => '',\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-4 vc_column mpc-advanced-field',\r\n\t\t\t\t),\r\n\t\t\t);\r\n\r\n\t\t\t$icon_animation = array(\r\n\t\t\t\tarray(\r\n\t\t\t\t\t'type' => 'mpc_animation',\r\n\t\t\t\t\t'heading' => __( 'Animation Effect', 'mpc' ),\r\n\t\t\t\t\t'param_name' => 'icon_animation',\r\n\t\t\t\t\t'tooltip' => __( 'Choose one of the animation types. You can apply the animation to the preview box on the right with the <b>Refresh</b> button.', 'mpc' ),\r\n\t\t\t\t\t'value' => MPC_Snippets::$animations_loop_list,\r\n\t\t\t\t\t'std' => 'none',\r\n\t\t\t\t\t'group' => __( 'Separator', 'mpc' ),\r\n\t\t\t\t\t'edit_field_class' => 'vc_col-sm-12 vc_column mpc-advanced-field',\r\n\t\t\t\t),\r\n\t\t\t);\r\n\r\n\t\t\t$margin = MPC_Snippets::vc_margin();\r\n\t\t\t$animation = MPC_Snippets::vc_animation();\r\n\t\t\t$class = MPC_Snippets::vc_class();\r\n\r\n\t\t\t$background = MPC_Snippets::vc_background( array( 'group' => __( 'Separator', 'mpc' ) ) );\r\n\t\t\t$border = MPC_Snippets::vc_border( array( 'group' => __( 'Separator', 'mpc' ) ) );\r\n\t\t\t$padding = MPC_Snippets::vc_padding( array( 'group' => __( 'Separator', 'mpc' ) ) );\r\n\t\t\t$icon_margin = MPC_Snippets::vc_margin( array( 'prefix' => 'icon', 'group' => __( 'Separator', 'mpc' ) ) );\r\n\t\t\t$icon = MPC_Snippets::vc_icon( array( 'group' => __( 'Separator', 'mpc' ) ) );\r\n\r\n\t\t\t$params = array_merge( $base, $margin, $icon, $icon_animation, $background, $border, $padding, $icon_margin, $animation, $class );\r\n\r\n\t\t\treturn array(\r\n\t\t\t\t'name' => __( 'Buttons Set', 'mpc' ),\r\n\t\t\t\t'description' => __( 'Buttons with separator', 'mpc' ),\r\n\t\t\t\t'base' => 'mpc_button_set',\r\n\t\t\t\t'class' => '',\r\n\t\t\t\t'icon' => 'mpc-shicon-buttons-set',\r\n\t\t\t\t'category' => __( 'MPC', 'mpc' ),\r\n\t\t\t\t'as_parent' => array( 'only' => 'mpc_button, mpc_lightbox' ),\r\n\t\t\t\t'content_element' => true,\r\n\t\t\t\t\"js_view\" => 'VcColumnView',\r\n\t\t\t\t'params' => $params,\r\n\t\t\t);\r\n\t\t}", "function address_meta_box()\n{\n\n\tadd_meta_box('main_address', 'Address Real Estate' , 'address_input', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\n\tadd_meta_box('district_address', 'District Real Estate' , 'address_district_input', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\t\tadd_meta_box('rew_floor', 'Floor Number' , 'rew_floors', array('apartment', 'villa') , 'advanced' , 'high',null);\n\t\tadd_meta_box('rew_rooms', 'Rooms Number' , 'rew_rooms',array('apartment', 'villa') , 'advanced' , 'high',null);\n\t\tadd_meta_box('Apartment_area', 'Real Estate Area' , 'rew_area', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\tadd_meta_box('rew_price', 'Real Estat Price' , 'rew_price', array('apartment', 'villa','land' , 'store') , 'advanced' , 'high',null);\n\n\t/// villa rew_garden\n\tadd_meta_box('rew_garden', 'Garden Real Estate' , 'rew_garden', array( 'villa') , 'advanced' , 'high',null);\n\n}", "public function getCodeUnitOfMeasureDataProvider()\n {\n return [\n ['LB'],\n ['KG'],\n ];\n }", "function the_block_editor_meta_boxes()\n {\n }", "function showMap() {\n\t\t$this->initMap();\n\n\t\t$template['list'] = $this->cObj2->getSubpart($this->templateCode,'###MAP###');\n\n\t\t// title, text - markers\n\t\t$markerArray = $this->helperGetLLMarkers(array(), $this->conf['map.']['LL'], 'map');\n\t\t$markerArray['###CAT_MENU###'] \t\t= $this->displayCatMenu(0);\n\t\t$markerArray['###CAT_LIST###'] \t\t= ($this->config['categoriesActive']!='') ? $this->config['categoriesActive'] : '9999';\n\t\t$markerArray['###MAP_WIDTH###'] \t= $this->config['mapWidth'];\n\t\t$markerArray['###MAP_HEIGHT###']\t= $this->config['mapHeight'];\n\n\t\t$content = $this->cObj2->substituteMarkerArrayCached($template['list'],$markerArray, $subpartArray,$wrappedSubpartArray);\n\t\treturn $content;\n\t}", "public static function add_metaboxes(){}", "function initControls()\n {\n\n $this->map->getControls()->getMaptype()->setDisplay((boolean) $this->showMapType);\n\n $this->map->getControls()->getMaptype()->setPosition($this->mapTypePosition);\n $this->map->getControls()->getMaptype()->setType($this->mapTypeType);\n\n $this->map->getControls()->getScale()->setDisplay((boolean) $this->showScale);\n $this->map->getControls()->getScale()->setPosition($this->scalePosition);\n\n $this->map->getControls()->getNavigation()->setDisplay((boolean) $this->showNavigation);\n\n $this->map->getControls()->getNavigation()->setPosition($this->navigationPosition);\n\n $this->map->getControls()->getNavigation()->setType($this->navigationType);\n\n\n $this->map->getControls()->getZoom()->setDisplay((boolean) $this->showZoom);\n $this->map->getControls()->getZoom()->setPosition($this->zoomPosition);\n $this->map->getControls()->getZoom()->setType($this->zoomType);\n\n $this->map->getControls()->getPan()->setDisplay((boolean) $this->showPan);\n $this->map->getControls()->getPan()->setPosition($this->panPosition);\n\n if ($this->initialMapType)\n {\n $this->map->setMaptype(new Tx_Listfeusers_Gmap_Maptype($this->initialMapType));\n }\n\n }", "public static function get_map_explorer_definition() {\n return array(\n 'title' => 'Map explorer',\n 'category' => 'Reporting',\n 'description' => 'A map plus grid of data, with various options for exploring the data. This is designed to integrate with the Easy Login feature\\'s '.\n 'preferred taxon groups and locality for the logged in user and is therefore specific to Drupal.'\n );\n }", "public function Get_Map ( $map )\n\t{\n\t\t// Official XIII Maps\n\t\t// Deathmatch\n\t\t\t if ($map == \"DM_Banque\")\t\t\treturn\t\"Winslow Bank\";\n\t\telse if ($map == \"DM_Base\")\t\t\t\treturn\t\"Platform-02\";\n\t\telse if ($map == \"DM_Base_XBox\")\t\treturn\t\"Platform-03\";\n\t\telse if ($map == \"DM_Base2\")\t\t\treturn\t\"AFM-10\";\n\t\telse if ($map == \"DM_Hual1\")\t\t\treturn\t\"Emerald\";\n\t\telse if ($map == \"DM_Amos\")\t\t\t\treturn\t\"FBI\";\n\t\telse if ($map == \"DM_Pal\")\t\t\t\treturn\t\"Bristol Suites\";\n\t\telse if ($map == \"DM_Spads\")\t\t\treturn\t\"SPADS (PC)\";\n\t\telse if ($map == \"DM_Spads_XBox\")\t\treturn\t\"SPADS (XBOX)\";\n\t\telse if ($map == \"DM_PRock\")\t\t\treturn\t\"Plain Rock\";\n\t\telse if ($map == \"DM_Warehouse\")\t\treturn\t\"Warehouse 33\";\n\t\telse if ($map == \"DM_USA2_demo\")\t\treturn\t\"Docks (DM)\";\n\t\telse if ($map == \"DM_Hual04a\")\t\t\treturn\t\"Hualpar\";\n\t\telse if ($map == \"DM_PRock01a\")\t\t\treturn\t\"Asylum\";\n\t\telse if ($map == \"DM_USA01\")\t\t\treturn\t\"USA\";\n\t\telse if ($map == \"DM_SM01\")\t\t\t\treturn\t\"SS-419\";\n\t\telse if ($map == \"DM_LostTemple\")\t\treturn \t\"Lost Temple\";\n\t\t\n\t\t// Team Maps\n\t\telse if ($map == \"CTF_Base\")\t\t\treturn\t\"USS-Patriot\";\n\t\telse if ($map == \"CTF_Sanc\")\t\t\treturn\t\"XX\";\n\t\telse if ($map == \"CTF_Snow\")\t\t\treturn\t\"Kellownee\";\n\t\telse if ($map == \"CTF_Toits\")\t\t\treturn\t\"New-York\";\n\t\telse if ($map == \"CTF_Temple\")\t\t\treturn\t\"Temple\";\n\n\t\t// Sabotage\n\t\telse if ($map == \"SB_USA2\")\t\t\t\treturn\t\"Docks\";\n\t\telse if ($map == \"SB_Hual1a\")\t\t\treturn\t\"Choland\";\n\t\telse if ($map == \"SB_Camp\")\t\t\t\treturn\t\"Camp\";\n\t\t\n\t\t//-------------------------------\n\t\t// Unofficial XIII Maps (We don't know the map, sorry)\n\t\treturn $map;\n\t}", "function get_map(){\n return $this->customizer_map_array;\n }", "function getUTM()\r\n\t{\r\n\t\t// get UTM letter\r\n\t\tif ( $this->nLat <= 84.0 && $this->nLat >= 72.0 )\r\n\t\t\t$utmLetter = 'X';\r\n\t\telse if ( $this->nLat < 72.0 && $this->nLat >= 64.0 )\r\n\t\t\t$utmLetter = 'W';\r\n\t\telse if ( $this->nLat < 64.0 && $this->nLat >= 56.0 )\r\n\t\t\t$utmLetter = 'V';\r\n\t\telse if ( $this->nLat < 56.0 && $this->nLat >= 48.0 )\r\n\t\t\t$utmLetter = 'U';\r\n\t\telse if ( $this->nLat < 48.0 && $this->nLat >= 40.0 )\r\n\t\t\t$utmLetter = 'T';\r\n\t\telse if ( $this->nLat < 40.0 && $this->nLat >= 32.0 )\r\n\t\t\t$utmLetter = 'S';\r\n\t\telse if ( $this->nLat < 32.0 && $this->nLat >= 24.0 )\r\n\t\t\t$utmLetter = 'R';\r\n\t\telse if ( $this->nLat < 24.0 && $this->nLat >= 16.0 )\r\n\t\t\t$utmLetter = 'Q';\r\n\t\telse if ( $this->nLat < 16.0 && $this->nLat >= 8.0 )\r\n\t\t\t$utmLetter = 'P';\r\n\t\telse if ( $this->nLat < 8.0 && $this->nLat >= 0.0 )\r\n\t\t\t$utmLetter = 'N';\r\n\t\telse if ( $this->nLat < 0.0 && $this->nLat >= -8.0 )\r\n\t\t\t$utmLetter = 'M';\r\n\t\telse if ( $this->nLat < -8.0 && $this->nLat >= -16.0 )\r\n\t\t\t$utmLetter = 'L';\r\n\t\telse if ( $this->nLat < -16.0 && $this->nLat >= -24.0 )\r\n\t\t\t$utmLetter = 'K';\r\n\t\telse if ( $this->nLat < -24.0 && $this->nLat >= -32.0 )\r\n\t\t\t$utmLetter = 'J';\r\n\t\telse if ( $this->nLat < -32.0 && $this->nLat >= -40.0 )\r\n\t\t\t$utmLetter = 'H';\r\n\t\telse if ( $this->nLat < -40.0 && $this->nLat >= -48.0 )\r\n\t\t\t$utmLetter = 'G';\r\n\t\telse if ( $this->nLat < -48.0 && $this->nLat >= -56.0 )\r\n\t\t\t$utmLetter = 'F';\r\n\t\telse if ( $this->nLat < -56.0 && $this->nLat >= -64.0 )\r\n\t\t\t$utmLetter = 'E';\r\n\t\telse if ( $this->nLat < -64.0 && $this->nLat >= -72.0 )\r\n\t\t\t$utmLetter = 'D';\r\n\t\telse if ( $this->nLat < -72.0 && $this->nLat >= -80.0 )\r\n\t\t\t$utmLetter = 'C';\r\n\t\telse\r\n\t\t\t$utmLetter = 'Z'; //returns 'Z' if the lat is outside the UTM limits of 84N to 80S\r\n\r\n\t\t$zone = (int) ( ( $this->nLon + 180 ) / 6 ) + 1;\r\n\r\n\t\tif ( $this->nLat >= 56.0 && $this->nLat < 64.0 && $this->nLon >= 3.0 && $this->nLon < 12.0 ) $zone = 32;\r\n\r\n\t\t// Special zones for Svalbard.\r\n\t\tif ($this->nLat >= 72.0 && $this->nLat < 84.0 )\r\n\t\t{\r\n\t\t\tif ( $this->nLon >= 0.0 && $this->nLon < 9.0 )\r\n\t\t\t\t$zone = 31;\r\n\t\t\telse if ( $this->nLon >= 9.0 && $this->nLon < 21.0 )\r\n\t\t\t\t$zone = 33;\r\n\t\t\telse if ( $this->nLon >= 21.0 && $this->nLon < 33.0 )\r\n\t\t\t\t$zone = 35;\r\n\t\t\telse if ( $this->nLon >= 33.0 && $this->nLon < 42.0 )\r\n\t\t\t\t$zone = 37;\r\n\t\t}\r\n\r\n\t\t$cs2csresult = $this->getCore(\"+proj=utm +datum=WGS84 +zone=$zone\");\r\n\r\n\t\treturn Array('zone' => $zone, 'letter' => $utmLetter, 'north' => 'N ' . floor($cs2csresult[1]), 'east' => 'E ' . floor($cs2csresult[0]));\r\n\t}", "function wpbm_shortcode_usage_metabox(){\n add_meta_box( 'wpbm_shortcode_usage_option', __( 'WP Blog Manager Usage', WPBM_TD ), array( $this, 'wpbm_shortcode_usage' ), 'wpblogmanager', 'side', 'default' );\n }", "function render_flags_meta() {\n\t\tglobal $post;\n\t\t$flag = get_post_meta( $post->ID, 'country_code', true );\n\t\t$filepath = 'flags/' . strtolower( $flag ) . '.gif';\n\t\tif ( is_file( plugin_dir_path( __FILE__ ) . $filepath ) ) {\n\t\t\t?>\n\t\t\t<img name=\"flags\" src=\"<?php echo plugins_url( $filepath, __FILE__ ); ?>\" />\n\t\t\t<?php\n\t\t} else {\n\t\t\techo '<p>' . __( 'Flag image not available.' ) . '</p>';\n\t\t}\n\t}", "abstract public function getUnitOfMaterial(): string;", "function geopost_write_metabox($post) {\r\n wp_nonce_field( plugin_basename(__FILE__), 'geopost_noncename' );\r\n $postid = $post->ID;\r\n echo '<input type=\"text\" id=\"geopost_location_field\" name=\"geopost_location_field\" value=\"\" size=\"20\" />';\r\n echo ' <a href=\"javascript:geopost_geocode(\\'preview_canvas\\', document.getElementById(\\'geopost_location_field\\').value);\">Search</a>';\r\n echo ' | <a href=\"javascript:geopost_set_preview_marker(\\'preview_canvas\\',null,null,\\'0\\');\">Clear</a>';\r\n echo '<br><br>';\r\n echo '<input type=\"hidden\" id=\"geopost_lat\" name=\"geopost_lat\" value=\"\" size=\"6\" />';\r\n echo '<input type=\"hidden\" id=\"geopost_lng\" name=\"geopost_lng\" value=\"\" size=\"6\" />'; \r\n echo '<input type=\"hidden\" id=\"geopost_icon\" name=\"geopost_icon\" value=\"0\" size=\"3\" />'; \r\n echo '<center><div id=\"preview_canvas\" style=\"width:220px; height:0px\"></div></center>';\r\n echo '<script>';\r\n echo 'geopost_map(\"preview_canvas\",\"'. geopost_icon_dir() .'\", 1, 0);';\r\n $lat = get_post_meta($postid, 'geopost_lat', true);\r\n $lng = get_post_meta($postid, 'geopost_lng', true);\r\n $icon = get_post_meta($postid, 'geopost_icon', true);\r\n if(($lat != null) && ($lng != null)) {\r\n if($icon == null)\r\n $icon = 0;\r\n echo 'geopost_set_preview_marker(\"preview_canvas\",' . $lat . ',' . $lng . ',' . $icon . ');';\r\n }\r\n echo '</script>';\r\n}", "function _display_status_meta( $post ) {\n\t\tinclude( 'includes/metaboxes/unit-status.php' );\n\t}", "function _register_manpower_meta_box_cb()\n{\n\tadd_meta_box(\"admin_manpower\", \"Worker Information\", \"WorkerController::admin_view\", MANPOWER);\n}", "function greater_jackson_habitat_extra_metabox_content() {\n\t\n\tgreater_jackson_habitat_do_field_textarea( array(\n\t\t'name' => 'gjh_extra',\n\t\t'group' => 'gjh_extra',\n\t\t'wysiwyg' => true,\n\t) );\n\t\n\tgreater_jackson_habitat_init_field_group( 'gjh_extra' );\n\t\n}", "public static function metabox() {\n\t\techo SimpleTags_Admin::getDefaultContentBox();\n\t}", "function cmb2_bbjobs_metabox() {\n\n\t// Start with an underscore to hide fields from custom fields list\n\t$prefix = 'bbjob_';\n\n\t/**\n\t * Initiate the metabox\n\t */\n\t$bbjob = new_cmb2_box( array(\n\t\t'id' => 'bbjob_metabox',\n\t\t'title' => __( 'Position Details', 'cmb2' ),\n\t\t'object_types' => array( 'jobs', ), // Post type\n\t\t'context' => 'normal',\n\t\t'priority' => 'high',\n\t\t'show_names' => true, // Show field names on the left\n\t\t// 'cmb_styles' => false, // false to disable the CMB stylesheet\n\t\t// 'closed' => true, // Keep the metabox closed by default\n\t) );\n\n\t$bbjob->add_field( array(\n \t\t'name' => 'Subtext',\n \t\t'desc' => '',\n \t\t'default' => '',\n \t\t'id' => $prefix . 'subtext',\n \t\t'type' => 'text'\n\t) );\n\n}", "public function add_metabox() {\n add_meta_box(\n 'customer_info',\n __( 'Customer Info', 'textdomain' ),\n array( $this, 'render_metabox' ),\n 'customer',\n 'advanced',\n 'default'\n );\n\n }", "function wpgooglemaps_gold_filter_control_map_output($content,$mapid) {\n return $content;\n}", "function filter_ModifyMapOutput( $HTML ) {\n\n // Hide Map\n if ( $this->slplus->is_CheckTrue( $this->addon->options['hide_map'] ) ) {\n return '<div id=\"map\" style=\"display:none;\"></div>';\n }\n\n // Map HTML\n $HTML .=\n\t $this->createstring_MapDisplaySlider() .\n\n empty($this->slplus->SmartOptions->maplayout->value) ?\n $this->slplus->SmartOptions->maplayout->default :\n\t $this->slplus->SmartOptions->maplayout->value ;\n\n // Widget Search\n\t if ( ! empty($_REQUEST['slp_widget']['search'] ) ) {\n\t\t $this->slplus->SmartOptions->map_initial_display->value = 'map';\n\t }\n\n // Map hidden\n //\n if ( $this->slplus->SmartOptions->map_initial_display->value == 'hide' ) {\n $HTML = '<div id=\"map_box_map\" style=\"display:none;\">' . $HTML . '</div>';\n\n // Starting Image\n //\n } else if ( ( $this->slplus->SmartOptions->map_initial_display->value == 'image' ) && ! empty( $this->slplus->SmartOptions->starting_image->value ) ){\n\n // Make sure URL starts with the plugin URL if it is not an absolute URL\n //\n $startingImage =\n ( ( preg_match('/^http/',$this->slplus->SmartOptions->starting_image->value ) <= 0 ) ?SLPLUS_PLUGINURL:'') .\n $this->slplus->SmartOptions->starting_image->value\n ;\n\n $HTML =\n '<div id=\"map_box_image\" style=\"'.\n \"width:\". $this->slplus->options_nojs['map_width'] . $this->slplus->options_nojs['map_width_units'] . ';'.\n \"height:\".$this->slplus->options_nojs['map_height']. $this->slplus->options_nojs['map_height_units']. ';'.\n '\">'.\n \"<img src='{$startingImage}'>\".\n '</div>' .\n '<div id=\"map_box_map\" style=\"display:none;\">' .\n $HTML .\n '</div>'\n ;\n }\n\n return $HTML;\n }", "public function add_metabox() {\r\n\t\tadd_meta_box(\r\n\t\t\t'stats', // ID\r\n\t\t\t'Stats', // Title\r\n\t\t\tarray(\r\n\t\t\t\t$this,\r\n\t\t\t\t'meta_box', // Callback to method to display HTML\r\n\t\t\t),\r\n\t\t\t'spam-stats', // Post type\r\n\t\t\t'normal', // Context, choose between 'normal', 'advanced', or 'side'\r\n\t\t\t'core' // Position, choose between 'high', 'core', 'default' or 'low'\r\n\t\t);\r\n\t}", "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}", "function si_custom_elements_icon_map( $icon_map ) {\n\t\t$icon_map['si_custom_elements'] = EXTENSION_URL . '/assets/svg/icons.svg';\n\t\treturn $icon_map;\n\t}", "public function test_current_map()\n {\n $this->assertSame('Heelsum Single 01', $this->postScriptumServer->currentMap());\n }", "function Add_Shortcode_metabox() \n{\n add_meta_box('shortcode_metabox_id', 'Shordcode', 'Display_Shortcode_metabox', 'Flipbox');\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}", "function tnz_tooltip_metabox() {\n\tadd_meta_box( 'cpt_tnz_tooltip_box', __( 'Tooltip Shortcode', '' ), 'tnz_tooltip_metabox_content', 'tnz_tooltip', 'side', 'high' );\n}", "public function metaboxes()\n\t{\n\t\t$this->admin()->metaboxes();\n\t}", "function render_countries_meta() {\n\t\t$arrayofcountries = $this->load_countries_from_xml();\n\t\t?>\n\t\t<select name=\"country_list\" style=\"width:265px;\">\n\t\t\t<?php\n\t\t\tfor ( $numerofcountries = 0; $numerofcountries <= count( $arrayofcountries ) - 1; $numerofcountries++ ) {\n\t\t\t\t$values = wp_parse_args( $arrayofcountries[$numerofcountries][0], array(\n\t\t\t\t\t'countrycode' => '',\n\t\t\t\t\t'countryname' => ''\n\t\t\t\t) );\n\t\t\t\techo '<option ' . selected( $values['countrycode'], $values['countrycode'], false ) . ' value=\"' . $values['countrycode'] . '\">' . $values['countryname'] . '</option>';\n\t\t\t}\n\t\t\t?>\n\t\t</select>\n\t\t<?php\n\t\techo '<p>' . __( 'Quick links to countries are in progress!', 'countries' ) . '</p>';\n\t}", "function listing_category_add_new_meta_field() { \n\t$map_countries = array(\n\t\t'Australia',\n\t\t'Brazil',\n\t\t'China',\n\t\t'Cyprus',\n\t\t'France',\n\t\t'India',\n\t\t'Indonesia',\n\t\t'Lithuania',\n\t\t'Malaysia',\n\t\t'New Zealand',\n\t\t'Panama',\n\t\t'Philippines',\n\t\t'Singapore',\n\t\t'Spain',\n\t\t'Thailand',\n\t\t'Turkey',\n\t\t'United Kingdom',\n\t\t'United States'\n\t);\n\t$map_zoom_levels = array(3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18);\n?>\n\t<div class=\"form-field\">\n\t\t<label for=\"listing_cat_meta[def_map_country]\"><?php _e( 'Manage Map Setting', 'listing_category' ); ?></label>\n\t\t<div class=\"map_setting_wrap\">\n\t\t\t<select name=\"listing_cat_meta[def_map_country]\" id=\"listing_cat_meta[def_map_country]\" class=\"sel_map_country map_setting_input_bdr\">\n\t\t\t\t<option value=\"\">Select Country For Google Map Setting</option>\n\t\t\t\t<?php foreach($map_countries as $map_country):?>\n\t\t\t\t\t<option value=\"<?php echo $map_country;?>\"><?php echo $map_country;?></option>\n\t\t\t\t<?php endforeach;?>\n\t\t\t</select>\n\t\t\t<span class=\"map_setting_divider\">\n\t\t\t\t<b>OR</b>\n\t\t\t</span>\n\t\t\t<div class=\"lat_long_wrap\">\n\t\t\t\t<label for=\"listing_cat_meta[latitude]\">Latitude</label>\n\t\t\t\t<input type=\"text\" name=\"listing_cat_meta[latitude]\" id=\"listing_cat_meta[latitude]\" class=\"map_setting_input_bdr\">\n\t\t\t\t<label for=\"listing_cat_meta[longitude]\">Longitude</label>\n\t\t\t\t<input type=\"text\" name=\"listing_cat_meta[longitude]\" id=\"listing_cat_meta[longitude]\" class=\"map_setting_input_bdr\">\n\t\t\t</div>\n\t\t</div>\n\t</div>\n\t<div class=\"form-field\">\n\t\t<label for=\"listing_cat_meta[zoom_level]\"><?php _e( 'Select Zoom Level For Map Setting', 'listing_category' ); ?></label>\n\t\t<select name=\"listing_cat_meta[zoom_level]\" id=\"listing_cat_meta[zoom_level]\" class=\"sel_zoom_level\">\n\t\t\t<?php foreach($map_zoom_levels as $zoom_level):?>\n\t\t\t<?php if($zoom_level == 11):?>\n\t\t\t<option value=\"<?php echo $zoom_level;?>\" selected=\"selected\"><?php echo $zoom_level;?></option>\n\t\t\t<?php else:?>\n\t\t\t<option value=\"<?php echo $zoom_level;?>\"><?php echo $zoom_level;?></option>\n\t\t\t<?php endif;?>\n\t\t\t<?php endforeach;?>\n\t\t</select>\n\t</div>\n<?php }", "public function setup_meta_box() {\n\t\t\tadd_meta_box( 'add-shortcode-section', __( 'Shortcode', IFLANG ), array( $this, 'meta_box' ), 'nav-menus', 'side', 'high' );\n\t\t}", "function createstring_MapDisplaySlider() {\n\n $content = '';\n if ( $this->slplus->is_CheckTrue( $this->addon->options['show_maptoggle'] ) ) {\n $content =\n $this->CreateSliderButton(\n 'maptoggle',\n ! $this->slplus->is_CheckTrue( $this->addon->options['hide_map'] ),\n \"jQuery('#map').toggle();jQuery('#slp_tagline').toggle();\"\n );\n }\n\n return $content;\n }", "function cmb2_sample_metaboxes() {\n\n // Start with an underscore to hide fields from custom fields list\n $prefix = '_datum_konani_';\n\n /**\n * Initiate the metabox\n */\n $cmb = new_cmb2_box( array(\n 'id' => 'test_metabox',\n 'title' => __( 'Doplňující informace', 'cmb2' ),\n 'object_types' => array( 'post', ), // Post type\n 'context' => 'normal',\n 'priority' => 'high',\n 'show_names' => true, // Show field names on the left\n // 'cmb_styles' => false, // false to disable the CMB stylesheet\n // 'closed' => true, // Keep the metabox closed by default\n ) );\n\n // Regular text field\n $cmb->add_field( array(\n\t\t'name' => esc_html__( 'Datum konání', 'cmb2' ),\n\t\t'desc' => esc_html__( 'vyberte v kalendáři', 'cmb2' ),\n\t\t'id' => $prefix . 'textdate',\n\t\t'type' => 'text_date',\n\t\t// 'date_format' => 'Y-m-d',\n\t\t) );\n\n}", "function metaboxes_output( $post, $metabox, $data ) {\n\n\t\tswitch ( $metabox ): case 'example-metabox': ?>\n\t\n\t\t\t<p>\n\t <label for=\"description\">Post Type Description:</label>\n\t <input id=\"description\" class=\"widefat\" type=\"text\" name=\"description\" value=\"<?php echo esc_attr( $data['description'] ); ?>\">\n\t </p>\n\n\t <p>\n\t <label for=\"date\">Post Type Date:</label>\n\t <input id=\"date\" class=\"widefat\" type=\"date\" name=\"date\" value=\"<?php echo esc_attr( $data['date'] ); ?>\">\n\t </p>\n\n\t\t<?php break;\n\n\t\tendswitch;\n\n\t}", "function truckindia_page_metabox() {\n\t$prefix = 'truckindia_page_';\n\n\t/**\n\t * Sample metabox to pagenstrate each field type included\n\t */\n\t$cmb_page = new_cmb2_box( array(\n\t\t'id' => $prefix . 'metabox',\n\t\t'title' => esc_html__( 'Page Option', 'cmb2' ),\n\t\t'object_types' => array( 'page' ), // Post type\n\n\t) );\n\n\n\t$cmb_page->add_field( array(\n\t\t'name' => esc_html__( 'Hide Page Header', 'cmb2' ),\n\t\t'desc' => esc_html__( '', 'cmb2' ),\n\t\t'id' => $prefix . 'hide_page_header',\n\t\t'type' => 'checkbox',\n\t) );\n\n\t$cmb_page->add_field( array(\n\t\t'name' => esc_html__( 'page short description', 'cmb2' ),\n\t\t'desc' => esc_html__( 'type your name here', 'cmb2' ),\n\t\t'id' => $prefix . 'textmedium1',\n\t\t'type' => 'text_medium',\n\t) );\n\n\t$cmb_page->add_field( array(\n\t\t'name' => esc_html__( 'Developed By', 'cmb2' ),\n\t\t'desc' => esc_html__( '', 'cmb2' ),\n\t\t'id' => $prefix . 'readonly',\n\t\t'type' => 'text_medium',\n\t\t'default' => esc_attr__( 'Aromal', 'cmb2' ),\n\t\t'save_field' => false, // Disables the saving of this field.\n\t\t'attributes' => array(\n\t\t\t'disabled' => 'disabled',\n\t\t\t'readonly' => 'readonly',\n\t\t),\n\t) );\n\n\n}", "static function metabox_at_post_edit_page(){\n\t\t \tadd_meta_box('matebox-to-handle-keywords', 'Affiliate Keywords', array(get_class(), 'metabox_to_deal_keywords'), 'product', 'advanced', 'high');\t \t\n\t\t }", "public static function registerMetaBoxes() {}", "function carrousel_metaboxes(){\n add_meta_box(\"MonCarrousel\", \"lien\", \"carrousel_metabox\");\n}", "private function setmapMode(){\n\n\t\t$this->mapMode = array(\n\t\t\t'befe'=>\t$this->settings['mapMode'], /* bad content from outside ... so use properly */\n\t\t\t'isbe'=>\tstristr($this->settings['mapMode'],'backend') !== false,\n\t\t);\n\t}", "function vulcan_page_meta_boxes() {\r\r\n $meta_boxes = array(\r\r\n \"short_desc\" => array(\r\r\n \"name\" => \"short_desc\",\r\r\n \"title\" => \"Short Description\",\r\r\n \"description\" => \"Add short description to your pages.\",\r\r\n \"type\" => \"textarea\"\r\r\n ),\r\r\n \"page_thumbnail_image\" => array(\r\r\n \"name\" => \"page_thumbnail_image\",\r\r\n \"title\" => \"Thumbnail Image\",\r\r\n \"description\" => \"Add thumbnail image url, will be use for your page thumbnail, for example in Services child pages list.\",\r\r\n \"type\" => \"text\"\r\r\n )\r\r\n );\r\r\n \r\r\n return $meta_boxes;\r\r\n}", "public function get_items_field() {\n\t\treturn 'premium_maps_map_pins';\n\t}", "private function generateAvailableUnits()\n {\n $code = rtrim($this->compileUnitTypes());\n\n return <<<EOF\n\n private \\$unitTypes = array(\n $code\n );\nEOF;\n }", "function cmb2_sample_metaboxes() {\n\t$prefix = '_simple_rec_';\n\n\t/**\n\t * Initiate the metabox\n\t */\n\t$cmb = new_cmb2_box( array(\n\t\t'id' => 'simple_rec_metabox',\n\t\t'title' => __( 'Recruitment Data', 'simple-rec' ),\n\t\t'object_types' => array( 'simple_rec'), // Post type\n\t\t'context' => 'normal',\n\t\t'priority' => 'high',\n\t\t'show_names' => true, \n\t) );\n\n\t// Regular text field\n\t$cmb->add_field( array(\n\t\t'name' => __( 'Name', 'simple-rec' ),\n\t\t'id' => $prefix . 'name',\n\t\t'type' => 'text',\n\t) );\n\n\t// Email text field\n\t$cmb->add_field( array(\n\t\t'name' => __( 'Email', 'simple-rec' ),\n\t\t'id' => $prefix . 'email',\n\t\t'type' => 'text_email',\n\t) );\n}", "function register_metaboxes() {\n\n\t\t$this->metaboxes = array(\n\t\t\t'example-metabox' => array(\n\t\t\t\t'title' => 'Example Post Type Metabox',\n\t\t\t\t'context' => 'normal',\n\t\t\t\t'priority' => 'high',\n\t\t\t\t'fields' => array(\n\t\t\t\t\t'description',\n\t\t\t\t\t'date'\n\t\t\t\t)\n\t\t\t)\n\t\t);\n\n\t\tparent::register_metaboxes();\n\n\t}", "public function register_metaboxes(){\n\t\tif ($this->options('use_metabox')){\n\t\t\t$metabox = $this->metabox();\n\t\t\tadd_meta_box(\n\t\t\t\t$metabox['id'],\n\t\t\t\t$metabox['title'],\n\t\t\t\t'show_meta_boxes',\n\t\t\t\t$metabox['page'],\n\t\t\t\t$metabox['context'],\n\t\t\t\t$metabox['priority']\n\t\t\t);\n\t\t}\n\t}", "function add_meta_box() {\t\t\n\t\t\t/* Gets available public post types. */\n\t\t\t$post_types = get_post_types( array( 'public' => true ), 'objects' );\n\t\t\t\n\t\t\t$post_types = apply_filters( 'remove_youtube_white_label_meta_box', $post_types );\n\t\t\t\n\t\t\t/* For each available post type, create a meta box on its edit page if it supports '$prefix-post-settings'. */\n\t\t\tforeach ( $post_types as $type ) {\n\t\t\t\t/* Add the meta box. */\n\t\t\t\tadd_meta_box( self::DOMAIN . \"-{$type->name}-meta-box\", __( 'YouTube Embed Shortcode Creator (does not save meta)', self::DOMAIN ), array( $this, 'meta_box' ), $type->name, 'side', 'default' );\n\t\t\t}\n\t\t}", "function vcex_milestone_vc_map() {\n\tvc_map( array(\n\t\t'name' => __( 'Milestone', 'wpex' ),\n\t\t'description' => __( 'Animated counter', 'wpex' ),\n\t\t'base' => 'vcex_milestone',\n\t\t'icon' => 'vcex-milestone vcex-icon fa fa-medium',\n\t\t'category' => WPEX_THEME_BRANDING,\n\t\t'params' => array(\n\t\t\t// General\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'admin_label' => true,\n\t\t\t\t'heading' => __( 'Unique Id', 'wpex' ),\n\t\t\t\t'param_name' => 'unique_id',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'admin_label' => true,\n\t\t\t\t'heading' => __( 'Classes', 'wpex' ),\n\t\t\t\t'param_name' => 'classes',\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Visibility', 'wpex' ),\n\t\t\t\t'param_name' => 'visibility',\n\t\t\t\t'value' => array_flip( wpex_visibility() ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Appear Animation', 'wpex' ),\n\t\t\t\t'param_name' => 'css_animation',\n\t\t\t\t'value' => array_flip( wpex_css_animations() ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Hover Animation', 'wpex'),\n\t\t\t\t'param_name' => 'hover_animation',\n\t\t\t\t'value' => array_flip( wpex_hover_css_animations() ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Animated', 'wpex' ),\n\t\t\t\t'param_name' => 'animated',\n\t\t\t\t'std' => 'true',\n\t\t\t\t'value' => array(\n\t\t\t\t\t__( 'Yes', 'wpex') => 'true',\n\t\t\t\t\t__( 'No', 'wpex' ) => 'false',\n\t\t\t\t),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Speed', 'wpex' ),\n\t\t\t\t'param_name' => 'speed',\n\t\t\t\t'value' => '2500',\n\t\t\t\t'description' => __('The number of milliseconds it should take to finish counting.','wpex'),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Refresh Interval', 'wpex' ),\n\t\t\t\t'param_name' => 'interval',\n\t\t\t\t'value' => '50',\n\t\t\t\t'description' => __('The number of milliseconds to wait between refreshing the counter.','wpex'),\n\t\t\t),\n\t\t\t// Number\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'admin_label' => true,\n\t\t\t\t'heading' => __( 'Number', 'wpex' ),\n\t\t\t\t'param_name' => 'number',\n\t\t\t\t'std' => '45',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Before', 'wpex' ),\n\t\t\t\t'param_name' => 'before',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'After', 'wpex' ),\n\t\t\t\t'param_name' => 'after',\n\t\t\t\t'default' => '%',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Font Family', 'wpex' ),\n\t\t\t\t'param_name' => 'number_font_family',\n\t\t\t\t'std' => '',\n\t\t\t\t'value' => vcex_fonts_array(),\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t'heading' => __( 'Color', 'wpex' ),\n\t\t\t\t'param_name' => 'number_color',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Font Size', 'wpex' ),\n\t\t\t\t'param_name' => 'number_size',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Font Weight', 'wpex' ),\n\t\t\t\t'param_name' => 'number_weight',\n\t\t\t\t'value' => array_flip( wpex_font_weights() ),\n\t\t\t\t'std' => '',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Bottom Margin', 'wpex' ),\n\t\t\t\t'param_name' => 'number_bottom_margin',\n\t\t\t\t'group' => __( 'Number', 'wpex' ),\n\t\t\t),\n\t\t\t// caption\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'class' => 'vcex-animated-counter-caption',\n\t\t\t\t'heading' => __( 'Caption', 'wpex' ),\n\t\t\t\t'param_name' => 'caption',\n\t\t\t\t'value' => 'Awards Won',\n\t\t\t\t'admin_label' => true,\n\t\t\t\t'group' => __( 'Caption', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Font Family', 'wpex' ),\n\t\t\t\t'param_name' => 'caption_font_family',\n\t\t\t\t'std' => '',\n\t\t\t\t'value' => vcex_fonts_array(),\n\t\t\t\t'group' => __( 'Caption', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t'heading' => __( 'Color', 'wpex' ),\n\t\t\t\t'param_name' => 'caption_color',\n\t\t\t\t'group' => __( 'Caption', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Font Size', 'wpex' ),\n\t\t\t\t'param_name' => 'caption_size',\n\t\t\t\t'group' => __( 'Caption', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Font Weight', 'wpex' ),\n\t\t\t\t'param_name' => 'caption_font',\n\t\t\t\t'value' => array_flip( wpex_font_weights() ),\n\t\t\t\t'std' => '',\n\t\t\t\t'group' => __( 'Caption', 'wpex' ),\n\t\t\t),\n\t\t\t// Link\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'URL', 'wpex' ),\n\t\t\t\t'param_name' => 'url',\n\t\t\t\t'group' => __( 'Link', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'URL Target', 'wpex' ),\n\t\t\t\t'param_name' => 'url_target',\n\t\t\t\t'value' => array(\n\t\t\t\t\t__( 'Self', 'wpex') => 'self',\n\t\t\t\t\t__( 'Blank', 'wpex' ) => 'blank',\n\t\t\t\t),\n\t\t\t\t'group' => __( 'Link', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'URl Rel', 'wpex' ),\n\t\t\t\t'param_name' => 'url_rel',\n\t\t\t\t'value' => array(\n\t\t\t\t\t__( 'None', 'wpex') => '',\n\t\t\t\t\t__( 'Nofollow', 'wpex' ) => 'nofollow',\n\t\t\t\t),\n\n\t\t\t\t'group' => __( 'Link', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'dropdown',\n\t\t\t\t'heading' => __( 'Link Container Wrap', 'wpex' ),\n\t\t\t\t'param_name' => 'url_wrap',\n\t\t\t\t'value' => array(\n\t\t\t\t\t__( 'Default', 'wpex' ) => '',\n\t\t\t\t\t__( 'No', 'wpex' ) => 'false',\n\t\t\t\t\t__( 'Yes', 'wpex' ) => 'true',\n\t\t\t\t),\n\t\t\t\t'group' => __( 'Link', 'wpex' ),\n\t\t\t\t'description' => __( 'Apply the link to the entire wrapper?', 'wpex' ),\n\t\t\t),\n\t\t\t\n\t\t\t// CSS\n\t\t\tarray(\n\t\t\t\t'type' => 'css_editor',\n\t\t\t\t'heading' => __( 'Design', 'wpex' ),\n\t\t\t\t'param_name' => 'css',\n\t\t\t\t'group' => __( 'Design options', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Width', 'wpex' ),\n\t\t\t\t'param_name' => 'width',\n\t\t\t\t'group' => __( 'Design options', 'wpex' ),\n\t\t\t),\n\t\t\tarray(\n\t\t\t\t'type' => 'textfield',\n\t\t\t\t'heading' => __( 'Border Radius', 'wpex' ),\n\t\t\t\t'param_name' => 'border_radius',\n\t\t\t\t'group' => __( 'Design options', 'wpex' ),\n\t\t\t),\n\t\t)\n\t) );\n}", "public function unit()\n {\n $data = ['aktif' => 'unit',\n 'data_unit' => $this->M_prospektus->get_unit_menu()->result_array(),\n 'data_blok' => $this->M_prospektus->get_blok_kws()->result_array()\n ];\n\n $this->template->load('template','prospektus/V_data_unit', $data);\n }", "public function add_metabox() {\n\t\tadd_meta_box(\n\t\t\t'Translation',\n\t\t\t'Translation',\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'meta_box',\n\t\t\t),\n\t\t\t'words',\n\t\t\t'side',\n\t\t\t'high'\n\t\t);\n\t}", "function cspm_add_locations_tabs($metabox_object, $metabox_options){\r\n\t\t\t\r\n\t\t\t/**\r\n\t\t\t * Setting tabs */\r\n\t\t\t \r\n\t\t\t$tabs_setting = array(\r\n\t\t\t\t'args' => $metabox_options,\r\n\t\t\t\t'tabs' => array()\r\n\t\t\t);\r\n\t\t\t\t\r\n\t\t\t\t/**\r\n\t\t\t\t * Tabs array */\r\n\t\t\t\t \r\n\t\t\t\t$cspm_tabs = array(\r\n\t\t\t\t\t\r\n\t\t\t\t\t/**\r\n\t\t\t\t \t * Coordinates */\r\n\t\t\t\t\t \r\n\t\t\t\t\tarray(\r\n\t\t\t\t\t\t'id' => 'post_coordinates', \r\n\t\t\t\t\t\t'title' => 'GPS Coordinates', \r\n\t\t\t\t\t\t'callback' => 'cspm_post_coordinates_fields'\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 \t * Marker */\r\n\t\t\t\t\t \r\n\t\t\t\t\tarray(\r\n\t\t\t\t\t\t'id' => 'post_marker', \r\n\t\t\t\t\t\t'title' => 'Marker', \r\n\t\t\t\t\t\t'callback' => 'cspm_post_marker_fields'\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 \t * Marker Label\r\n\t\t\t\t\t * @since 5.5 */\r\n\t\t\t\t\t \r\n\t\t\t\t\tarray(\r\n\t\t\t\t\t\t'id' => 'post_marker_label', \r\n\t\t\t\t\t\t'title' => 'Marker Label', \r\n\t\t\t\t\t\t'callback' => 'cspm_post_marker_label_fields'\r\n\t\t\t\t\t),\r\n\r\n\t\t\t\t\t/**\r\n\t\t\t\t \t * Format & Media */\r\n\t\t\t\t\t \r\n\t\t\t\t\tarray(\r\n\t\t\t\t\t\t'id' => 'post_format_and_media', \r\n\t\t\t\t\t\t'title' => 'Format & Media', \r\n\t\t\t\t\t\t'callback' => 'cspm_post_format_and_media'\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/**\r\n\t\t\t\t * Custom Fields of the extension \"Submit locations\"\r\n\t\t\t\t * @since 5.3 */\r\n\t\t\t\t\r\n\t\t\t\tif(class_exists('CspmSubmitLocations')){ \r\n\t\t\t\t\t$cspm_tabs[] = array(\r\n\t\t\t\t\t\t'id' => 'post_submited_custom_fields', \r\n\t\t\t\t\t\t'title' => 'Custom Fields', \r\n\t\t\t\t\t\t'callback' => 'cspm_post_submit_locations_custom_fields'\r\n\t\t\t\t\t);\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tforeach($cspm_tabs as $tab_data){\r\n\t\t\t\t \r\n\t\t\t\t\t$tabs_setting['tabs'][] = array(\r\n\t\t\t\t\t\t'id' => 'cspm_' . $tab_data['id'],\r\n\t\t\t\t\t\t'title' => '<span class=\"cspm_tabs_menu_image\"><img src=\"'.$this->plugin_url.'admin/img/add-locations-metabox/'.str_replace('_', '-', $tab_data['id']).'.png\" style=\"width:20px;\" /></span> <span class=\"cspm_tabs_menu_item\">'.esc_attr__( $tab_data['title'], 'cspm' ).'</span>',\t\t\t\t\t\t\r\n\t\t\t\t\t\t'fields' => call_user_func(array($this, $tab_data['callback'])),\r\n\t\t\t\t\t);\r\n\t\t\r\n\t\t\t\t}\r\n\t\t\t\r\n\t\t\t/*\r\n\t\t\t * Set tabs */\r\n\t\t\t \r\n\t\t\t$metabox_object->add_field( array(\r\n\t\t\t\t'id' => 'cspm_add_locations_tabs',\r\n\t\t\t\t'type' => 'tabs',\r\n\t\t\t\t'tabs' => $tabs_setting\r\n\t\t\t) );\r\n\t\t\t\r\n\t\t\treturn $metabox_object;\r\n\t\t\t\r\n\t\t}", "function wp_nav_menu_post_type_meta_boxes()\n {\n }", "public abstract function render( \\RWC\\Metabox $metabox );", "public function getMcode()\n {\n return $this->mcode;\n }", "public function handleShortcodes($attr, $content)\r\n {\r\n $this->mapNum++;\r\n $mapInfo = $this->getMapDetails($attr, $content);\r\n if (function_exists('json_encode')) {\r\n \t$json = json_encode($mapInfo);\r\n } else {\r\n\t\t\trequire_once('json_encode.php');\r\n \t$json = Zend_Json_Encoder::encode($mapInfo);\r\n\t\t}\r\n\r\n return <<<mapCode\r\n<div id='map_{$this->mapNum}' style='width:{$mapInfo->width}; height:{$mapInfo->height};' class='googleMap'></div>\r\n<div id='dir_{$this->mapNum}'></div>\r\n<script type=\"text/javascript\">\r\n//<![CDATA[\r\nif (GBrowserIsCompatible()) {\r\n wpGMaps.wpNewMap({$this->mapNum}, {$json});\r\n}\r\n//]]>\r\n</script>\r\nmapCode;\r\n }", "function adonepage_adonepagecmb_metaboxes( array $meta_boxes ) {\r\n\r\n\trequire('gfonts-list.php');\r\n\trequire('pattern-list.php');\r\n\t\r\n\t$fields = array(\r\n\t\t\r\n\t\tarray( 'id' => 'block-name', \r\n\t\t\t\t'name' => 'Block Name', \r\n\t\t\t\t'type' => 'text',\r\n\t\t\t\t'cols' => 2\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-pattern', \r\n\t\t\t'name' => 'Pattern', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => $pattern_list,\r\n\t\t\t'cols' => 2\t\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'block-pattern-color', \r\n\t\t\t'name' => 'Pattern BG Color', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4 \t\t \r\n\t\t),\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-pattern-opacity', \r\n\t\t\t'name' => 'Pattern Opacity (0.1 to 1)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-active-menu', \r\n\t\t\t'name' => 'Show Name In Menu',\r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'yes' => 'Yes',\r\n\t\t\t\t\t\t'no' => 'no'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4\t\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-active', \r\n\t\t\t'name' => 'Show Name',\r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'yes' => 'Yes',\r\n\t\t\t\t\t\t'no' => 'no'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4\t\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-effects', \r\n\t\t\t'name' => 'Name Effects',\r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array(\r\n\t\t\t\t\t\t'none' => 'none', \r\n\t\t\t\t\t\t'left' => 'Left',\r\n\t\t\t\t\t\t'right' => 'Right'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4\t\t\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-font-size', \r\n\t\t\t'name' => 'Size', \r\n\t\t\t'type' => 'text', \r\n\t\t\t'cols' => 2 \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-position', \r\n\t\t\t'name' => 'Position', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'left' => 'left', \r\n\t\t\t\t\t\t'right' => 'right',\r\n\t\t\t\t\t\t'center' => 'center'\t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 2\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-font-style', \r\n\t\t\t'name' => 'Name Style', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'normal' => 'Normal', \r\n\t\t\t\t\t\t'italic' => 'Italic',\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 2 \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-font-weight', \r\n\t\t\t'name' => 'Name Font Weight', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \t\t\t\t\t \r\n\t\t\t\t\t 'normal' => 'normal',\r\n\t\t\t\t\t\t'100' => '100', \r\n\t\t\t\t\t\t'200' => '200',\r\n\t\t\t\t\t\t'300' => '300', \r\n\t\t\t\t\t\t'400' => '400',\r\n\t\t\t\t\t\t'500' => '500', \r\n\t\t\t\t\t\t'600' => '600',\r\n\t\t\t\t\t\t'700' => '700', \r\n\t\t\t\t\t\t'800' => '800',\r\n\t\t\t\t\t\t'900' => '900', \t\t\t\t\t\t\t\t\t\t\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'cols' => 2 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'block-name-font-color', \r\n\t\t\t'name' => 'Name Font Color', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4 \r\n\t\t),\t\t\t\t\t\t\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-height', \r\n\t\t\t'name' => 'Block Height',\t\t\t \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'auto' => 'auto', \r\n\t\t\t\t\t\t'100%' => '100%',\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t\t),\r\n\t\t\t'cols' => 2\r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-wrapper-padding', \r\n\t\t\t'name' => 'Wrap Padding',\r\n\t\t\t'desc' => 'ex 20px or 120px 0 120px 0',\t\t\t \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 2\r\n\t\t),\t\t \t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-wrapper-custom-active', \r\n\t\t\t'name' => 'Active Block Wrapper',\r\n\t\t\t'desc' => 'If you active this option you can customize wrapper width of single block', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'off' => 'Off',\r\n\t\t\t\t\t\t'on' => 'On'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 3\t\t\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-wrapper-custom', \r\n\t\t\t'name' => 'Wrapper Block (Leave Empty for 100%)',\r\n\t\t\t'desc' => 'Work Only if you set \"Active Block Wrapper\" on ON', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 5\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-type-active', \r\n\t\t\t'name' => 'Choose Block Background', \r\n\t\t\t'desc' => 'Choose while background you want on onepage block', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'color' => 'Color',\r\n\t\t\t\t\t\t'image' => 'Image',\r\n\t\t\t\t\t\t'video' => 'Video'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 12\t\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-image-title', \r\n\t\t\t'name' => 'Image Background', \r\n\t\t\t'type' => 'title', \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-image', \r\n\t\t\t'name' => 'Background Block', \r\n\t\t\t'type' => 'image', \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'show_size' => false,\r\n\t\t\t'cols' => 12\t\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-color-title', \r\n\t\t\t'name' => 'Color Background', \r\n\t\t\t'type' => 'title', \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-color', \r\n\t\t\t'name' => 'Color BG', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 12\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-video-title', \r\n\t\t\t'name' => 'Video Background', \r\n\t\t\t'type' => 'title', \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-video', \r\n\t\t\t'name' => 'Youtube Url Video', \r\n\t\t\t'type' => 'url',\r\n\t\t\t'cols' => 6\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-video-audio', \r\n\t\t\t'name' => 'Audio', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'false' => 'On',\r\n\t\t\t\t\t\t'true' => 'Off'\t\t\t\t\t\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'cols' => 6\t \r\n\t\t),\t\r\n\t\t/*\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-slider-title', \r\n\t\t\t'name' => 'Slider Background', \r\n\t\t\t'type' => 'title', \r\n\t\t),\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-slider-image', \r\n\t\t\t'name' => 'Slider Image', \r\n\t\t\t'type' => 'image',\r\n\t\t\t'repeatable' => true,\r\n\t\t\t'sortable' => true,\r\n\t\t\t'cols' => 4\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-slider-text', \r\n\t\t\t'name' => 'Slider Text', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'repeatable' => true,\r\n\t\t\t'sortable' => true,\r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'bg-slider-text-effects', \r\n\t\t\t'name' => 'Slider Text Effects', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'solid' => 'solid',\r\n\t\t\t\t\t\t'dashed' => 'dashed',\r\n\t\t\t\t\t\t'dotted' => 'dotted',\r\n\t\t\t\t\t\t'double' => 'double',\r\n\t\t\t\t\t\t'groove' => 'groove',\r\n\t\t\t\t\t\t'ridge' => 'ridge',\r\n\t\t\t\t\t\t'inset' => 'inset',\r\n\t\t\t\t\t\t'outset' => 'outset',\r\n\t\t\t\t\t\t'initial' => 'initial'\t\t\t\t\t\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'repeatable' => true,\r\n\t\t\t'sortable' => true,\r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\t*/\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'content-block', \r\n\t\t\t'name' => 'Content Block', \r\n\t\t\t'type' => 'wysiwyg', \r\n\t\t\t'options' => array( \r\n\t\t\t\t'editor_height' => '100' \r\n\t\t\t), \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'sortable' => false \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'block-border-px', \r\n\t\t\t'name' => 'Block Px Border Bottom (ex 3)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'block-border-bottom-color', \r\n\t\t\t'name' => 'Color Boder Bottom', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4\t\t\t \r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'block-border-bottom-type', \r\n\t\t\t'name' => 'Border Type', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'solid' => 'solid',\r\n\t\t\t\t\t\t'dashed' => 'dashed',\r\n\t\t\t\t\t\t'dotted' => 'dotted',\r\n\t\t\t\t\t\t'double' => 'double',\r\n\t\t\t\t\t\t'groove' => 'groove',\r\n\t\t\t\t\t\t'ridge' => 'ridge',\r\n\t\t\t\t\t\t'inset' => 'inset',\r\n\t\t\t\t\t\t'outset' => 'outset',\r\n\t\t\t\t\t\t'initial' => 'initial'\t\t\t\t\t\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'cols' => 4\t \r\n\t\t),\t\t\t\r\n\t);\r\n\r\n\r\n\r\n\t$fields_slider = array( \t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-slider-image', \r\n\t\t\t'name' => 'Slider Image', \r\n\t\t\t'type' => 'image',\r\n\t\t\t'size' => 'height=200&width=795'\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-slider-content-area', \r\n\t\t\t'name' => 'Slider Content Area',\r\n\t\t\t'type' => 'wysiwyg',\r\n\t\t\t'options' => array( \r\n\t\t\t\t'editor_height' => '200' \r\n\t\t\t)\t\t\t\r\n\t\t)\t\t\t\t\t\t\r\n\t);\r\n\r\n\r\n\r\n\r\n\t$first_block = array(\r\n\t\t\r\n\t\tarray( 'id' => 'first-block-name', \r\n\t\t\t\t'name' => 'Block Name', \r\n\t\t\t\t'type' => 'text',\r\n\t\t\t\t'cols' => 4\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-pattern', \r\n\t\t\t'name' => 'Pattern', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => $pattern_list,\r\n\t\t\t'cols' => 2\t\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-pattern-color', \r\n\t\t\t'name' => 'Pattern BG Color', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4 \t\t \r\n\t\t),\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-pattern-opacity', \r\n\t\t\t'name' => 'Pattern Opacity (0.1 to 1)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 2\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-name-active-menu', \r\n\t\t\t'name' => 'Show Name In Menu',\r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'yes' => 'Yes',\r\n\t\t\t\t\t\t'no' => 'no'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 6\t\t\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-height', \r\n\t\t\t'name' => 'Block Height',\t\t\t \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'auto' => 'auto', \r\n\t\t\t\t\t\t'100%' => '100%',\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t\t),\r\n\t\t\t'cols' => 6\r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-wrapper-padding', \r\n\t\t\t'name' => 'Wrap Padding',\r\n\t\t\t'desc' => 'ex 20px or 120px 0 120px 0',\t\t\t \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 3\r\n\t\t),\t\t \t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-wrapper-custom-active', \r\n\t\t\t'name' => 'Active Block Wrapper',\r\n\t\t\t'desc' => 'If you active this option you can customize wrapper width of single block', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'off' => 'Off',\r\n\t\t\t\t\t\t'on' => 'On'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4\t\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-wrapper-custom', \r\n\t\t\t'name' => 'Wrapper Block (Leave Empty for 100%)',\r\n\t\t\t'desc' => 'Work Only if you set \"Active Block Wrapper\" on ON', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 5\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-type-active', \r\n\t\t\t'name' => 'Choose Block Background', \r\n\t\t\t'desc' => 'Choose while background you want on onepage block', \r\n\t\t\t'type' => 'radio', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'color' => 'Color',\r\n\t\t\t\t\t\t'image' => 'Image',\r\n\t\t\t\t\t\t'video' => 'Video',\r\n\t\t\t\t\t\t'slider' => 'Slider'\t\t\t\t\t\t\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 12\t\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-image-title', \r\n\t\t\t'name' => 'Image Background', \r\n\t\t\t'type' => 'title', \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-image', \r\n\t\t\t'name' => 'Background Block', \r\n\t\t\t'type' => 'image', \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'show_size' => false,\r\n\t\t\t'cols' => 12\t\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-color-title', \r\n\t\t\t'name' => 'Color Background', \r\n\t\t\t'type' => 'title', \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-color', \r\n\t\t\t'name' => 'Color BG', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 12\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-video-title', \r\n\t\t\t'name' => 'Video Background', \r\n\t\t\t'type' => 'title', \r\n\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-video', \r\n\t\t\t'name' => 'Url Video', \r\n\t\t\t'type' => 'url',\r\n\t\t\t'cols' => 6\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-video-audio', \r\n\t\t\t'name' => 'Audio', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'false' => 'On',\r\n\t\t\t\t\t\t'true' => 'Off'\t\t\t\t\t\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'cols' => 6\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-slider-title', \r\n\t\t\t'name' => 'Slider Option', \r\n\t\t\t'type' => 'title', \r\n\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-slider-spinner', \r\n\t\t\t'name' => 'Type Spinner', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'plane' => 'Plane',\r\n\t\t\t\t\t\t'bounce' => 'Bounce',\r\n\t\t\t\t\t\t'wave' => 'Wave',\r\n\t\t\t\t\t\t'cubes' => 'Cubes',\r\n\t\t\t\t\t\t'pulse' => 'Pulse',\r\n\t\t\t\t\t\t'dots' => 'Dots',\r\n\t\t\t\t\t\t'three-bounce' => 'Three Bounce',\r\n\t\t\t\t\t\t'circle' => 'Circle'\t\t\t\t\t\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'cols' => 4\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-slider-spinner-color', \r\n\t\t\t'name' => 'Spinner Color', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-bg-slider-spinner-bg-color', \r\n\t\t\t'name' => 'Spinner Background Color', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4\t \r\n\t\t),/*\r\n\t\tarray( \r\n\t\t\t'id' => 'first-slider-effects', \r\n\t\t\t'name' => 'Slider Effects', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'fade' \t\t\t=> 'fade',\r\n\t\t\t\t\t\t'fadeZoom' \t\t=> 'fadeZoom',\r\n\t\t\t\t\t\t'blindX' \t\t=> 'blindX',\r\n\t\t\t\t\t\t'blindY' \t\t=> 'blindY',\r\n\t\t\t\t\t\t'blindZ' \t\t=> 'blindZ',\r\n\t\t\t\t\t\t'cover' \t\t=> 'cover',\r\n\t\t\t\t\t\t'curtainX' \t\t=> 'curtainX',\r\n\t\t\t\t\t\t'curtainY' \t\t=> 'curtainY',\r\n\t\t\t\t\t\t'growX' \t\t=> 'growX',\r\n\t\t\t\t\t\t'growY' \t\t=> 'growY',\t\r\n\t\t\t\t\t\t'cover' \t\t=> 'cover',\r\n\t\t\t\t\t\t'none' \t\t\t=> 'none',\r\n\t\t\t\t\t\t'scrollUp' \t\t=> 'scrollUp',\r\n\t\t\t\t\t\t'scrollDown' \t=> 'scrollDown',\r\n\t\t\t\t\t\t'scrollLeft' \t=> 'scrollLeft',\t\t\t\t\t\t\r\n\t\t\t\t\t\t'scrollRight' \t=> 'scrollRight',\r\n\t\t\t\t\t\t'scrollHorz' \t=> 'scrollHorz',\r\n\t\t\t\t\t\t'scrollVert' \t=> 'scrollVert',\r\n\t\t\t\t\t\t'shuffle' \t\t=> 'shuffle',\t\t\t\t\t\t\r\n\t\t\t\t\t\t'slideX' \t\t=> 'slideX',\r\n\t\t\t\t\t\t'slideY' \t\t=> 'slideY',\r\n\t\t\t\t\t\t'toss' \t\t\t=> 'toss',\t\t\t\t\t\t\r\n\t\t\t\t\t\t'turnUp' \t\t=> 'turnUp',\r\n\t\t\t\t\t\t'turnDown' \t\t=> 'turnDown',\r\n\t\t\t\t\t\t'turnLeft' \t\t=> 'turnLeft',\r\n\t\t\t\t\t\t'turnRight'\t\t=> 'turnRight',\t\t\t\t\t\t\r\n\t\t\t\t\t\t'uncover'\t\t=> 'uncover',\r\n\t\t\t\t\t\t'wipe' \t\t\t=> 'wipe',\r\n\t\t\t\t\t\t'zoom' \t\t\t=> 'zoom'\t\t\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'cols' => 4\t \r\n\t\t),\t*/\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-slider-autoplay', \r\n\t\t\t'name' => 'Slider Autoplay', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'yes' \t=> 'Yes',\r\n\t\t\t\t\t\t'no' \t=> 'no'\t\t\t\t\t\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'cols' => 6\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-slider-speed', \r\n\t\t\t'name' => 'Slider Speed (ex 1000)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 6 \t \r\n\t\t),\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'slider-group', \r\n\t\t\t'name' => 'Slider Background', \r\n\t\t\t'type' => 'group',\r\n\t\t\t'repeatable' => true, \r\n\t\t\t'sortable' => true,\r\n\t\t\t'fields' => $fields_slider // An array of fields. \r\n\t\t),\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-content-block', \r\n\t\t\t'name' => 'Content Block', \r\n\t\t\t'type' => 'wysiwyg', \r\n\t\t\t'options' => array( \r\n\t\t\t\t'editor_height' => '100' \r\n\t\t\t), \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'sortable' => false \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-border-px', \r\n\t\t\t'name' => 'Block Px Border Bottom (ex 3)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-border-bottom-color', \r\n\t\t\t'name' => 'Color Boder Bottom', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4\t\t\t \r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'first-block-border-bottom-type', \r\n\t\t\t'name' => 'Border Type', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'solid' => 'solid',\r\n\t\t\t\t\t\t'dashed' => 'dashed',\r\n\t\t\t\t\t\t'dotted' => 'dotted',\r\n\t\t\t\t\t\t'double' => 'double',\r\n\t\t\t\t\t\t'groove' => 'groove',\r\n\t\t\t\t\t\t'ridge' => 'ridge',\r\n\t\t\t\t\t\t'inset' => 'inset',\r\n\t\t\t\t\t\t'outset' => 'outset',\r\n\t\t\t\t\t\t'initial' => 'initial'\t\t\t\t\t\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'cols' => 4\t \r\n\t\t),\t\t\t\r\n\t);\r\n\r\n\r\n\r\n\r\n\r\n\t// Groups and Columns\r\n\r\n\t$general_configuration = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'adonepage-logo', \r\n\t\t\t'name' => 'Logo', \r\n\t\t\t'type' => 'image', \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'show_size' => false, \r\n\t\t\t'cols' => 6\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'adonepage-favicon', \r\n\t\t\t'name' => 'Favicon', \r\n\t\t\t'type' => 'image', \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'show_size' => false,\r\n\t\t\t'cols' => 6\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'wrapper-width', \r\n\t\t\t'name' => 'Wrapper Width (Ex: 1000 - Empty for 100%)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'logo-position', \r\n\t\t\t'name' => 'Logo Position', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'left' => 'left', \r\n\t\t\t\t\t\t'right' => 'right'\t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'logo-link', \r\n\t\t\t'name' => 'Logo Link', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'home' => 'Home', \r\n\t\t\t\t\t\t'Page' => 'Page'\t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4\r\n\t\t),\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'font-family', \r\n\t\t\t'name' => 'Font Family', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => $adonepage_gfonts_list, \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'font-style', \r\n\t\t\t'name' => 'Font Style', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'normal' => 'Normal', \r\n\t\t\t\t\t\t'italic' => 'Italic',\r\n\t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'font-weight', \r\n\t\t\t'name' => 'Font Weight', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \t\t\t\t\t \r\n\t\t\t\t\t 'normal' => 'normal',\r\n\t\t\t\t\t\t'100' => '100', \r\n\t\t\t\t\t\t'200' => '200',\r\n\t\t\t\t\t\t'300' => '300', \r\n\t\t\t\t\t\t'400' => '400',\r\n\t\t\t\t\t\t'500' => '500', \r\n\t\t\t\t\t\t'600' => '600',\r\n\t\t\t\t\t\t'700' => '700', \r\n\t\t\t\t\t\t'800' => '800',\r\n\t\t\t\t\t\t'900' => '900', \t\t\t\t\t\t\t\t\t\t\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'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'font-color', \r\n\t\t\t'name' => 'Font Color', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'color-link', \r\n\t\t\t'name' => 'Color Link', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'color-link-over', \r\n\t\t\t'name' => 'Color Link Over', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4 \r\n\t\t)\r\n\t);\r\n\r\n\t$menu_list1 = array();\r\n\t\r\n\t$menu_list1[] = 'landing-page';\r\n\t$menu_list1[] = 'adonepage-menu';\t\r\n\t\r\n\t$adonepage_number_menu = get_option( 'adonepage_number_menu', '' );\r\n\t\tif(!empty($adonepage_number_menu)) {\r\n\t\t\tfor($i=1;$i<=$adonepage_number_menu;$i++) {\r\n\t\t\t\t$menu_list1[] = 'adonepage-menu-'.$i.'';\r\n\t\t\t}\r\n\t\t}\t\r\n\t$menu_list2 = array();\t\r\n\t\r\n\t$menu_list2[] = 'Landing Page';\r\n\t$menu_list2[] = 'Wp Menu (ADOnePage)';\r\n\t\t\t\r\n\t\tif(!empty($adonepage_number_menu)) {\r\n\t\t\tfor($i=1;$i<=$adonepage_number_menu;$i++) {\r\n\t\t\t\t$menu_list2[] = 'Wp Menu (ADOnePage) '.$i.'';\r\n\t\t\t}\r\n\t\t}\t\r\n\t\r\n\t$menu_list = array_combine($menu_list1, $menu_list2);\r\n\t\t\r\n\t$menu_configuration = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'menu', \r\n\t\t\t'name' => 'Select Menu', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => $menu_list, \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-position', \r\n\t\t\t'name' => 'Position Menu', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'top' => 'Top', \r\n\t\t\t\t\t\t'bottom' => 'Bottom' \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'active-sticky-menu', \r\n\t\t\t'name' => 'Type Menu', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'normal' => 'normal (Sticky menu OFF)', \r\n\t\t\t\t\t\t'stickymenu' => 'Sticky Menu',\r\n\t\t\t\t\t\t'stickymenu-v2' => 'Sticky Menu (First Slide no menu)',\r\n\t\t\t\t\t\t),\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-font-family', \r\n\t\t\t'name' => 'Menu Font Family', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => $adonepage_gfonts_list, \r\n\t\t\t'cols' => 3 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-font-family-weight', \r\n\t\t\t'name' => 'Menu Font Weight', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \t\t\t\t\t \r\n\t\t\t\t\t 'normal' => 'normal',\r\n\t\t\t\t\t\t'100' => '100', \r\n\t\t\t\t\t\t'200' => '200',\r\n\t\t\t\t\t\t'300' => '300', \r\n\t\t\t\t\t\t'400' => '400',\r\n\t\t\t\t\t\t'500' => '500', \r\n\t\t\t\t\t\t'600' => '600',\r\n\t\t\t\t\t\t'700' => '700', \r\n\t\t\t\t\t\t'800' => '800',\r\n\t\t\t\t\t\t'900' => '900', \t\t\t\t\t\t\t\t\t\t\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'cols' => 2 \r\n\t\t),\t\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-bg-color', \r\n\t\t\t'name' => 'Color Background', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-bg-opacity', \r\n\t\t\t'name' => 'Opacity Background (0.1 to 1)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 3\r\n\t\t),\t\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-font-color', \r\n\t\t\t'name' => 'Font Color', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-font-color-over', \r\n\t\t\t'name' => 'Font Color Over', \r\n\t\t\t'type' => 'colorpicker', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'woocommerce-menu-active', \r\n\t\t\t'name' => 'Woocommerce Menu', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'off' => 'Off',\r\n\t\t\t\t\t\t'on' => 'On'\t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4 \r\n\t\t),\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-border-size', \r\n\t\t\t'name' => 'Border Bottom Size (ex 1)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-border-color', \r\n\t\t\t'name' => 'Border Bottom Color', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'menu-border-shadow', \r\n\t\t\t'name' => 'Border Shadow', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'on' => 'On', \r\n\t\t\t\t\t\t'off' => 'Off' \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 4 \r\n\t\t),\t\t\t\t\t\t\t\t\t\t\r\n\t);\r\n\r\n\t$seo_configuration = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'title-page', \r\n\t\t\t'name' => 'SEO: Page Title', \r\n\t\t\t'type' => 'textarea', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'description-page', \r\n\t\t\t'name' => 'SEO: Page Description', \r\n\t\t\t'type' => 'textarea', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'keyword-page', \r\n\t\t\t'name' => 'SEO: Page Keyword', \r\n\t\t\t'type' => 'textarea', \r\n\t\t\t'cols' => 4\t\t\r\n\t\t)\r\n\t);\r\n\r\n\t$footer_configuration = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-active', \r\n\t\t\t'name' => 'Footer Active', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'on' => 'On', \r\n\t\t\t\t\t\t'off' => 'Off' \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 2 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-pattern', \r\n\t\t\t'name' => 'Footer Pattern', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => $pattern_list,\r\n\t\t\t'cols' => 2 \t\t \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-pattern-color', \r\n\t\t\t'name' => 'Pattern BG Color', \r\n\t\t\t'type' => 'colorpicker',\r\n\t\t\t'cols' => 4 \t\t \r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-pattern-opacity', \r\n\t\t\t'name' => 'P. Opacity (0.1 to 1)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 2\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-bg-type', \r\n\t\t\t'name' => 'Choose Block BG', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'color' => 'color',\r\n\t\t\t\t\t\t'image' => 'image'\r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 2 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-bg-image', \r\n\t\t\t'name' => 'Background Footer', \r\n\t\t\t'type' => 'image', \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'show_size' => false,\r\n\t\t\t'size' => 'height=400&width=1000'\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-bg-color', \r\n\t\t\t'name' => 'Color BG Footer', \r\n\t\t\t'type' => 'colorpicker' \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'active-widget', \r\n\t\t\t'name' => 'Active Widget', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'on' => 'On', \r\n\t\t\t\t\t\t'off' => 'Off' \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 6 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'number-column-widget', \r\n\t\t\t'name' => 'Number column Widget', \r\n\t\t\t'type' => 'select', \r\n\t\t\t'options' => array( \r\n\t\t\t\t\t\t'1' => '1', \r\n\t\t\t\t\t\t'2' => '2',\r\n\t\t\t\t\t\t'3' => '3', \r\n\t\t\t\t\t\t'4' => '4' \t\t\t\t\t\t \r\n\t\t\t\t\t\t), \r\n\t\t\t'cols' => 6\t\t\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'footer-text', \r\n\t\t\t'name' => 'Footer Content', \r\n\t\t\t'type' => 'wysiwyg', \r\n\t\t\t'options' => array( \r\n\t\t\t\t'editor_height' => '200' \r\n\t\t\t), \r\n\t\t\t'repeatable' => false, \r\n\t\t\t'sortable' => false \r\n\t\t)\r\n\t);\r\n\r\n\t$advanced_configuration = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'analytics', \r\n\t\t\t'name' => 'Analytics Code', \r\n\t\t\t'type' => 'textarea', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'custom-css', \r\n\t\t\t'name' => 'Custom CSS', \r\n\t\t\t'type' => 'textarea', \r\n\t\t\t'cols' => 4 \r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'custom-js', \r\n\t\t\t'name' => 'Custom JS', \r\n\t\t\t'type' => 'textarea', \r\n\t\t\t'cols' => 4\t\t\r\n\t\t)\r\n\t);\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'General Configuration',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => $general_configuration\r\n\t);\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'Menu Configuration',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => $menu_configuration\r\n\t);\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'First Block',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => $first_block\r\n\t);\r\n\t\r\n\t// Example of repeatable group. Using all fields.\r\n\t// For this example, copy fields from $fields, update I\r\n\t$group_fields = $fields;\r\n\tforeach ( $group_fields as &$field ) {\r\n\t\t$field['id'] = str_replace( 'field', 'gfield', $field['id'] );\r\n\t}\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'Landing Page Block',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => array(\r\n\t\t\tarray( \r\n\t\t\t\t'id' => 'gp', \r\n\t\t\t\t'name' => 'Block for Landing Page', \r\n\t\t\t\t'type' => 'group', \r\n\t\t\t\t'repeatable' => true,\r\n\t\t\t\t'sortable' => true,\r\n\t\t\t\t'fields' => $group_fields,\r\n\t\t\t\t'desc' => 'Compile your landing page block'\r\n\t\t\t)\r\n\t\t)\r\n\t);\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'Footer',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => $footer_configuration\r\n\t);\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'SEO Configuration',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => $seo_configuration\r\n\t);\r\n\t\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'Advanced Configuration',\r\n\t\t'pages' => 'adonepage',\r\n\t\t'fields' => $advanced_configuration\r\n\t);\r\n\t\r\n\r\n\t$gallery_image = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'gallery-image', \r\n\t\t\t'name' => 'Image', \r\n\t\t\t'type' => 'image', \r\n\t\t\t'repeatable' => true, \r\n\t\t\t'show_size' => false,\r\n\t\t\t'size' => 'height=400&width=1000'\r\n\t\t)\r\n\t);\t\r\n\t\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'GALLERY',\r\n\t\t'pages' => 'adgallery_post',\r\n\t\t'fields' => $gallery_image\r\n\t);\r\n\r\n\t$team_fields = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'facebook-team', \r\n\t\t\t'name' => 'Facebook Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'twitter-team', \r\n\t\t\t'name' => 'Twitter Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'googleplus-team', \r\n\t\t\t'name' => 'Google Plus Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'google-team', \r\n\t\t\t'name' => 'Google Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'vimeo-team', \r\n\t\t\t'name' => 'Vimeo Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\t\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'feed-team', \r\n\t\t\t'name' => 'Feed Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'youtube-team', \r\n\t\t\t'name' => 'Youtube Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'flickr-team', \r\n\t\t\t'name' => 'Flickr Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\t\t\t\t\t\r\n\t\tarray( \r\n\t\t\t'id' => 'linkedin-team', \r\n\t\t\t'name' => 'Linkedin Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'tumblr-team', \r\n\t\t\t'name' => 'Tumblr Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'blogger-team', \r\n\t\t\t'name' => 'Blogger Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'mail-team', \r\n\t\t\t'name' => 'Mail Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'github-team', \r\n\t\t\t'name' => 'Github Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'pinterest-team', \r\n\t\t\t'name' => 'Pinterest Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'skype-team', \r\n\t\t\t'name' => 'Skype Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\r\n\t\tarray( \r\n\t\t\t'id' => 'picassa-team', \r\n\t\t\t'name' => 'Picassa Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'dribbble-team', \r\n\t\t\t'name' => 'Dribbble Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\r\n\t\tarray( \r\n\t\t\t'id' => 'yahoo-team', \r\n\t\t\t'name' => 'Yahoo Link (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t),\t\t\t\t\t\t\t\t\r\n\t);\r\n\r\n\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'Social Team',\r\n\t\t'pages' => 'adteam_post',\r\n\t\t'fields' => $team_fields\r\n\t);\t\r\n\t\r\n\t\r\n\t$partner_fields = array(\r\n\t\tarray( \r\n\t\t\t'id' => 'url-partner', \r\n\t\t\t'name' => 'Url Link Partner (leave empty for disable)', \r\n\t\t\t'type' => 'text',\r\n\t\t\t'cols' => 4\r\n\t\t)\t\r\n\t);\r\n\t$meta_boxes[] = array(\r\n\t\t'title' => 'URL Partners',\r\n\t\t'pages' => 'adpartners_post',\r\n\t\t'fields' => $partner_fields\r\n\t);\t\r\n\t\r\n\treturn $meta_boxes;\r\n\r\n}", "function registry_add_post_meta_boxes() {\n\n add_meta_box(\n 'registry-info', // Unique ID\n 'When did you complete the Cozmeena Shawl?', // Title\n 'registry_coz_info_meta_box', // Callback function\n 'coz_registry', // Admin page (or post type)\n 'side', // Context\n 'core' // Priority\n );\n\n global $current_user;\n if($current_user->roles[0] == 'administrator') {\n add_meta_box(\n\t\t'registry-num', // Unique ID\n\t\t'International Cozmeena Registration Number', // Title\n\t\t'registry_coz_num_meta_box', // Callback function\n\t\t'coz_registry', // Admin page (or post type)\n\t\t'normal', // Context\n\t\t'low' // Priority\n\t\t);\n }\n}", "public function getMapID()\n {\n return sprintf('%s_Map', $this->getHTMLID());\n }", "public static function map() {\n\t\t\treturn array(\n\t\t\t\t'name' => __( 'Divider Dots', 'total' ),\n\t\t\t\t'description' => __( 'Dot Separator', 'total' ),\n\t\t\t\t'base' => 'vcex_divider_dots',\n\t\t\t\t'icon' => 'vcex-dots vcex-icon fa fa-ellipsis-h',\n\t\t\t\t'category' => wpex_get_theme_branding(),\n\t\t\t\t'params' => array(\n\t\t\t\t\t// General\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'vcex_visibility',\n\t\t\t\t\t\t'heading' => __( 'Visibility', 'total' ),\n\t\t\t\t\t\t'param_name' => 'visibility',\n\t\t\t\t\t),\n\t\t\t\t\tvcex_vc_map_add_css_animation(),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'textfield',\n\t\t\t\t\t\t'heading' => __( 'Extra class name', 'total' ),\n\t\t\t\t\t\t'param_name' => 'el_class',\n\t\t\t\t\t\t'description' => __( 'Style particular content element differently - add a class name and refer to it in custom CSS.', 'total' ),\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'vcex_text_alignments',\n\t\t\t\t\t\t'heading' => __( 'Align', 'total' ),\n\t\t\t\t\t\t'param_name' => 'align',\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'textfield',\n\t\t\t\t\t\t'heading' => __( 'Count', 'total' ),\n\t\t\t\t\t\t'param_name' => 'count',\n\t\t\t\t\t\t'value' => '3',\n\t\t\t\t\t\t'admin_label' => true,\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'textfield',\n\t\t\t\t\t\t'heading' => __( 'Size', 'total' ),\n\t\t\t\t\t\t'param_name' => 'size',\n\t\t\t\t\t\t'description' => __( 'Default', 'total' ) . ': 5px',\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'colorpicker',\n\t\t\t\t\t\t'heading' => __( 'Color', 'total' ),\n\t\t\t\t\t\t'param_name' => 'color',\n\t\t\t\t\t),\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'type' => 'vcex_trbl',\n\t\t\t\t\t\t'heading' => __( 'Margin', 'total' ),\n\t\t\t\t\t\t'param_name' => 'margin',\n\t\t\t\t\t),\n\t\t\t\t\t// Hidden Removed attributes\n\t\t\t\t\tarray( 'type' => 'hidden', 'param_name' => 'margin_top' ),\n\t\t\t\t\tarray( 'type' => 'hidden', 'param_name' => 'margin_bottom' ),\n\t\t\t\t),\n\t\t\t);\n\t\t}", "function mpfy_mt_map_location_custom_fields($custom_fields) {\n\n\t$custom_fields = mpfy_array_push_key($custom_fields, 'map_location_map', array(\n\t\t'map_location_tags'=>Carbon_Field::factory('map_tags', 'map_location_tags', 'Map Tags'),\n\t));\n\n\treturn $custom_fields;\n}", "function amap_ma_get_unit_of_measurement_string_simple() {\n $unitmeas = trim(elgg_get_plugin_setting('unitmeas', AMAP_MA_PLUGIN_ID));\n if ($unitmeas === 'meters') {\n return elgg_echo(\"amap_maps_api:search:meters\");\n } else if ($unitmeas === 'km') {\n return elgg_echo(\"amap_maps_api:search:km\");\n } else if ($unitmeas === 'miles') {\n return elgg_echo(\"amap_maps_api:search:miles\");\n }\n\n return elgg_echo(\"amap_maps_api:search:meters\"); // default value is for meters\n}" ]
[ "0.6468183", "0.58479995", "0.579256", "0.56953067", "0.56925803", "0.56658876", "0.5644808", "0.55971956", "0.55805874", "0.55689377", "0.5552088", "0.555088", "0.5535579", "0.541608", "0.5403218", "0.54004365", "0.53865427", "0.5365935", "0.5361866", "0.53326154", "0.5323825", "0.5321035", "0.53158814", "0.5271796", "0.52602", "0.5259395", "0.5205471", "0.5195526", "0.5188592", "0.51826704", "0.5177498", "0.517177", "0.51695174", "0.5155177", "0.5142637", "0.5141549", "0.51381654", "0.51267207", "0.5122867", "0.5113202", "0.51085985", "0.51006407", "0.5100252", "0.508058", "0.5076819", "0.5075644", "0.5066837", "0.505871", "0.505646", "0.50560105", "0.5052512", "0.50476646", "0.50436664", "0.5036287", "0.50354445", "0.5034606", "0.5026362", "0.50247324", "0.50234747", "0.5021911", "0.5007771", "0.4998028", "0.49910435", "0.49877185", "0.49868467", "0.4982974", "0.4977488", "0.49686024", "0.49549615", "0.49492595", "0.49471393", "0.49358553", "0.49356735", "0.49311876", "0.49293214", "0.4924766", "0.4922992", "0.4914957", "0.49089965", "0.49034366", "0.49024978", "0.48913527", "0.4887017", "0.48843035", "0.4875942", "0.48758993", "0.48737222", "0.48736736", "0.48703238", "0.4870059", "0.4869083", "0.4868982", "0.486895", "0.48616248", "0.48568684", "0.48557353", "0.48541245", "0.48501015", "0.48490226", "0.4846713" ]
0.6270081
1
Includes the unit gallery metabox code.
function _display_gallery_meta( $post ) { include( 'includes/metaboxes/gallery.php' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function devvn_gallery_meta_box() {\n\tadd_meta_box(\n\t\t'devvn-gallery-metabox',\n\t\t__( 'Gallery Option', 'devvn' ),\n\t\t'devvn_gallery_meta_box_callback',\n\t\t'gallery',\n\t\t'side',\n\t\t'high'\n\t);\n}", "function tg_add_product_gallery_metabox() { \n\t// More info about arguments in the WP Codex\n\tadd_meta_box(\n\t\t'product_gallery', // Name of the box\n\t\t'Gallery', // Title of the box\n\t\t'tg_product_gallery_metabox', // The metabox html function \n\t\t'post', // SET TO THE POST TYPE WHERE THE METABOX IS SHOWN\n\t\t'normal', // Specifies where the box is shown\n\t\t'high' // Specifies where the box is shown\n\t); \n}", "public static function metabox() {\n\t\techo SimpleTags_Admin::getDefaultContentBox();\n\t}", "public function add_meta_boxes() {\n add_meta_box( 'wc-product-label-gallery', __( 'Label gallery', 'wc-label-gallery' ), array( $this, 'gallery_output' ), 'product', 'side', 'low' );\n }", "function tg_product_gallery_metabox() {\n\tglobal $post;\n\t// Here we get the current images ids of the gallery\n\t$values = get_post_custom($post->ID);\n\tif(isset($values['product_gallery'])) {\n\t\t// The json decode return an array of image ids\n\t\t$ids = json_decode($values['product_gallery'][0]);\n\t}else {\n\t\t$ids = array();\n\t}\n\t//wp_nonce_field('my_meta_box_nonce', 'post_gallery_meta_box_nonce'); // Security\n\techo '<input type=\"hidden\" name=\"post_gallery_meta_box_nonce\" value=\"', wp_create_nonce(basename(__FILE__)), '\" />';\n\t// Implode the array to a comma separated list\n\t$cs_ids = implode(\",\", $ids); \n\t// We display the gallery\n\t$html = do_shortcode('[gallery ids=\"'.$cs_ids.'\"]');\n\t// Here we store the image ids which are used when saving the product\n\t$html .= '<input id=\"product_gallery_ids\" type=\"hidden\" name=\"product_gallery_ids\" value=\"'.$cs_ids. '\" />';\n\t// A button which we will bind to later on in JavaScript\n\t$html .= '<div class=\"clear_div\">';\n\t$html .= '<input id=\"manage_gallery\" title=\"Manage gallery\" type=\"button\" value=\"Manage gallery\" class=\"button-primary button-large\" />';\n\tif(!empty($cs_ids))\t{\n\t\t$html .= '&nbsp;&nbsp;<input id=\"remove_gallery\" title=\"Remove gallery\" type=\"button\" value=\"Remove gallery\" class=\"remove_gallery\" />';\n\t\t$html .= '</div>';\n\t}else{\n\t\t$html .= '&nbsp;&nbsp;<input id=\"remove_gallery\" title=\"Remove gallery\" type=\"button\" value=\"Remove gallery\" \n\t\tclass=\"remove_gallery\" style=\"display:none;\" />';\n\t\t$html .= '</div>';\t\t\n\t}\t\n\techo $html;\n}", "function igv_cmb_metaboxes() {\n\t$prefix = '_igv_';\n\n\t/**\n\t * Metaboxes declarations here\n * Reference: https://github.com/WebDevStudios/CMB2/blob/master/example-functions.php\n\t */\n\n}", "function add_meta_boxes() {\n\t\tif( function_exists( 'add_meta_box' ) ) {\n\t\t\tadd_meta_box( 'unit-info', __('Unit Information'), array( $this, '_display_unitinfo_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'maps', __('Maps'), array( $this, '_display_maps_meta'), 'units', 'normal', 'high');\n\t\t\tadd_meta_box( 'gallery', __('Gallery'), array( $this, '_display_gallery_meta'), 'units', 'normal', 'low');\n\t\t\tadd_meta_box( 'unit-status', __('Availability'), array( $this, '_display_status_meta'), 'units', 'side', 'high');\n\t\t}\n\t}", "function _display_unitinfo_meta( $post ) {\n\t\tinclude( 'includes/metaboxes/unit-info.php' );\n\t}", "function wpbm_shortcode_usage_metabox(){\n add_meta_box( 'wpbm_shortcode_usage_option', __( 'WP Blog Manager Usage', WPBM_TD ), array( $this, 'wpbm_shortcode_usage' ), 'wpblogmanager', 'side', 'default' );\n }", "public function metabox_content() {\n\t\t\n\t\t\n\t\t\n\t}", "function rng_METANAME_metabox_init() {\n}", "function listing_image_add_metabox () {\n\t\tadd_meta_box( 'listingimagediv', __( 'Image Containers Loop', 'text-domain' ), 'listing_image_metabox', 'product', 'side', 'low');\n\t}", "public function meta_box_gallery( $page ) {\n\t\t\t$this->draw_galleries_uploader();\n\t\t}", "function gallery_metaboxes( $post ) {\n global $wp_meta_boxes;\n\n remove_meta_box('postimagediv', 'gallery', 'side');\n add_meta_box('postimagediv', __('Featured Image'), 'post_thumbnail_meta_box', 'gallery', 'normal', 'high');\n}", "function the_block_editor_meta_boxes()\n {\n }", "function add_meta_box() {\t\t\n\t\t\t/* Gets available public post types. */\n\t\t\t$post_types = get_post_types( array( 'public' => true ), 'objects' );\n\t\t\t\n\t\t\t$post_types = apply_filters( 'remove_youtube_white_label_meta_box', $post_types );\n\t\t\t\n\t\t\t/* For each available post type, create a meta box on its edit page if it supports '$prefix-post-settings'. */\n\t\t\tforeach ( $post_types as $type ) {\n\t\t\t\t/* Add the meta box. */\n\t\t\t\tadd_meta_box( self::DOMAIN . \"-{$type->name}-meta-box\", __( 'YouTube Embed Shortcode Creator (does not save meta)', self::DOMAIN ), array( $this, 'meta_box' ), $type->name, 'side', 'default' );\n\t\t\t}\n\t\t}", "function mobile_kiosk_gallery_options_meta_box($object, $box) {\n\t\n\t// Try to load the gallery logo\n\t$gallery_logo_id = get_post_meta($object->ID, 'gallery_logo', TRUE);\n\t$thumbnail = (!empty($gallery_logo_id)) ? wp_get_attachment_image_src($gallery_logo_id, 'thumbnail', TRUE)[0] : NULL;\n\t\n\t// Get the available sources\n\t$sources = mobile_kiosk_get_slide_sources();\n\t\n\t// Get the sources for this gallery\n\t$selectedSources = (get_post_meta($object->ID, 'sources', TRUE)) ? get_post_meta($object->ID, 'sources', TRUE) : array();\n\t\n\t// Load our HTML template\n\tinclude('metaboxes/gallery_options.php');\n}", "function ev_gallery_add_box() {\n\tglobal $ev_gallery_metabox;\n\t\n\tadd_meta_box($ev_gallery_metabox['id'], $ev_gallery_metabox['title'], 'ev_gallery_show_box', $ev_gallery_metabox['page'], $ev_gallery_metabox['context'], $ev_gallery_metabox['priority']);\n}", "function ev_gallery_show_box() {\n\tglobal $ev_gallery_metabox, $post;\n\t\n\t// Use nonce for verification\n\techo '<input type=\"hidden\" name=\"ev_gallery_nonce\" value=\"', wp_create_nonce(basename(__FILE__)), '\" />';\n\t\n\techo '<table class=\"form-table\">';\n\n\tforeach ($ev_gallery_metabox['fields'] as $field) {\n\t\t// get current post meta data\n\t\t$meta = get_post_meta($post->ID, $field['id'], true);\n\t\t\n\t\techo '<tr>',\n\t\t\t\t'<th style=\"width:20%; vertical-align:middle;\"><label for=\"', $field['id'], '\" style=\"font-size:15px; color:#464646; text-shadow:0px 1px 0px #fff; font-family: Georgia, \\'Times New Roman\\', Times\">', $field['name'], '</label></th>',\n\t\t\t\t'<td>';\n\t\tswitch ($field['type']) {\n\t\t\tcase 'text':\n\t\t\t\techo '<input type=\"text\" name=\"', $field['id'], '\" id=\"', $field['id'], '\" value=\"', $meta ? $meta : $field['std'], '\" size=\"30\" style=\"width:97%\" />',\n\t\t\t\t\t'<br />', $field['desc'];\n\t\t\t\tbreak;\n\t\t}\n\t\techo \t'<td>',\n\t\t\t'</tr>';\n\t}\n\t\n\techo '</table>';\n\t\n}", "function pz_add_custom_meta_box()\n{\n add_meta_box(\n 'custom_meta_box',\n 'Custom Image Metabox',\n 'pz_custom_meta_box_callbacks',\n 'page', // page, post etc.\n 'normal',\n 'high');\n}", "public function setup_meta_box() {\n\t\t\tadd_meta_box( 'add-shortcode-section', __( 'Shortcode', IFLANG ), array( $this, 'meta_box' ), 'nav-menus', 'side', 'high' );\n\t\t}", "function thmplt_carousel_slide_meta(){\r\n\tadd_meta_box(\"thmplt_carousel_meta_box1\", \"Slide Settings\", \"thmplt_carousel_slide_settings_html\", \"thmplt_carousel\", \"normal\", \"high\");\r\n\tadd_meta_box(\"thmplt_carousel_meta_box2\", \"Slide Images\", \"thmplt_carousel_slide_settings_html2\", \"thmplt_carousel\", \"normal\", \"high\");\r\n}", "function pg_add_custom_box() {\r\n\tif( function_exists( 'add_meta_box' )) {\r\n\t\tadd_meta_box( 'pg_custom_box_1', __( 'Edit Photocrati Galleries / Albums', 'photocrati' ), 'pg_inner_custom_box_1', 'page', 'normal', 'high' );\r\n\t\tadd_meta_box( 'pg_custom_box_2', __( 'Edit Photocrati Galleries / Albums', 'photocrati' ), 'pg_inner_custom_box_1', 'post', 'normal', 'high' );\r\n\t}\r\n}", "function add_ingredienten_metabox(){\n\tadd_meta_box(\n\t\t'ingredienten_metabox',//id\n\t\t'Ingrediënten',//title\n\t\t'content_ingredienten_metabox',//callback\n\t\t'smaak',//page\n\t\t'normal', //context\n\t\t'high'//priority\n\t\t);\n}", "public function meta_box_gallery_code_callback( $post ) {\n\n // Load view\n $this->base->load_admin_partial( 'metabox-gallery-code', array(\n 'post' => $post,\n 'gallery_data' => get_post_meta( $post->ID, '_eg_gallery_data', true ),\n ) );\n\n }", "public static function add_metaboxes(){}", "function cmb2_gallery() {\n $prefix = '_gallery_';\n\n /**\n * Initiate the metabox\n */\n $cmb = new_cmb2_box( array(\n 'id' => 'gallery_metabox',\n 'title' => __( 'Galería de fotos', 'cmb2' ),\n 'object_types' => array( 'page', 'post' ), // post type\n //'object_types' => array( 'gallery'),\n //'show_on' => array( 'key' => 'page-template', 'value' => 'page-gallery.php' ),\n 'context' => 'normal',\n 'priority' => 'high',\n 'show_names' => true, // Show field names on the left\n // 'cmb_styles' => false, // false to disable the CMB stylesheet\n // 'closed' => true, // Keep the metabox closed by default\n ) );\n /*\n // Regular text field\n $cmb->add_field( array(\n 'name' => __( 'Teléfono', 'cmb2' ),\n 'desc' => __( 'agregar un telefono (opcional)', 'cmb2' ),\n 'id' => $prefix . 'phone',\n 'type' => 'text',\n 'repeatable' => true,\n 'show_on_cb' => 'cmb2_hide_if_no_cats', // function should return a bool value\n // 'sanitization_cb' => 'my_custom_sanitization', // custom sanitization callback parameter\n // 'escape_cb' => 'my_custom_escaping', // custom escaping callback parameter\n // 'on_front' => false, // Optionally designate a field to wp-admin only\n // 'repeatable' => true,\n ) );\n */\n\n // Regular text field\n $cmb->add_field( array(\n 'name' => 'Imágenes de la Galería',\n 'desc' => 'Subir y administrar imágenes',\n 'button' => 'Administrar Galería', // Optionally set button label\n 'id' => $prefix . 'images',\n 'type' => 'pw_gallery',\n 'sanitization_cb' => 'pw_gallery_field_sanitise',\n ));\n}", "public function metabox() {\n\n\t\t/**\n\t\t * Initialize the metabox\n\t\t */\n\t\t$cmb = new_cmb2_box( [\n\t\t\t'id' => 'expedia_hotel_data_metabox',\n\t\t\t'title' => __( 'Expedia Hotel Data', 'cmb2' ),\n\t\t\t'object_types' => [ 'hawaii-hotels' ], // Post type\n\t\t\t'context' => 'normal',\n\t\t\t'priority' => 'low',\n\t\t\t'show_names' => false, // Show field names on the left\n\t\t\t'closed' => true, // Metabox is closed by default\n\t\t\t'show_on_cb' => [ $this, 'excludeFromPages' ],\n\t\t] );\n\t}", "function greater_jackson_habitat_extra_metabox_content() {\n\t\n\tgreater_jackson_habitat_do_field_textarea( array(\n\t\t'name' => 'gjh_extra',\n\t\t'group' => 'gjh_extra',\n\t\t'wysiwyg' => true,\n\t) );\n\t\n\tgreater_jackson_habitat_init_field_group( 'gjh_extra' );\n\t\n}", "function edc_campos_galeria() {\n\t$prefix = 'edc_galeria_';\n\n\t/**\n\t * Repeatable Field Groups\n\t */\n\t$edc_galeria = new_cmb2_box( array(\n\t\t'id' => $prefix . 'metabox',\n\t\t'title' => esc_html__( 'Galería de Imágenes', 'cmb2' ),\n\t\t'object_types' => array( 'page' ),\n\t\t'context' \t=> 'normal',\n\t\t'priority'\t=> 'high',\n\t\t'show_names' => 'true',\n\t\t'show_on'\t\t=> array(\n\t\t\t'key'\t=> 'page-template',\n\t\t\t'value' => 'page-galeria.php'\n\t\t)\n\t) );\n\n\t$edc_galeria->add_field( array(\n\t\t'name' => esc_html__( 'Imágenes', 'cmb2' ),\n\t\t'desc' => esc_html__( 'Cargue las imágenes de la galería aquí', 'cmb2' ),\n\t\t'id' => $prefix . 'imagenes',\n\t\t'type' => 'file_list',\n\t\t'preview_size' => array( 100, 100 ), // Default: array( 50, 50 )\n\t) );\n}", "function portfolioism_add_custom_metabox() {\n add_meta_box(\n 'portfolioism_meta',\n 'Artwork',\n 'portfolioism_meta_callback',\n 'artwork'\n );\n }", "function metabox_styles() { ?>\n\t<style type=\"text/css\">\n\t.hidetable { display:none; }\n\t#uploadfield { width:500px; }\n\t#uploadfield input { display:inline; }\n\t.req { font-size:12px; color:#FF0000; font-weight:bold; }\n\t.attchmt { border-bottom:21px solid #666; padding:10px 0; margin:10px 0; }\n\t.prevImage { float:right; width:250px; text-align:center; }\n\t.fr { float:right; }\n\t</style>\n\t<?php\t\n}", "function Add_Shortcode_metabox() \n{\n add_meta_box('shortcode_metabox_id', 'Shordcode', 'Display_Shortcode_metabox', 'Flipbox');\n}", "public function register_metaboxes() {\n\n\t\t\twapu_core()->get_core()->init_module( 'cherry-post-meta', array(\n\t\t\t\t'id' => 'wapu_gallery',\n\t\t\t\t'title' => esc_html__( 'Gallery', 'wapu-core' ),\n\t\t\t\t'page' => array( $this->post_type ),\n\t\t\t\t'context' => 'normal',\n\t\t\t\t'priority' => 'high',\n\t\t\t\t'callback_args' => false,\n\t\t\t\t'fields' => array(\n\t\t\t\t\t'_wapu_single_large_thumb' => array(\n\t\t\t\t\t\t'type' => 'media',\n\t\t\t\t\t\t'title' => esc_html__( 'Single Large Image', 'wapu-core' ),\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t) );\n\n\t\t\twapu_core()->get_core()->init_module( 'cherry-post-meta', array(\n\t\t\t\t'id' => 'wapu_clear_caches',\n\t\t\t\t'title' => esc_html__( 'Clear Caches', 'wapu-core' ),\n\t\t\t\t'page' => array( $this->post_type ),\n\t\t\t\t'context' => 'side',\n\t\t\t\t'priority' => 'high',\n\t\t\t\t'callback_args' => false,\n\t\t\t\t'fields' => array(\n\t\t\t\t\t'_wapu_clear_reviews_cache' => array(\n\t\t\t\t\t\t'type' => 'html',\n\t\t\t\t\t\t'title' => esc_html__( 'Clear Reviews Cache', 'wapu-core' ),\n\t\t\t\t\t\t'html' => sprintf(\n\t\t\t\t\t\t\t'<a href=\"%s\" class=\"button\">Clear Reviews Cache</a><br><br>',\n\t\t\t\t\t\t\tadd_query_arg( array( 'clear_meta_cache' => '_rating_cache' ) )\n\t\t\t\t\t\t),\n\t\t\t\t\t),\n\t\t\t\t\t'_wapu_clear_terms_cache' => array(\n\t\t\t\t\t\t'type' => 'html',\n\t\t\t\t\t\t'title' => esc_html__( 'Clear Terms Cache', 'wapu-core' ),\n\t\t\t\t\t\t'html' => sprintf(\n\t\t\t\t\t\t\t'<a href=\"%s\" class=\"button\">Clear Terms Cache</a>',\n\t\t\t\t\t\t\tadd_query_arg( array( 'clear_meta_cache' => '_terms_cache' ) )\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\twapu_core()->get_core()->init_module( 'cherry-post-meta', array(\n\t\t\t\t'id' => 'wapu_misc',\n\t\t\t\t'title' => esc_html__( 'Misc Options', 'wapu-core' ),\n\t\t\t\t'page' => array( $this->post_type ),\n\t\t\t\t'context' => 'normal',\n\t\t\t\t'priority' => 'high',\n\t\t\t\t'callback_args' => false,\n\t\t\t\t'fields' => apply_filters(\n\t\t\t\t\t'wapu-core/edd/metabxes/misc',\n\t\t\t\t\tarray(\n\t\t\t\t\t\t'_wapu_ld_url' => array(\n\t\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t\t'title' => esc_html__( 'Live Demo URL', 'wapu-core' ),\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\twapu_core()->get_core()->init_module( 'cherry-term-meta', array(\n\t\t\t\t'tax' => 'download_category',\n\t\t\t\t'priority' => 10,\n\t\t\t\t'fields' => array(\n\t\t\t\t\t'_wapu_category_home' => array(\n\t\t\t\t\t\t'type' => 'text',\n\t\t\t\t\t\t'label' => 'Home URL for current category (for breadcrumbs)',\n\t\t\t\t\t),\n\t\t\t\t),\n\t\t\t) );\n\n\t\t}", "function meta_box( $object, $box ) {\n\t\t\n\t\t\t$meta_box_options = self::meta_box_args( $object->post_type );\n\t\t\n\t\t\tforeach ( $meta_box_options as $option ) {\n if ( method_exists( 'YouTube_White_Label_Shortcode', \"meta_box_{$option['type']}\" ) )\n call_user_func( array( $this, \"meta_box_{$option['type']}\" ), $option, get_post_meta( $object->ID, $option['name'], true ) );\n } ?>\n\t\t\t\n\t\t\t<p class=\"youtube-advanced-wrap\" style=\"text-align:right\"><a class=\"youtube-advanced\" href=\"#\"><?php _e( 'Advanced options', self::DOMAIN ); ?></a></p>\n \n <div id=\"youtube-advanced\" class=\"hide-if-js\"></div>\n \n <p class=\"output\">\n\t\t\t\t<label for=\"_YouTube_output\"><?php _e( 'Output:', self::DOMAIN ); ?></label>\n\t\t\t\t<br />\n\t\t\t\t<span id=\"_YouTube_output\" class=\"postbox\" style=\"box-sizing: border-box; display:block; min-height: 50px; padding: 5px;\"></span>\n\t\t\t</p>\n \n\t\t\t<!--<a id=\"youtube-send-to-content\" href=\"#\"><?php _e( 'send to content', self::DOMAIN ); ?></a>-->\n \n <div id=\"youtube-colorpicker\"></div>\n \n <?php printf( __( 'Like this plugin? <a href=\"%s\" target=\"_blank\">Buy me a beer</a>!', self::DOMAIN ), 'https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=XQRHECLPQ46TE' ); ?></p>\n\t\t\t<?php\n\t\t}", "function mt_testimonials_custom_meta_boxes() {\r\n \r\n /**\r\n * Create a custom meta boxes array that we pass to \r\n * the OptionTree Meta Box API Class.\r\n */\r\n \r\n $mt_testimonial_meta_box = array(\r\n 'id' => 'mt_testimonial_meta_box',\r\n 'title' => __('Item Customization', 'match'),\r\n 'desc' => '',\r\n 'pages' => array( 'mt_testimonials' ),\r\n 'context' => 'normal',\r\n 'priority' => 'high',\r\n 'fields' => array(\r\n \t array(\r\n 'label' => __('Client Name', 'match'),\r\n 'id' => 'mt_testimonial_client_name',\r\n 'type' => 'text',\r\n 'desc' => __('Add testimonial client name', 'match'),\r\n 'std' => 'John Doe',\r\n 'rows' => '',\r\n 'post_type' => '',\r\n 'taxonomy' => '',\r\n 'class' => '' \r\n ),\r\n\t \r\n\t array(\r\n 'label' => __('Client Company', 'match'),\r\n 'id' => 'mt_testimonial_client_company',\r\n 'type' => 'text',\r\n 'desc' => __('Add testimonial client company', 'match'),\r\n 'std' => 'Company Name',\r\n 'rows' => '',\r\n 'post_type' => '',\r\n 'taxonomy' => '',\r\n 'class' => '' \r\n ),\r\n\t \r\n\t array(\r\n 'label' => __('Client Small Image', 'match'),\r\n 'id' => 'mt_testimonial_client_img',\r\n 'type' => 'upload',\r\n 'desc' => __('Add testimonial client small image. Make sure is 70x70px.', 'match'),\r\n 'std' => '',\r\n 'rows' => '',\r\n 'post_type' => '',\r\n 'taxonomy' => '',\r\n 'class' => '' \r\n )\r\n\t \t \r\n \t)\r\n );\r\n \r\n /**\r\n * Register our meta boxes using the \r\n * ot_register_meta_box() function.\r\n */\r\n ot_register_meta_box( $mt_testimonial_meta_box );\r\n\r\n}", "public function display_meta_box() {\n\t\t\n\t\tinclude_once( 'views/q-and-a-admin.php' );\n }", "function media_upload_gallery()\n {\n }", "static function metabox($post){\n\t\twp_nonce_field( 'flat-options', 'flat-options_nonce' );\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\t\t\t\t\t\t\t\t\t\t\n\t\techo '<style>';\n\t\techo '.admin-meta-input{display:block; margin-top: 10px;}';\n\t\techo 'div.field-holder{display: block;float: left; margin: 10px 20px; height: 80px;}';\n\t\techo '.field-block{display: inline-block;clear: both;float: none;}';\n\t\techo '.postbox .inside .field-block h2{padding: 8px 12px;font-weight: 600;font-size: 18px;margin: 0;line-height: 1.4}';\n\t\techo '</style>';\n\t\t\t\t\t\n\t\t$fieldblocks = self::get_fields();\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Licitálással kapcsolatos adatok</h2>';\n\t\tforeach ($fieldblocks['licit'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Hely adatok</h2>';\n\t\tforeach ($fieldblocks['location'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Ingatlan adatok és településrendezési előírások</h2>';\n\t\tforeach ($fieldblocks['parameters'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Ingatlanjogi jellemzők</h2>';\n\t\tforeach ($fieldblocks['info'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\n\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Közművek, energiaellátás, telekommunikáció</h2>';\n\t\tforeach ($fieldblocks['sources'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\t\t\n\t\t\t\t\t\n\t\techo '<div class=\"field-block\">';\n\t\techo '<h2>Építmény (épület) jellemzői</h2>';\n\t\tforeach ($fieldblocks['building'] as $key => $field){\t\t\n\t\t\techo '<div class=\"field-holder\">';\n\t\t\techo '<label>' .$field['label']. '</label>';\n\t\t\techo '<input type=\"' .$field['type']. '\" class=\"admin-meta-input ' .$field['class']. '\" name=\"' .$key. '\" value=\"' .get_post_meta( $post->ID, $key, true ). '\" />';\t\t\t\n\t\t\techo \"</div>\";\n\t\t}\n\t\techo '</div>';\t\t\t\t\t\t\n\t\t\t\t\t\t\t\n\t\techo \"\n\t\t\t<script>\n\t\t\t\tjQuery(document).ready(function(){\n\t\t\t\t\tjQuery('.datepicker').datepicker();\t\n\t\t\t\t});\t\n\t\t\t</script>\t\n\t\t\";\n\t\t\n\t\techo '<br clear=\"all\">';\n\t\t\n }", "public function metaboxes()\n\t{\n\t\t$this->admin()->metaboxes();\n\t}", "public function add_meta_boxes() {\n\n global $post;\n\n // Check we're on an Envira Gallery\n if ( 'envira' != $post->post_type ) {\n return;\n }\n\n // Let's remove all of those dumb metaboxes from our post type screen to control the experience.\n $this->remove_all_the_metaboxes();\n \n // Add our metaboxes to Envira CPT.\n\n // Types Metabox\n // Allows the user to upload images or choose an External Gallery Type\n // We don't display this if the Gallery is a Dynamic or Default Gallery, as these settings don't apply\n $type = $this->get_config( 'type', $this->get_config_default( 'type' ) );\n if ( ! in_array( $type, array( 'defaults', 'dynamic' ) ) ) {\n add_meta_box( 'envira-gallery', __( 'Envira Gallery', 'envira-gallery' ), array( $this, 'meta_box_gallery_callback' ), 'envira', 'normal', 'high' );\n }\n\n // Settings Metabox\n add_meta_box( 'envira-gallery-settings', __( 'Envira Gallery Settings', 'envira-gallery' ), array( $this, 'meta_box_callback' ), 'envira', 'normal', 'high' );\n \n // Preview Metabox\n // Displays the images to be displayed when using an External Gallery Type\n // In the future, this could include a 'live' preview of the gallery theme options etc.\n add_meta_box( 'envira-gallery-preview', __( 'Envira Gallery Preview', 'envira-gallery' ), array( $this, 'meta_box_preview_callback' ), 'envira', 'normal', 'high' );\n \n // Display the Gallery Code metabox if we're editing an existing Gallery\n if ( $post->post_status != 'auto-draft' ) {\n add_meta_box( 'envira-gallery-code', __( 'Envira Gallery Code', 'envira-gallery' ), array( $this, 'meta_box_gallery_code_callback' ), 'envira', 'side', 'default' );\n }\n\n // Output 'Select Files from Other Sources' button on the media uploader form\n add_action( 'post-plupload-upload-ui', array( $this, 'append_media_upload_form' ), 1 );\n add_action( 'post-html-upload-ui', array( $this, 'append_media_upload_form' ), 1 );\n \n }", "function register_block_core_gallery()\n {\n }", "function add_audio_metaboxes() {\n\tadd_meta_box('wpt_vocal', 'Vocal', 'wpt_vocal', 'audio', 'normal', 'default');\n\tadd_meta_box('wpt_music', 'Music', 'wpt_music', 'audio', 'normal', 'default');\n\tadd_meta_box('wpt_rec_details', 'Recording Details', 'wpt_rec_details', 'audio', 'normal', 'default');\n \n}", "public function get_name() {\n\t\treturn 'gallery';\n\t}", "function kurama_custom_meta() {\n add_meta_box( 'kurama_meta', __( 'Display Options', 'kurama' ), 'kurama_meta_callback', 'page','side','high' );\n}", "function register_block_core_gallery() {\n\tregister_block_type_from_metadata(\n\t\t__DIR__ . '/gallery',\n\t\tarray(\n\t\t\t'render_callback' => function ( $attributes, $content ) {\n\t\t\t\treturn $content;\n\t\t\t},\n\t\t)\n\t);\n}", "public function add_the_meta_boxes() {\n\t add_meta_box(\n\t 'spat_options_metabox'\t\t\t\t\t// ID\n\t , __( 'Subpages As Tabs Options' ) \t\t// Title\n\t , array( $this, 'plugin_options_form' ) // Render Code function\n\t , $this->pagehook\t\t\t\t\t\t\t// Page hook\n\t , 'normal'\t\t\t\t\t\t\t\t// Context\n\t , 'core'\t\t\t\t\t\t\t\t// ??\n\t );\n\n\t add_meta_box(\n\t 'spat_demo_metabox'\t\t\t\t\t// ID\n\t , __( 'Preview' )\t\t\t\t\t\t\t// Title\n\t , array( $this, 'plugin_demo_page' ) \t// Render Code Function\n\t , $this->pagehook\t\t\t\t\t\t// Page hook\n\t , 'side'\t\t\t\t\t\t\t\t// Context\n\t , 'core'\t\t\t\t\t\t\t\t// ??\n\t );\n\t }", "function mobile_kiosk_add_post_meta_boxes() {\n\t\n\t// Gallery Options\n\tadd_meta_box(\n\t\t'gallery-options',\n\t\tesc_html__( 'Gallery Options', 'gallery-options' ),\n\t\t'mobile_kiosk_gallery_options_meta_box', \n\t\t'kioskgallery', \n\t\t'normal', \n\t\t'high' \n\t);\n\t\n\t// Gallery Slides\n\tadd_meta_box(\n\t\t'gallery-slides',\n\t\tesc_html__( 'Gallery Slides', 'gallery-slides' ),\n\t\t'mobile_kiosk_gallery_slides_meta_box', \n\t\t'kioskgallery', \n\t\t'normal', \n\t\t'low' \n\t);\n\t\n}", "function wpb_add_custom_meta_boxes() {\n\tglobal $post;\n\tif ('134' == $post -> ID) { \n\t\tadd_meta_box(\n\t\t\t'league_table',\n\t\t\t'League Table',\n\t\t\t'league_table_callback',\n\t\t\t'page'\n\t\t);\n\t}\n\n\tif ('136' == $post -> ID) { \n\t\tadd_meta_box(\n\t\t\t'league_table',\n\t\t\t'League Table',\n\t\t\t'league_table_callback',\n\t\t\t'page'\n\t\t);\n\t}\n\n\tif ('138' == $post -> ID) { \n\t\tadd_meta_box(\n\t\t\t'league_table',\n\t\t\t'League Table',\n\t\t\t'league_table_callback',\n\t\t\t'page'\n\t\t);\n\t}\n}", "function add_meta_box_horse_gallery() {\n\tglobal $meta_box_portfolio_images;\n\tadd_meta_box($meta_box_portfolio_images['id'], $meta_box_portfolio_images['title'], 'meta_box_horse_gallery', $meta_box_portfolio_images['page'], $meta_box_portfolio_images['context'], $meta_box_portfolio_images['priority']);\n}", "function my_top_right_help_metabox_content() { ?>\n <p>Assicurati di cliccare sul pulsante 'Pubblica' sottostante per pubblicare la nuova voce del menù, oppure 'Aggiorna' per salvare le modifiche.</p>\n<?php }", "function add_meta_boxes() {\r\n\t\tglobal $post;\r\n\t\t$code = get_post_meta($post->ID, $this->meta_value_key, true);\r\n\t\tif (empty($code) && $this->check_genesis())\treturn false;\r\n\t\t\r\n\t\t$screens = array('page', 'post');\r\n\t\tforeach ($screens as $screen) {\r\n\t\t\tadd_meta_box('embed_js', 'Embed JS (eg, Adwords Conversion Code)', array($this,'metabox_embed_js'), $screen, 'normal', 'low');\r\n\t\t}\r\n\t}", "function MetaBox()\n\t{\n\t\t\n\t\t// wordpress global\n\t\tglobal $post;\n\n\t\t// grab meta data, if it exists\n\t\t$tlsp_text = get_post_meta( $post->ID, 'tlsp_text', true );\n\n\t\t// use a nonce for verification\n\t\twp_nonce_field( plugin_basename(__FILE__), 'tlsp_noncename' );\n\t\t\n\t\t// this is the html for the metabox\n\t\t$security = 1;\n\t\tinclude( 'metabox-html.php' );\n\t\t$security = 0;\n\t\t\n\t}", "function zilla_metabox_posts() {\n $meta_box = array(\n 'id' => 'zilla-metabox-post-gallery',\n 'title' => __('Gallery Settings', 'zilla'),\n 'description' => __('Set up your gallery.', 'zilla'),\n 'page' => 'post',\n 'context' => 'normal',\n 'priority' => 'high',\n 'fields' => array(\n array(\n 'name' => __('Upload Images', 'zilla'),\n 'desc' => __('Click to upload images.', 'zilla'),\n 'id' => '_zilla_gallery_upload',\n 'type' => 'images',\n 'std' => __('Upload Images', 'zilla')\n )\n )\n );\n zilla_add_meta_box( $meta_box );\n\n /* Create a quote metabox -----------------------------------------------------*/\n $meta_box = array(\n 'id' => 'zilla-metabox-post-quote',\n 'title' => __('Quote Settings', 'zilla'),\n 'description' => __('Input your quote.', 'zilla'),\n 'page' => 'post',\n 'context' => 'normal',\n 'priority' => 'high',\n 'fields' => array(\n array(\n 'name' => __('The Quote', 'zilla'),\n 'desc' => __('Input your quote.', 'zilla'),\n 'id' => '_zilla_quote_quote',\n 'type' => 'textarea',\n 'std' => ''\n ),\n array(\n 'name' => __('The Author', 'zilla'),\n 'desc' => __('Input the quote\\'s author.', 'zilla'),\n 'id' => '_zilla_quote_author',\n 'type' => 'text',\n 'std' => ''\n ),\n array(\n 'name' => __('Author Description', 'zilla'),\n 'desc' => __('Input a description for the quote\\'s author.', 'zilla'),\n 'id' => '_zilla_quote_description',\n 'type' => 'text',\n 'std' => ''\n )\n )\n );\n zilla_add_meta_box( $meta_box );\n\n /* Create a link metabox ----------------------------------------------------*/\n $meta_box = array(\n 'id' => 'zilla-metabox-post-link',\n 'title' => __('Link Settings', 'zilla'),\n 'description' => __('Input your link', 'zilla'),\n 'page' => 'post',\n 'context' => 'normal',\n 'priority' => 'high',\n 'fields' => array(\n array(\n 'name' => __('', 'zilla'),\n 'desc' => __('', 'zilla'),\n 'id' => '_zilla_link_url',\n 'type' => 'text',\n 'std' => ''\n )\n )\n );\n zilla_add_meta_box( $meta_box );\n\n /* Create a video metabox -------------------------------------------------------*/\n $meta_box = array(\n 'id' => 'zilla-metabox-post-video',\n 'title' => __('Video Settings', 'zilla'),\n 'description' => __('These settings enable you to embed videos into your posts.', 'zilla'),\n 'page' => 'post',\n 'context' => 'normal',\n 'priority' => 'high',\n 'fields' => array(\n array(\n 'name' => __('M4V File URL', 'zilla'),\n 'desc' => __('The URL to the .m4v video file', 'zilla'),\n 'id' => '_zilla_video_m4v',\n 'type' => 'file',\n 'std' => ''\n ),\n array(\n 'name' => __('OGV File URL', 'zilla'),\n 'desc' => __('The URL to the .ogv video file', 'zilla'),\n 'id' => '_zilla_video_ogv',\n 'type' => 'file',\n 'std' => ''\n ),\n array(\n 'name' => __('MP4 File URL', 'zilla'),\n 'desc' => __('The URL to the .mp4 video file', 'zilla'),\n 'id' => '_zilla_video_mp4',\n 'type' => 'file',\n 'std' => ''\n ),\n array(\n 'name' => __('Poster Image', 'zilla'),\n 'desc' => __('The preview image.', 'zilla'),\n 'id' => '_zilla_video_poster_url',\n 'type' => 'text',\n 'std' => ''\n ),\n array(\n 'name' => __('Embedded Code', 'zilla'),\n 'desc' => __('If you are using something other than self hosted video such as Youtube or Vimeo, paste the embed code here. Width is best at 600px with any height.<br><br> This field will override the above.', 'zilla'),\n 'id' => '_zilla_video_embed_code',\n 'type' => 'textarea',\n 'std' => ''\n )\n )\n );\n zilla_add_meta_box( $meta_box );\n\n /* Create an audio metabox ------------------------------------------------------*/\n $meta_box = array(\n 'id' => 'zilla-metabox-post-audio',\n 'title' => __('Audio Settings', 'zilla'),\n 'description' => __('These settings enable you to embed audio into your posts.', 'zilla'),\n 'page' => 'post',\n 'context' => 'normal',\n 'priority' => 'high',\n 'fields' => array(\n array(\n 'name' => __('MP3 File URL', 'zilla'),\n 'desc' => __('The URL to the .mp3 audio file', 'zilla'),\n 'id' => '_zilla_audio_mp3',\n 'type' => 'file',\n 'std' => ''\n ),\n array(\n 'name' => __('OGA File URL', 'zilla'),\n 'desc' => __('The URL to the .oga, .ogg audio file', 'zilla'),\n 'id' => '_zilla_audio_ogg',\n 'type' => 'file',\n 'std' => ''\n )\n )\n );\n zilla_add_meta_box( $meta_box );\n}", "function create_meta_box() {\n\tif ( function_exists('add_meta_box') ) {\n\t\tadd_meta_box( 'new-meta-boxes', '<div class=\"icon-small\"></div> '.PEXETO_THEMENAME.' PAGE SETTINGS', 'new_meta_boxes', 'page', 'normal', 'high' );\n\t}\n}", "function austeve_gallery_admin_add_page() {\n add_options_page('AUSteve Gallery settings', 'AUSteve Gallery settings', 'manage_options', 'austeve_image_gallery', 'austeve_image_gallery_options_page');\n}", "public function create_meta_box() {\n\t\tadd_meta_box( 'slider_meta', 'Example metabox', array( $this, 'slider_meta_fields_callback' ), [ 'Page', 'post' ] );\n\n\t}", "function carrousel_metaboxes(){\n add_meta_box(\"MonCarrousel\", \"lien\", \"carrousel_metabox\");\n}", "public function addMetaboxes() {}", "public function get_name() {\n\t\treturn 'main-gallery';\n\t}", "function article_metabox() {\n\t$prefix = '_article_image_';\n\n\t$cmb_produit = new_cmb2_box ( array (\n\t\t\t'id' => $prefix . 'metabox',\n\t\t\t'title' => __ ( 'Article Informations', 'cmb2' ),\n\t\t\t'object_types' => array (\n\t\t\t\t\t'bienetre'\n\t\t\t)\n\t) );\n\n\t\n\t$cmb_produit->add_field ( array (\n\t\t\t'name' => __ ( 'Image', 'cmb2' ),\n\t\t\t'desc' => __ ( 'Ajouter une image a afficher dans larticle', 'cmb2' ),\n\t\t\t'id' => $prefix . 'image',\n\t\t\t'type' => 'file'\n\t) );\n\n\t}", "function image_gallery_admin() {\r\n _image_check_settings();\r\n\r\n $tree = taxonomy_get_tree(_image_gallery_get_vid());\r\n if ($tree) {\r\n $header = array(t('Name'), t('Operations'));\r\n foreach ($tree as $term) {\r\n $rows[] = array(str_repeat(' -- ', $term->depth) . ' ' . l($term->name, \"image/tid/$term->tid\"), l(t('edit gallery'), \"admin/content/image/edit/$term->tid\"));\r\n }\r\n return theme('table', $header, $rows);\r\n }\r\n else {\r\n return t('No galleries available');\r\n }\r\n}", "public function add_metabox() {\r\n\t\tadd_meta_box(\r\n\t\t\t'stats', // ID\r\n\t\t\t'Stats', // Title\r\n\t\t\tarray(\r\n\t\t\t\t$this,\r\n\t\t\t\t'meta_box', // Callback to method to display HTML\r\n\t\t\t),\r\n\t\t\t'spam-stats', // Post type\r\n\t\t\t'normal', // Context, choose between 'normal', 'advanced', or 'side'\r\n\t\t\t'core' // Position, choose between 'high', 'core', 'default' or 'low'\r\n\t\t);\r\n\t}", "function meta_boxes() {\n\t\tadd_meta_box( 'event-details', 'Event Details', array( $this , 'details_box' ), 'event', 'normal', 'high' );\n\t}", "public function insert_gallery_shortcode() {\n\t\t\n\t\tcheck_ajax_referer( 'daylife-gallery-add-nonce', 'nonce' );\n\t\t// TODO: Update to insert ids into shortcode so it works with new media tool\n\t\techo '[gallery]';\n\t\tdie();\n\n\t}", "public function meta_box_gallery_callback( $post ) {\n\n // Load view\n $this->base->load_admin_partial( 'metabox-gallery-type', array(\n 'post' => $post,\n 'types' => $this->get_envira_types( $post ),\n 'instance' => $this,\n ) ); \n\n }", "public function meta_box_form_items() {\n include_once (SWPM_FORM_BUILDER_PATH . 'views/button_palette_metabox.php');\n }", "public function meta_box() {\n\t\t\tglobal $_nav_menu_placeholder, $nav_menu_selected_id;\n\n\t\t\t$_nav_menu_placeholder = 0 > $_nav_menu_placeholder ? $_nav_menu_placeholder - 1 : -1;\n\n\t\t\t$last_object_id\t = get_option( 'gs_sim_last_object_id', 0 );\n\t\t\t$object_id\t\t = $this->new_object_id( $last_object_id );\n\t\t\t?>\n\t\t\t<div class=\"gs-sim-div\" id=\"gs-sim-div\">\n\t\t\t\t<input type=\"hidden\" class=\"menu-item-db-id\" name=\"menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-db-id]\" value=\"0\" />\n\t\t\t\t<input type=\"hidden\" class=\"menu-item-object-id\" name=\"menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-object-id]\" value=\"<?php echo $object_id; ?>\" />\n\t\t\t\t<input type=\"hidden\" class=\"menu-item-object\" name=\"menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-object]\" value=\"gs_sim\" />\n\t\t\t\t<input type=\"hidden\" class=\"menu-item-type\" name=\"menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-type]\" value=\"gs_sim\" />\n\t\t\t\t<input type=\"hidden\" id=\"gs-sim-description-nonce\" value=\"<?php echo wp_create_nonce( 'gs-sim-description-nonce' ) ?>\" />\n\t\t\t\t<p id=\"menu-item-title-wrap\">\n\t\t\t\t\t<label for=\"gs-sim-title\"><?php _e( 'Title Menu', IFLANG ); ?></label>\n\t\t\t\t\t<input id=\"gs-sim-title\" name=\"menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-title]\" type=\"text\" class=\"regular-text menu-item-textbox\" title=\"<?php esc_attr_e( 'Title Menu',IFLANG ); ?>\" style=\"width:100%\" /> \n\t\t\t\t</p>\n\n\t\t\t\t<p id=\"menu-item-html-wrap\">\n\t\t\t\t\t<textarea style=\"width:100%;\" rows=\"9\" id=\"gs-sim-html\" name=\"menu-item[<?php echo $_nav_menu_placeholder; ?>][menu-item-description]\" class=\"code menu-item-textbox\" title=\"<?php esc_attr_e( 'Text/HTML/shortcode here!' , IFLANG); ?>\"></textarea>\n\t\t\t\t\t<span><?php esc_attr_e( 'Text/HTML/shortcode here!' , IFLANG); ?></span>\n\t\t\t\t</p>\n\n\t\t\t\t<p class=\"button-controls\">\n\t\t\t\t\t<span class=\"add-to-menu\">\n\t\t\t\t\t\t<input type=\"submit\"<?php wp_nav_menu_disabled_check( $nav_menu_selected_id ); ?> class=\"button-secondary submit-add-to-menu right\" value=\"<?php esc_attr_e( 'Add to Menu' ); ?>\" name=\"add-gs-sim-menu-item\" id=\"submit-gs-sim\" />\n\t\t\t\t\t\t<span class=\"spinner\"></span>\n\t\t\t\t\t</span>\n\t\t\t\t</p>\n\n\t\t\t</div>\n\t\t\t<?php\n\t\t}", "function add_meta_boxes()\n {\n }", "function dfcg_help_gallery() {\n?>\n\t<h3><?php _e( 'Dynamic Content Gallery - Quick Help - Gallery Method', DFCG_DOMAIN ); ?></h3>\n\t\n\t<p><?php _e( 'For many users the best option is One Category. It is great as a \"set and forget\" option, because it will always pull in the latest posts from your chosen category. The Custom Post option works in a similar way to the One Category method and is, obviously, the best option for pulling in posts from one Custom Post type. In server performance terms, these two methods are probably the most efficient ones to use.', DFCG_DOMAIN ); ?></p>\n\t\n\t<p><?php _e( 'The Multi-Option method is perfect for when you want to mix posts from different categories, for example if you want to feature the latest post from a number of different categories.', DFCG_DOMAIN ); ?></p>\n\t\n\t<p><?php _e( 'The ID Method is the most flexible because you can pull in any type of post (normal of Custom) and Pages, and mix them in any order you wish using the Sort Order field in the DCG metabox.', DFCG_DOMAIN ); ?></p>\n\n<?php\n}", "function of_metabox_function(){\n require_once('of_meta_database.php');\n echo '<h2 class=\"text-left\">OF Metabox and Taxonomy Options<h2><br/>';\n of_settings_page();\n}", "public function pro_features_metabox() {\r\n\t\t// Upgrade url for upsell.\r\n\t\t$upsell_url = add_query_arg(\r\n\t\t\tarray(\r\n\t\t\t\t'utm_source' => 'smush',\r\n\t\t\t\t'utm_medium' => 'plugin',\r\n\t\t\t\t'utm_campaign' => 'smush-advanced-settings-upsell',\r\n\t\t\t),\r\n\t\t\t$this->upgrade_url\r\n\t\t);\r\n\r\n\t\t// Upgrade url with analytics keys.\r\n\t\t$upgrade_url = add_query_arg(\r\n\t\t\tarray(\r\n\t\t\t\t'utm_source' => 'smush',\r\n\t\t\t\t'utm_medium' => 'plugin',\r\n\t\t\t\t'utm_campaign' => 'smush-advanced-settings-video-button',\r\n\t\t\t),\r\n\t\t\t$this->upgrade_url\r\n\t\t);\r\n\r\n\t\t$this->view(\r\n\t\t\t'pro-features/meta-box',\r\n\t\t\tarray(\r\n\t\t\t\t'upgrade_url' => $upgrade_url,\r\n\t\t\t\t'upsell_url' => $upsell_url,\r\n\t\t\t)\r\n\t\t);\r\n\t}", "function igv_cmb_metaboxes() {\n\t$prefix = '_igv_';\n\n\t/**\n\t * Metaboxes declarations here\n * Reference: https://github.com/WebDevStudios/CMB2/blob/master/example-functions.php\n\t */\n\n\n\n $show_meta = new_cmb2_box( array(\n 'id' => $prefix . 'show_meta',\n 'title' => esc_html__( 'Show Metadata', 'cmb2' ),\n 'object_types' => array( 'show', ), // Post type\n // 'show_on_cb' => 'yourprefix_show_if_front_page', // function should return a bool value\n // 'context' => 'normal',\n 'priority' => 'high',\n // 'show_names' => true, // Show field names on the left\n // 'cmb_styles' => false, // false to disable the CMB stylesheet\n // 'closed' => true, // true to keep the metabox closed by default\n // 'classes' => 'extra-class', // Extra cmb2-wrap classes\n // 'classes_cb' => 'yourprefix_add_some_classes', // Add classes through a callback.\n ) );\n\n $show_meta->add_field( array(\n 'name' => 'Cover photo',\n 'desc' => 'Upload an image or enter an URL.',\n 'id' => $prefix . 'cover_photo',\n 'type' => 'file',\n // Optional:\n 'options' => array(\n 'url' => false, // Hide the text input for the url\n ),\n 'text' => array(\n 'add_upload_file_text' => 'Add Cover Photo' // Change upload button text. Default: \"Add or Upload File\"\n ),\n ) );\n\n $show_meta->add_field( array(\n 'name' => __( 'Youtube playlist ID', 'cmb2' ),\n 'id' => $prefix . 'playlist_id',\n 'type' => 'text',\n ));\n\n $show_meta->add_field( array(\n 'name' => __( 'Youtube playlist link', 'cmb2' ),\n 'id' => $prefix . 'playlist_link',\n 'type' => 'text',\n ));\n\n $show_meta->add_field( array(\n 'name' => __( 'Tracklist', 'cmb2' ),\n 'id' => $prefix . 'tracklist',\n 'type' => 'wysiwyg',\n ));\n\n $show_meta->add_field( array(\n 'name' => __( 'Episode #', 'cmb2' ),\n 'id' => $prefix . 'episode_number',\n 'type' => 'text',\n 'attributes' => array(\n 'pattern' => '\\d*',\n ),\n ));\n\n}", "function country_meta_boxes() {\n\t\t//add_meta_box( 'countries_meta', __( 'Quick link - All Countries', 'countries' ), array( $this, 'render_countries_meta' ), 'countries', 'side', 'low' );\n\t\tadd_meta_box( 'countrycode_meta', __( 'Country', 'countries' ), array( $this, 'render_countrycode_meta' ), 'countries', 'normal', 'low' );\n\t\t}", "function add_group_metabox() {\r\n\r\n\t\tadd_meta_box( 'bp_group_events', _x( 'Group Events', 'group admin edit screen', 'bp-simple-events' ), array( $this, 'show_group_metabox'), get_current_screen()->id, 'side' );\r\n\r\n\t}", "function biodynamics_medical()\n{\n\t/**\n\t * Sample metabox to demonstrate each field type included\n\t */\n\t$biodynamics_campos = new_cmb2_box( array(\n\t\t'id' => 'biodynamics_campos',\n\t\t'title' => esc_html__( 'Campos para imagen y url', 'cmb2' ),\n\t\t'object_types' => array( 'post' ), // Post type\n\t\t// 'show_on_cb' => 'yourprefix_show_if_front_page', // function should return a bool value\n\t\t// 'context' => 'normal',\n\t\t// 'priority' => 'high',\n\t\t// 'show_names' => true, // Show field names on the left\n\t\t// 'cmb_styles' => false, // false to disable the CMB stylesheet\n\t\t// 'closed' => true, // true to keep the metabox closed by default\n\t\t// 'classes' => 'extra-class', // Extra cmb2-wrap classes\n // 'classes_cb' => 'yourprefix_add_some_classes', // Add classes through a callback.\n\t\t) );\n\t\t\n\n $biodynamics_campos->add_field( array(\n 'name' => esc_html__( 'Seleciones las Imagenes', 'cmb2' ),\n 'desc' => esc_html__( 'Upload or add multiple images/attachments.', 'cmb2' ),\n 'id' => 'galeria_biodynamics',\n 'type' => 'file_list',\n 'preview_size' => array( 100, 100 ), // Default: array( 50, 50 )\n\t\t) );\n\t\n\t\n\t\t\n\t\n\n}", "public function register_metabox() {\n\t\t$fm = new Fieldmanager_Group( [\n\t\t\t'name' => 'hero_fields', // \"name\" id deceiving, used as the key/ID.\n\t\t\t'serialize_data' => false,\n\t\t\t'add_to_prefix' => false,\n\t\t\t'children' => [\n\t\t\t\t'_headline' => new Fieldmanager_RichTextArea( 'Main Headline', [\n\t\t\t\t\t'buttons_1' => [ 'bold', 'italic', 'strikethrough' ],\n\t\t\t\t\t'editor_settings' => [\n\t\t\t\t\t\t'media_buttons' => false,\n\t\t\t\t\t],\n\t\t\t\t] ),\n\t\t\t\t'_subheadline' => new Fieldmanager_RichTextArea( 'Sub Headline', [\n\t\t\t\t\t'buttons_1' => [ 'bold', 'italic', 'strikethrough' ],\n\t\t\t\t\t'editor_settings' => [\n\t\t\t\t\t\t'media_buttons' => false,\n\t\t\t\t\t],\n\t\t\t\t] ),\n\t\t\t],\n\t\t] );\n\n\t\t/**\n\t\t * Initiate the metabox\n\t\t */\n\t\t$fm->add_meta_box( 'Hero', 'page' );\n\t}", "public function add_meta_boxes()\n \t{\n\n \t\t// Add this metabox to every selected post\n \t\tadd_meta_box( \n \t\t\tsprintf('WP_Custom_Login_Profile_%s_section', self::POST_TYPE),\n \t\t\tsprintf('%s Information', ucwords(str_replace(\"_\", \" \", self::POST_TYPE))),\n \t\t\tarray(&$this, 'add_inner_meta_boxes'),\n \t\t\tself::POST_TYPE\n \t );\t\n\n \t}", "function vulcan_page_meta_boxes() {\r\r\n $meta_boxes = array(\r\r\n \"short_desc\" => array(\r\r\n \"name\" => \"short_desc\",\r\r\n \"title\" => \"Short Description\",\r\r\n \"description\" => \"Add short description to your pages.\",\r\r\n \"type\" => \"textarea\"\r\r\n ),\r\r\n \"page_thumbnail_image\" => array(\r\r\n \"name\" => \"page_thumbnail_image\",\r\r\n \"title\" => \"Thumbnail Image\",\r\r\n \"description\" => \"Add thumbnail image url, will be use for your page thumbnail, for example in Services child pages list.\",\r\r\n \"type\" => \"text\"\r\r\n )\r\r\n );\r\r\n \r\r\n return $meta_boxes;\r\r\n}", "public function add_metabox() {\n\t\tadd_meta_box(\n\t\t\t'Word linkages',\n\t\t\t'Word linkages',\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'linkages_meta_box',\n\t\t\t),\n\t\t\t'questions',\n\t\t\t'side',\n\t\t\t'high'\n\t\t);\n\n\t\tadd_meta_box(\n\t\t\t'Answers',\n\t\t\t'Answers',\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'answers_meta_box',\n\t\t\t),\n\t\t\t'questions',\n\t\t\t'side',\n\t\t\t'high'\n\t\t);\n\t}", "public function add_metaboxes() {\n\t\tadd_meta_box(\n\t\t\t'codes',\n\t\t\t__( 'Codes' ),\n\t\t\tarray( $this, 'render_codes_metabox' )\n\t\t);\n\n\t\tadd_meta_box(\n\t\t\t'edit-codes',\n\t\t\t__( 'Edit codes' ),\n\t\t\tarray( $this, 'render_edit_metabox' )\n\t\t);\n\t}", "function vulcan_slideshow_meta_boxes() {\r\r\n $meta_boxes = array(\r\r\n \"slideshow_image\" => array(\r\r\n \"name\" => \"slideshow_image\",\r\r\n \"title\" => \"Slideshow Image\",\r\r\n \"description\" => \"Add image url for your slideshow.\",\r\r\n \"type\" => \"text\"\r\r\n ),\r\r\n \"slideshow_url\" => array(\r\r\n \"name\" => \"slideshow_url\",\r\r\n \"title\" => \"Slideshow Url\",\r\r\n \"description\" => \"Link url for slideshow.\",\r\r\n \"type\" => \"text\"\r\r\n ),\r\r\n \"slideshow_readmore\" => array(\r\r\n \"name\" => \"slideshow_readmore\",\r\r\n \"title\" => \"Slideshow Read More Text\",\r\r\n \"description\" => \"Please enter the read more text for slideshow, eg : Continue Reading, Read More.\",\r\r\n \"type\" => \"text\"\r\r\n ),\r\r\n \"slideshow_style\" => array(\r\r\n \"name\" => \"slideshow_style\",\r\r\n \"title\" => \"Slideshow Stage Style\",\r\r\n \"description\" => \"Please one style of them for each image slideshow.\",\r\r\n \"type\" => \"select\",\r\r\n \"options\" => array(\"full image\",\"with right description\",\"with left description\",\"with bottom description\")\r\r\n ), \r\r\n \"num_excerpt\" => array(\r\r\n \"name\" => \"num_excerpt\",\r\r\n \"title\" => \"Number of Words for Slideshow Excerpt\",\r\r\n \"description\" => \"Add number of words excerpt to display in slideshow description, eg. 20\",\r\r\n \"type\" => \"text\"\r\r\n ) \r\r\n );\r\r\n \r\r\n return $meta_boxes;\r\r\n}", "public static function createMetaBox() {\r\n add_meta_box( \r\n \\WPDisablePage\\Setup::PLUGIN_ID, // Metabox ID\r\n \\WPDisablePage\\Setup::PLUGIN_NAME, // Metabox Name\r\n array( __CLASS__, 'createView' ), // Metabox Callback\r\n apply_filters( strtolower( \\WPDisablePage\\Setup::PLUGIN_ID ) . '__post_types', self::POST_TYPES ), // Metabox Post Types\r\n self::POSITION, // Metabox Position\r\n self::PRIORITY // Metabox Priority\r\n );\r\n }", "function render_meta_box($post, $metabox)\n {\n }", "function add_metabox() {\n\tadd_meta_box(\n\t\t'external-connection-groups',\n\t\t__( 'External Connection Groups', 'distributor' ),\n\t\t__NAMESPACE__ . '\\render_metabox',\n\t\t\\Distributor\\Waves\\get_distributable_custom_post_types(),\n\t\t'side',\n\t\t'high'\n\t);\n\n}", "function shortcode_reference_render_meta_box(){\n\t$ShortcodeReferenceUIManager = new ShortcodeReferenceUIManager();\n\tforeach (get_post_types( array('public' => true) ) as $posttype){\n\t\tadd_meta_box('shortcode_overview_container',__('Shortcode reference','ShortcodesAutoreference'), array(&$ShortcodeReferenceUIManager,'showReferencePanel'), $posttype, 'side');\n\t}\n}", "function ppes_admin_init(){\r\n\tadd_meta_box(\"et_post_meta\", \"ET Settings\", \"et_post_meta\", \"auctions\", \"normal\", \"high\");\r\n}", "public function add_meta_boxes()\n \t{\n \t\t// Add this metabox to every selected post\n \t\tadd_meta_box( \n \t\t\tsprintf('wp_plugin_template_%s_section', self::POST_TYPE),\n \t\t\tsprintf('%s Information', ucwords(str_replace(\"_\", \" \", self::POST_TYPE))),\n \t\t\tarray($this, 'add_inner_meta_boxes'),\n \t\t\tself::POST_TYPE\n \t );\t\t\t\t\t\n \t}", "static function metabox_at_post_edit_page(){\n\t\t \tadd_meta_box('matebox-to-handle-keywords', 'Affiliate Keywords', array(get_class(), 'metabox_to_deal_keywords'), 'product', 'advanced', 'high');\t \t\n\t\t }", "function tabify_add_meta_boxes($post_type)\n {\n }", "function buildGallery ()\t{\n\t\t\t// Get the needed Information\n\t\t\t\n\t\t}", "function wtfdivi099_add_meta_boxes() {\r\n\tforeach(get_post_types() as $pt) {\r\n\t\tif (post_type_supports($pt, 'editor') and function_exists('et_single_settings_meta_box')) {\r\n\t\t\tadd_meta_box('et_settings_meta_box', __('Divi Custom Post Settings', 'Divi'), 'et_single_settings_meta_box', $pt, 'side', 'high');\r\n\t\t}\r\n\t} \r\n}", "public function add_order_meta_box() {\n\t\t\\add_meta_box(\n\t\t\t'bwcpp_profile_picture_box',\n\t\t\t__( 'Profile Picture', 'bwcpp' ),\n\t\t\tarray( $this, 'render_order_meta_box' ),\n\t\t\t'shop_order',\n\t\t\t'side',\n\t\t\t'default'\n\t\t);\n\t}", "function md_metadraft_metabox($post){\n\n\t$metadraft = md_get_metadraft($post->ID);\n\t$source = md_get_source($post->ID);\n\n\techo \"<div class='submitbox'>\";\n\n\t// Provide a hook to attach metabox content in discrete chunks\n\tdo_action('md_metadraft_metabox', $post, $metadraft, $source);\n\n\techo \"</div>\";\n\n}", "function qtgallery_register_type() {\n\n\t$labelsoption = array(\n 'name' => esc_attr__(\"Gallery\",\"qt-extensions-suite\"),\n 'singular_name' => esc_attr__(\"Gallery\",\"qt-extensions-suite\"),\n 'add_new' => esc_attr__(\"Add new\",\"qt-extensions-suite\"),\n 'add_new_item' => esc_attr__(\"Add new gallery\",\"qt-extensions-suite\"),\n 'edit_item' => esc_attr__(\"Edit gallery\",\"qt-extensions-suite\"),\n 'new_item' => esc_attr__(\"New gallery\",\"qt-extensions-suite\"),\n 'all_items' => esc_attr__(\"All galleries\",\"qt-extensions-suite\"),\n 'view_item' => esc_attr__(\"View gallery\",\"qt-extensions-suite\"),\n 'search_items' => esc_attr__(\"Search gallery\",\"qt-extensions-suite\"),\n 'not_found' => esc_attr__(\"No galleries found\",\"qt-extensions-suite\"),\n 'not_found_in_trash' => esc_attr__(\"No galleries found in trash\",\"qt-extensions-suite\"),\n 'menu_name' => esc_attr__(\"Galleries\",\"qt-extensions-suite\")\n );\n\n \t$args = array(\n 'labels' => $labelsoption,\n 'public' => true,\n 'publicly_queryable' => true,\n 'show_ui' => true, \n 'show_in_menu' => true, \n 'query_var' => true,\n 'rewrite' => true,\n 'capability_type' => 'page',\n 'has_archive' => true,\n 'hierarchical' => false,\n 'menu_position' => 40,\n 'menu_icon' => 'dashicons-format-gallery',\n \t'page-attributes' => false,\n \t'show_in_nav_menus' => true,\n \t'show_in_admin_bar' => true,\n \t'show_in_menu' => true,\n 'supports' => array('title','thumbnail','editor')\n \t); \n\n register_post_type( CUSTOMTYPE_GALLERY , $args );\n \n //add_theme_support( 'post-formats', array( 'gallery','status','video','audio' ) );\n\t\n\t$labels = array(\n\t\t'name' => esc_attr__( 'Gallery type',\"qt-extensions-suite\" ),\n\t\t'singular_name' => esc_attr__( 'Types',\"qt-extensions-suite\" ),\n\t\t'search_items' => esc_attr__( 'Search by type',\"qt-extensions-suite\" ),\n\t\t'popular_items' => esc_attr__( 'Popular type',\"qt-extensions-suite\" ),\n\t\t'all_items' => esc_attr__( 'All types',\"qt-extensions-suite\" ),\n\t\t'parent_item' => null,\n\t\t'parent_item_colon' => null,\n\t\t'edit_item' => esc_attr__( 'Edit Type',\"qt-extensions-suite\" ), \n\t\t'update_item' => esc_attr__( 'Update Type',\"qt-extensions-suite\" ),\n\t\t'add_new_item' => esc_attr__( 'Add New Type',\"qt-extensions-suite\" ),\n\t\t'new_item_name' => esc_attr__( 'New Type Name',\"qt-extensions-suite\" ),\n\t\t'separate_items_with_commas' => esc_attr__( 'Separate Types with commas',\"qt-extensions-suite\" ),\n\t\t'add_or_remove_items' => esc_attr__( 'Add or remove Types',\"qt-extensions-suite\" ),\n\t\t'choose_from_most_used' => esc_attr__( 'Choose from the most used Types',\"qt-extensions-suite\" ),\n\t\t'menu_name' => esc_attr__( 'Types',\"qt-extensions-suite\" ),\n\t); \n\n\t\n\n $fields = array(\n /* */ \n\t\tarray(\n\t\t\t'label' => 'Style',\n\t\t\t'class' => 'style',\n\t\t\t'id' => 'style',\n\t\t\t'type' => 'select',\n\t\t\t'options' => array(\n\t array('label' => 'Masonry','value' => 'masonry'),\n\t array('label' => 'Carousel','value' => 'carousel')\n\t )\n\t\t\t),\n\t\tarray( // Repeatable & Sortable Text inputs\n\t\t\t'label'\t=> 'Gallery', // <label>\n\t\t\t'id'\t=> 'galleryitem', // field id and name\n\t\t\t'type'\t=> 'repeatable', // type of field\n\t\t\t'sanitizer' => array( // array of sanitizers with matching kets to next array\n\t\t\t\t'featured' => 'meta_box_santitize_boolean',\n\t\t\t\t'title' => 'sanitize_text_field',\n\t\t\t\t'desc' => 'wp_kses_data'\n\t\t\t)\n\t\t\t,'repeatable_fields' => array ( // array of fields to be repeated\n\t\t\t\t'title' => array(\n\t\t\t\t\t'label' => 'Title',\n\t\t\t\t\t'id' => 'title',\n\t\t\t\t\t'type' => 'text'\n\t\t\t\t),\n\t\t\t\t'video' => array(\n\t\t\t\t\t'label' => 'Video',\n\t\t\t\t\t'id' => 'video',\n\t\t\t\t\t'description' => 'Youtube or Vimeo url',\n\t\t\t\t\t'type' => 'text'\n\t\t\t\t),\n\t\t\t\t'image' => array(\n\t\t\t\t\t'label' => 'Image',\n\t\t\t\t\t'id' => 'image',\n\t\t\t\t\t'type' => 'image'\n\t\t\t\t)\n\t\t\t)\n\t\t)\t \n );\n if(post_type_exists(CUSTOMTYPE_GALLERY)){\n if(function_exists('custom_meta_box_field')){\n $sample_box \t\t= new custom_add_meta_box(CUSTOMTYPE_GALLERY, 'Gallery details', $fields, CUSTOMTYPE_GALLERY, true );\n }\n }\n\t\n}", "function pa_add_custom_testi() {\r\r\n add_meta_box( 'pa-testimonial-option', __( 'Testimonial Option', 'my_framework' ), 'pa_custom_testi_option', 'testimonial', 'normal', 'high');\r\r\n}", "public function add_admin_meta_boxes() {\n\t\tadd_meta_box(\n\t\t\t'content_directory_options',\n\t\t\t__( 'Change Content Directory', 'it-l10n-ithemes-security-pro' ),\n\t\t\tarray( $this, 'metabox_advanced_settings' ),\n\t\t\t'security_page_toplevel_page_itsec_advanced',\n\t\t\t'advanced',\n\t\t\t'core'\n\t\t);\n\t}", "public function results_upload_metabox() {\n\n\t\tadd_meta_box(\n\t\t\t'iracing-results-uploader', // ID\n\t\t\t__( 'Upload iRacing results', 'src' ), // Title\n\t\t\tarray(\n\t\t\t\t$this,\n\t\t\t\t'results_upload_metabox_html', // Callback to method to display HTML\n\t\t\t),\n\t\t\tarray( 'event', 'post' ), // Post type\n\t\t\t'side', // Context, choose between 'normal', 'advanced', or 'side'\n\t\t\t'high' // Position, choose between 'high', 'core', 'default' or 'low'\n\t\t);\n\n\t}", "public function get_gallery_controls()\n\t{\n\t\treturn '<a class=\"left carousel-control\" href=\"#carousel-example-generic\" data-slide=\"prev\">\n\t\t\t<span class=\"glyphicon glyphicon-chevron-left\"></span>\n\t\t</a>\n\t\t<a class=\"right carousel-control\" href=\"#carousel-example-generic\" data-slide=\"next\">\n\t\t\t<span class=\"glyphicon glyphicon-chevron-right\"></span>\n\t\t</a>';\n\t}", "function md_metadraft_comments_metabox($post){\n\n\t$metadraft = md_get_metadraft($post->ID);\n\t$source = md_get_source($post->ID);\n\n\techo \"<div id='md_comments_inner'>\";\n\n\t// Provide a hook to attach metabox content in discrete chunks\n\tdo_action('md_metadraft_comments_metabox', $post, $metadraft, $source);\n\n\techo \"</div>\";\n\n}" ]
[ "0.66594106", "0.66292554", "0.64197373", "0.6387661", "0.6386686", "0.637107", "0.63206136", "0.63137263", "0.62749636", "0.6229118", "0.62216794", "0.6218269", "0.6179596", "0.6120624", "0.61103976", "0.60784316", "0.60754055", "0.6062967", "0.6062274", "0.6045659", "0.6000481", "0.5997591", "0.5997081", "0.5992499", "0.5987857", "0.59850264", "0.59616345", "0.59567183", "0.59398174", "0.59386355", "0.5936958", "0.59327745", "0.59135085", "0.59111184", "0.5908019", "0.58980715", "0.5895471", "0.5887737", "0.5883794", "0.5876965", "0.5868877", "0.5866258", "0.5866132", "0.58368564", "0.583659", "0.58364046", "0.5829623", "0.58294505", "0.58275074", "0.5820641", "0.5811987", "0.5805016", "0.57979155", "0.5794903", "0.57897377", "0.5789329", "0.5789032", "0.5787148", "0.5786294", "0.5785871", "0.57827634", "0.577523", "0.5768694", "0.5763012", "0.5752146", "0.5750621", "0.5748594", "0.5744843", "0.5735841", "0.57357043", "0.5734936", "0.5732985", "0.5722417", "0.5719865", "0.5718234", "0.5716765", "0.57102686", "0.57065845", "0.57015395", "0.5698049", "0.5686346", "0.568231", "0.56801426", "0.5672139", "0.5670405", "0.56696475", "0.5658426", "0.56548965", "0.56521225", "0.56461746", "0.5644259", "0.564358", "0.56404763", "0.56326514", "0.56266046", "0.56140774", "0.5605926", "0.560026", "0.5599242", "0.55992275" ]
0.6437768
2
Includes the unit status metabox code.
function _display_status_meta( $post ) { include( 'includes/metaboxes/unit-status.php' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getStatus(): UnitEnum|string;", "function i4_get_unit_status() {\n global $current_i4_user, $post;\n\n //Store the Parent Data for the Unit for use.\n $unit_parent_data = WPCW_units_getAssociatedParentData($post->ID);\n\n $user_id = $current_i4_user->ID;\n\n //Check if the Unit is complete\n $unit_status = $this->i4_is_unit_complete($unit_parent_data->course_id, $user_id, $post->ID);\n\n return $unit_status;\n }", "function getStatusString() {\n\t\tswitch ($this->getData('status')) {\n\t\t\tcase THESIS_STATUS_INACTIVE:\n\t\t\t\treturn 'plugins.generic.thesis.manager.status.inactive';\n\t\t\tcase THESIS_STATUS_ACTIVE:\n\t\t\t\treturn 'plugins.generic.thesis.manager.status.active';\n\t\t\tdefault:\n\t\t\t\treturn 'plugins.generic.thesis.manager.status';\n\t\t}\n\t}", "function _display_unitinfo_meta( $post ) {\n\t\tinclude( 'includes/metaboxes/unit-info.php' );\n\t}", "function pafd_metabox_status_cb() {\n\n\tglobal $post, $pafd_textdomain;\n\n\t// Prepare status for use with K\n\t$statuses[ '' ] = __( 'None', $pafd_textdomain );\n\t$status_terms = get_terms( 'pafd_status', 'hide_empty=0' ); \n\tforeach ( $status_terms as $status_term ) {\n\t\t$statuses[ $status_term->term_id ] = $status_term->name;\n\t}\n\n\t// Get the file current status id\n\tif ( $post ) {\n\t\t$post_status_terms = wp_get_object_terms( $post->ID, 'pafd_status' );\n\t\t$post_status_term = array_shift( $post_status_terms );\n\t\tif( ! empty( $post_status_term ) ) {\n\t\t\t$post_status_id = $post_status_term->term_id;\n\t\t} else {\n\t\t\t$post_status_id = '';\n\t\t}\n\t}\n\n\t// Print the statuses\n\tK::select(\n\t\t'pafd-status',\n\t\tnull,\n\t\tarray(\n\t\t\t'options' => $statuses,\n\t\t\t'selected' => $post_status_id,\n\t\t)\n\t);\n\n\t// Print a nonce field\n\tK::input(\n\t\t'pafd-status-nonce',\n\t\tarray(\n\t\t\t'type' => 'hidden',\n\t\t\t'value' => wp_create_nonce( 'pafd_save_status' ),\n\t\t)\n\t);\n}", "public function getStatusAdmin()\n {\n switch ($this->status) {\n case 0:\n return '<span class=\"label label-danger\">Open</span>';\n case 1:\n return '<span class=\"label label-success\">Closed</span>';\n }\n }", "function GetStatus() {\n if ($this->buttons['lunch_end']) {\n return \"Out to lunch.\";\n }\n if ($this->buttons['work_start']) {\n return \"Not working.\";\n }\n else {\n return \"Working.\";\n }\n }", "function getDetailedStatus() ;", "public function register_status() {\n register_post_status( self::$status, array(\n 'label' => __( 'Limbo', 'fu-events-calendar' ),\n 'label_count' => _nx_noop( 'Limbo <span class=\"count\">(%s)</span>', 'Limbo <span class=\"count\">(%s)</span>', 'event status', 'fu-events-calendar' ),\n 'show_in_admin_all_list' => false,\n 'show_in_admin_status_list' => true,\n 'public' => false,\n 'internal' => false,\n ) );\n }", "public function status() {\n\t\treturn self::STATUS_DESCRIPTIONS[$this->status];\n\t}", "public function getStatus () {\n\n\t// TODO\n\n\treturn \"invalid\";\n }", "public function getBarUnit() {\n return $this->cBarUnit;\n }", "public function getStatus() {\n\t\t$code = $this->status['code'];\n\t\tif ($code === '0'){\n\t\t\treturn 'Closed';\n\t\t}else if($code === '1'){\n\t\t\treturn 'On Hold';\n\t\t}else if($code === '2'){\n\t\t\treturn 'Open';\n\t\t}else if($code === '3'){\n\t\t\t$openingDate = ($this->status['openingdate'] === '') ? 'soon' : date(\"j M\", strtotime($this->status['openingdate']));\n\t\t\treturn 'Opening '.$openingDate; \n\t\t}else if($code === '4'){\n\t\t\treturn 'Closed For Season'; \n\t\t}else if($code === '5'){ \n\t\t\t$updateTime = ($this->status['updatetime'] === '') ? 'No Estimate' : 'Estimated: '.date(\"g:ia\", strtotime($this->status['updatetime']));\n\t\t\treturn 'Delayed '.$updateTime; \n\t\t}\n\t}", "function get_status() {\n return $this->status;\n }", "public function getStatus() \n {\n if ($this->status) \n {\n \techo 'user status : присутствует<br><br><br>';\n }\n else\n {\n \techo 'user status : отсутствует<br><br><br>';\t\n }\n }", "function statusMessage()\n {\n }", "public function getStatusString()\r\n {\r\n return $GLOBALS['TICKETSTATUS_DESC'][$this->status];\r\n }", "public function status() {\n\t\treturn self::STATUS_DESCRIPTIONS[$this->oehhstat];\n\t}", "public function getDetailedSystemStatus() {}", "public function GetStatus()\n\t{\n\t\t// Demnach ist der Status in IPS der einzige der vorliegt.\t\t\n\t}", "public function getStatusAsString(){\r\n $list = self::getStatusList();\r\n if (isset($list[$this->status]))\r\n return $list[$this->status];\r\n \r\n return 'Unknown';\r\n }", "function _showStatus() {\r\n $okMessage = implode('<br />', $this->_okMessage);\r\n $errMessage = implode('<br />', $this->_errMessage);\r\n\r\n if (!empty($errMessage)) {\r\n $this->_objTpl->setVariable('FILEBROWSER_ERROR_MESSAGE', $errMessage);\r\n } else {\r\n $this->_objTpl->hideBlock('errormsg');\r\n }\r\n\r\n if (!empty($okMessage)) {\r\n $this->_objTpl->setVariable('FILEBROWSER_OK_MESSAGE', $okMessage);\r\n } else {\r\n $this->_objTpl->hideBlock('okmsg');\r\n }\r\n }", "public function statusButton() {\n\t\t$code = $this->status['code'];\n\t\tif ($code === '0'){\n\t\t\treturn '<div class=\"status-button s'.$code.'\">Closed</div>';\n\t\t}else if($code === '1'){\n\t\t\treturn '<div class=\"status-button s'.$code.'\">On Hold</div>';\n\t\t}else if($code === '2'){\n\t\t\treturn '<div class=\"status-button s'.$code.'\">Open</div>';\n\t\t}else if($code === '3'){\n\t\t\t$openingDate = ($this->status['openingdate'] === '') ? 'soon' : date(\"j M\", strtotime($this->status['openingdate']));\n\t\t\treturn '<div class=\"status-button s'.$code.'\">Opening '.$openingDate.'</div>'; \n\t\t}else if($code === '4'){\n\t\t\treturn '<div class=\"status-button s'.$code.'\">Closed <span>For Season</span></div>'; \n\t\t}else if($code === '5'){ \n\t\t\t$updateTime = ($this->status['updatetime'] === '') ? 'No Estimate' : 'Estimated: '.date(\"g:ia\", strtotime($this->status['updatetime']));\n\t\t\treturn '<div class=\"status-button s'.$code.'\">Delayed Opening</div>\n\t\t\t\t\t<div class=\"estimate\">'.$updateTime.'</div>'; \n\t\t}\n\t}", "public function get_status(){\n return $this->status;\n }", "function getStatusName() {\n\t\treturn $this->data_array['status_name'];\n\t}", "public function get_status()\n {\n }", "public function get_status()\n {\n }", "function wpmantis_get_status_translation()\n{\n\t$options = get_option('wp_mantis_options');\n\textract($options);\n\t$client = new SoapClient($mantis_soap_url);\n\ttry\n\t{\t\n\t\t$results = $client->mc_enum_status($mantis_user, $mantis_password);\n\t\t\n\t\tforeach ($results as $result)\n\t\t{\n\t\t\t\t$id = $result->id;\n\t\t\t\t$name = $result->name;\n\t\t\t\t\n\t\t\t\t$mantis_statuses[$id] = $name;\n\t\t}\n\t\t$options['mantis_statuses'] = $mantis_statuses;\n\t\tupdate_option('wp_mantis_options', $options);\n\t\t\n\t\t?>\n <div id=\"message\" class=\"updated fade\">\n <p><?php _e('Options saved.', 'wp-mantis'); ?></p>\n </div>\n <?php\n\t}\n\tcatch(SoapFault $e)\n\t{\n\t\tthrow $e;\n\t\t?>\n <div id=\"message\" class=\"error fade\">\n <p><?php printf(__('Error: %s', 'wp-mantis'), $e->getMessage()); ?></p>\n </div>\n <?php\n\t}\n}", "function get_status()\r\n {\r\n return $this->get_default_property(self :: PROPERTY_STATUS);\r\n }", "public function getUnitName()\n {\n return $this->unit_name;\n }", "public function getUnitLabel()\n {\n return $this->unitLabel;\n }", "public function get_name() {\r\n\t\treturn 'status';\r\n\t}", "function getStatus() ;", "function getStatus() ;", "function getStatus() ;", "function getStatus() \n {\n return $this->instance->getStatus();\n }", "function getStatus() {\n return $this->status;\n }", "public function ctlStatus() \n {\n if($this->getStatus() < $this->_statusOkDel) : \n $this->setIdDel(true);\n else:\n $this->setIdDel(false);\n endif;\n \n if($this->getStatus() < $this->_statusOkMaj) : \n $this->setIdMaj(true);\n else:\n $this->setIdMaj(false);\n endif;\n $this->setOnlinedat();\n }", "function getStatus()\n {\n return $this->status;\n }", "function getStatusMessage(){\n\t\tif($this->_StatusMessage){ return $this->_StatusMessage; }\n\n\t\t//cerpano z\n\t\t//http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html\n\t\t$status = array(\n\t\t\t// Successful 2xx\n\t\t\t\"200\" => \"OK\",\n\t\t\t\"201\" => \"Created\",\n\t\t\t\"202\" => \"Accepted\",\n\t\t\t\"203\" => \"Non-Authoritative Information\",\n\t\t\t\"204\" => \"No Content\",\n\t\t\t\"205\" => \"Reset Content\",\n\t\t\t\"206\" => \"Partial Content\",\n\t\t\t// Redirection 3xx\n\t\t\t\"300\" => \"Multiple Choices\",\n\t\t\t\"301\" => \"Moved Permanently\",\n\t\t\t\"302\" => \"Found\",\n\t\t\t\"303\" => \"See Other\",\n\t\t\t\"304\" => \"Not Modified\",\n\t\t\t\"305\" => \"Use Proxy\",\n\t\t\t// (306 Unused)\n\t\t\t\"307\" => \"Temporary Redirect\",\n\t\t\t// Client Error 4xx\n\t\t\t\"400\" => \"Bad Request\",\n\t\t\t\"401\" => \"Unauthorized\",\n\t\t\t\"402\" => \"Payment Required\",\n\t\t\t\"403\" => \"Forbidden\",\n\t\t\t\"404\" => \"Not Found\",\n\t\t\t\"405\" => \"Method Not Allowed\",\n\t\t\t\"406\" => \"Not Acceptable\",\n\t\t\t\"407\" => \"Proxy Authentication Required\",\n\t\t\t\"408\" => \"Request Timeout\",\n\t\t\t\"409\" => \"Conflict\",\n\t\t\t\"410\" => \"Gone\",\n\t\t\t\"411\" => \"Length Required\",\n\t\t\t\"412\" => \"Precondition Failed\",\n\t\t\t\"413\" => \"Request Entity Too Large\",\n\t\t\t\"414\" => \"Request-URI Too Long\",\n\t\t\t\"415\" => \"Unsupported Media Type\",\n\t\t\t\"416\" => \"Requested Range Not Satisfiable\",\n\t\t\t\"417\" => \"Expectation Failed\",\n\t\t\t\"418\" => \"I'm a teapot\",\n\t\t\t// Server Error 5xx\n\t\t\t\"500\" => \"Internal Server Error\",\n\t\t\t\"501\" => \"Not Implemented\",\n\t\t\t\"502\" => \"Bad Gateway\",\n\t\t\t\"503\" => \"Service Unavailable\",\n\t\t\t\"504\" => \"Gateway Timeout\",\n\t\t\t\"505\" => \"HTTP Version Not Supported\",\n\t\t\t\"506\" => \"Variant Also Negotiates\",\n\t\t\t\"507\" => \"Insufficient Storage\",\n\t\t);\n\t\treturn isset($status[\"$this->_StatusCode\"]) ? $status[\"$this->_StatusCode\"] : \"Unknown\";\n\t}", "public function getStatusText()\r\n {\r\n return $this->status_text;\r\n }", "function Status()\n\t{\n\t\treturn $this->status;\n\t}", "public function getDetailedStatus() {}", "public function get_status() {\n return $this->_status;\n }", "public function status_name(){\n\t\t$status = '';\n\t\t\tswitch($this->status){\n\t\t\t\tCASE '1' : $status = 'Active';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '2' : $status = 'Currently Working';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '3' : $status = 'Work Completed';\n\t\t\t\t\t\tbreak;\n\t\t\t\tCASE '4' : $status = 'Payment Approved';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '5' : $status = 'Feedback Employer';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '6' : $status = 'Feedback Freelancer';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '7' : $status = 'Refund';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '8' : $status = 'Conflict';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '9' : $status = 'Closed';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '11' : $status = 'Payment Released';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '15' : $status = 'Charge Back';\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\treturn $status;\n\t}", "public function getStatusLabelAttribute()\n {\n //ADAPUN VALUENYA AKAN MENCETAK HTML BERDASARKAN VALUE DARI FIELD STATUS\n if ($this->status == 0) {\n return '<span class=\"badge badge-secondary\">Draft</span>';\n }\n return '<span class=\"badge badge-success\">Aktif</span>';\n }", "public function getStatusMessage()\n\t{\n\t\t$actionPhrase = 'Deleting';\n\t\t$typePhrase = 'Add-on data';\n\n\t\t$currentType = ucfirst(str_replace('_', ' ', $this->currentType));\n\n\t\t if ($currentType)\n\t\t{\n\t\t\treturn sprintf('%s... %s (%s)', $actionPhrase, $typePhrase, $currentType);\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn sprintf('%s... %s', $actionPhrase, $typePhrase);\n\t\t}\n\t}", "public function getStatus(){\n\t\treturn $this->status;\n\t}", "public function getStatusText()\n {\n return $this->statusText;\n }", "function getStatus() {\n\t\treturn $this->getData('status');\n\t}", "public function statusBulu(){\r\n\t\t\treturn parent::lihatBulu();\r\n\t\t}", "public function printStatus()\n {\n switch ($this->status) {\n case $this::STATUS_INACTIVE:\n return \\Yii::t('app', 'Inactive');\n break;\n case $this::STATUS_ACTIVE_LOCKED:\n return \\Yii::t('app', 'Locked');\n break;\n case $this::STATUS_ACTIVE_UNLOCKED:\n return \\Yii::t('app', 'Unlocked');\n break;\n }\n\n return \\Yii::t('app', 'Unknown status');\n }", "public function status_label(){\n\t\t$label='';\n\t\t\tswitch($this->status){\n\t\t\t\tCASE '1' : $label = 'label-info';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '2' : $label = 'label-info';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '3' : $label = 'label-info';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '4' : $label = 'label-success';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '5' : $label = 'label-info';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '6' : $label = 'label-info';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '7' : $label = 'label-warning';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '8' : $label = 'label-danger';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '9' : $label = 'label-danger';\n\t\t\t\t\tbreak;\t\t\t\t\t\n\t\t\t\tCASE '11' : $label = 'label-success';\n\t\t\t\t\tbreak;\n\t\t\t\tCASE '15' : $label = 'label-danger';\n\t\t\t\t\tbreak;\t\n\t\t\t}\n\t\treturn $label;\n\t}", "public function getSystemStatus() {}", "public function getStatusText()\n {\n return $this->statusText;\n }", "public function status()\r\n {\r\n return $this->status;\r\n }", "function updateStatus(&$status, &$statusflag)\n {\n Requirements::customCSS('.col-ScheduledStatusDataColumn i {\n width: 16px;\n height: 16px;\n display: block;\n float: left;\n margin-right: 6px;\n }', 'ScheduledStatusDataColumn_Icons');\n if ( $this->owner->getEmbargoIsSet() ) {\n if ( $this->owner->getScheduledStatus() ) {\n // Under Embargo\n $status .= '<i class=\"font-icon-eye btn--icon-md text-danger\" title=\"Embargo active\"></i>'.$this->owner->dbObject(\"Embargo\")->Nice();\n } else {\n // Embargo expired\n $status .= '<i class=\"font-icon-eye btn--icon-md text-info\" title=\"Embargo expired\"></i>'.$this->owner->dbObject(\"Embargo\")->Nice();\n }\n }\n if ( $this->owner->getExpiryIsSet() ) {\n if ( $this->owner->getEmbargoIsSet() ) {\n $status .= '<br />'; // add a break if both set\n }\n if ( $this->owner->getExpiredStatus() ) {\n // Expired/unpublished\n $status .= '<i class=\"font-icon-eye-with-line btn--icon-md text-danger\" title=\"Expired/unpublished\"></i>'.$this->owner->dbObject(\"Expiry\")->Nice();\n } else {\n // Scheduled to expire\n $status .= '<i class=\"font-icon-eye-with-line btn--icon-md text-warning\" title=\"Scheduled to expire\"></i>'.$this->owner->dbObject(\"Expiry\")->Nice();\n }\n }\n }", "public function getItemStatus() {\r\n\t\t$status = array();\r\n\t\t\t$status[0] = array('id' => 0,\r\n\t\t\t\t\t\t\t'name' => 'Sold',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'sold'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[1] = array('id' => 1,\r\n\t\t\t\t\t\t\t'name' => 'Available',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'available'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[2] = array('id' => 2,\r\n\t\t\t\t\t\t\t'name' => 'Out on Job',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'out_on_job'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[3] = array('id' => 3,\r\n\t\t\t\t\t\t\t'name' => 'Pending Sale',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'pending_sale'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[4] = array('id' => 4,\r\n\t\t\t\t\t\t\t'name' => 'Out on Memo',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'out_on_memo'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[5] = array('id' => 5,\r\n\t\t\t\t\t\t\t'name' => 'Burgled',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'burgled'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[6] = array('id' => 6,\r\n\t\t\t\t\t\t\t'name' => 'Assembled',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'assembled'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[7] = array('id' => 7,\r\n\t\t\t\t\t\t\t'name' => 'Returned To Consignee',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'return_to_consignee'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[8] = array(\r\n\t\t\t\t\t\t\t'id' => 8,\r\n\t\t\t\t\t\t\t'name' => 'Pending Repair Queue',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'pending_repair'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[91] = array('id' => 91,\r\n\t\t\t\t\t\t\t'name' => 'Francesklein Import',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'francesklein_import'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[98] = array('id' => 98,\r\n\t\t\t\t\t\t\t'name' => 'Never Going Online',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'never_going_online'\r\n\t\t\t\t\t\t);\r\n\t\t\t$status[99] = array('id' => 99,\r\n\t\t\t\t\t\t\t'name' => 'Unavailable',\r\n\t\t\t\t\t\t\t'checked' => false,\r\n\t\t\t\t\t\t\t'field_name' => 'unavailable'\r\n\t\t\t\t\t);\r\n\t\treturn $status;\r\n\t}", "public function getStatusMessage();", "function getCustomStatusName() {\n\t\t$custom_status_id = $this->ArtifactType->getCustomStatusField();\n\t\tif ($custom_status_id) {\n\t\t\t$result = db_query_params ('SELECT element_name FROM artifact_extra_field_elements aefe, artifact_extra_field_data aefd\n\t\t\t\t\t\t\t\t\t\tWHERE artifact_id=$1 AND aefd.extra_field_id=$2 AND CAST(aefd.field_data AS INTEGER)=aefe.element_id',\n\t\t\t\t\t\t\t\tarray ($this->getID(), $custom_status_id)) ;\n\t\t\tif ($result) {\n\t\t\t\treturn db_result($result, 0, 'element_name');\n\t\t\t}\n\t\t}\n\t\treturn $this->data_array['status_name'];\n\t}", "public function display_status($status){\n\t\tif($status == '1'){\n\t\t\t$st = 'Active';\n\t\t}else{\t\n\t \t\t$st = 'Inactive';\n\t\t}\n\t\treturn $st;\n\t}", "public function getStatusText()\n {\n return 'entity.organization.field.status.' . $this->status;\n }", "function getStatus() {\n\t\treturn $this->_Status;\n\t}", "abstract public function GetStatus();", "public function getStatus()\n {\n return $this->data['status'];\n }", "public function getStatusLabel()\n {\n return \\BFOS\\PagseguroBundle\\Utils\\Pagseguro::$transaction_status[$this->status];\n }", "public function status()\n {\n return $this->_status;\n }", "public function getTestStatus()\n {\n switch ($this->getData('status')) {\n case 0:\n return 'Stopped';\n case 1:\n return 'Running';\n case 2:\n return 'Paused';\n }\n }", "abstract public function getStatus();", "public function status() {\n\t\treturn $this->_status;\n\t}", "public function getStatusAsString()\n {\n $list = self::getStatusList();\n if (isset($list[$this->status]))\n return $list[$this->status];\n\n return 'Unknown';\n }", "protected function status( $status )\n\t{\n\t\techo $status . PHP_EOL;\n\t}", "public function getStatusText()\n {\n return $this->statusText;\n }", "public function getDetailedStatus()\n {\n return isset($this->detailed_status) ? $this->detailed_status : '';\n }", "public function status()\n {\n return $this->status;\n }", "public function unit()\n {\n $data = ['aktif' => 'unit',\n 'data_unit' => $this->M_prospektus->get_unit_menu()->result_array(),\n 'data_blok' => $this->M_prospektus->get_blok_kws()->result_array()\n ];\n\n $this->template->load('template','prospektus/V_data_unit', $data);\n }", "function VM_status($type, $vmName)\n{\n\tswitch ($type)\n\t{\n\t\tcase VM_SW_VBOX:\n\t\t\t$cmd = \"VBoxManage showvminfo \\\"$vmName\\\" | grep \\\":\\\" | tr -s [':blank:'] 2>&1 | cat\";\n\t\t\tbreak;\n\t}\n\treturn($cmd);\n}", "public function getStatusDescription()\n {\n return \\BFOS\\PagseguroBundle\\Utils\\Pagseguro::$transaction_status_description[$this->status];\n }", "public function getStatus()\n {\n switch ($this->temp) {\n case 0:\n return \"Définitif\";\n case 1:\n return \"Valide\";\n default:\n return \"Temporaire\";\n }\n }", "public function get_status() {\n return $this->status;\n }", "public function billing_status_cls($status){\n\t\tif($status == 'W' || $status == 'R'){\n\t\t $stat = '';\n\t\t}elseif($status == 'A'){\t\n\t\t $stat = 'success';\t\n\t\t}\n\t\treturn $stat;\n\t}", "public function status_cls($status){\n\t\tif($status == '1'){\n\t\t $stat = 'success';\n\t\t}else{\t\n\t\t $stat = 'important';\t\n\t\t}\n\t\treturn $stat;\n\t}", "public function getStatus()\n {\n return isset($this->status) ? $this->status : '';\n }", "public function getStatusLabelAttribute()\n {\n //ADAPUN VALUENYA AKAN MENCETAK HTML BERDASARKAN VALUE DARI FIELD STATUS\n if ($this->status == 'draft') {\n return '<span class=\"badge badge-secondary\">Draft</span>';\n }\n else {\n return '<span class=\"badge badge-success\">Aktif</span>';\n }\n }", "public function status(): string\n {\n return $this->status;\n }", "public function render_license_status_settings_field() {\n\t\t$settings_field_name = $this->get_settings_field_name();\n\t\t$options = get_option( $settings_field_name );\n\t\t$license_status = $options['license_status'];\n\n\t\t?>\n\t\t<!-- <input type=\"hidden\" name=\"<?php echo $settings_field_name; ?>[license_status]\" value='' -->\n\n\t\t<?php\n\t\tif ( $license_status !== false && $license_status === 'valid' ) { ?>\n\t\t\t<span class=\"title-count\" style=\"background-color:#41DCAB\"><?php _e( 'Active', $this->text_domain ); ?></span>\n\t\t<?php } else { ?>\n\t\t\t<span class=\"title-count\" style=\"background-color:#d54e21\"><?php _e( 'Inactive', $this->text_domain ); ?></span>\n\t\t<?php }\n\t}", "public function getStatus()\n\t{\n\t\treturn $this->status; \n\n\t}", "public function getStatus() {\n return $this->status;\n }", "public function getStatus() {\n return $this->status;\n }", "public function getUM()\n {\n $UnitOfMeasure = UnitOfMeasure::find($this->um_id); \n \n return $UnitOfMeasure->description;\n }", "public function getStatus(): void{\n\n echo json_encode([ 'Undefined','To start','In progress','Stopped','Finished' ]);\n\n }", "protected function status()\n {\n }", "public function getStatus();", "public function getStatus();", "public function getStatus();", "public function getStatus();", "public function getStatus();", "public function getStatus();", "public function getStatus();", "public function getStatus();" ]
[ "0.63098574", "0.61501235", "0.6001096", "0.5992697", "0.59849507", "0.59756595", "0.57938856", "0.57717305", "0.5759435", "0.5735232", "0.57280993", "0.5669508", "0.56585354", "0.5649375", "0.564511", "0.56441", "0.56288064", "0.56246394", "0.56232274", "0.5615621", "0.5614538", "0.56127924", "0.5607352", "0.5603187", "0.5585588", "0.5584951", "0.5584951", "0.5580617", "0.55603945", "0.55484474", "0.55342656", "0.552942", "0.5516836", "0.5516488", "0.5516488", "0.5511275", "0.55022573", "0.5495509", "0.5489615", "0.5487343", "0.5477928", "0.54774386", "0.5475523", "0.5469106", "0.5466065", "0.54651606", "0.54583645", "0.5456232", "0.5453122", "0.5449284", "0.54451746", "0.54419184", "0.5439824", "0.54354274", "0.5431274", "0.54303116", "0.5426611", "0.54239035", "0.5420071", "0.541262", "0.5411982", "0.54118955", "0.541138", "0.5409457", "0.5403926", "0.5385593", "0.53836787", "0.5370527", "0.5350256", "0.53498995", "0.5346943", "0.5345596", "0.53445554", "0.5343786", "0.5343277", "0.53431594", "0.53406477", "0.5338252", "0.5334573", "0.5332177", "0.5326748", "0.5321088", "0.53174794", "0.53169507", "0.53166944", "0.53143364", "0.5313398", "0.5306597", "0.5306597", "0.52924746", "0.52881306", "0.52837604", "0.52823865", "0.52823865", "0.52823865", "0.52823865", "0.52823865", "0.52823865", "0.52823865", "0.52823865" ]
0.6889715
0
Handles saving data from unit metaboxes.
function save_unit_meta_boxes( $post_id ) { /* * If we arent doing an autosave we merge all the extra fields with their corresponding post data. * Next we check to make sure we are saving a unit vs a post or page so we dont make the geocoding * request when we dont need to. Once we geocode the address, we save the long/lat in the DB. Next we * check to see if we are chaging the property from rented to available and if so, we set that date time * so we can calculate the listing age later on. */ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return; //Check to make sure we are on a "Units" page so we dont geocode on every page save// if (isset($_POST['unitsMetaBoxUpdate']) && $_POST['unitsMetaBoxUpdate'] == 'yesPlease') { $post_data = array_merge($this->extra_fields, $_POST); foreach( $this->extra_fields as $key => $value ) { update_post_meta( $post_id, $key, $post_data[$key]); } $address = $post_data['address']." ".$post_data['city'].", ".$post_data['state']." ".$post_data['zip']; $geoCode = $this->_geo_code( $address, $post_data ); update_post_meta( $post_id, 'lat', $geoCode['lat']); update_post_meta( $post_id, 'lon', $geoCode['lon']); //Lets see if user is making the unit available for rent.// //1) Check previous status $prevStatus = $_POST['previousStatus']; //2) Check if posted value is avail && previousStatus is rented if ($prevStatus == 'Rented' && $_POST['status'] == 'For Rent') { update_post_meta( $post_id, 'last_avail_date', strtotime('now')); } else { update_post_meta( $post_id, 'last_avail_date', $_POST['last_avail_date']); } } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function meta_boxes_save() {\r\n\t\t\r\n\t\t// Only process if the form has actually been submitted\r\n\t\tif (\r\n\t\t\tisset( $_POST['_wpnonce'] ) &&\r\n\t\t\tisset( $_POST['post_ID'] )\r\n\t\t) {\r\n\t\t\t\r\n\t\t\t// Do nonce security check\r\n\t\t\twp_verify_nonce( '_wpnonce', $_POST['_wpnonce'] );\r\n\t\t\t\r\n\t\t\t// Grab post ID\r\n\t\t\t$post_ID = (int) $_POST['post_ID'];\r\n\t\t\t\r\n\t\t\t// Iterate through each possible piece of meta data\r\n\t\t\tforeach( $this->post_meta as $key => $value ) {\r\n\t\t\t\tif ( isset( $_POST['_' . $key] ) ) {\r\n\t\t\t\t\t$data = esc_html( $_POST['_' . $key] ); // Sanitise data input\r\n\t\t\t\t\tupdate_post_meta( $post_ID, '_' . $key, $data ); // Store the data\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "protected function saveData()\n {\n // TODO: データ保存\n\n // 一次データ削除\n $this->deleteStore();\n\n drupal_set_message($this->t('The form has been saved.'));\n }", "function liblynx_save_meta_box_data($post_id)\n{\n\n /*\n * We need to verify this came from our screen and with proper authorization,\n * because the save_post action can be triggered at other times.\n */\n\n // Check if our nonce is set.\n if (!isset($_POST['liblynx_meta_box_nonce'])) {\n return;\n }\n\n\n\n // Verify that the nonce is valid.\n if (!wp_verify_nonce($_POST['liblynx_meta_box_nonce'], 'liblynx_save_meta_box_data')) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't want to do anything.\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\n return;\n }\n\n // Check the user's permissions.\n if (isset($_POST['post_type']) && 'page'==$_POST['post_type']) {\n if (!current_user_can('edit_page', $post_id)) {\n return;\n }\n } else {\n if (!current_user_can('edit_post', $post_id)) {\n return;\n }\n }\n\n /* OK, it's safe for us to save the data now. */\n\n //is our metabox is being submitted?\n if (!isset($_POST['liblynx_metabox'])) {\n return;\n }\n\n //determine new state\n $protect=isset($_POST['liblynx_protect'])?true:false;\n $unit=trim($_POST['liblynx_custom_unit']);\n\n // Update the meta field in the database.\n update_post_meta($post_id, '_liblynx_protect', $protect);\n update_post_meta($post_id, '_liblynx_unit', $unit);\n}", "function apprenants_save_meta_box_data($post_id)\r\n {\r\n // verify taxonomies meta box nonce\r\n if (!isset($_POST['apprenants_meta_box_nonce']) || !wp_verify_nonce($_POST['apprenants_meta_box_nonce'], basename(__FILE__))) {\r\n return;\r\n }\r\n\r\n // return if autosave\r\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\r\n return;\r\n }\r\n\r\n // Check the user's permissions.\r\n if (!current_user_can('edit_post', $post_id)) {\r\n return;\r\n }\r\n\r\n // store custom fields values\r\n // nom string\r\n if (isset($_REQUEST['nom'])) {\r\n update_post_meta($post_id, '_apprenants_nom', sanitize_text_field($_POST['nom']));\r\n }\r\n\r\n // store custom fields values\r\n // prénom string\r\n if (isset($_REQUEST['prenom'])) {\r\n update_post_meta($post_id, '_apprenants_prenom', sanitize_text_field($_POST['prenom']));\r\n }\r\n\r\n // store custom fields values\r\n // github string\r\n if (isset($_REQUEST['github'])) {\r\n update_post_meta($post_id, '_apprenants_github', sanitize_text_field($_POST['github']));\r\n }\r\n\r\n // store custom fields values\r\n //linkedIn string\r\n if (isset($_REQUEST['linkedIn'])) {\r\n update_post_meta($post_id, '_apprenants_linkedIn', sanitize_text_field($_POST['linkedIn']));\r\n }\r\n\r\n // store custom fields values\r\n //portfolio string\r\n if (isset($_REQUEST['portfolio'])) {\r\n update_post_meta($post_id, '_apprenants_portfolio', sanitize_text_field($_POST['portfolio']));\r\n }\r\n }", "function meta_boxes_save() {\n\n\t\t// Bail out now if something not set\n\t\tif (\n\t\t\tisset( $_POST['_wpnonce'] ) &&\n\t\t\tisset( $_POST['post_ID'] ) &&\n\t\t\tisset( $_POST['_lingo_hidden'] ) // This is required to ensure that auto-saves are not processed\n\t\t) {\n\t\t\t// Do nonce security check\n\t\t\twp_verify_nonce( '_wpnonce', $_POST['_wpnonce'] );\n\n\t\t\t// Grab post ID\n\t\t\t$post_ID = (int) $_POST['post_ID'];\n\n//echo '<textarea style=\"width:800px;height:600px;\">';print_r( $_POST['_translation'] );echo '</textarea>';\n//die('dead');\n\n\t\t\t// Stash all the post meta\n\t\t\tif ( isset( $_POST['_translation'] ) ) {\n\t\t\t\t$_translation = $_POST['_translation'];\n\t\t\t\tdelete_post_meta( $post_ID, '_translation' );\n\t\t\t\tforeach( $_translation as $key => $trans ) {\n\t\t\t\t\t$trans = wp_kses( $trans, '', '' );\n\t\t\t\t\tif ( $trans != '' )\n\t\t\t\t\t\tadd_post_meta( $post_ID, '_translation', $trans );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "static function save_metabox_data($post_id){\n\t\t\t// If this is an autosave, our form has not been submitted, so we don't want to do anything.\n\t\t\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ){\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t\n\t\t\t$keywords = array();\t\t\t\n\t\t\t//now it's safe to save info\n\t\t\tif(isset($_POST['affiliate_keywords'])){\n\t\t\t\tforeach($_POST['affiliate_keywords'] as $key => $value){\n\t\t\t\t\t$keywords[$key] = trim($value);\n\t\t\t\t}\n\t\t\t\tself::save_keywords($post_id, $keywords);\n\t\t\t}\n\t\t\t\n\t\t\tif(isset($_POST['local_position_enabled'])){\n\t\t\t\tupdate_post_meta($post_id, 'local_position_enabled', 'y');\n\t\t\t}\n\t\t\telse{\n\t\t\t\tupdate_post_meta($post_id, 'local_position_enabled', '');\n\t\t\t}\n\t\t\t\n\t\t\tif(isset($_POST['position'])){\n\t\t\t\t$positions = array();\n\t\t\t\tforeach($_POST['position'] as $key => $value){\n\t\t\t\t\t$positions[$key] = $value;\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tupdate_post_meta($post_id, 'local_positions', $positions);\n\t\t\t}\n\t\t\t\n\t\t\t//saving loal links\n\t\t\tif(isset($_POST['local_links'])){\n\t\t\t\tupdate_post_meta($post_id, 'local_links', $_POST['local_links']);\n\t\t\t}\n\t\t}", "function save() {\r\n foreach ($this->_data as $v)\r\n $v -> save();\r\n }", "function meta_boxes_save() {\n\n\t\t// Bail out now if something not set\n\t\tif (\n\t\t\tisset( $_POST['_wpnonce'] ) &&\n\t\t\tisset( $_POST['post_ID'] ) &&\n\t\t\tisset( $_POST['_lingo_hidden'] ) // This is required to ensure that auto-saves are not processed\n\t\t) {\n\n\t\t\t// Do nonce security check\n\t\t\twp_verify_nonce( '_wpnonce', $_POST['_wpnonce'] );\n\n\t\t\t// Grab post ID\n\t\t\t$post_ID = (int) $_POST['post_ID'];\n\t\t\t\n\t\t\t// Set wrong answers\n\t\t\tdelete_post_meta( $post_ID, '_wrong_answers' );\n\t\t\tforeach( $_POST['_wrong_answers'] as $key => $value ) {\n\t\t\t\tif ( $value != '' && $value != 0 ) {\n\t\t\t\t\t$value = (int) $value;\n\t\t\t\t\tadd_post_meta( $post_ID, '_wrong_answers', $value );\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t// Stash all the post meta\n\t\t\tforeach( $this->post_meta as $key => $x ) {\n\t\t\t\tif ( isset( $_POST[$key] ) ) {\n\t\t\t\t\t$value = (int) $_POST[$key];\n\t\t\t\t\tif ( $value != 0 )\n\t\t\t\t\t\tupdate_post_meta( $post_ID, $key, $value );\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "function saveForm(){\t\n\t\t$this->saveFormBase();\n\t\t$this->saveFormGeoCoverage();\n\t\t$this->saveVaFormResolution();\n\t\tif ($this->dataset->nbModForm >0) $this->saveModForm();\n\t\tif ($this->dataset->nbSatForm >0) $this->saveSatForm();\n\t\tif ($this->dataset->nbInstruForm >0) $this->saveInstruForm();\n\t\t$this->saveFormGrid();\n\t\t//Parameter\n\t\t$this->saveFormVariables($this->dataset->nbVars);\n\t\t//REQ DATA_FORMAT\n\t\t$this->dataset->required_data_formats = array();\n\t\t$this->dataset->required_data_formats[0] = new data_format;\n\t\t$this->dataset->required_data_formats[0]->data_format_id = $this->exportValue('required_data_format');\n\t}", "function tiva_product_custom_data_meta_box_save($post_id)\n{\n if (defined('DOING_AJAX')) {\n return;\n }\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\n return;\n }\n\n if (isset($_POST['product_garanti'])) {\n\n update_post_meta($post_id, 'product_garanti', $_POST['product_garanti']);\n\n } else {\n\n delete_post_meta($post_id, 'product_garanti');\n }\n\n if (isset($_POST['shoper_input'])) {\n\n update_post_meta($post_id, 'shoper_input', $_POST['shoper_input']);\n\n } else {\n delete_post_meta($post_id, 'shoper_input');\n }\n\n if (isset($_POST['bastebandi_input'])) {\n\n update_post_meta($post_id, 'bastebandi_input', $_POST['bastebandi_input']);\n\n } else {\n delete_post_meta($post_id, 'bastebandi_input');\n }\n\n\n if (isset($_POST['haml_input'])) {\n\n update_post_meta($post_id, 'haml_input', $_POST['haml_input']);\n\n } else {\n delete_post_meta($post_id, 'haml_input');\n }\n\n}", "function caviar_save_meta_box_data( $post_id ) {\n\t// Sanitize user input.\n\t$txtname = sanitize_text_field( $_POST['txtName'] );\n\t$txtAddress = $_POST['txtAddress'];\n\t$selTrans = $_POST['selTrans'];\n\t$txtWebsite = sanitize_text_field( $_POST['txtWebsite'] );\n\t$chkFood = $_POST['chkFood'];\n\t$itemFeatures = $_POST['itemFeatures'];\n\t$rePersonalData = $_POST['rePersonalData'];\n\t$gender = $_POST['gender'];\n\t$edAboutMe = $_POST['edAboutMe'];\n\n\t$features = array();\n\n\t// Update the meta field in the database.\n\tupdate_post_meta( $post_id, '_txtName', $txtname );\n\tupdate_post_meta( $post_id, '_txtAddress', $txtAddress );\n\tupdate_post_meta( $post_id, '_selTrans', $selTrans );\n\tupdate_post_meta( $post_id, '_txtWebsite', $txtWebsite );\n\tupdate_post_meta( $post_id, '_chkFood', $chkFood );\n\tupdate_post_meta( $post_id, '_gender', $gender );\n\tupdate_post_meta( $post_id, '_colorMeta', $_POST['colorMeta'] );\n\tupdate_post_meta( $post_id, '_selHobby', $_POST['selHobby'] );\n\tupdate_post_meta( $post_id, '_edAboutMe', $edAboutMe );\n\tupdate_post_meta( $post_id, '_selCats', $_POST['selCats'] );\n\tupdate_post_meta( $post_id, '_upPhoto', $_POST['upPhoto'] );\n\tupdate_post_meta( $post_id, '_upLicense', $_POST['upLicense'] );\n\n\t// var_dump($itemFeatures);\n\tif ( isset( $itemFeatures ) )\n\t{\n\t\tforeach ( $itemFeatures as $feature )\n\t\t{\n\t\t\tif ( '' !== trim( $feature['title'] ) )\n\t\t\t\t$features[] = $feature;\n\t\t}\n\t}\n\n\tupdate_post_meta( $post_id, '_itemFeatures', $features );\n\n\n\tif ( isset( $rePersonalData ) )\n\t{\n\t\tforeach ( $rePersonalData as $data )\n\t\t{\n\t\t\t$pData[] = $data;\n\t\t}\n\t}\n\n\tupdate_post_meta( $post_id, '_rePersonalData', $pData );\n}", "function save_rew_meta_box_input($rew_id)\n{\n\n\tif (isset($_POST['main_address'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'main_address', $_POST['main_address']);\n\t}\n\n\tif (isset($_POST['district_address'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'district_address', $_POST['district_address']);\n\t}\n\n\tif (isset($_POST['rew_rooms'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'rew_rooms', $_POST['rew_rooms']);\n\t}\n\n\n\tif (isset($_POST['rew_floors'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'rew_floors', $_POST['rew_floor']);\n\t}\n\tif (isset($_POST['Apartment_area'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'Apartment_area', $_POST['Apartment_area']);\n\t}\n\n\tif (isset($_POST['flat_type'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'flat_type', $_POST['flat_type']);\n\t}\n\n\tif (isset($_POST['rew_price'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'rew_price', $_POST['rew_price']);\n\t}\n\n\n\n\t\t// villa rew_garden\n\tif (isset($_POST['rew_garden'])){\n\t\t\n\t\tupdate_post_meta($rew_id , 'rew_garden', $_POST['rew_garden']);\n\t}\n\n}", "function metabox_store($post){\n\t\tglobal $postmec;\n\t\tinclude $postmec->get_postmec_dir() . 'metaboxes/metabox.store.php';\n\t}", "Function Wp_meta_box_store(){\n\n\t$mult_posts = array( 'post', 'page' );\n\n\tforeach ($mult_posts as $mult_post) {\n\t\tadd_meta_box(\n\t\t\t'meta_box_id', \t\t\t\t\t# metabox id\n\t\t\t__('Author Bio', 'textdomain'),\t# Title \n\t\t\t'wp_meta_box_call_back_func_store', \t# Callback Function \n\t\t\t$mult_post, \t\t\t\t\t# Post Type\n\t\t\t'normal'\t\t\t\t\t\t# textcontent\n\t\t);\n\t}\n\t\n}", "public function saveData($data)\n\t {\n\t \t$name = self::getNameMetaBox($data['_title_meta_box']);\n\n\t \t$content = self::getDataMetas();\n\t \t$data['_name_meta_box'] = $name;\n\t \t$content[$name] = $data;\n\t \tupdate_option('metas-custom', $content);\n\t }", "function ccwts_metabox_ticketsale_save( $post_id )\n{\n //if( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n \n // if our nonce isn't there, or we can't verify it, bail\n //if( !isset( $_POST['meta_box_nonce'] ) || !wp_verify_nonce( $_POST['meta_box_nonce'], 'my_meta_box_nonce' ) ) return;\n \n // if our current user can't edit this post, bail\n //if( !current_user_can( 'edit_post' ) ) return;\n \n // now we can actually save the data\n /*$allowed = array( \n 'a' => array( // on allow a tags\n 'href' => array() // and those anchors can only have href attribute\n )\n );*/\n \n // Make sure your data is set before trying to save it\n if(basename( get_page_template() ) == 'page-biglietteria-2017.php' || basename( get_page_template() ) == 'page-biglietteria-2017-hotel.php' )\n {\n \n if( isset( $_POST['ccwts_ticketsale_id'] ) && intval($_POST['ccwts_ticketsale_id']) > 0)\n ccwts_field('ticketsale_id', $_POST['ccwts_ticketsale_id']);\n\n if(basename( get_page_template() ) == 'page-biglietteria-2017-hotel.php' ){\n if( isset( $_POST['ccwts_parkhotel_ticket_id'] ) && intval($_POST['ccwts_parkhotel_ticket_id']) > 0)\n ccwts_field('parkhotel_ticket_id', $_POST['ccwts_parkhotel_ticket_id']);\n }\n\n }\n //update_post_meta( $post_id, 'my_meta_box_text', wp_kses( $_POST['my_meta_box_text'], $allowed ) );\n \n //if( isset( $_POST['my_meta_box_select'] ) )\n //update_post_meta( $post_id, 'my_meta_box_select', esc_attr( $_POST['my_meta_box_select'] ) );\n \n // This is purely my personal preference for saving check-boxes\n //$chk = isset( $_POST['my_meta_box_check'] ) && $_POST['my_meta_box_select'] ? 'on' : 'off';\n //update_post_meta( $post_id, 'my_meta_box_check', $chk );\n}", "function OF_meta_box_data_update( $post_id ) {\n\n /*\n * We need to verify this came from our screen and with proper authorization,\n * because the save_post action can be triggered at other times.\n */\n\n // Check if our nonce is set.\n if ( ! isset( $_POST['OF_meta_box_nonce'] ) ) {\n return;\n }\n\n // Verify that the nonce is valid.\n if ( ! wp_verify_nonce( $_POST['OF_meta_box_nonce'], 'OF_meta_box' ) ) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't want to do anything.\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return;\n }\n\n // Check the user's permissions.\n if ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\n\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\n return;\n }\n\n } else {\n\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n }\n\n /* OK, it's safe for us to save the data now. */\n \n\n global $allowedtags;\n\n // allow iframe only in this instance\n $iframe = array( 'iframe' => array(\n 'src' => array(),\n 'width' => array(),\n 'height' => array(),\n 'frameborder' => array(),\n 'div' => array(),\n 'span'=> array(),\n 'class' => array(),\n 'allowFullScreen' => array() // add any other attributes you wish to allow\n ) );\n\n $allowed_html = array_merge( $allowedtags, $iframe );\n\n\n // Sanitize user input.\n // Without html \"sanitize_text_field\"\n global $wpdb;\n $allnormalMetas = $wpdb->get_results(\"SELECT * FROM `plugin_of_metabox`\", OBJECT); //\\\n foreach($allnormalMetas as $single_meta){ \n $my_data_sku = wp_kses( $_POST[$single_meta->meta_slug], $allowed_html ); // pic data from post \n update_post_meta( $post_id, $single_meta->meta_slug, $my_data_sku); // Update the meta field in the database.\n }\n}", "public function save()\n {\n $this->save_meta_value('_sim_city_main_info', $this->city_main_info);\n\n $this->save_meta_value('_sim_city_shops', $this->city_shops);\n }", "function do_save(){\n\t\t// check that number and post_ID is set\n\t\tif( empty($this->post_ID) || empty($this->number) ) return false;\n\t\t\n\t\t// check that we have data in POST\n\t\tif( $this->id_base != 'checkbox' && (\n\t\t\t\tempty($_POST['field-'.$this->id_base][$this->number]) ||\n\t\t\t\t!is_array($_POST['field-'.$this->id_base][$this->number])\n\t\t\t)\n\t\t )\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\t$input = @$_POST['field-'.$this->id_base][$this->number];\n\t\t// get real values\n\t\t$values = $this->save( $input );\n\t\t// save to post meta\n\t\tupdate_post_meta($this->post_ID, $this->slug, $values);\n\t\treturn true;\n\t}", "protected function save_meta() {\n\n\t\t// save all data in array\n\t\tupdate_user_meta( $this->user_id, APP_REPORTS_U_DATA_KEY, $this->meta );\n\n\t\t// also save total reports in separate meta for sorting queries\n\t\tupdate_user_meta( $this->user_id, APP_REPORTS_U_TOTAL_KEY, $this->total_reports );\n\t}", "function wck_save_single_metabox( $post_id, $post ){\r\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )\r\n return $post_id;\r\n\r\n // Check the user's permissions.\r\n if ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\r\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\r\n return $post_id;\r\n }\r\n } else {\r\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\r\n return $post_id;\r\n }\r\n }\r\n\r\n /* only go through for metaboxes defined for this post type */\r\n if( get_post_type( $post_id ) != $this->args['post_type'] )\r\n return $post_id;\r\n\r\n if( !empty( $_POST ) ){\r\n /* for single metaboxes we save a hidden input that contains the meta_name attr as a key so we need to search for it */\r\n foreach( $_POST as $request_key => $request_value ){\r\n if( strpos( $request_key, '_wckmetaname_' ) !== false && strpos( $request_key, '#wck' ) !== false ){\r\n /* found it so now retrieve the meta_name from the key formatted _wckmetaname_actuaname#wck */\r\n $request_key = str_replace( '_wckmetaname_', '', $request_key );\r\n $meta_name = sanitize_text_field( str_replace( '#wck', '', $request_key ) );\r\n /* we have it so go through only on the WCK object instance that has this meta_name */\r\n if( $this->args['meta_name'] == $meta_name ){\r\n\r\n /* get the meta values from the $_POST and store them in an array */\r\n $meta_values = array();\r\n if( !empty( $this->args['meta_array'] ) ){\r\n foreach ($this->args['meta_array'] as $meta_field){\r\n /* in the $_POST the names for the fields are prefixed with the meta_name for the single metaboxes in case there are multiple metaboxes that contain fields wit hthe same name */\r\n $single_field_name = $this->args['meta_name'] .'_'. Wordpress_Creation_Kit_PB::wck_generate_slug( $meta_field['title'],$meta_field );\r\n if (isset($_POST[$single_field_name])) {\r\n /* checkbox needs to be stored as string not array */\r\n if( $meta_field['type'] == 'checkbox' )\r\n $_POST[$single_field_name] = implode( ', ', $_POST[$single_field_name] );\r\n\r\n $meta_values[Wordpress_Creation_Kit_PB::wck_generate_slug( $meta_field['title'], $meta_field )] = wppb_sanitize_value( $_POST[$single_field_name] );\r\n }\r\n else\r\n $meta_values[Wordpress_Creation_Kit_PB::wck_generate_slug( $meta_field['title'], $meta_field )] = '';\r\n }\r\n }\r\n\r\n /* test if we have errors for the required fields */\r\n $errors = self::wck_test_required( $this->args['meta_array'], $meta_name, $meta_values, $post_id );\r\n if( !empty( $errors ) ){\r\n /* if we have errors then add them in the global. We do this so we get all errors from all single metaboxes that might be on that page */\r\n global $wck_single_forms_errors;\r\n if( !empty( $errors['errorfields'] ) ){\r\n foreach( $errors['errorfields'] as $key => $field_name ){\r\n $errors['errorfields'][$key] = $this->args['meta_name']. '_' .$field_name;\r\n }\r\n }\r\n $wck_single_forms_errors[] = $errors;\r\n }\r\n else {\r\n /* no errors so we can save */\r\n update_post_meta($post_id, $meta_name, array($meta_values));\r\n /* handle unserialized fields */\r\n if ($this->args['unserialize_fields']) {\r\n if (!empty($this->args['meta_array'])) {\r\n foreach ($this->args['meta_array'] as $meta_field) {\r\n update_post_meta($post_id, $meta_name . '_' . Wordpress_Creation_Kit_PB::wck_generate_slug( $meta_field['title'], $meta_field ) . '_1', $_POST[$this->args['meta_name'] . '_' . Wordpress_Creation_Kit_PB::wck_generate_slug( $meta_field['title'], $meta_field )]);\r\n }\r\n }\r\n }\r\n }\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n }", "function pexeto_save_meta_data($new_meta_boxes, $post_id){\n\tforeach($new_meta_boxes as $meta_box) {\n\n\t\tif($meta_box['type']!='heading'){\n\t\t\t// Verify\n\t\t\tif ( !wp_verify_nonce( $_POST[$meta_box['name'].'_noncename'], plugin_basename(__FILE__) )) {\n\t\t\t\treturn $post_id;\n\t\t\t}\n\n\t\t\tif ( 'page' == $_POST['post_type'] ) {\n\t\t\t\tif ( !current_user_can( 'edit_page', $post_id ))\n\t\t\t\treturn $post_id;\n\t\t\t} else {\n\t\t\t\tif ( !current_user_can( 'edit_post', $post_id ))\n\t\t\t\treturn $post_id;\n\t\t\t}\n\n\t\t\t$data = $_POST[$meta_box['name'].'_value'];\n\n\n\n\t\t\tif(get_post_meta($post_id, $meta_box['name'].'_value') == \"\")\n\t\t\tadd_post_meta($post_id, $meta_box['name'].'_value', $data, true);\n\t\t\telseif($data != get_post_meta($post_id, $meta_box['name'].'_value', true))\n\t\t\tupdate_post_meta($post_id, $meta_box['name'].'_value', $data);\n\t\t\telseif($data == \"\")\n\t\t\tdelete_post_meta($post_id, $meta_box['name'].'_value', get_post_meta($post_id, $meta_box['name'].'_value', true));\n\n\t\t}\n\t}\n}", "function mf_SALF_artist_meta_save_data($post_id) {\n\tglobal $artist_meta_box;\n\t\n\t\n\t\n\t\n \n \n // verify nonce\n if (!wp_verify_nonce($_POST['artist_meta_box_nonce'], basename(__FILE__))) {\n return $post_id;\n }\n\n // check autosave\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\n return $post_id;\n }\n\n // check permissions\n if ('page' == $_POST['post_type']) {\n if (!current_user_can('edit_page', $post_id)) {\n return $post_id;\n }\n } elseif (!current_user_can('edit_post', $post_id)) {\n return $post_id;\n }\n \n foreach ($artist_meta_box['fields'] as $field) {\n\t\t\n\t\tif($field['type']!='checkbox'){\n $old = get_post_meta($post_id, $field['id'], true);\n $new = $_POST[$field['id']];\n\t\t \n\t\t\n if ($new && $new != $old) {\n update_post_meta($post_id, $field['id'], $new);\n } elseif ('' == $new && $old) {\n delete_post_meta($post_id, $field['id'], $old);\n }\n\n\t\t} else {\n\t\t\n\t\t$old = get_post_meta($post_id, 'mf_SALF_artist_meta_checks', true);\n\t\t$new = $_POST['mf_SALF_artist_meta_checks'];\n\t\t\n\t\t\n\t\tif ($new && $new != $old) {\n update_post_meta($post_id, 'mf_SALF_artist_meta_checks', $new);\n } elseif ('' == $new && $old) {\n delete_post_meta($post_id, 'mf_SALF_artist_meta_checks', $old);\n }\t\n\t\t}\n\t\t\n }\n}", "function save_metabox_data($post_id){\t\n\t\t\t\n\t\tupdate_post_meta($post_id,'wiki-contributons-status',$_REQUEST['wiki-tabel-shownorhide']);\n\t\t\n\t}", "function meta_box_save( $post_id )\n{\n if( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n \n // if our nonce isn't there, or we can't verify it, bail\n if( !isset( $_POST['meta_box_nonce'] ) || !wp_verify_nonce( $_POST['meta_box_nonce'], 'meta_box_nonce' ) ) return;\n \n // if our current user can't edit this post, bail\n //if( !current_user_can( 'edit_post' ) ) return;\n\t\n\t// now we can actually save the data\n $allowed = array(\n 'a' => array( // on allow a tags\n 'href' => array() // and those anchors can only have href attribute\n )\n );\n // Make sure your data is set before trying to save it\n if( isset( $_POST['meta_box_manufacturer'] ) )\n update_post_meta( $post_id, 'meta_box_manufacturer', $_POST['meta_box_manufacturer'] );\n}", "function save_my_meta_box_data2( $post_id ) {\n\n\n // Check if our nonce is set.\n if ( ! isset( $_POST['post_meta_box_nonce'] ) ) {\n return;\n }\n\n // Verify that the nonce is valid.\n if ( ! wp_verify_nonce( $_POST['post_meta_box_nonce'], 'post_meta_box' ) ) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't want to do anything.\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return;\n }\n\n // Check the user's permissions.\n if ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\n\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\n return;\n }\n\n } else {\n\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n }\n\n /* OK, it's safe for us to save the data now. */\n\n // Make sure that it is set.\n if ( ! isset( $_POST['second_title'] ) ) {\n return;\n }\n // Make sure that it is set.\n if ( ! isset( $_POST['fexid'] ) ) {\n return;\n }\n // Make sure that it is set.\n if ( ! isset( $_POST['po_sources'] ) ) {\n return;\n }\n\n // Sanitize user input.\n $my_sec_title = sanitize_text_field( $_POST['second_title'] );\n $my_post_sources = sanitize_text_field( $_POST['po_sources'] );\n $my_fexid = sanitize_text_field( $_POST['fexid'] );\n\n // Update the meta field in the database.\n update_post_meta( $post_id, 'post_second_title', $my_sec_title );\n update_post_meta( $post_id, 'post_sources', $my_post_sources );\n update_post_meta( $post_id, 'post_fexid', $my_fexid );\n}", "static function save_metabox($post_id){\n\t\tif ( ! isset( $_POST['flat-options_nonce'] ) )\n\t\t\treturn $post_id;\n\n\t\t$nonce = $_POST['flat-options_nonce'];\n\n\n\t\t// Verify that the nonce is valid.\n\t\tif ( ! wp_verify_nonce( $nonce, 'flat-options' ) )\n\t\t\treturn $post_id;\n\n\t\t// If this is an autosave, our form has not been submitted,\n // so we don't want to do anything.\n\t\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) \n\t\t\treturn $post_id;\n\n\t\t// Check the user's permissions.\n\t\tif ( 'page' == $_POST['post_type'] ) {\n\n\t\t\tif ( ! current_user_can( 'edit_page', $post_id ) )\n\t\t\t\treturn $post_id;\n\t\n\t\t} else {\n\n\t\t\tif ( ! current_user_can( 'edit_post', $post_id ) )\n\t\t\t\treturn $post_id;\n\t\t}\n\n\t\t/* OK, its safe for us to save the data now. */\n\t\t\n\t\t$fieldblocks = self::get_fields();\n\t\t\n\t\tforeach ($fieldblocks as $key => $fields){\n\t\t\tforeach ($fields as $key => $field){\t\t\t\n\t\t\t\tif ($field['type'] == \"text\") $value = sanitize_text_field($_POST[$key]);\n\t\t\t\tif ($field['type'] == \"number\") $value = (int) $_POST[$key];\n\t\t\t\t\n\t\t\t\tupdate_post_meta( $post_id, $key, $value );\n\t\t\t}\n\t\t}\t\n\t \n }", "function prosody_poem_type_save_meta_box_data ($post_id=null)\n{\n $post_id = (is_null($post_id)) ? get_post()->ID : $post_id;\n\n /*\n * We need to verify this came from our screen and with proper\n * authorization, because the save_post action can be triggered at other\n * times.\n */\n\n // Check if our nonce is set.\n if ( ! isset( $_POST['prosody_poem_type_meta_box_nonce'] ) ) {\n return;\n }\n\n // Verify that the nonce is valid.\n $nonce = $_POST['prosody_poem_type_meta_box_nonce'];\n if ( ! wp_verify_nonce( $nonce, 'prosody_poem_type_meta_box' ) ) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't\n // want to do anything.\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return;\n }\n\n // Check the user's permissions.\n if ( isset( $_POST['post_type'] ) &&\n 'prosody_poem' == $_POST['post_type'] ) {\n\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\n return;\n }\n\n } else {\n\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n }\n\n /* OK, its safe for us to save the data now. */\n\n // Make sure that it is set.\n if ( ! isset( $_POST['prosody_poem_type'] ) ) {\n return;\n }\n\n // Sanitize user input. In this case we don't so the transform will work.\n $my_data = sanitize_text_field( $_POST['prosody_poem_type'] );\n\n // Update the meta field in the database.\n update_post_meta( $post_id, 'Type', $my_data );\n}", "function saveData() {\n\n\t\t$this->getMapper()->saveData();\t\n\t\t\n\t\t\n\t}", "abstract protected function saveItems();", "function meta_box_save_func_store($post_id){\n\n\t# Doing autosave then return.\n\tif (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE)\n\t\treturn;\n\n\t# If the nonce is not present there or we can not versify it.\n\tif ( !isset($_POST['product_nonce_name']) || !wp_verify_nonce($_POST['product_nonce_name'], 'product_nonce_action' ))\n\t\treturn;\n\n\t# Save Author Name \n\tif (isset($_POST['author_name']) && ($_POST['author_name'] != '') ) {\n\t \tupdate_post_meta($post_id, 'author_name', esc_html($_POST['author_name']));\n\t } \n\n\t# Save data Product name.\n\tif (isset($_POST['product_name']) && ($_POST['product_name'] != '')) {\n\t\tupdate_post_meta($post_id, 'product_name', esc_html($_POST['product_name']));\n\t}\n\n\t# Save data Product Description.\n\tif (isset($_POST['product_description']) && ($_POST['product_description'] != '')) {\n\t\tupdate_post_meta($post_id, 'product_description', esc_html($_POST['product_description']));\n\t}\n\n\n}", "public function save() {\n foreach($this->getMenuItems() as $item){\n $item->setMenu($this);\n $item->save();\n }\n parent::save();\n }", "function ariana_save_services_metabox( $post_id ) {\n $nonce_name = isset( $_POST['_ariana_services_metabox_nonce'] ) ? $_POST['_ariana_services_metabox_nonce'] : '';\n $nonce_action = 'ariana_services_metabox_nonce';\n\n // Check if nonce is valid.\n if ( ! wp_verify_nonce( $nonce_name, $nonce_action ) ) {\n return;\n }\n\n // Check if user has permissions to save data.\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n\n // Check if not an autosave.\n if ( wp_is_post_autosave( $post_id ) ) {\n return;\n }\n\n // Check if not a revision.\n if ( wp_is_post_revision( $post_id ) ) {\n return;\n }\n\n $allowed_tags = array(\n 'a' => array(\n 'href' => array(),\n 'title' => array(),\n 'id' => array()\n )\n );\n\n\n if ( isset( $_POST['post-sec-title'] ) ){\n update_post_meta(\n $post_id,\n 'post_sec_title',\n wp_kses( $_POST['post-sec-title'], $allowed_tags )\n );\n }\n\n\t\tif ( isset( $_POST['post-home-subtitle'] ) ){\n update_post_meta(\n $post_id,\n 'post_home_subtitle',\n wp_kses( $_POST['post-home-subtitle'], $allowed_tags )\n );\n }\n\n if ( isset( $_POST['post-desc'] ) ){\n update_post_meta(\n $post_id,\n 'post_desc',\n wp_kses_post( $_POST['post-desc'] )\n );\n }\n\n}", "public function vendors_save_metabox_data($post_id)\n {\n // die(print_r(basename(__FILE__)));\n\n // Contact Person field nonce\n if (!isset($_POST['vendor_contact_person_metabox_nonce']) || !wp_verify_nonce($_POST['vendor_contact_person_metabox_nonce'], 'vendor_contact_person_metabox')) {\n return $post_id;\n }\n // Email field nonce\n if (!isset($_POST['vendor_email_metabox_nonce']) || !wp_verify_nonce($_POST['vendor_email_metabox_nonce'], 'vendor_email_metabox')) {\n return $post_id;\n }\n // Phone field nonce\n if (!isset($_POST['vendor_phone_metabox_nonce']) || !wp_verify_nonce($_POST['vendor_phone_metabox_nonce'], 'vendor_phone_metabox')) {\n return $post_id;\n }\n\n // URL field nonce\n if (!isset($_POST['vendor_url_metabox_nonce']) || !wp_verify_nonce($_POST['vendor_url_metabox_nonce'], 'vendor_url_metabox')) {\n return $post_id;\n }\n\n // return if autosave\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\n return;\n }\n // Check the user's permissions.\n if (! current_user_can('edit_post', $post_id)) {\n return;\n }\n\n // store custom fields values\n // Save contact person\n if (isset($_POST['vendor_contact_person'])) {\n update_post_meta($post_id, '_vendor_contact_person', sanitize_text_field($_POST['vendor_contact_person']));\n }\n\n // Save email\n if (isset($_POST['vendor_email'])) {\n update_post_meta($post_id, '_vendor_email', sanitize_text_field($_POST['vendor_email']));\n }\n\n // Save phone\n if (isset($_POST['vendor_phone'])) {\n update_post_meta($post_id, '_vendor_phone', sanitize_text_field($_POST['vendor_phone']));\n }\n\n // Save URL\n if (isset($_POST['vendor_url'])) {\n update_post_meta($post_id, '_vendor_url', sanitize_text_field($_POST['vendor_url']));\n }\n }", "public function save(){\r\n // Need the post type name again\r\n $post_type_name = $this->post_type_name;\r\n\r\n add_action( 'save_post',\r\n function() use( $post_type_name ){\r\n // Deny the WordPress autosave function\r\n if( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE ) return;\r\n\r\n if ( ! wp_verify_nonce( $_POST['custom_post_type'], plugin_basename(__FILE__) ) ) return;\r\n\r\n global $post;\r\n\r\n if( isset( $_POST ) && isset( $post->ID ) && get_post_type( $post->ID ) == $post_type_name ){\r\n global $custom_fields;\r\n\r\n // Loop through each meta box\r\n foreach( $custom_fields as $title => $fields ){\r\n // Loop through all fields\r\n foreach( $fields as $label => $type ){\r\n $field_id_name = strtolower( str_replace( ' ', '_', $title ) ) . '_' . strtolower( str_replace( ' ', '_', $label ) );\r\n if($_POST['custom_meta'][$field_id_name] != ''){//Check Entry is not empty\r\n update_post_meta( $post->ID, $field_id_name, $_POST['custom_meta'][$field_id_name] );\r\n }\r\n }\r\n\r\n }\r\n }\r\n }\r\n );\r\n }", "public function save () {\r\n\t\tif (isset($_POST['data'])) {\r\n\t\t\t$data = stripslashes_deep($_POST['data']);\r\n\t\t\tif (!empty($data['preset']) && !empty($data['id'])) $data['preset'] = $data['id']; // Also override whatever preset we're seding\r\n\t\t\t$_POST['data'] = $data;\r\n\t\t}\r\n\t\tparent::save();\r\n\t}", "public function save()\n {\n // Quantity is reset to 1 if it's not specified, so make sure it's included\n if (count($this->updatedFields) AND !in_array('Quantity', $this->updatedFields)) {\n $this->updatedFields[] = 'Quantity';\n }\n\n // Need to save custom fields first\n $this->saveCustom();\n parent::save();\n }", "function calsteams_mbox_save($post_id){\n // Checks save status\n global $mbox;\n\n $is_autosave = wp_is_post_autosave( $post_id );\n $is_revision = wp_is_post_revision( $post_id );\n $is_valid_nonce = ( isset( $_POST['calsteams_nonce'] ) ) && wp_verify_nonce($_POST['calsteams_nonce'],'calsteams_update_field') ? 'true' : 'false';\n\n // Exits script depending on save status\n if ( $is_autosave || $is_revision || !$is_valid_nonce ) {\n return;\n }\n\n //Real foreach, temporarily commented out\n foreach ($mbox['fields'] as $field) {\n\n $input_id = $field['id'];//get the current item's input id property\n\n // Checks for input and sanitizes/saves if needed\n if( isset( $_POST[ $input_id ] ) ) {\n\n update_post_meta( $post_id, $input_id, sanitize_text_field( $_POST[ $input_id ] ) );\n }\n }\n}", "protected function save_meta() {\n\n\t\t// save all data in array\n\t\tupdate_post_meta( $this->post_id, APP_REPORTS_P_DATA_KEY, $this->meta );\n\n\t\t// also save total reports in separate meta for sorting queries\n\t\tupdate_post_meta( $this->post_id, APP_REPORTS_P_TOTAL_KEY, $this->total_reports );\n\t}", "function aerospace101_save_meta_box_data( $post_id ) {\n\t// Verify meta box nonce.\n\tif ( ! isset( $_POST['aerospace101_meta_box_nonce'] ) || ! wp_verify_nonce( sanitize_key( wp_unslash( $_POST['aerospace101_meta_box_nonce'] ) ), basename( __FILE__ ) ) ) { // Input var okay.\n\t\treturn;\n\t}\n\t// Return if autosave.\n\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n\t\treturn;\n\t}\n\t// Check the user's permissions.\n\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\treturn;\n\t}\n\t\n\t// Is Featured?\n\tif ( isset( $_REQUEST['is_featured'] ) ) {\n\t\tupdate_post_meta( $post_id, '_post_is_featured', intval( wp_unslash( $_POST['is_featured'] ) ) );\n\t} else {\n\t\tupdate_post_meta( $post_id, '_post_is_featured', 0 );\n\t}\n\t// Sources.\n\tif ( isset( $_REQUEST['sources'] ) ) { // Input var okay.\n\t\tupdate_post_meta( $post_id, '_post_sources', wp_kses_post( wp_unslash( $_POST['sources'] ) ) ); // Input var okay.\n\t}\n\n}", "function italystrap_meta_box_save( $post_id ){\n\tif( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n\t\n\t// if our nonce isn't there, or we can't verify it, bail\n\tif( !isset( $_POST['meta_box_nonce'] ) || !wp_verify_nonce( $_POST['meta_box_nonce'], 'my_meta_box_nonce' ) ) return;\n\t\n\t// if our current user can't edit this post, bail\n\t//http://code.tutsplus.com/tutorials/how-to-create-custom-wordpress-writemeta-boxes--wp-20336#comment-802227555\n\t//prevents undefined offset notice and cannot modify header warning - add second parameters $post_id\n\tif( !current_user_can( 'edit_post' , $post_id ) ) return;\n\t\n\t// now we can actually save the data\t\n\t// Probably a good idea to make sure your data is set\n\t// This is purely my personal preference for saving checkboxes\n\t$chk = ( isset( $_POST['slide'] ) && $_POST['slide'] ) ? 'on' : 'off';\n\tupdate_post_meta( $post_id, 'slide', $chk );\n}", "public function save_metabox($post_id) {\r\n\t \tif (!isset($_POST['omfw_meta_box_nonce']) || !wp_verify_nonce($_POST['omfw_meta_box_nonce'], 'update-omfw-meta-'.$post_id)) {\r\n\t\t\treturn $post_id;\r\n\t\t}\r\n\t\t\t\r\n\t\t// check autosave\r\n\t\tif (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\r\n\t\t\treturn $post_id;\r\n\t\t}\r\n\t\t\r\n\t\t// check if targeted post type\r\n\t\tif ($this->post_type != $_POST['post_type']) {\r\n\t\t\treturn $post_id;\r\n\t\t}\r\n\t \r\n\t\t// check permissions\r\n\t\tif ('page' == $_POST['post_type']) {\r\n\t\t\tif (!current_user_can('edit_page', $post_id)) {\r\n\t\t\t\treturn $post_id;\r\n\t\t\t}\r\n\t\t} elseif (!current_user_can('edit_post', $post_id)) {\r\n\t\t\treturn $post_id;\r\n\t\t}\r\n\t\r\n\t \tforeach ($this->metaboxes as $metabox_key=>$metabox) {\r\n\t\t\tforeach ($metabox['fields'] as $field) {\r\n\t\t\t\tif( isset($_POST[$field['id']]) ) {\r\n\t\t\t\t\tif($field['type'] == 'categories_list_multiple') {\r\n\t\t\t\t\t\tif(is_array($_POST[$field['id']])) {\r\n\t\t\t\t\t\t\tupdate_post_meta($post_id, $field['id'], implode(',',$_POST[$field['id']]));\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t \tupdate_post_meta($post_id, $field['id'], '');\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\tupdate_post_meta($post_id, $field['id'], $_POST[$field['id']]);\r\n\t\t\t\t\t}\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif($field['type'] == 'categories_list_multiple') {\r\n\t\t\t\t\t \tupdate_post_meta($post_id, $field['id'], '');\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}", "protected function save_meta() {}", "public function ecf_save_meta_box( $post_id ) {\r\n\t\t\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\r\n\t\t\tif ( $parent_id = wp_is_post_revision( $post_id ) ) {\r\n\t\t\t\t$post_id = $parent_id;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$fields = array();\r\n\r\n\t\t\tforeach($this->customFields as $customField){\r\n\t\t\t\tarray_push( $fields, $customField['name'] );\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tforeach ( $fields as $field ) {\r\n\t\t\t\tif ( array_key_exists( $field, $_POST ) ) {\r\n\t\t\t\t\tupdate_post_meta( $post_id, $field, sanitize_text_field( $_POST[$field] ) );\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}", "private function SaveData()\n {\n // loop tanks and save data\n foreach ($this->tanks AS $tank_id => $data) {\n // get category id from tank id\n $category_id_tank = $this->CreateCategoryByIdentifier($this->InstanceID, $tank_id, $data['Name']);\n\n // loop tank data and add variables to tank category\n $position = 0;\n foreach ($data AS $key => $value) {\n $this->CreateVariableByIdentifier($category_id_tank, $key, $value, $position);\n $position++;\n }\n }\n }", "function prosody_poem_difficulty_save_meta_box_data ($post_id=null)\n{\n $post_id = (is_null($post_id)) ? get_post()->ID : $post_id;\n\n /*\n * We need to verify this came from our screen and with proper\n * authorization, because the save_post action can be triggered at other\n * times.\n */\n\n // Check if our nonce is set.\n if ( ! isset( $_POST['prosody_poem_difficulty_meta_box_nonce'] ) ) {\n return;\n }\n\n // Verify that the nonce is valid.\n $nonce = $_POST['prosody_poem_difficulty_meta_box_nonce'];\n if ( ! wp_verify_nonce( $nonce, 'prosody_poem_difficulty_meta_box' ) ) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't\n // want to do anything.\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return;\n }\n\n // Check the user's permissions.\n if ( isset( $_POST['post_type'] ) &&\n 'prosody_poem' == $_POST['post_type'] ) {\n\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\n return;\n }\n\n } else {\n\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n }\n\n /* OK, its safe for us to save the data now. */\n\n // Make sure that it is set.\n if ( ! isset( $_POST['prosody_poem_difficulty'] ) ) {\n return;\n }\n\n // Sanitize user input. We don't need this since it's a dropdown.\n // $my_data = sanitize_text_field( $_POST['prosody_poem_difficulty'] );\n\n // Update the meta field in the database.\n update_post_meta( $post_id, 'Difficulty', $_POST['prosody_poem_difficulty'] );\n}", "public function metaboxes()\n\t{\n\t\t$this->admin()->metaboxes();\n\t}", "function PostProcessItemData()\n {\n $this->AddEventQuestDatas();\n $this->ItemDataGroups();\n }", "protected function saveInfoValues() {\r\n\t\tif(is_a($this->infoValueCollection, 'tx_ptgsaconfmgm_infoValueCollection')) {\r\n\t\t\t\r\n\t\t\tif($this->tableName=='tx_ptconference_domain_model_persdata') {\r\n\t\t\t\t$persArticleUid = $this->rowUid;\r\n\t\t\t\t$relArticleUid = 0;\r\n\t\t\t} else {\r\n\t\t\t\t$persArticleUid = $this->get_persdata();\r\n\t\t\t\t$relArticleUid = $this->rowUid;\r\n\t\t\t}\t\t\t\r\n\t\t\t\r\n\t\t\tforeach($this->infoValueCollection as $infoValue) {\r\n\t\t\t\t$infoValue->set_persdata($persArticleUid);\r\n\t\t\t\t$infoValue->set_relarticle($relArticleUid);\r\n\t\t\t\t$infoValue->save();\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function setMetaboxes() {\n $metaboxTemp = new Metabox();\n\n $args = array(\n // ## Certification ##\n array(\n 'id' => self::MTB_CERT,\n 'title' => 'Certification Type',\n 'callback' => array($metaboxTemp, 'certification'),\n 'screen' => self::POST_TYPE_BADGES,\n 'context' => 'side',\n 'priority' => 'high',\n ),\n // ## Target ##\n array(\n 'id' => self::MTB_TARGET,\n 'title' => 'Target Type',\n 'callback' => array($metaboxTemp, 'target'),\n 'screen' => self::POST_TYPE_BADGES,\n 'context' => 'side',\n 'priority' => 'high',\n ),\n );\n\n $this->settings->loadMetaBoxes($args);\n }", "public function saveData()\r\n {\r\n \r\n }", "public static function save_meta_boxes( $post_id, $post ) {\n\t\tif ( $post->post_type != Group_Buying_Merchant::POST_TYPE ) {\n\t\t\treturn;\n\t\t}\n\t\t// don't do anything on autosave, auto-draft, bulk edit, or quick edit\n\t\tif ( wp_is_post_autosave( $post_id ) || $post->post_status == 'auto-draft' || defined('DOING_AJAX') || isset($_GET['bulk_edit']) ) {\n\t\t\treturn;\n\t\t}\n\t\tself::save_meta_box($post_id, $post);\n\t}", "public function saveSettings()\n {\n $this->store->save($this->data);\n }", "public function save()\n {\n if($this->changed) {\n Item::saveNewValues($this->id, $this->name, $this->status);\n } else {\n echo 'Nothing changed!';\n }\n }", "function act_unidad_m(){\n\t\t$u= new Unidad_medida();\n\t\t$u->usuario_id=$GLOBALS['usuarioid'];\n\t\t$related = $u->from_array($_POST);\n\n\t\t// save with the related objects\n\t\tif($u->save($related))\n\t\t{\n\t\t\techo \"<html> <script>alert(\\\"Se han actualizado los datos de la Unidad de Medida.\\\"); window.location='\".base_url().\"index.php/inicio/acceso/\".$GLOBALS['ruta'].\"/menu';</script></html>\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\tshow_error(\"\".$u->error->string);\n\t\t}\n\t}", "public function save_metabox( $post_id, $post ) {\n\t\tif( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n\t\t\treturn;\n\t\t}\n\t\t// if our nonce isn't there, or we can't verify it, bail\n\t\tif( !isset( $_POST['staff_position_nonce'] ) || !wp_verify_nonce( $_POST['staff_position_nonce'], 'staff_position_meta_nonce' ) ) {\n\t\t\treturn;\n\t\t}\n\t\t// if our current user can't edit this post, bail\n\t\tif( !current_user_can( 'edit_post', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t\tupdate_post_meta( $post_id, 'staff_position', sanitize_text_field( $_POST['staff_position'] ) );\n\t}", "function save_custom_meta_box($post_id, $post, $update)\n {\n if (!isset($_POST[\"meta-box-nonce\"]) || !wp_verify_nonce($_POST[\"meta-box-nonce\"], basename(__FILE__)))\n return $post_id;\n\n if(!current_user_can(\"edit_post\", $post_id))\n return $post_id;\n\n if(defined(\"DOING_AUTOSAVE\") && DOING_AUTOSAVE)\n return $post_id;\n\n $slug = \"post\";\n if($slug != $post->post_type)\n return $post_id;\n \n $Main_checkbox_value = \"\"; //Empty Variable To Save Main Posts Meta In It\n $Feature_checkbox_value = \"\"; //Empty Variable To Save Feature Posts Meta In It\n $Local_checkbox_value = \"\"; //Empty Variable To Save Local Posts Meta In It\n $World_checkbox_value = \"\"; //Empty Variable To Save World Posts Meta In It\n\n\n if(isset($_POST[\"Main_Posts\"]))\n {\n $Main_checkbox_value = $_POST[\"Main_Posts\"];\n } \n //Update The Value Of Main Posts Meta Box\n update_post_meta($post_id, \"Main_Posts\", $Main_checkbox_value);\n \n \n if(isset($_POST[\"Features_Posts\"]))\n {\n $Feature_checkbox_value = $_POST[\"Features_Posts\"];\n } \n //Update The Value Of Feature Posts Meta Box\n update_post_meta($post_id, \"Features_Posts\", $Feature_checkbox_value);\n \n \n if(isset($_POST[\"Local_Posts\"]))\n {\n $Local_checkbox_value = $_POST[\"Local_Posts\"];\n \n } \n //Update The Value Of Local Posts Meta Box\n update_post_meta($post_id, \"Local_Posts\", $Local_checkbox_value);\n \n \n if(isset($_POST[\"World_Posts\"]))\n {\n $World_checkbox_value = $_POST[\"World_Posts\"];\n \n } \n //Update The Value Of World Posts Meta Box\n update_post_meta($post_id, \"World_Posts\", $World_checkbox_value);\n \n }", "function dish_save_metaboxes_data()\r\n{\r\n\t// If it is our form has not been submitted, so we dont want to do anything\r\n\tif ( defined('DOING_AUTOSAVE') && DOING_AUTOSAVE ) \r\n\t return $post_id;\r\n\t \r\n\t// verify if this is dish post type and current user can edit it\r\n\tif('dish' == $_POST['post_type'] && current_user_can('edit_post'))\r\n\t{\r\n\t\t$price = $_POST['dish_price'];\r\n\t\t$post_id = $_POST['post_ID'];\r\n\t\tif(!update_post_meta($post_id, 'dish_price', $price)) \r\n\t\t\tadd_post_meta($post_id, 'dish_price', $price, true);\r\n\t}\r\n\telse\r\n\t\treturn $post_id;\r\n\t\t\r\n}", "protected function _postSave()\n {\n $titlePhrase = $this->getExtraData(self::DATA_TITLE);\n if ($titlePhrase !== null) {\n $this->_insertOrUpdateMasterPhrase($this->_getTitlePhraseName($this->get('tab_name_id')), $titlePhrase, '');\n }\n\n $defaults = $this->getExtraData(self::DATA_DEFAULTS);\n if ($defaults !== null) {\n $this->_setDefaultOptions($defaults);\n }\n }", "function tg_save_product_metaboxes($post_id) {\n\tif ( !isset( $_POST['post_gallery_meta_box_nonce'] ) || !wp_verify_nonce($_POST['post_gallery_meta_box_nonce'] , basename(__FILE__))) {\n\t\treturn ;\n\t}\t\t\n\t// Check if data is in post\n\tif (isset($_POST['product_gallery_ids'])) {\n\t\t// Encode so it can be stored an retrieved properly\n\t\t$encode = json_encode(explode(',',$_POST['product_gallery_ids']));\n\t\tupdate_post_meta($post_id, 'product_gallery', $encode);\n\t}\n}", "function salva_meta_box( $post_id ) {\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n if ( $parent_id = wp_is_post_revision( $post_id ) ) {\n $post_id = $parent_id;\n }\n $fields_consulta = [\n 'lista_de_remedios',\n 'especialista',\n 'paciente',\n 'motivo_da_consulta',\n 'marcar_volta',\n ];\n /*\n 'foreach' percorre o vetor 'fields_consulta'\n sendo que cada item do vetor é um parametro/field.\n salva no post deste key: '$post_id', chave: valor\n */\n foreach ( $fields_consulta as $field ) {\n if ( array_key_exists($field, $_POST) ) {\n update_post_meta( $post_id, $field, sanitize_text_field( $_POST[$field] ) );\n }\n }\n}", "function metabox_save( $post_id ) {\n\t\t// because save_post can be triggered at other times\n\t\tglobal $wpdb;\n\t\t\n\t\tif( ! isset( $_POST['mhPresentatie_noncename'] ) || ! wp_verify_nonce( $_POST['mhPresentatie_noncename'], plugin_basename( __FILE__ ) ) ) {\n\t\t\treturn $post_id;\n\t\t}\n\n\t\t// verify if this is an auto save routine. If it is our form has not been submitted, so we dont want to do anything\n\t\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE )\n\t\t{\n\t\t\treturn $post_id;\n\t\t}\n\n\t\t// Check permissions\n\t\tif ( !current_user_can( 'edit_post', $post_id ) )\n\t\t{\n\t\t\treturn $post_id;\n\t\t}\n\n\t\tupdate_post_meta( $post_id, '_style', $_POST['presentation_style'] );\n\t\tupdate_post_meta( $post_id, '_css', $_POST['presentationCSS'] );\n\t}", "public function save()\n {\n $this->save_meta_value('_sim_service_price', $this->service_price);\n $this->save_meta_value('_sim_service_price_registered', $this->service_price_registered);\n $this->save_meta_value('_sim_service_hide_price', $this->service_hide_price);\n }", "public function save_meta_boxes($post_id, $post){\n\t\tif ( empty( $post_id ) || empty( $post ) ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Dont' save meta boxes for revisions or autosaves\n\t\tif ( defined( 'DOING_AUTOSAVE' ) || is_int( wp_is_post_revision( $post ) ) || is_int( wp_is_post_autosave( $post ) ) ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Check the post being saved == the $post_id to prevent triggering this call for other save_post events\n\t\tif ( empty( $_POST['post_ID'] ) || $_POST['post_ID'] != $post_id ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t// Check user has permission to edit\n\t\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t\t// Check the post type\n\t\tif ('dhvcform'!==$post->post_type ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tforeach ((array)$this->_get_tabs() as $key=>$tab){\n\t\t\t$call_fnc = '_'.$key.'_setting';\n\t\t\tif(is_callable(array($this,$call_fnc))){\n\t\t\t\t$settings = call_user_func(array($this,$call_fnc));\n\t\t\t\tforeach ($settings as $meta_box){\n\t\t\t\t\tif(isset($meta_box['name'])){\n\t\t\t\t\t\t$meta_name = false !== strpos($meta_box['name'], 'dhvc_form_messages') ? 'dhvc_form_messages': $meta_box['name'];\n\t\t\t\t\t\t$meta_value = isset($_POST[$meta_name]) ? $_POST[$meta_name] : null;\n\t\t\t\t\t\tif(is_array($meta_value)){\n\t\t\t\t\t\t\t$meta_value = array_map( 'sanitize_text_field', (array) $meta_value ) ;\n\t\t\t\t\t\t\tif(false === strpos($meta_box['name'], 'dhvc_form_messages'))\n\t\t\t\t\t\t\t\t$meta_value = array_filter($meta_value);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (empty( $meta_value ) && false === strpos($meta_box['name'], 'dhvc_form_messages') ) {\n\t\t\t\t\t\t\tdelete_post_meta( $post_id, '_'.$meta_name );\n\t\t\t\t\t\t} elseif($meta_value !== null) {\n\t\t\t\t\t\t\tupdate_post_meta( $post_id, '_'.$meta_name , $meta_value );\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\n\t}", "public function do_save( $term_id ) {\n\t\tif ( ! class_exists( 'cmb_Meta_Box' ) )\n\t\t\treturn;\n\n\t\tif (\n\t\t\t// check nonce\n\t\t\t! isset( $_POST['term_opt_name'], $_POST['wp_meta_box_nonce'], $_POST['action'] )\n\t\t\t|| ! wp_verify_nonce( $_POST['wp_meta_box_nonce'], cmb_Meta_Box::nonce() )\n\t\t)\n\t\t\treturn;\n\n\t\t$this->do_override_filters( $term_id );\n\t\t// Save the metabox if it's been submitted\n\t\tcmb_save_metabox_fields( $this->fields(), $this->id() );\n\t}", "function mredir_save_meta_box_data( $post_id ){\n\t\t\tif ( !isset( $_POST['mredir_metabox_nonce'] ) || !wp_verify_nonce( $_POST['mredir_metabox_nonce'], basename( __FILE__ ) ) ){\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t// return if autosave\n\t\t\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ){\n\t\t\t\treturn;\n\t\t\t}\n\t\t // Check the user's permissions.\n\t\t\tif ( ! current_user_can( 'edit_post', $post_id ) ){\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif ( isset( $_REQUEST['country_id'] ) ) {\n\t\t\t\tupdate_post_meta( $post_id, 'country_id', sanitize_text_field( $_POST['country_id'] ) );\n\t\t\t}\n\t\t\tif ( isset( $_REQUEST['target_url'] ) ) {\n\t\t\t\tupdate_post_meta( $post_id, 'target_url', sanitize_text_field( $_POST['target_url'] ) );\n\t\t\t}\n\t\t}", "function SaveMemberEditor () {\n\n global $gSITEDOMAIN;\n\n global $gGROUPMEMBERACTION, $gGROUPMEMBERUSERNAME, $gGROUPMEMBERDOMAIN;\n\n // Loop through the action list.\n foreach ($gGROUPMEMBERACTION as $count => $action) {\n $username = $gGROUPMEMBERUSERNAME[$count];\n $domain = $gGROUPMEMBERDOMAIN[$count];\n switch ($action) {\n case GROUP_ACTION_APPROVE:\n $this->Approve ($username, $domain);\n break;\n case GROUP_ACTION_REMOVE:\n $USER = new cOLDUSER ();\n $USER->Select (\"Username\", $username);\n $USER->FetchArray ();\n if ($USER->uID != $this->userAuth_uID) {\n //$this->Leave ($username, $domain);\n } // if\n unset ($USER);\n break;\n } // switch\n } // foreach\n\n $this->Message = __(\"Member List Saved\");\n return (TRUE);\n }", "function notes_save_meta_box_data( $post_id ) {\n\n\t/*\n\t * We need to verify this came from our screen and with proper authorization,\n\t * because the save_post action can be triggered at other times.\n\t */\n\n\t// Check if our nonce is set.\n\tif ( ! isset( $_POST['notes_meta_box_nonce'] ) ) {\n\t\treturn;\n\t}\n\n\t// Verify that the nonce is valid.\n\tif ( ! wp_verify_nonce( $_POST['notes_meta_box_nonce'], 'notes_meta_box' ) ) {\n\t\treturn;\n\t}\n\n\t// If this is an autosave, our form has not been submitted, so we don't want to do anything.\n\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n\t\treturn;\n\t}\n\n\t// Check the user's permissions.\n\tif ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\n\n\t\tif ( ! current_user_can( 'edit_page', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\n\t} else {\n\n\t\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t}\n\n\t/* OK, it's safe for us to save the data now. */\n\t\n\t// Make sure that it is set.\n\tif ( ! isset( $_POST['notes_new_field'] ) ) {\n\t\treturn;\n\t}\n\n\t// Sanitize user input.\n\t$my_data = sanitize_text_field( $_POST['notes_new_field'] );\n\n\t// Update the meta field in the database.\n\tupdate_post_meta( $post_id, '_my_meta_value_key', $my_data );\n}", "function draw_metabox_quote_meta($post, $metabox)\n {\n wp_nonce_field( 'save_metabox_lh_quote', 'metabox_lh_quote' );\n\n $post_id = $post->ID;\n\n // get the saved quote breakdown\n $quote_breakdown = get_post_meta($post_id,'quote_breakdown',true);\n $quote_total = get_post_meta($post_id,'quote_total',true);\n\n $default_wood = lh_queries::get_quote_items();\n\n echo '<div id=\"lh_quote_calculator\">';\n echo '<table>';\n echo '<tr><th>Item</th><th>Quantity</th><th></th><th>Subtotal</th></tr>';\n foreach ($default_wood as $id => $quote_meta)\n {\n\n $unit = $quote_meta['unit'];\n $cost = $quote_meta['cost'];\n $this_value = 0;\n\n if(isset($quote_breakdown[$id] ) )\n {\n $this_value = $quote_breakdown[$id];\n }\n\n echo '<tr>';\n echo '<td>'.$quote_meta['name'].'</td>';\n echo '<td><input value=\"'.$this_value.'\" name=\"'.$id.'\" value=\"\" id=\"'.$id.'\" size=\"5\" data-unit=\"'.$unit.'\" data-cost=\"'.$cost.'\"/></td>';\n echo '<td>';\n if($unit==\"fixed\")\n {\n\n }\n else\n {\n if($unit==\"each\")\n {\n echo '£'.$cost.' each';\n }\n elseif($unit==\"sqm\")\n {\n echo '£'.$cost.' / sqm';\n }\n }\n echo '</td>';\n echo '<td><span id=\"subtotal_'.$id.'\" class=\"quote_subtotal\">-</td>';\n\n echo '</tr>';\n }\n\n echo '<tr><td>Total Price</td><td></td><td></td><td><span class=\"quote_total\">£<input type=\"text\" readonly id=\"quote_total\" name=\"quote_total\" value=\"'.$quote_total.'\"></span></td></tr>';\n echo '</table>';\n echo '</div>';\n\n\n }", "function am2_vanity_save_meta_box_data( $post_id ) {\n\tif ( ! isset( $_POST['am2_vanity_meta_box_nonce'] ) ) return;\n\t// Verify that the nonce is valid.\n\tif ( ! wp_verify_nonce( $_POST['am2_vanity_meta_box_nonce'], 'am2_vanity_meta_box' ) ) return;\n\t// If this is an autosave, our form has not been submitted, so we don't want to do anything.\n\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n\n\t// Check the user's permissions.\n\tif ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\n\t\tif ( ! current_user_can( 'edit_page', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t} else {\n\t\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t}\n\t// Sanitize user input.\n\t//$am2_vanity_url = sanitize_url( $_POST['am2_vanity_url'] );\n\t$am2_vanity_url = $_POST['am2_vanity_url'];\n\tunset($_POST['am2_vanity_url']);\n\t\n\t$post_type = get_post_type($post_id);\n\tif($post_type == 'revision') continue;\n\t// Handle Vanity Pages\n\tam2_on_update_vanity($post_id, $am2_vanity_url, $post_type);\t\n}", "public function store()\n {\n $this->preStoreActions($this->data);\n\n //check all the fields\n $this->validate();\n\n //save to the database\n $this->save();\n\n //do broadcast\n //$this->broadcastUpdate(\"Updated Menu for - \".Str::limit($this->accountName,50));\n\n //tidy up\n $this->afterStore($this->data['id'] ?? '');\n\n //run a user specific method IF installed and needed after save\n $this->afterStoreActions($this->data);\n }", "function save_book_meta_box_data( $post_id ) {\n\n // Check if our nonce is set.\n if ( ! isset( $_POST['global_notice_nonce'] ) ) {\n return;\n }\n\n // Verify that the nonce is valid.\n if ( ! wp_verify_nonce( $_POST['global_notice_nonce'], 'global_notice_nonce' ) ) {\n return;\n }\n\n // If this is an autosave, our form has not been submitted, so we don't want to do anything.\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return;\n }\n\n // Check the user's permissions.\n if ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\n\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\n return;\n }\n\n }\n else {\n\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return;\n }\n }\n\n /* OK, it's safe for us to save the data now. */\n\n // Make sure that it is set.\n if ( ! isset( $_POST['book_meta'] ) ) {\n return;\n }\n\n // Sanitize user input.\n $my_data = sanitize_text_field( $_POST['book_meta'] );\n\n // Update the meta field in the database.\n update_post_meta( $post_id, '_book_meta', $my_data );\n\n if(isset($_POST[\"meta-checkbox\"]))\n {\n $meta_box_checkbox_value = $_POST[\"meta-checkbox\"];\n }\n update_post_meta($post_id, \"meta-checkbox\", $meta_box_checkbox_value);\n}", "function save_my_meta_box_data( $post_id ) {\n\n\t// Check if our nonce is set.\n\tif ( ! isset( $_POST['myplugin_meta_box_nonce'] ) ) {\n\t\treturn;\n\t}\n\n\t// Verify that the nonce is valid.\n\tif ( ! wp_verify_nonce( $_POST['myplugin_meta_box_nonce'], 'myplugin_meta_box' ) ) {\n\t\treturn;\n\t}\n\n\n\t// If this is an autosave, our form has not been submitted, so we don't want to do anything.\n\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n\t\treturn;\n\t}\n\n\t// Check the user's permissions.\n\tif ( isset( $_POST['post_type'] ) && 'page' == $_POST['post_type'] ) {\n\n\t\tif ( ! current_user_can( 'edit_page', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\n\t} else {\n\n\t\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t}\n\n\t/* OK, it's safe for us to save the data now. */\n\t\n\t// Make sure that it is set.\n\tif ( ! isset( $_POST['video_url'] ) ) {\n\t\treturn;\n\t}\n\n\n\t// Sanitize user input.\n\t$my_data = sanitize_text_field( $_POST['video_url'] );\n\t$my_sec_title = sanitize_text_field( $_POST['second_title'] );\n\n\t// Update the meta field in the database.\n\tupdate_post_meta( $post_id, 'video_url_key', $my_data );\n}", "public function save_widget_state() {\n\n\t\tcheck_ajax_referer( 'mi-admin-nonce', 'nonce' );\n\n\t\t$default = self::$default_options;\n\t\t$current_options = $this->get_options();\n\n\t\t$reports = $default['reports'];\n\t\tif ( isset( $_POST['reports'] ) ) {\n\t\t\t$reports = json_decode( sanitize_text_field( wp_unslash( $_POST['reports'] ) ), true );\n\t\t\tforeach ( $reports as $report => $reports_sections ) {\n\t\t\t\t$reports[ $report ] = array_map( 'boolval', $reports_sections );\n\t\t\t}\n\t\t}\n\n\t\t$options = array(\n\t\t\t'width' => ! empty( $_POST['width'] ) ? sanitize_text_field( wp_unslash( $_POST['width'] ) ) : $default['width'],\n\t\t\t'interval' => ! empty( $_POST['interval'] ) ? absint( wp_unslash( $_POST['interval'] ) ) : $default['interval'],\n\t\t\t'compact' => ! empty( $_POST['compact'] ) ? 'true' === sanitize_text_field( wp_unslash( $_POST['compact'] ) ) : $default['compact'],\n\t\t\t'reports' => $reports,\n\t\t\t'notice30day' => $current_options['notice30day'],\n\t\t);\n\n\t\tarray_walk( $options, 'sanitize_text_field' );\n\t\tupdate_user_meta( get_current_user_id(), 'monsterinsights_user_preferences', $options );\n\n\t\twp_send_json_success();\n\n\t}", "function meta_box_save($post_id)\n {\n\n// if($post_id == 245)\n// {\n// debugvar($_FILES);\n// debugvar($_POST);\n// exit;\n// }\n\n if (in_array(get_post_type($post_id), $this->post_types)) {\n\n if(!isset($_POST['_inline_edit']))\n {\n\n $product = SIM_Product::getById($post_id);\n\n if(isset($_POST['product_declarations']) && $_POST['product_declarations'])\n {\n\n delete_post_meta($post_id, '_sim_declaration_pdf');\n foreach($_POST['product_declarations'] as $id_manufacturer => $attachments)\n {\n\n if($attachments['_sim_declaration_pdf'] != '')\n {\n $attach_ids = array();\n\n if(isset($attachments['_sim_declaration_pdf']['new']))\n {\n\n $arr_ids = array_filter(explode(',', $attachments['_sim_declaration_pdf']['new']));\n\n foreach($arr_ids as $id)\n {\n array_push($attach_ids, $id);\n }\n }\n\n\n\n unset($attachments['_sim_declaration_pdf']['new']);\n\n if(is_array($attachments['_sim_declaration_pdf']))\n {\n foreach ($attachments['_sim_declaration_pdf'] as $attach) {\n $attach_ids[] = $attach;\n }\n\n }\n\n debugvar(array($id_manufacturer =>$attach_ids));\n// exit;\n\n /*\n * Array\n (\n [0] => 1095\n [1] => 1092\n )\n */\n add_post_meta($post_id, '_sim_declaration_pdf', serialize(array($id_manufacturer =>$attach_ids)));\n }\n }\n\n// exit;\n\n\n }\n }\n\n }\n\n }", "function metaboxes_output( $post, $metabox, $data ) {\n\n\t\tswitch ( $metabox ): case 'example-metabox': ?>\n\t\n\t\t\t<p>\n\t <label for=\"description\">Post Type Description:</label>\n\t <input id=\"description\" class=\"widefat\" type=\"text\" name=\"description\" value=\"<?php echo esc_attr( $data['description'] ); ?>\">\n\t </p>\n\n\t <p>\n\t <label for=\"date\">Post Type Date:</label>\n\t <input id=\"date\" class=\"widefat\" type=\"date\" name=\"date\" value=\"<?php echo esc_attr( $data['date'] ); ?>\">\n\t </p>\n\n\t\t<?php break;\n\n\t\tendswitch;\n\n\t}", "public function post_save($data) {\n\n\t\t// Empty save result\n\t\tif (!$data) {\n\t\t\treturn $data;\n\t\t}\n\n\t\t// Fetch elements\n\t\t$this->_load_elements_lib();\n\t\t$content_elements = $this->EE->elements->fetch_avaiable_elements($this->get_vars2export());\n\n\t\t// Current settings\n\t\tif (!is_array($data))\n\t\t\t$data = unserialize($data);\n\n\t\tforeach ($data as $eid => $element) {\n\n\t\t\tif (empty($element[\"element_type\"]))\n\t\t\t\tcontinue;\n\n\t\t\t$element_data = $element[\"data\"];\n\t\t\t$element_settings = unserialize(base64_decode($element[\"element_settings\"]));\n\t\t\t$element_type = $element_settings[\"type\"];\n\n\t\t\tif (!empty($this->EE->elements->$element_type) and method_exists($this->EE->elements->$element_type->handler, 'post_save_element')) {\n\t\t\t\t// Attach element settings\n\t\t\t\tforeach ($this->_exclude_setting_system_fields($element_settings[\"settings\"]) as $setting_var => $setting_value) {\n\t\t\t\t\t$this->EE->elements->$element_type->handler->settings[$setting_var] = $setting_value;\n\t\t\t\t}\n\n\t\t\t\t// Attach element field name\n\t\t\t\t$this->EE->elements->$element_type->handler->field_name = $this->_element_field_name() . '[' . $eid . '][data]';\n\n\t\t\t\t// Attach title\t\t\t\t\t\n\t\t\t\t$this->EE->elements->$element_type->handler->element_title = $element_settings[\"settings\"][\"title\"];\n\n\t\t\t\t// Set element id\n\t\t\t\t$this->EE->elements->$element_type->handler->element_id = $eid;\n\n\t\t\t\t// Set field id\t\n\t\t\t\tif (isset($this->field_id) && $this->field_id) {\n\t\t\t\t\t$this->EE->elements->$element_type->handler->field_id = $this->field_id;\n\t\t\t\t}\n\n\t\t\t\t// Send data & call event\n\t\t\t\t$this->EE->elements->$element_type->handler->post_save_element($data[$eid][\"data\"]);\n\t\t\t}\n\t\t}\n\n\t\t## fix saved revision\n\t\t\n\t\t// get channel settings\n\t\t$query = ee()->api_channel_structure->get_channel_info($_POST['channel_id']);\n\t\tforeach(array('channel_url', 'rss_url', 'deft_status', 'comment_url', 'comment_system_enabled', 'enable_versioning', 'max_revisions') as $key)\n\t\t{\n\t\t\t$c_prefs[$key] = $query->row($key);\n\t\t}\n\t\t\n\t\t// get entry titles\n\t\tee()->db->select('versioning_enabled');\n\t\t$query_v = ee()->db->get_where('channel_titles', array('entry_id' => $this->settings['entry_id']));\n\t\t\n\t\t// if entry version is disable then disable versioning\n\t\tif ($query_v->row('versioning_enabled') == 'n')\n\t\t{\n\t\t\t$c_prefs['enable_versioning'] = 'n';\n\t\t}\n\t\t\n\t\t// if is versioning enabled then fix saved data\n\t\tif ($c_prefs['enable_versioning'] == 'y')\n\t\t{\n\t\t\t// get last saved revision\n\t\t\tee()->db->select('*');\n\t\t\tee()->db->from('entry_versioning');\n\t\t\tee()->db->where('entry_id', $this->settings['entry_id']);\n\t\t\tee()->db->order_by('version_id', 'desc');\n\t\t\tee()->db->limit(1);\n\t\t\t\t\n\t\t\t$query = ee()->db->get();\n\t\t\t\t\n\t\t\t// if revision exist\n\t\t\tif ($query->num_rows == 1) {\n\t\t\n\t\t\t\t$temp = $query->result_array();\n\t\t\n\t\t\t\t// replace wrong data\n\t\t\t\t$field = unserialize($temp[0]['version_data']);\n\t\t\t\t$field[$this->settings['field_name']] = $data;\n\t\t\t\t$field = serialize($field);\n\t\t\n\t\t\t\t// update last revision with correct data\n\t\t\t\tee()->db->update('entry_versioning', array('version_data'\t=> $field), array('version_id' => $temp[0]['version_id']));\n\t\t\n\t\t\t}\n\t\t\t\t\n\t\t}\n\n\t\treturn $data;\n\t}", "public function afterSave()\n\t{\n\t\t//annoying on every edit, move to a checkbox on form and handle in controller\n\t}", "function plugin_save_post_meta( $post_id ) {\r\n\t\tglobal $post, $new_meta_boxes;\r\n\t\t// print var_export($_POST,true);\r\n\t\t// only save if we have something to save\r\n\t\tif (isset($_POST['post_type']) && $_POST['post_type'] && $this->postmeta[$_POST['post_type']] ) {\r\n\t\t\t// print var_export($_POST,true);\r\n\t\t\t// go through each of the registered post metaboxes\r\n\t\t\tforeach ($this->postmeta[$_POST['post_type']] as $cur) {\r\n\t\t\t\r\n\t\t\t\t// save fields only for the current custom post type.\t\r\n\t\t\t\tforeach($cur as $meta_box) {\r\n\t\t\t\t// Verify\r\n\t\t\t\tif ( !wp_verify_nonce( $_POST[$meta_box['id'].'_noncename'], plugin_basename($this->filename) )) {\r\n\t\t\t\t\treturn $post_id;\r\n\t\t\t\t}\r\n\t\r\n\t\t\t\t// Check some permissions\r\n\t\t\t\tif ( 'page' == $_POST['post_type'] ) {\r\n\t\t\t\t\tif ( !current_user_can( 'edit_page', $post_id ))\r\n\t\t\t\t\treturn $post_id;\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif ( !current_user_can( 'edit_post', $post_id ))\r\n\t\t\t\t\treturn $post_id;\r\n\t\t\t\t}\r\n\t\t \r\n\t\t\t\t$data = $_POST[$meta_box['id'].'_value'];\r\n\t\t\t\r\n\t\t\t\r\n\t\t\t\t// Convert autosuggest value to a post id\r\n\t\t\t\t$data= $this->suggest_to_id($data);\r\n\t\t\t\t\r\n\t\t\t\t// if no post id is found then kill the autocomplete thinger\r\n\t\t \r\n\t\t\t\tif(get_post_meta($post_id, $meta_box['id'].'_value') == \"\")\r\n\t\t\t\t\tadd_post_meta($post_id, $meta_box['id'].'_value', $data, true);\r\n\t\t\t\telseif($data != get_post_meta($post_id, $meta_box['id'].'_value', true))\r\n\t\t\t\t\tupdate_post_meta($post_id, $meta_box['id'].'_value', $data);\r\n\t\t\t\telseif($data == \"\")\r\n\t\t\t\t\tdelete_post_meta($post_id, $meta_box['id'].'_value', get_post_meta($post_id, $meta_box['id'].'_value', true));\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t} //end if isset\r\n\t}", "public function save_settings($data) {\n\t\t//dump_var($_POST['content_element_item']);\n\t\t//dump_var($data, 1);\n\t\t// Not set? set!\n\t\tif (!isset($data['content_element_item']) and isset($_POST['content_element_item'])) {\n\t\t\t$data['content_element_item'] = (array) $_POST['content_element_item'];\n\t\t\t$data['content_element'] = (array) $_POST['content_element'];\n\t\t}\n\n\t\t// Not array? array!\n\t\tif (empty($data['content_element_item']) or !is_array($data['content_element_item'])) {\n\t\t\t$data['content_element_item'] = array();\n\t\t\t$data['content_element'] = array();\n\t\t}\n\n\t\t// Get lists of elements\n\t\t$this->_load_elements_lib();\n\t\t$content_elements = $this->EE->elements->fetch_avaiable_elements($this->get_vars2export());\n\n\t\t$save_settings = array();\n\n\t\t// Loop element types\n\t\t//foreach ($_POST['content_element_item'] as $element_id => $element_type) {\n\t\tforeach ($data['content_element_item'] as $element_id => $element_type) {\n\n\t\t\t//$settings = @$_POST['content_element'][$element_type][$element_id];\n\t\t\t$settings = @$data['content_element'][$element_type][$element_id];\n\t\t\tif (is_array($settings)) {\n\n\t\t\t\t// Separate systems settings (title & eid) // the reason is compatibility with CE 1.4.0.3\n\t\t\t\t$title = '';\n\t\t\t\t$eid = $element_id;\n\n\t\t\t\tif (isset($settings[\"title\"])) {\n\t\t\t\t\t$title = $settings[\"title\"];\n\t\t\t\t}\n\n\t\t\t\tif (isset($settings[\"eid\"])) {\n\t\t\t\t\t$eid = $settings[\"eid\"];\n\t\t\t\t}\n\n\t\t\t\t// Loop params\n\t\t\t\tif (!empty($this->EE->elements->$element_type->handler) and method_exists($this->EE->elements->$element_type->handler, 'save_element_settings')) {\n\t\t\t\t\t$settings = $this->EE->elements->$element_type->handler->save_element_settings($this->_exclude_setting_system_fields($settings));\n\t\t\t\t}\n\n\t\t\t\t$settings[\"eid\"] = $element_id;\n\t\t\t\t$settings[\"title\"] = $title;\n\t\t\t}\n\n\t\t\t$save_settings[] = array(\n\t\t\t\t'type' => $element_type,\n\t\t\t\t'settings' => $settings,\n\t\t\t);\n\t\t}\n\n\t\t//dump_var($save_settings, 1);\n\n\t\treturn array(\n\t\t\t'content_elements' => serialize($save_settings)\n\t\t);\n\t}", "function cd_meta_box_save( $post_id )\n{\n if( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n \n // if our nonce isn't there, or we can't verify it, bail\n if( !isset( $_POST['meta_box_nonce'] ) || !wp_verify_nonce( $_POST['meta_box_nonce'], 'my_meta_box_nonce' ) ) return;\n \n // // if our current user can't edit this post, bail\n if( !current_user_can( 'edit_post' ) ) return;\n \n // now we can actually save the data\n $allowed = array( \n 'a' => array( // on allow a tags\n 'href' => array() // and those anchors can only have href attribute\n )\n );\n \n // Make sure your data is set before trying to save it\n if( isset( $_POST['my_meta_box_text'] ) )\n update_post_meta( $post_id, 'my_meta_box_text', wp_kses( $_POST['my_meta_box_text'], $allowed ) );\n\n if( isset( $_POST['my_meta_box_text'] ) )\n update_post_meta( $post_id, 'my_meta_box_text', wp_kses( $_POST['my_meta_box_text2'], $allowed ) );\n\n if( isset( $_POST['my_meta_box_text'] ) )\n update_post_meta( $post_id, 'my_meta_box_text', wp_kses( $_POST['my_meta_box_text3'], $allowed ) );\n if( isset( $_POST['my_meta_box_text'] ) )\n update_post_meta( $post_id, 'my_meta_box_text', wp_kses( $_POST['my_meta_box_text4'], $allowed ) );\n \n \n}", "function pvplugin_save_meta_box_data( $post_id ) {\n\n\t/*\n\t * We need to verify this came from our screen and with proper authorization,\n\t * because the save_post action can be triggered at other times.\n\t */\n\n\t// Check if our nonce is set.\n\tif ( ! isset( $_POST['pvplugin_meta_box_nonce'] ) ) {\n\t\treturn;\n\t}\n\n\t// Verify that the nonce is valid.\n\tif ( ! wp_verify_nonce( $_POST['pvplugin_meta_box_nonce'], 'pvplugin_save_meta_box_data' ) ) {\n\t\treturn;\n\t}\n\n\t// If this is an autosave, our form has not been submitted, so we don't want to do anything.\n\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n\t\treturn;\n\t}\n\n\t// Check the user's permissions.\n\tif ( isset( $_POST['post_type'] ) && 'policy' == $_POST['post_type'] ) {\n\n\t\tif ( ! current_user_can( 'edit_page', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\n\t} else {\n\n\t\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\t\treturn;\n\t\t}\n\t}\n\n\t/* OK, it's safe for us to save the data now. */\n\t\n\n\t$next_update = $_POST['next_update_month'].'/'.$_POST['next_update_year'];\n\t$date_adopted = $_POST['date_adopted_month'].'/'.$_POST['date_adopted_year'];\n\n\t// Sanitize user input.\n\t$approvers = sanitize_text_field( $_POST['approvers'] );\n\t$next_update = sanitize_text_field( $next_update );\n\t$division = sanitize_text_field( $_POST['division'] );\n\t$responsible_office = sanitize_text_field( $_POST['responsible_office'] );\n\t$date_adopted = sanitize_text_field( $_POST['date_adopted'] );\n\t$additional_refrence = sanitize_text_field( $_POST['additional_refrence'] );\n\n\t// Update the meta field in the database.\n\tupdate_post_meta( $post_id, 'approvers', $approvers );\n\tupdate_post_meta( $post_id, 'next_update', $next_update );\n\tupdate_post_meta( $post_id, 'next_update_month', $_POST['next_update_month'] );\n\tupdate_post_meta( $post_id, 'next_update_year', $_POST['next_update_year'] );\n\tupdate_post_meta( $post_id, 'division', $division );\n\tupdate_post_meta( $post_id, 'responsible_office', $responsible_office );\n\tupdate_post_meta( $post_id, 'date_adopted', $date_adopted );\n\tupdate_post_meta( $post_id, 'date_adopted_month', $_POST['date_adopted_month'] );\n\tupdate_post_meta( $post_id, 'date_adopted_year', $_POST['date_adopted_year'] );\n\tupdate_post_meta( $post_id, 'additional_refrence', $additional_refrence );\n\tupdate_post_meta( $post_id, '_expiration-date', strtotime('+ 1 year') );\n\t\n}", "protected function _postSave()\r\n\t{\r\n\t}", "protected function save()\n\t{\n\t\t$this->saveItems();\n\t\t//$this->saveAssignments();\n\t\t//$this->saveRules();\n\t}", "private function _saveQcontrol() {\r\n\r\n }", "public function definition_after_data() {\n global $DB;\n\n $mform = $this->_form;\n\n // Check that we are updating a current customcert.\n if ($this->id) {\n // Get the pages for this customcert.\n if ($pages = $DB->get_records('customcert_pages', array('customcertid' => $this->id))) {\n // Loop through the pages.\n foreach ($pages as $p) {\n // Set the width.\n $element = $mform->getElement('pagewidth_' . $p->id);\n $element->setValue($p->width);\n // Set the height.\n $element = $mform->getElement('pageheight_' . $p->id);\n $element->setValue($p->height);\n // Set the margin.\n $element = $mform->getElement('pagemargin_' . $p->id);\n $element->setValue($p->margin);\n }\n }\n }\n }", "function saveInfo(){\n mysql_query(\"UPDATE resolution SET text='$this->text' WHERE id='$this->clauseId'\") or die(mysql_error());\n mysql_query(\"UPDATE resolution SET nextId='$this->nextId' WHERE id='$this->clauseId'\") or die(mysql_error());\n if($this->subClause==array()){\n mysql_query(\"UPDATE resolution SET subId='0' WHERE id='$this->clauseId'\") or die(mysql_error());\n }else{\n $subId=$this->subClause[0]->clauseId;\n mysql_query(\"UPDATE resolution SET subId='$subId' WHERE id='$this->clauseId'\") or die(mysql_error());\n foreach($this->subClause as $subClause){\n $subClause->saveInfo();\n }\n }\n }", "function save_meta_box( $post_id ) {\n if ( defined( 'DOING_AUTOSAVE') && DOING_AUTOSAVE ) return;\n if ( $parent_id = wp_is_post_revision( $post_id ) ) {\n $post_id = $parent_id;\n }\n $fields = ['published_date'];\n foreach ( $fields as $field ) {\n if ( array_key_exists( $field, $_POST ) ) {\n update_post_meta( $post_id, $field, sanitize_text_field( $_POST[$field] ) );\n }\n }\n }", "function save()\n {\n /* remove objectclass GOhard if this is an ogroup tab */\n if(isset($this->parent->by_object['ogroup'])){\n $this->objectclasses = array();\n }\n\n plugin::save();\n\n /* Strip out 'default' values */\n foreach(array(\"gotoXMethod\",\"gotoXDriver\", \"gotoXResolution\", \"gotoXColordepth\",\n \"gotoLpdServer\", \"gotoXKbModel\", \"gotoXKbLayout\",\n \"gotoXKbVariant\", \"gotoXMouseType\", \"gotoXMouseport\") as $val){\n\n if ($this->attrs[$val] == \"default\"){\n $this->attrs[$val]= array();\n }\n }\n\n if($this->gotoXMethod == \"default\"){\n $this->attrs['gotoXdmcpServer'] = array();\n $this->attrs['gotoXMethod'] = array();\n }else{\n $this->attrs['gotoXdmcpServer'] = array_values($this->selected_xdmcp_servers);\n }\n\n\n if($this->AutoSync){\n $this->attrs['gotoXHsync'] = \"30+55\";\n $this->attrs['gotoXVsync'] = \"50+70\";\n }\n\n /* Write back to ldap */\n $ldap= $this->config->get_ldap_link();\n $ldap->cd($this->dn);\n $this->cleanup();\n $ldap->modify ($this->attrs); \n new log(\"modify\",\"terminal/\".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());\n\n if (!$ldap->success()){\n msg_dialog::display(_(\"LDAP error\"), msgPool::ldaperror($ldap->get_error(), $this->dn, LDAP_MOD, get_class()));\n }\n $this->handle_post_events(\"modify\");\n\n /* Send goto reload event */\n if(count($this->attrs)){\n $this->send_goto_reload();\n }\n }", "function sample_save_metabox( $post_id, $post ) {\n\t// Add nonce for security and authentication.\n\t$nonce_name = isset( $_POST['custom_nonce'] ) ? $_POST['custom_nonce'] : '';\n\t$nonce_action = 'custom_nonce_action';\n\n\t// Check if nonce is set.\n\tif ( ! isset( $nonce_name ) ) {\n\t\treturn;\n\t}\n\n\t// Check if nonce is valid.\n\tif ( ! wp_verify_nonce( $nonce_name, $nonce_action ) ) {\n\t\treturn;\n\t}\n\n\t// Check if user has permissions to save data.\n\tif ( ! current_user_can( 'edit_post', $post_id ) ) {\n\t\treturn;\n\t}\n\n\t// Check if not an autosave.\n\tif ( wp_is_post_autosave( $post_id ) ) {\n\t\treturn;\n\t}\n\n\t// Check if not a revision.\n\tif ( wp_is_post_revision( $post_id ) ) {\n\t\treturn;\n\t}\n\n\tif ( ! isset( $_POST['notes'] ) ) {\n\t\treturn;\n\t}\n\n\tupdate_post_meta( $post_id, 'notes', wp_unslash( sanitize_text_field( $_POST['notes'] ) ) );\n}", "public function save_additional_editors() {\n\n\t\tglobal $post;\n\t\t$post_id = $post->ID;\n\n\t\tif ( ! empty( $_POST['contents'] ) ) {\n\t\t\t$data = htmlspecialchars( $_POST['contents'] );\n\t\t\tupdate_post_meta( $post_id, 'contents', $data );\n\t\t}\n\t\tif ( ! empty( $_POST['authordesc'] ) ) {\n\t\t\t$data = htmlspecialchars( $_POST['authordesc'] );\n\t\t\tupdate_post_meta( $post_id, 'authordesc', $data );\n\t\t}\n\t\tif ( ! empty( $_POST['heweb17reviews'] ) ) {\n\t\t\t$data = htmlspecialchars( $_POST['heweb17reviews'] );\n\t\t\tupdate_post_meta( $post_id, 'heweb17reviews', $data );\n\t\t}\n\t\tif ( ! empty( $_POST['featureblurb'] ) ) {\n\t\t\t$data = htmlspecialchars( $_POST['featureblurb'] );\n\t\t\tupdate_post_meta( $post_id, 'featureblurb', $data );\n\t\t}\n\n\n\t}", "public function save_widget() {\n\t\t$this->get_cache();\n\t\t$this->get_db_values();\n\t\tif ( 'POST' === $_SERVER['REQUEST_METHOD'] && isset( $_POST[ $this->unique() ] ) ) {\n\t\t\t$this->get_db_values();\n\t\t\t$this->get_cache();\n\t\t\t$instance = new Save_Handler( array(\n\t\t\t\t'module' => &$this,\n\t\t\t\t'unique' => $this->unique(),\n\t\t\t\t'fields' => $this->fields(),\n\t\t\t\t'db_values' => $this->get_db_values(),\n\t\t\t) );\n\t\t\t$instance->run();\n\n\t\t\t$this->options_cache['field_errors'] = $instance->get_errors();\n\t\t\t$this->set_db_cache( $this->options_cache );\n\t\t\t$this->set_db_values( $instance->get_values() );\n\t\t\tif ( ! empty( $instance->get_errors() ) ) {\n\t\t\t\twp_redirect( add_query_arg( 'wponion-save', 'error' ) );\n\t\t\t\texit;\n\t\t\t}\n\t\t} else {\n\t\t\t$this->init_theme()->render();\n\t\t}\n\t}", "function store(){\n update_option( $this->option_name, $this->settings );\n }", "function save_variation_settings_fields( $post_id ) {\n\n // Text Field\n $text_field = $_POST['_upc_variation_code'][ $post_id ];\n if( ! empty( $text_field ) ) {\n update_post_meta( $post_id, '_upc_variation_code', esc_attr( $text_field ) );\n }\n\n // Number Field\n $number_field = $_POST['_number_field'][ $post_id ];\n if( ! empty( $number_field ) ) {\n update_post_meta( $post_id, '_number_field', esc_attr( $number_field ) );\n }\n\n // Textarea\n $textarea = $_POST['_textarea'][ $post_id ];\n if( ! empty( $textarea ) ) {\n update_post_meta( $post_id, '_textarea', esc_attr( $textarea ) );\n }\n\n // Select\n $select = $_POST['_select'][ $post_id ];\n if( ! empty( $select ) ) {\n update_post_meta( $post_id, '_select', esc_attr( $select ) );\n }\n\n // Checkbox\n $checkbox = isset( $_POST['_checkbox'][ $post_id ] ) ? 'yes' : 'no';\n update_post_meta( $post_id, '_checkbox', $checkbox );\n\n // Hidden field\n $hidden = $_POST['_hidden_field'][ $post_id ];\n if( ! empty( $hidden ) ) {\n update_post_meta( $post_id, '_hidden_field', esc_attr( $hidden ) );\n }\n\n}", "function caviar_meta_box_callback( $post ) {\n\n\t// Add a nonce field so we can check for it later.\n\twp_nonce_field( 'caviar_save_meta_box_data', 'caviar_meta_box_nonce' );\n\n\t/*\n\t * Use get_post_meta() to retrieve an existing value\n\t * from the database and use the value for the form.\n\t */\n\t$txtName = get_post_meta( $post->ID, '_txtName', true );\n\t$txtAddress = get_post_meta( $post->ID, '_txtAddress', true );\n\t$txtWebsite = get_post_meta( $post->ID, '_txtWebsite', true );\n\t$chkFood = get_post_meta( $post->ID, '_chkFood', true );\n\t$selHobby\t = get_post_meta( $post->ID, '_selHobby', true );\n\t$selTrans\t = get_post_meta( $post->ID, '_selTrans', true );\n\t$itemFeatures = get_post_meta( $post->ID, '_itemFeatures', true );\n\t$gender = get_post_meta( $post->ID, '_gender', true );\n\t$colorMeta = get_post_meta( $post->ID, '_colorMeta', true );\n\t$edAboutMe = get_post_meta( $post->ID, '_edAboutMe', true );\n\t$selCats = get_post_meta( $post->ID, '_selCats', true );\n\t$upPhoto = get_post_meta( $post->ID, '_upPhoto', true );\n\t$upLicense = get_post_meta( $post->ID, '_upLicense', true );\n\t$rePersonalData = get_post_meta( $post->ID, '_rePersonalData', true );\n\n\t// var_dump($rePersonalData);\n\n\t$fields = array(\n\t\t'title' => array(\n\t\t\t'title' => 'Feature',\n\t\t\t'type' => 'text',\n\t\t),\n\t\t'desc' => array(\n\t\t\t'title' => 'Price',\n\t\t\t'type' => 'textarea',\n\t\t),\n\t\t'pic' => array(\n\t\t\t'id' => 'repeaterPic',\n\t\t\t'title' => 'Picture',\n\t\t\t'type' => 'upload',\n\t\t),\n\t\t'featured' => array(\n\t\t\t'title' => 'Featured',\n\t\t\t'type' => 'checkbox',\n\t\t\t'options' => array(\n\t\t\t\t'1' => 'Yes',\n\t\t\t\t'2' => 'No',\n\t\t\t\t'3' => 'Undecided',\n\t\t\t)\n\t\t) \n\t);\n\n\t$fieldx = array(\n\t\t'name' => array(\n\t\t\t'title' => 'Name',\n\t\t\t'type' => 'text',\n\t\t),\n\t\t'gender' => array(\n\t\t\t'title' => 'Feature',\n\t\t\t'type' => 'radioimage',\n\t\t\t'options' => array(\n\t\t\t\t'1' => 'http://placeimg.com/100/100/arch',\n\t\t\t\t'2' => 'http://placeimg.com/100/100/tech',\n\t\t\t),\n\t\t),\n\t\t'pic' => array(\n\t\t\t'id' => 'profilePic',\n\t\t\t'title' => 'Picture',\n\t\t\t'type' => 'upload',\n\t\t),\n\t);\n\n\t$fieldControl = new Field_Controls();\n\t$fieldControl->upload('Photo', 'upPhoto', array('name' => 'upPhoto', 'value' => $upPhoto, 'class' => 'single previewImage', 'placeholder' => esc_html__('Image URL' , 'claypress')));\n\t$fieldControl->upload('License Url', 'upLicense', array('name' => 'upLicense', 'value' => $upLicense, 'class' => 'single previewImage', 'placeholder' => esc_html__('Driving License url' , 'claypress')));\n\n\t$fieldControl->text('Name', 'txtName', array('value' => esc_attr( $txtName ), 'attr' => array('data-test1' => 'test1', 'data-validate' => 'true')));\n\t$fieldControl->text('Website', 'txtWebsite', array('type' => 'url','value' => esc_attr( $txtWebsite )));\n\t$fieldControl->textarea('Address', 'txtAddress', array('value' => $txtAddress) );\n\t$fieldControl->select('Transportation?', 'selTrans', array('name' => 'selTrans', 'value' => $selTrans, 'class' => 'widefat chosen-select'), array('car' => 'Car', 'bike' => 'Bike', 'train' => 'Train') );\n\t$fieldControl->select('Hobby?', 'selHobby', array('name' => 'selHobby', 'multiple' => 'multiple', 'value' => $selHobby, 'class' => 'widefat chosen-select'), array('Out Door' => array('football' => 'Football', 'basketball' => 'Basketball', 'tennis' => 'Tennis', 'swimming' => 'Swimming'), 'Indoor' => array('reading' => 'Reading', 'writing' => 'Writing'), 'Extreme' => array('basejump' => 'Base Jumping', 'surving' => 'Surving', 'diving' => 'Diving')) );\n \t$fieldControl->checkbox('Food?', 'chkFood', array('name' => 'chkFood', 'value' => $chkFood, 'class' => 'widefat'), array('fruit' => 'Fruit', 'vegetable' => 'Vegetable', 'bread' => 'Bread') );\n \t// $fieldControl->radio('Gender', 'gender', array('name' => 'gender', 'value' => $gender, 'attr' => array('data-test1' => 'test1')), array('male' => 'Male', 'female' => 'Female', 'other' => 'Other'));\n \t// $fieldControl->radiopill('Gender', 'gender', array('name' => 'gender', 'value' => $gender, 'attr' => array('data-test1' => 'test1')), array('male' => 'Male', 'female' => 'Female', 'other' => 'Other'));\n \t$fieldControl->radioimage('Gender', 'gender', array('name' => 'gender', 'value' => $gender, 'attr' => array('data-test1' => 'test1')), array('male' => 'http://placeimg.com/100/100/nature', 'female' => 'http://placeimg.com/100/100/tech', 'other' => 'http://placeimg.com/100/100/arch'));\n \t$fieldControl->colorpicker('Fav Color', 'colorMeta', array('class' => 'widefat', 'value' => $colorMeta, 'attr' => array('data-color' => 'test1')));\n \t$fieldControl->editor('About me', 'edAboutMe', array('value' => $edAboutMe), array('textarea_rows' => '5'));\n \t\n \t// $fieldControl->taxonomy('Category', 'selCats', array('name' => 'selCats', 'type' => 'select', 'value' => $selCats), 'post_tag', '');\n \t$fieldControl->repeaterField('Repeated Feature', 'itemFeatures', array('name' => 'itemFeatures', 'value' => $itemFeatures), $fields);\n\n \t$fieldControl->repeaterField('Personal data', 'rePersonalData', array('name' => 'rePersonalData', 'value' => $rePersonalData), $fieldx);\n \t?>\n<?php\n}", "function dp_template_save_meta_box_data($post_id)\r\n{\r\n\r\n /*\r\n * We need to verify this came from our screen and with proper authorization,\r\n * because the save_post action can be triggered at other times.\r\n */\r\n\r\n // Check if our nonce is set.\r\n if (!isset($_POST['myplugin_meta_box_nonce'])) {\r\n return;\r\n }\r\n // Verify that the nonce is valid.\r\n if (!wp_verify_nonce($_POST['myplugin_meta_box_nonce'], 'myplugin_meta_box')) {\r\n return;\r\n }\r\n // If this is an autosave, our form has not been submitted, so we don't want to do anything.\r\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) {\r\n return;\r\n }\r\n // Check the user's permissions.\r\n if (isset($_POST['post_type']) && 'page' == $_POST['post_type']) {\r\n if (!current_user_can('edit_page', $post_id)) {\r\n return;\r\n }\r\n } else {\r\n if (!current_user_can('edit_post', $post_id)) {\r\n return;\r\n }\r\n }\r\n\r\n /* OK, it's safe for us to save the data now. */\r\n\r\n // Make sure that it is set.\r\n// if (!isset($_POST['dp-sort-element'])) {\r\n// return;\r\n// }\r\n\r\n // Sanitize user input.\r\n $my_data = sanitize_text_field($_POST['dp_sort-element']);\r\n $dp_title_s = serialize($_POST['dp_title']);\r\n $dp_image_s = serialize($_POST['dp_image']);\r\n $dp_excerpt_s= serialize($_POST['dp_excerpt']);\r\n $dp_price_s=serialize($_POST['dp_price']);\r\n $dp_addtocartbutton_s=serialize($_POST['dp_addtocartbutton']);\r\n $dp_customfield_s=serialize($_POST['dp_customfield']);\r\n $dp_variable_s=serialize($_POST['dp_variable']);\r\n $dp_option_s=serialize($_POST['dp_option']);\r\n\r\n\r\n // Update the meta field in the database.\r\n update_post_meta($post_id, 'dp_sort-element', $my_data);\r\n update_post_meta($post_id, 'dp_select_template', $_POST['dp_select_template']);\r\n update_post_meta($post_id,'dp_title',$dp_title_s);\r\n update_post_meta($post_id,'dp_image',$dp_image_s);\r\n update_post_meta($post_id,'dp_excerpt',$dp_excerpt_s);\r\n update_post_meta($post_id,'dp_price',$dp_price_s);\r\n update_post_meta($post_id,'dp_addtocartbutton',$dp_addtocartbutton_s);\r\n update_post_meta($post_id,'dp_customfield',$dp_customfield_s);\r\n update_post_meta($post_id,'dp_variable',$dp_variable_s);\r\n update_post_meta($post_id,'dp_option',$dp_option_s);\r\n}", "function foodpress_save_meta_data($post_id, $post){\n\t\t\tglobal $pagenow;\n\n\t\t\tif ( empty( $post_id ) || empty( $post ) ) return;\n\t\t\tif($post->post_type!='menu') return;\n\t\t\tif (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) return;\n\n\t\t\t// Prevent quick edit from clearing custom fields\n\t\t\tif (defined('DOING_AJAX') && DOING_AJAX) return;\n\t\t\tif ( is_int( wp_is_post_revision( $post ) ) ) return;\n\t\t\tif ( is_int( wp_is_post_autosave( $post ) ) ) return;\n\t\t\t\n\t\t\t// verify this came from the our screen and with proper authorization,\n\t\t\t// because save_post can be triggered at other times\n\t\t\tif( isset($_POST['fp_noncename']) ){\n\t\t\t\tif ( !wp_verify_nonce( $_POST['fp_noncename'], plugin_basename( __FILE__ ) ) ){\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\n\n\t\t\t$_allowed = array( 'post-new.php', 'post.php' );\n\t\t\tif(!in_array($pagenow, $_allowed)) return;\n\n\t\t\t/* Get the post type object. */\n\t\t\t$post_type = get_post_type_object( $post->post_type );\n\t\t\t\n\t\t\t\n\t\t\t// Check permissions\n\t\t\tif ( !current_user_can( $post_type->cap->edit_post, $post_id ) )\n\t\t\t\treturn;\t\n\n\t\t\t\n\t\t\t//save the post meta values\n\t\t\t//$fields_ar =apply_filters();\n\t\t\t\n\t\t\t$meta_fields = $this->foodpress_menu_metabox_array();\t\t\t\n\t\t\t\n\t\t\t// run through all the custom meta fields\n\t\t\tforeach($meta_fields as $mb=>$f_val){\n\t\t\t\t\n\t\t\t\tif(!empty($f_val)){\n\t\t\t\t\tif( $f_val['type']=='multiinput'){\n\t\t\t\t\t\tforeach($f_val['ids'] as $fvals){\n\t\t\t\t\t\t\t$this->fp_individual_post_values($fvals, $post_id);\n\t\t\t\t\t\t}\n\t\t\t\t\t}else{\n\t\t\t\t\t\t$this->fp_individual_post_values($f_val['id'], $post_id);\n\t\t\t\t\t}\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//update_post_meta($post_id, 'test', $_POST['fp_menuicons']);\n\t\t\t\n\t\t\t// save user closed meta field boxes\n\t\t\t$fp_closemeta_value = (isset($_POST['fp_collapse_meta_boxes']))? $_POST['fp_collapse_meta_boxes']: '';\n\t\t\t\n\t\t\tfoodpress_save_collapse_metaboxes($post_id, $fp_closemeta_value );\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t\n\t\t\t// (---) hook for addons\n\t\t\tdo_action('foodpress_save_meta', $post_id);\t\n\t\t\t\t\n\t\t}", "function tower_save_meta_box($post_id) {\n // Check if the post_type is correct\n if (! array_key_exists(get_post_type($post_id), TOWER_CUSTOM_POSTS)) return $post_id;\n\n // Check if nonce is set\n if (! isset($_POST['tower_nonce'])) return $post_id;\n\n // Verify that nonce is valid\n if (! wp_verify_nonce($_POST['tower_nonce'], basename(__FILE__))) return $post_id;\n\n // For Autosave, dont proceed\n if (defined('DOING_AUTOSAVE') && DOING_AUTOSAVE) return $post_id;\n\n // Check data validation\n foreach (TOWER_CUSTOM_POSTS['tower_policies']['fields'] as $field) {\n update_post_meta(\n $post_id, \n $field['name'], \n sanitize_text_field($_POST[$field['name']])\n );\n }\n}", "function tumi_metaboxes() {\n\n // Start with an underscore to hide fields from custom fields list\n $prefix = '_tumi_';\n\n /**\n * Initiate the metabox\n */\n $tumi_event_metabox = new_cmb2_box( array(\n 'id' => 'tumi_event_metabox',\n 'title' => __( 'Event Metabox', 'cmb2' ),\n 'object_types' => array( 'events', ), // Post type\n 'context' => 'normal',\n 'priority' => 'high',\n 'show_names' => true, // Show field names on the left\n // 'cmb_styles' => false, // false to disable the CMB stylesheet\n // 'closed' => true, // Keep the metabox closed by default\n ) );\n $tumi_portfolio_metabox = new_cmb2_box( array(\n 'id' => 'tumi_portfolio_metabox',\n 'title' => __( 'Portfolio Metabox', 'cmb2' ),\n 'object_types' => array( 'portfolis', ), // Post type\n 'context' => 'normal',\n 'priority' => 'high',\n 'show_names' => true,\n ) );\n\n // Regular text field\n $tumi_event_metabox->add_field( array(\n 'name' => __( 'Event Sub-Title', 'cmb2' ),\n 'desc' => __( 'Put your sub-tile here', 'cmb2' ),\n 'id' => $prefix . 'event_sub_title',\n 'type' => 'text',\n 'show_on_cb' => 'cmb2_hide_if_no_cats', // function should return a bool value\n\t\t'default' => 'Lorem '\n // 'sanitization_cb' => 'my_custom_sanitization', // custom sanitization callback parameter\n // 'escape_cb' => 'my_custom_escaping', // custom escaping callback parameter\n // 'on_front' => false, // Optionally designate a field to wp-admin only\n // 'repeatable' => true,\n ) );\n\n // URL text field\n $tumi_event_metabox->add_field( array(\n 'name' => __( 'Event Date', 'cmb2' ),\n 'desc' => __( 'Put event date', 'cmb2' ),\n 'id' => $prefix . 'event_date',\n 'type' => 'text_date',\n // 'protocols' => array('http', 'https', 'ftp', 'ftps', 'mailto', 'news', 'irc', 'gopher', 'nntp', 'feed', 'telnet'), // Array of allowed protocols\n // 'repeatable' => true,\n ) );\n\n // event format \n $tumi_event_metabox->add_field( array(\n 'name' => __( 'Event Format', 'cmb2' ),\n 'desc' => __( 'select event format', 'cmb2' ),\n 'id' => $prefix . 'event_format',\n 'type' => 'select',\n\t\t'options' => array(\n\t\t\t'1' => __( 'Left Image & Right Content', 'cmb2' ),\n\t\t\t'2' => __( 'Right Image & Left Content', 'cmb2' ),\n\t\t),\t\t\n ) );\n\n\t$tumi_event_metabox->add_field( array(\n\t\t'name' => __( 'Event Taxonomy Select', 'cmb2' ),\n\t\t'desc' => __( 'field description (optional)', 'cmb2' ),\n\t\t'id' => $prefix . 'event_taxonomy_select',\n\t\t'type' => 'taxonomy_select',\n\t\t'taxonomy' => 'events_cat', // Taxonomy Slug\n\t) );\n\n $tumi_portfolio_metabox->add_field( array(\n 'name' => __( 'Portfolio Thin Title', 'cmb2' ),\n 'desc' => __( 'Put your thin-title here', 'cmb2' ),\n 'id' => $prefix . 'portfolio_thin_title',\n 'type' => 'text',\n 'show_on_cb' => 'cmb2_hide_if_no_cats', // function should return a bool value\n\t\t'default' => 'Zoe '\n ) );\n\t\n\t$tumi_portfolio_metabox->add_field( array(\n\t\t'name' => __( 'Portfolio Link', 'cmb2' ),\n\t\t'desc' => __( 'Put your link here', 'cmb2' ),\n\t\t'id' => $prefix . 'portfolio_link',\n\t\t'type' => 'text_url',\n\t\t'default' => 'http://google.com'\n\t) );\n\n $tumi_portfolio_metabox->add_field( array(\n 'name' => __( 'Portfolio Content', 'cmb2' ),\n 'desc' => __( 'Put your content here', 'cmb2' ),\n 'id' => $prefix . 'portfolio_details',\n 'type' => 'textarea',\n 'show_on_cb' => 'cmb2_hide_if_no_cats', // function should return a bool value\n\t\t'default' => 'Lorem ipsum dolor sit amet, consectetuer adipiscing'\n ) );\t\n\t\n}", "public function save_meta_settings( $post_id ) {\n \n \n // Check if our nonce is set.\n if ( ! isset( $_POST['metabox_' . $this->id . '_nonce'] ) ) {\n\n return $post_id;\n }\n \n\n $nonce = $_POST['metabox_' . $this->id . '_nonce'];\n \n // Verify that the nonce is valid.\n if ( ! wp_verify_nonce( $nonce, 'metabox_' . $this->id ) ) {\n echo('passed validation');\n }\n \n /*\n * If this is an autosave, our form has not been submitted,\n * so we don't want to do anything.\n */\n if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) {\n return $post_id;\n }\n \n // Check the user's permissions.\n if ( 'page' == $_POST['post_type'] ) {\n if ( ! current_user_can( 'edit_page', $post_id ) ) {\n return $post_id;\n }\n } else {\n if ( ! current_user_can( 'edit_post', $post_id ) ) {\n return $post_id;\n }\n }\n \n foreach ( $this->fields as $field ) {\n $field_type = $field['type'];\n $field_meta_key = $field['meta_key'];\n $field_meta_value = $_POST[$field['meta_key']];\n if( 'checkbox' === $field['type'] && !isset( $_POST[$field['meta_key']] ) ) {\n $field_meta_value = 0;\n }\n update_post_meta( $post_id, $field['meta_key'], sanitize_text_field( $field_meta_value ) );\n \n }\n\n }" ]
[ "0.6280761", "0.6053815", "0.5933455", "0.5899549", "0.58380383", "0.57930064", "0.57580316", "0.5753993", "0.57531196", "0.5750848", "0.57364553", "0.5716982", "0.5690367", "0.56795466", "0.56663674", "0.56576496", "0.5636568", "0.5627613", "0.5614143", "0.55847514", "0.5566941", "0.55539846", "0.55235106", "0.55074954", "0.550669", "0.5496418", "0.5489133", "0.5481315", "0.54795426", "0.54488623", "0.54309356", "0.5419242", "0.54109895", "0.5404586", "0.54027516", "0.5400095", "0.5396516", "0.53945345", "0.53701025", "0.5368707", "0.536796", "0.5367365", "0.53604096", "0.53462726", "0.5345101", "0.5335755", "0.5332033", "0.53228956", "0.53133446", "0.530199", "0.52861124", "0.5284284", "0.5279403", "0.52728206", "0.5264906", "0.5260561", "0.5242069", "0.5237134", "0.523641", "0.5232742", "0.5228727", "0.52272725", "0.52229315", "0.5189527", "0.51785797", "0.517734", "0.5173912", "0.51727194", "0.5169477", "0.5167469", "0.51657", "0.51611936", "0.5155443", "0.51549995", "0.51520884", "0.51518965", "0.5151626", "0.5147888", "0.51339215", "0.51313496", "0.51230484", "0.5121654", "0.512099", "0.5109377", "0.51093507", "0.51048607", "0.5101668", "0.5100942", "0.5100669", "0.51003265", "0.50998074", "0.5089488", "0.5081495", "0.507646", "0.50746137", "0.50679207", "0.5067836", "0.5062164", "0.5054652", "0.5052113" ]
0.6570864
0
Handles the geocoding of the address when the property is saved. However, prior to doing so, it checks to see if the address has changed. If it hasnt changed, there is no need to regeocode.
function _geo_code( $address, $post_data ) { if ( !is_null($address) ) { if ( strtolower( str_replace( " ", "", $post_data['o_address']) ) == strtolower( str_replace( " ", "", $address) ) ) { //The Address has not changed, just send bak the orig. lat and lon.// //die(print_r($post_data['lat'].' '.$post_data['lon'])) return array('lat' => $post_data['lat'], 'lon' => $post_data['lon']); } else { //The address changed, so lets re-geocoge it and send back new coords.// $url = 'http://maps.googleapis.com/maps/api/geocode/json?address='.urlencode($address).'&sensor=false'; $data = wp_remote_get( $url ); $j = json_decode($data['body']); return array( 'lat' => $j->results[0]->geometry->location->lat, 'lon' => $j->results[0]->geometry->location->lng); } } else { return false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function do_geocoding( $address = null ) {\n\n\t\t\t// Null address, build from current location\n\t\t\t//\n\t\t\tif ( $address === null ) {\n\t\t\t\t$address =\n\t\t\t\t\t$this->address . ' ' .\n\t\t\t\t\t$this->address2 . ' ' .\n\t\t\t\t\t$this->city . ' ' .\n\t\t\t\t\t$this->state . ' ' .\n\t\t\t\t\t$this->zip . ' ' .\n\t\t\t\t\t$this->country;\n\t\t\t}\n\t\t\t$address = trim( $address );\n\n\t\t\t// Only process non-empty addresses.\n\t\t\t//\n\t\t\tif ( ! empty( $address ) ) {\n\t\t\t\t$this->count ++;\n\t\t\t\tif ( $this->count === 1 ) {\n\t\t\t\t\t$this->retry_maximum_delayms = (int) $this->slplus->options_nojs['retry_maximum_delay'] * 1000000;\n\t\t\t\t\t$this->iterations = max( 1, (int) $this->slplus->options_nojs['geocode_retries'] );\n\t\t\t\t}\n\n\t\t\t\t$errorMessage = '';\n\n\t\t\t\t// Get lat/long from Google\n\t\t\t\t//\n\t\t\t\t$json_response = $this->get_LatLong( $address );\n\t\t\t\tif ( ! empty( $json_response ) ) {\n\n\t\t\t\t\t// Process the data based on the status of the JSON response.\n\t\t\t\t\t//\n\t\t\t\t\t$json = json_decode( $json_response );\n\t\t\t\t\tif ( $json === null ) {\n\t\t\t\t\t\t$json = json_decode( json_encode( array( 'status' => 'ERROR', 'message' => $json_response ) ) );\n\t\t\t\t\t}\n\n\t\t\t\t\tswitch ( $json->{'status'} ) {\n\n\t\t\t\t\t\t// OK\n\t\t\t\t\t\t// Geocode completed successfully\n\t\t\t\t\t\t// Update the lat/long if it has changed.\n\t\t\t\t\t\t//\n\t\t\t\t\t\tcase 'OK':\n\t\t\t\t\t\t\t$this->set_LatLong( $json->results[0]->geometry->location->lat, $json->results[0]->geometry->location->lng );\n\t\t\t\t\t\t\t$this->delay = SLPlus_Location::StartingDelay;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t// OVER QUERY LIMIT\n\t\t\t\t\t\t// Google is getting to many requests from this IP block.\n\t\t\t\t\t\t// Loop through for X retries.\n\t\t\t\t\t\t//\n\t\t\t\t\t\tcase 'OVER_QUERY_LIMIT':\n\t\t\t\t\t\t\t$errorMessage .= sprintf( __( \"Address %s (%d in current series) hit the Google query limit.\\n\", 'store-locator-le' ),\n\t\t\t\t\t\t\t\t\t$address,\n\t\t\t\t\t\t\t\t\t$this->count\n\t\t\t\t\t\t\t ) . '<br/>';\n\t\t\t\t\t\t\t$attempts = 1;\n\t\t\t\t\t\t\t$totalDelay = 0;\n\n\t\t\t\t\t\t\t// Keep trying up until the user-selected number of retries.\n\t\t\t\t\t\t\t// Increase the wait between each try by 1 second.\n\t\t\t\t\t\t\t// Wait no more than 10 seconds between attempts.\n\t\t\t\t\t\t\t//\n\t\t\t\t\t\t\twhile ( $attempts ++ < $this->iterations ) {\n\t\t\t\t\t\t\t\tif ( $this->delay <= $this->retry_maximum_delayms + 1 ) {\n\t\t\t\t\t\t\t\t\t$this->delay += 1000000;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t$totalDelay += $this->delay;\n\t\t\t\t\t\t\t\tusleep( $this->delay );\n\t\t\t\t\t\t\t\t$json = $this->get_LatLong( $address );\n\t\t\t\t\t\t\t\tif ( $json !== null ) {\n\t\t\t\t\t\t\t\t\t$json = json_decode( $json );\n\t\t\t\t\t\t\t\t\tif ( $json->{'status'} === 'OK' ) {\n\t\t\t\t\t\t\t\t\t\t$this->set_LatLong( $json->results[0]->geometry->location->lat, $json->results[0]->geometry->location->lng );\n\t\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\tbreak;\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$errorMessage .= sprintf(\n\t\t\t\t\t\t\t\t __( 'Waited up to %4.2f seconds between request, total wait for this location was %4.2f seconds.', 'store-locator-le' ),\n\t\t\t\t\t\t\t\t $this->delay / 1000000,\n\t\t\t\t\t\t\t\t $totalDelay / 1000000\n\t\t\t\t\t\t\t ) .\n\t\t\t\t\t\t\t \"\\n<br>\";\n\t\t\t\t\t\t\t$errorMessage .= sprintf(\n\t\t\t\t\t\t\t\t __( '%d total attempts for this location.', 'store-locator-le' ),\n\t\t\t\t\t\t\t\t $attempts - 1\n\t\t\t\t\t\t\t ) .\n\t\t\t\t\t\t\t \"\\n<br>\";\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t// ZERO RESULTS\n\t\t\t\t\t\t// Bad address provided or nothing found on Google end.\n\t\t\t\t\t\t//\n\t\t\t\t\t\tcase 'ZERO_RESULTS':\n\t\t\t\t\t\t\t$errorMessage .= sprintf( __( \"Address #%d : %s <font color=red>failed to geocode</font>.\", 'store-locator-le' ),\n\t\t\t\t\t\t\t\t\t$this->id,\n\t\t\t\t\t\t\t\t\t$address\n\t\t\t\t\t\t\t ) . \"<br />\\n\";\n\t\t\t\t\t\t\t$errorMessage .= sprintf( __( \"Unknown Address! Received status %s.\", 'store-locator-le' ), $json->{'status'} ) . \"\\n<br>\";\n\t\t\t\t\t\t\t$this->delay = SLPlus_Location::StartingDelay;\n\t\t\t\t\t\t\tbreak;\n\n\t\t\t\t\t\t// GENERIC\n\t\t\t\t\t\t// Could not geocode.\n\t\t\t\t\t\t//\n\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t$errorMessage .=\n\t\t\t\t\t\t\t\tsprintf( __( \"Address #%d : %s <font color=red>failed to geocode</font>.\", 'store-locator-le' ),\n\t\t\t\t\t\t\t\t\t$this->id,\n\t\t\t\t\t\t\t\t\t$address ) .\n\t\t\t\t\t\t\t\t\"<br/>\\n\" .\n\t\t\t\t\t\t\t\tsprintf( __( \"Received status %s.\", 'store-locator-le' ),\n\t\t\t\t\t\t\t\t\t$json->{'status'} ) .\n\t\t\t\t\t\t\t\t\"<br/>\\n\" .\n\t\t\t\t\t\t\t\tsprintf( __( \"Received data %s.\", 'store-locator-le' ),\n\t\t\t\t\t\t\t\t\t'<pre>' . print_r( $json, true ) . '</pre>' );\n\t\t\t\t\t\t\t$this->delay = SLPlus_Location::StartingDelay;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\n\t\t\t\t\t// No raw json\n\t\t\t\t\t//\n\t\t\t\t} else {\n\t\t\t\t\t$errorMessage .= __( 'Geocode service non-responsive', 'store-locator-le' ) .\n\t\t\t\t\t \"<br/>\\n\" .\n\t\t\t\t\t $this->geocodeURL . urlencode( $address );\n\t\t\t\t}\n\n\t\t\t\t// Blank Address Error\n\t\t\t\t//\n\t\t\t} else {\n\t\t\t\t$errorMessage = __( 'Address is blank.', 'store-locator-le' );\n\t\t\t}\n\n\t\t\t// Show Error Messages\n\t\t\t//\n\t\t\tif ( $errorMessage != '' ) {\n\t\t\t\tif ( ! $this->geocodeIssuesRendered ) {\n\t\t\t\t\t$errorMessage =\n\t\t\t\t\t\t'<strong>' .\n\t\t\t\t\t\tsprintf(\n\t\t\t\t\t\t\t__( 'If you are having geocoding issues, %s', 'store-locator-le' ),\n\t\t\t\t\t\t\t$this->slplus->Text->get_web_link( 'docs_for_geocoding' )\n\t\t\t\t\t\t) .\n\t\t\t\t\t\t\"</strong><br/>\\n\" .\n\t\t\t\t\t\t$errorMessage;\n\t\t\t\t\t$this->geocodeIssuesRendered = true;\n\t\t\t\t}\n\t\t\t\t$this->slplus->notifications->add_notice( 6, $errorMessage );\n\n\t\t\t\t// Good encoding\n\t\t\t\t//\n\t\t\t} elseif ( ! $this->geocodeSkipOKNotices ) {\n\t\t\t\t$this->slplus->notifications->add_notice(\n\t\t\t\t\t9,\n\t\t\t\t\tsprintf(\n\t\t\t\t\t\t__( 'Google thinks %s is at <a href=\"%s\" target=\"_blank\">lat: %s long %s</a>', 'store-locator-le' ),\n\t\t\t\t\t\t$address,\n\t\t\t\t\t\tsprintf( 'https://%s/?q=%s,%s',\n\t\t\t\t\t\t\t$this->slplus->options['map_domain'],\n\t\t\t\t\t\t\t$this->latitude,\n\t\t\t\t\t\t\t$this->longitude ),\n\t\t\t\t\t\t$this->latitude, $this->longitude\n\t\t\t\t\t)\n\t\t\t\t);\n\t\t\t}\n\n\t\t\t/**\n\t\t\t * HOOK: slp_location_geocoded\n\t\t\t *\n\t\t\t * Run this when the current location is geocoded.\n\t\t\t *\n\t\t\t * @param SLPLus_Location $location\n\t\t\t */\n\t\t\tdo_action( 'slp_location_geocoded', $this );\n\n\t\t}", "public function geocode(Address $address);", "function hook_commerce_adyen_shopper_address_alter(\\Commerce\\Adyen\\Payment\\Composition\\Address $address, \\EntityDrupalWrapper $profile, array $checkout_values, \\EntityDrupalWrapper $order) {\n if ('Dnipropetrovsk' === $address->getCity()) {\n $address->setCity('Dnipro');\n }\n}", "private function resolveAddressData()\n {\n /** @var \\Magento\\Quote\\Model\\Quote $quote */\n $quote = $this->checkoutSession->getQuote();\n /** @var \\Magento\\Quote\\Model\\Quote\\Address $shippingAddress */\n $shippingAddress = $quote->getShippingAddress();\n\n $customerData = $this->geoIp->getCurrentLocation();\n if ($customerData->getCode() && $this->helper->isCountryAllowed($customerData->getCode())) {\n /** @var \\Magento\\Directory\\Model\\Country $currentCountry */\n $currentCountry = $shippingAddress\n ->getCountryModel()\n ->loadByCode($customerData->getCode());\n\n if (!$currentCountry) {\n return;\n }\n\n $shippingAddress->setCountryId($currentCountry->getId());\n $shippingAddress->setRegion($customerData->getRegion());\n $shippingAddress->setRegionCode($customerData->getRegionCode());\n $shippingAddress->setCity($customerData->getCity());\n $shippingAddress->setPostcode($customerData->getPosttalCode());\n\n $regionModel = $this->regionFactory->create();\n if ($customerData->getRegionCode() && $currentCountry->getId()) {\n $regionModel->loadByCode($customerData->getRegionCode(), $currentCountry->getId());\n $regionId = $regionModel->getRegionId();\n $shippingAddress->setRegionId($regionId);\n }\n }\n }", "public function saveAddress()\n\t{\n\t\trequire_once Component::path('com_members') . DS . 'models' . DS . 'address.php';\n\n\t\t// get request vars\n\t\t$data = Request::getArray('address', array());\n\t\t$data['uidNumber'] = User::get('id');\n\n\t\t// set up objects\n\t\t$address = Components\\Members\\Models\\Address::blank()->set($data);\n\n\t\t// attempt to save\n\t\tif (!$address->save())\n\t\t{\n\t\t\t$this->setError($address->getError());\n\t\t\treturn $this->editAddress($address);\n\t\t}\n\n\t\t//inform and redirect\n\t\tApp::redirect(\n\t\t\tRoute::url('index.php?option=com_members&id=' . User::get('id') . '&active=profile'),\n\t\t\tLang::txt('PLG_MEMBERS_PROFILE_ADDRESS_SAVED'),\n\t\t\t'passed'\n\t\t);\n\t}", "private function saveAddresses() {\n\t\t\t$billingSaved = false;\n\t\t\t$shippingSaved = false;\n\t\t\tif ($this->memberID && $this->billingAddress->validAddress() && $this->shippingAddress->validAddress()) {\n\t\t\t\t// compare billing and shipping addresses\n\t\t\t\t$billingIsShipping = true;\n\t\t\t\tforeach ($this->billingAddress->get('addressForm') as $key => $val) {\n\t\t\t\t\tif ($val != $this->shippingAddress->getArrayData('addressForm', $key)) {\n\t\t\t\t\t\t$billingIsShipping = false;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif ($billingIsShipping) {\n\t\t\t\t\t// if the billing address is the same as the shipping address\n\t\t\t\t\t// address record will retain the shipping address name\n\t\t\t\t\t// billing address does not have a name\n\t\t\t\t\t// (payment method name will be in the payment record)\n\t\t\t\t\t$this->shippingAddress->addType('billing');\n\t\t\t\t\tif ($this->shippingAddress->get('saveAddress') || systemSettings::get('FORCESAVESHIPPING')) {\n\t\t\t\t\t\tif (!$this->shippingAddress->get('addressID')) {\n\t\t\t\t\t\t\tif ($this->shippingAddress->saveAddress($this->memberID)) {\n\t\t\t\t\t\t\t\t$shippingSaved = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ($this->shippingAddress->updateAddress()) {\n\t\t\t\t\t\t\t\t$shippingSaved = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($this->shippingAddress->get('defaultAddress')) {\n\t\t\t\t\t\t\t$this->dbh->query(\"UPDATE `customers` SET `shippingID` = '\".$this->shippingAddress->get('addressID').\"' WHERE `memberID` = '\".$this->memberID.\"'\");\n\t\t\t\t\t\t}\n\t\t\t\t\t\t$billingIsDefault = false;\n\t\t\t\t\t\tif ($this->billingAddress->get('defaultAddress')) {\n\t\t\t\t\t\t\t$billingIsDefault = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($this->billingAddress->loadAddress($this->shippingAddress->get('addressID'))) {\n\t\t\t\t\t\t\t$billingSaved = true;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif ($this->billingAddress->get('saveAddress') || systemSettings::get('FORCESAVEBILLING')) {\n\t\t\t\t\t\tif (!$this->billingAddress->get('addressID')) {\n\t\t\t\t\t\t\tif ($this->billingAddress->saveAddress($this->memberID)) {\n\t\t\t\t\t\t\t\t$billingSaved = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ($this->billingAddress->updateAddress()) {\n\t\t\t\t\t\t\t\t$billingSaved = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($this->billingAddress->get('defaultAddress')) {\n\t\t\t\t\t\t\t$this->dbh->query(\"UPDATE `customers` SET `billingID` = '\".$this->billingAddress->get('addressID').\"' WHERE `memberID` = '\".$this->memberID.\"'\");\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$billingSaved = true;\n\t\t\t\t\t}\n\t\t\t\t\tif ($this->shippingAddress->get('saveAddress') || systemSettings::get('FORCESAVESHIPPING')) {\n\t\t\t\t\t\tif (!$this->shippingAddress->get('addressID')) {\n\t\t\t\t\t\t\tif ($this->shippingAddress->saveAddress($this->memberID)) {\n\t\t\t\t\t\t\t\t$shippingSaved = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif ($this->shippingAddress->updateAddress()) {\n\t\t\t\t\t\t\t\t$shippingSaved = true;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif ($this->shippingAddress->get('defaultAddress')) {\n\t\t\t\t\t\t\t$this->dbh->query(\"UPDATE `customers` SET `shippingID` = '\".$this->shippingAddress->get('addressID').\"' WHERE `memberID` = '\".$this->memberID.\"'\");\n\t\t\t\t\t\t}\n\t\t\t\t\t} else {\n\t\t\t\t\t\t$shippingSaved = true;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn ($billingSaved && $shippingSaved);\n\t\t}", "abstract protected function doSaveAddress(AddressInterface $address);", "function checkAddress($address = null, $state = null, $city = null, $zip = null) {\n $this->autoRender = false;\n if (isset($_POST)) {\n $zipCode = ltrim($zip, \" \");\n $stateName = $state;\n $cityName = strtolower($city);\n $cityName = ucwords($cityName);\n $dlocation = $address . \" \" . $cityName . \" \" . $stateName . \" \" . $zipCode;\n $adjuster_address2 = str_replace(' ', '+', $dlocation);\n $geocode = file_get_contents('https://maps.google.com/maps/api/geocode/json?key='.GOOGLE_GEOMAP_API_KEY.'&address=' . $adjuster_address2 . '&sensor=false');\n $output = json_decode($geocode);\n if ($output->status == \"ZERO_RESULTS\" || $output->status != \"OK\") {\n echo 2;\n die; // Bad Address\n } else {\n $latitude = @$output->results[0]->geometry->location->lat;\n $longitude = @$output->results[0]->geometry->location->lng;\n $formated_address = @$output->results[0]->formatted_address;\n if ($latitude) {\n echo 1;\n die; // Good Address\n }\n }\n }\n }", "public function update_address(){\n\t\t\t\t\t\t//$this->ADDRESS[$last_index] = $address;\n\t\t\t\t$error = 0;\n\t\t\t\t\t$updated = 0;\n\t\t\t\t\t\t\t$address;\n\t\t\t\t$count = 0;\n\n\n\t\t\t\twhile($count < $this->get_address_count()) {\n\n\n\t\t\t\t\t\tif($this->get_address($count + 1)->get_status() == 'updated' ) {\n\t\t\t\t\t\tif((!$address[$updated]['addressId'] = $this->get_address($count + 1)->get_id()) && $error = 1)\n\t\t\t\t\t\t\ttrigger_error('REQUIRED Organization (ID) not provided', E_USER_ERROR);\n\t\t\t\t\t\tif((!$address[$updated]['country'] = $this->get_address($count + 1)->get_country()) && $error = 1)\n\t\t\t\t\t\t\ttrigger_error('REQUIRED Organization (country) not provided', E_USER_ERROR);\n\t\t\t\t\t\tif((!$address[$updated]['city'] = $this->get_address($count + 1)->get_city()) && $error = 1)\n\t\t\t\t\t\t\ttrigger_error('REQUIRED Organization (city) not provided', E_USER_ERROR);\n\t\t\t\t\t\tif((!$address[$updated]['subCity'] = $this->get_address($count + 1)->get_sub_city()) && $error = 1)\n\t\t\t\t\t\t\ttrigger_error('REQUIRED Organization (Sub-City) not provided', E_USER_ERROR);\n\t\t\t\t\t\tif((!$address[$updated]['location'] = $this->get_address($count + 1)->get_location()) && $error = 1)\n\t\t\t\t\t\t\ttrigger_error('REQUIRED Organization (Location) not provided', E_USER_ERROR);\n\t\t\t\t\t\tif((!$address[$updated]['latitude'] = $this->get_address($count + 1)->get_latitude()))\n\t\t\t\t\t\t\ttrigger_error(' Organization (latitude) not provided', E_USER_WARNING);\n\t\t\t\t\t\tif((!$address[$updated]['longitude'] = $this->get_address($count + 1)->get_longitude() ))\n\t\t\t\t\t\t\ttrigger_error(' Organization (longitude) not provided', E_USER_WARNING);\n\n\t\t\t\t\t\t\t$updated++;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t$count++;\n\n\t\t\t\t}\n\n\n\n\t\t\t\t\tif($error == 0) {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t$address = json_encode($address);\n\t\t\t\t\t\t\t\t$sql = 'CALL updateOrganizationAddress('.$this->get_id().', '.json_encode($address) .')';\n\t\t\t\t\t\t\t\t$statement = $this->DB_Driver->prepare_query($sql);\n\t\t\t\t\t\t\t\t$statement->execute();\n\t\t\t\t\t\t} catch(Exception $e) {\n\t\t\t\t\t\t\ttrigger_error($e->getMessage(), E_USER_ERROR);\n\t\t\t\t\t\t\t$error = 1;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\treturn ($error == 0 ) ? true : false;\n\n\t\t\t}", "function venture_geo_process_geocodes() {\n $geocoded = false;\n \n $query = \"SELECT nid FROM {content_type_profile} WHERE LENGTH(IFNULL(field_location_value, '')) = 0\";\n $result = db_query($query);\n \n while ($row = db_fetch_object($result)) {\n $profile = node_load($row->nid);\n $city = $profile->field_city[0]['value'];\n $state = $profile->field_state[0]['value'];\n $country = $profile->field_country[0]['value'];\n \n $geo_location = $city . ',' . $state . ',' . $country;\n $geo_query = array('query' => $geo_location, 'maxRows' => 1);\n $geo_result = geonames_query('search', $geo_query);\n \n $location = 'invalid';\n \n if (!$geo_result) {\n watchdog('venture', \"Unable to geocode $location\");\n continue;\n }\n else if ($geo_result->results) {\n $geocode = $geo_result->results[0];\n $location = $geocode['name'] . '|' . $geocode['lat'] . '|' . $geocode['lng'];\n $geocoded = true;\n }\n \n $profile->field_location[0]['value'] = $location;\n node_save($profile);\n }\n \n return $geocoded;\n}", "function post_getFromDB () {\n\n // Be sure to remove addresses, otherwise reusing will provide old objects for getAddress, ...\n unset($this->address);\n unset($this->netmask);\n unset($this->gateway);\n\n if (isset($this->fields[\"address\"])\n && isset($this->fields[\"netmask\"])) {\n if ($this->fields[\"version\"] == 4) {\n $this->fields[\"network\"] = sprintf(__('%1$s / %2$s'), $this->fields[\"address\"],\n $this->fields[\"netmask\"]);\n } else { // IPv6\n $this->fields[\"network\"] = sprintf(__('%1$s / %2$s'), $this->fields[\"address\"],\n $this->fields[\"netmask\"]);\n }\n }\n\n }", "function rec_regenerate_coordinates() {\n\n\tif( ! isset( $_GET['coord_debug'] ) ) {\n\t\treturn;\n\t}\n\n\t$posts = new WP_Query(\n\t\tarray(\n\t\t\t'post_type'\t\t=>\tepl_get_core_post_types(),\n\t\t\t'post_status'\t=>\t'any',\n\t\t\t'posts_per_page' =>\t-1,\n\t\t\t'meta_query'\t=>\tarray(\n\t\t\t\tarray(\n\t\t\t\t\t'key'\t\t=>\t'property_address_coordinates',\n\t\t\t\t\t'value'\t\t=>\tarray(\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'compare'\t=>\t'IN'\n\t\t\t\t)\n\t\t\t)\n\t\t)\n\t);\n\twhile( $posts->have_posts() ) {\n\t\t$posts->the_post();\n\t\t$coord = get_property_meta( 'property_address_coordinates' );\n\t\t\n\t\t$query_address = epl_property_get_the_full_address();\n\t\t$query_address = trim( $query_address );\n\n\t\tif( $query_address != ',' ) {\n\t\n\t\t\t$googleapiurl = \"https://maps.google.com/maps/api/geocode/json?address=$query_address&sensor=false\";\n\t if( epl_get_option('epl_google_api_key') != '' ) {\n\t $googleapiurl = $googleapiurl.'&key='.epl_get_option('epl_google_api_key');\n\t }\n\n\t $geo_response = wp_remote_get( $googleapiurl );\n\t $geocode = $geo_response['body'];\n\t $output = json_decode($geocode);\n\t /** if address is validated & google returned response **/\n\t if( !empty($output->results) && $output->status == 'OK' ) {\n\n\t $lat = $output->results[0]->geometry->location->lat;\n\t $long = $output->results[0]->geometry->location->lng;\n\t $coord = $lat.','.$long;\n\n\t update_post_meta( get_the_ID(), 'property_address_coordinates', $coord);\n\t update_post_meta( get_the_ID(), 'property_address_display', 'yes');\n\t }\n }\n\t}\n}", "public function handleAddress ()\n {\n /**\n * Wir verzichten der Übersichtlichkeit halber auf eine Validierung. Eigentlich müsste hier eine Daten-\n * validierung durchgeführt werden und etwaige Fehler an den User zurückgespielt werden. Im Login machen wir das\n * beispielsweise und auch bei der Bearbeitung eines Produkts. Der nachfolgende Code dürfte gar nicht mehr\n * ausgeführt werden, wenn Validierungsfehler aufgetreten sind.\n */\n\n /**\n * Eingeloggten User abfragen\n */\n $user = User::getLoggedInUser();\n\n /**\n * Wurde das linke Formular abgeschickt?\n */\n if (isset($_POST['address_id'])) {\n /**\n * Ausgefühlte AddressId in die Session speichern, damit wir sie in einem weiteren Checkout-Schritt wieder\n * verwenden können.\n */\n Session::set(self::ADDRESS_KEY, (int)$_POST['address_id']);\n }\n\n /**\n * Wurde das rechte Formular abgeschickt?\n */\n if (isset($_POST['address'])) {\n /**\n * Neue Addresse erstellen und in die Datenbank speichern.\n */\n $address = new Address();\n $address->address = $_POST['address'];\n $address->user_id = $user->id;\n $address->save();\n\n /**\n * ID der neu erstellten Adresse in die Session speichern, damit wir sie in einem weiteren Checkout-Schritt\n * wieder verwenden können.\n */\n Session::set(self::ADDRESS_KEY, (int)$address->id);\n }\n\n /**\n * Weiterleiten auf den nächsten Schritt im Checkout Prozess.\n */\n $baseUrl = Config::get('app.baseUrl');\n header(\"Location: {$baseUrl}checkout/final\");\n }", "function venture_geo_process() {\n $geocoded = venture_geo_process_geocodes();\n $existing_map = venture_geo_get_map_path();\n \n if ($geocoded || !$existing_map) {\n venture_geo_process_map($existing_map);\n }\n}", "protected function processShippingAddress()\n {\n $this->updateStreetFields($this->addressFields['children']['street'], 'shippingAddress');\n\n if(false === $this->configResolver->getUseRegions()){\n unset($this->addressFields['children']['region']['filterBy']);\n unset($this->addressFields['children']['region_id']);\n }\n\n foreach ($this->fieldsConfig as $fieldName => $config) {\n $field = &$this->addressFields['children'][$fieldName];\n $this->configureField($field, 'shippingAddress', $config);\n }\n }", "public function save_addressAction() {\r\n\t\t$billing_data = $this->getRequest()->getPost('billing', false);\r\n\t\t$shipping_data = $this->getRequest()->getPost('shipping', false);\r\n\t\t$shipping_method = $this->getRequest()->getPost('shipping_method', false);\r\n\t\t$billing_address_id = $this->getRequest()->getPost('billing_address_id', false);\t\r\n\t\t\r\n\t\t//load default data for disabled fields\r\n\t\tif (Mage::helper('onestepcheckout')->isUseDefaultDataforDisabledFields()) {\r\n\t\t\tMage::helper('onestepcheckout')->setDefaultDataforDisabledFields($billing_data);\r\n\t\t\tMage::helper('onestepcheckout')->setDefaultDataforDisabledFields($shipping_data);\r\n\t\t}\r\n\t\t\r\n\t\tif (isset($billing_data['use_for_shipping']) && $billing_data['use_for_shipping'] == '1') {\r\n\t\t\t$shipping_address_data = $billing_data;\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$shipping_address_data = $shipping_data;\r\n\t\t}\r\n\t\t\r\n\t\t$billing_street = trim(implode(\"\\n\", $billing_data['street']));\r\n\t\t$shipping_street = trim(implode(\"\\n\", $shipping_address_data['street']));\r\n\t\t\r\n\t\tif(isset($billing_data['email'])) {\r\n\t\t\t$billing_data['email'] = trim($billing_data['email']);\r\n\t\t}\t\t\t\t\t\t\t\t\r\n\t\t\r\n\t\t// Ignore disable fields validation --- Only for 1..4.1.1\r\n\t\t$this->setIgnoreValidation();\r\n\t\tif(Mage::helper('onestepcheckout')->isShowShippingAddress()) {\r\n\t\t\tif(!isset($billing_data['use_for_shipping']) || $billing_data['use_for_shipping'] != '1')\t{\t\t\r\n\t\t\t\t$shipping_address_id = $this->getRequest()->getPost('shipping_address_id', false);\r\n\t\t\t\t$this->getOnepage()->saveShipping($shipping_data, $shipping_address_id);\r\n\t\t\t}\r\n\t\t}\t\t\r\n\t\t$this->getOnepage()->saveBilling($billing_data, $billing_address_id);\r\n\t\tif($billing_data['country_id']){\r\n\t\t\tMage::getModel('checkout/session')->getQuote()->getBillingAddress()->setData('country_id',$billing_data['country_id'])->save();\r\n\t\t}\r\n\t\t//var_dump($billing_data['country_id']);die();\r\n\t\t//Mage::getModel('core/session')->setData('country',$billing_data['country_id']);\r\n\t\t// if different shipping address is enabled and customer ship to another address, save it\r\n\t\t\r\n\t\t\r\n\t\tif ($shipping_method && $shipping_method != '') {\r\n\t\t\tMage::helper('onestepcheckout')->saveShippingMethod($shipping_method);\r\n\t\t}\r\n\t\t$this->loadLayout(false);\r\n\t\t$this->renderLayout();\t\r\n\t}", "function geocode() {\n if ( ! $this->input->is_ajax_request() || ! $this->auth->is_login()) {\n return redirect(config_item('site_url'));\n }\n \n $latitude = filter($this->input->get('lat'), 'float', 20);\n $longitude = filter($this->input->get('lon'), 'float', 20);\n\n if (empty($latitude) || empty($longitude)) {\n return $this->output->set_output(json_encode(array(\n 'code' => 'error'\n )));\n }\n\n $this->load->library('Location');\n \n $geocode = $this->location->get_address($latitude, $longitude);\n\n if ( ! empty($geocode) && is_array($geocode)) {\n return $this->output->set_output(json_encode(array(\n 'code' => 'luck',\n 'address' => $geocode['address']\n )));\n }\n\n log_write(LOG_WARNING, 'Yandex geocode error, USER: ' . $this->auth->get_user_id(), __METHOD__);\n\n return $this->output->set_output(json_encode(array(\n 'code' => 'error',\n 'address' => 'Сервер определения местоположения недоступен. Попробуйте позже.'\n )));\n }", "function google_map_get_coordinates( $address, $force_refresh = false ) {\n\t$address_hash = md5( $address );\n\t$coordinates = get_transient( $address_hash );\n\tif ($force_refresh || $coordinates === false) {\n\t\t$args = array( 'address' => urlencode( $address ), 'sensor' => 'false', 'key' => 'AIzaSyA4-ZxE3QqrSWpnwsjSke4Bs5DDN1LeFB0' );\n\t\t$url = add_query_arg( $args, 'https://maps.googleapis.com/maps/api/geocode/json' );\n\t\t// var_dump($url);\n\t\t$response \t= wp_remote_get( $url );\n\t\tif( is_wp_error( $response ) )\n\t\t\treturn;\n\t\t$data = wp_remote_retrieve_body( $response );\n\t\tif( is_wp_error( $data ) )\n\t\t\treturn;\n\t\tif ( $response['response']['code'] == 200 ) {\n\t\t\t// var_dump($data);\n\t\t\t$data = json_decode( $data );\n\t\t\tif ( $data->status === 'OK' ) {\n\t\t\t\t$coordinates = $data->results[0]->geometry->location;\n\t\t\t\t$cache_value['lat'] \t= $coordinates->lat;\n\t\t\t\t$cache_value['lng'] \t= $coordinates->lng;\n\t\t\t\t$cache_value['address'] = (string) $data->results[0]->formatted_address;\n\t\t\t\t// // cache coordinates for 3 months\n\t\t\t\t// set_transient($address_hash, $cache_value, 3600*24*30*3);\n\t\t\t\t// $data = $cache_value;\n\t\t\t\t// var_dump($data->status);\n\t\t\t} elseif ( $data->status === 'ZERO_RESULTS' ) {\n\t\t\t\treturn __( 'No location for the address.', 'aletheme' );\n\t\t\t} elseif( $data->status === 'INVALID_REQUEST' ) {\n\t\t\t\treturn __( 'Bad request. Did you enter an address name?', 'aletheme' );\n\t\t\t} else {\n\t\t\t\treturn ($data->status);\n\t\t\t\t// return __( 'Error, please check if you have entered the shortcode correctly.', 'aletheme' );\n\t\t\t}\n\t\t} else {\n\t\t\treturn __( 'Can\\'t connect Google API.', 'aletheme' );\n\t\t}\n\t} else {\n\t\t// return cached results\n\t\t$data = $coordinates;\n\t}\n\t// return (array) $data;\n\t$coords = array();\n\t// var_dump($data);\n\t// print(\"<pre>\".print_r($data,true).\"</pre>\");\n\t// var_dump($data->results[0]->geometry->location->lat);\n\t$coords['lat'] = $data->results[0]->geometry->location->lat;\n\t$coords['lng'] = $data->results[0]->geometry->location->lng;\n\t// var_dump($data->results[0]->geometry->location->lng);\n\treturn $coords;\n}", "function ale_map_get_coordinates( $address, $force_refresh = false ) {\n\n $address_hash = md5( $address );\n\n $coordinates = get_transient( $address_hash );\n\n if ($force_refresh || $coordinates === false) {\n\n $args = array( 'address' => urlencode( $address ), 'sensor' => 'false' );\n $url = add_query_arg( $args, 'http://maps.googleapis.com/maps/api/geocode/json' );\n $response \t= wp_remote_get( $url );\n\n if( is_wp_error( $response ) )\n return;\n\n $data = wp_remote_retrieve_body( $response );\n\n if( is_wp_error( $data ) )\n return;\n\n if ( $response['response']['code'] == 200 ) {\n\n $data = json_decode( $data );\n\n if ( $data->status === 'OK' ) {\n\n $coordinates = $data->results[0]->geometry->location;\n\n $cache_value['lat'] \t= $coordinates->lat;\n $cache_value['lng'] \t= $coordinates->lng;\n $cache_value['address'] = (string) $data->results[0]->formatted_address;\n\n // cache coordinates for 3 months\n set_transient($address_hash, $cache_value, 3600*24*30*3);\n $data = $cache_value;\n\n } elseif ( $data->status === 'ZERO_RESULTS' ) {\n return __( 'No location for the address.', 'aletheme' );\n } elseif( $data->status === 'INVALID_REQUEST' ) {\n return __( 'Bad request. Did you enter an address name?', 'aletheme' );\n } else {\n return __( 'Error, please check if you have entered the shortcode correctly.', 'aletheme' );\n }\n\n } else {\n return __( 'Can\\'t connect Google API.', 'aletheme' );\n }\n\n } else {\n // return cached results\n $data = $coordinates;\n }\n\n return $data;\n }", "protected function prepareForValidation()\n {\n $address = $this->input('address');\n\n if (!empty($address)) {\n $this->merge([\n 'geocoder' => Geocoder::getCoordinatesForAddress($address),\n ]);\n }\n }", "public function setAddress(Address $address);", "public function updateBillingAddress() {\n Log::debug(\"Entering updateBillingAddress\");\n DB::transaction(function () {\n $order = $this->getOrderData();\n if (isset($order)) {\n // update the existing billing adress or create a new one\n $address = $order->billingAddress;\n if (!isset($address))\n $address = new Address();\n $address = $this->fillOrderAddress($address);\n $address->save();\n $order->billing_address = $address->id;\n $order->save();\n }\n });\n }", "public function saveaddress() {\n if (isset($_POST['address'])) {\n $userId = $this->session->userdata('user_id');\n $address = $this->input->post('address');\n $result = $this->Users->saveaddress($address, $userId);\n if ($result) {\n $this->output\n ->set_content_type('application/json')\n ->set_output(json_encode(array('result' => 1)));\n } else {\n $this->output\n ->set_content_type('application/json')\n ->set_output(json_encode(array('result' => 0)));\n }\n }\n }", "public function geocode($address)\n {\n $requestUrl = 'https://maps.googleapis.com/maps/api/geocode/json?';\n $params = array(\n 'sensor' => 'false',\n 'language' => 'de',\n 'address' => $address,\n );\n\n $requestUrl .= http_build_query($params);\n\t\n $json = json_decode(file_get_contents($requestUrl), true);\n $return = array(\n 'status' => $json['status'],\n 'succeed' => $json['status'] == 'OK',\n );\n\n if ($json['status'] == 'OK') {\n $result = $json['results'][0];\n\n $return['formatted_address'] = $result['formatted_address'];\n $return['coordinates'] = new Point($result['geometry']['location']['lat'], $result['geometry']['location']['lng']);\n\n // find zip code and city name\n $return = array_merge($return, $this->parseAddressComponents($result));\n\n if (isset($result['partial_match']) && $result['partial_match']) {\n $return['partial_match'] = true;\n }\n }\n\n return $return;\n }", "public function geocodeLocation($address) {\n\t\tLoggerRegistry::debug('GoogleModule::geocodeLocation({address})', array( 'address' => TypeUtilities::describe($address) ));\n\t\t$url = sprintf('http://%s/maps/api/geocode/json?address=%s&sensor=false', $this->config('maps.api.host'), urlencode($address));\n\t\t$data = json_decode(file_get_contents($url), true);\n\t\tif (!isset($data['status'])) {\n\t\t\tthrow new \\RuntimeException(sprintf('Could not geocode location \"%s\", invalid geocode response structure', $address));\n\t\t}\n\t\tif ($data['status'] !== 'OK') {\n\t\t\tthrow new \\RuntimeException(sprintf('Could not geocode location \"%s\", geocode response status indicates an error: %s', $address, $data['status']));\n\t\t}\n\t\tif (!isset($data['results']) || !isset($data['results'][0]) || !isset($data['results'][0]['geometry']) || !isset($data['results'][0]['geometry']['location'])) {\n\t\t\tthrow new \\RuntimeException(sprintf('Could not geocode location \"%s\", geocode response contains no results', $address));\n\t\t}\n\t\t$coordinates = $data['results'][0]['geometry']['location'];\n\t\treturn array(\n\t\t\t'latitude' => $coordinates['lat'],\n\t\t\t'longitude' => $coordinates['lng']\n\t\t);\n\t}", "function store()\n {\n $db =& eZDB::globalDatabase();\n $db->begin();\n \n $ret = false;\n if ( $this->CountryID <= 0 )\n $country_id = \"NULL\";\n else\n $country_id = \"$this->CountryID\";\n\n $street1 = $db->escapeString( $this->Street1 );\n $street2 = $db->escapeString( $this->Street2 );\n $name = $db->escapeString( $this->Name );\n $place = $db->escapeString( $this->Place );\n if ( !isSet( $this->ID ) )\n {\n $db->lock( \"eZAddress_Address\" );\n\t\t\t$this->ID = $db->nextID( \"eZAddress_Address\", \"ID\" );\n $res[] = $db->query( \"INSERT INTO eZAddress_Address\n (ID, Street1, Street2, Zip, Place, CountryID, AddressTypeID, Name)\n VALUES\n ('$this->ID',\n '$street1',\n '$street2',\n '$this->Zip',\n '$place',\n '$country_id',\n '$this->AddressTypeID',\n '$name')\" );\n $db->unlock();\n $ret = true;\n }\n else\n {\n $res[] = $db->query( \"UPDATE eZAddress_Address\n SET Street1='$street1',\n Street2='$street2',\n Zip='$this->Zip',\n Place='$place',\n AddressTypeID='$this->AddressTypeID',\n Name='$name',\n CountryID=$country_id\n WHERE ID='$this->ID'\" ); \n $ret = true; \n }\n\n eZDB::finish( $res, $db );\n return $ret;\n }", "public function saveAddress(Commerce_AddressModel $address)\n {\n $customer = $this->getSavedCustomer();\n if(craft()->commerce_addresses->saveAddress($address)){\n\n $customerAddress = Commerce_CustomerAddressRecord::model()->findByAttributes([\n 'customerId' => $customer->id,\n 'addressId' => $address->id\n ]);\n\n if(!$customerAddress){\n $customerAddress = new Commerce_CustomerAddressRecord;\n }\n\n $customerAddress->customerId = $customer->id;\n $customerAddress->addressId = $address->id;\n if($customerAddress->save()){\n return true;\n }\n }\n\n return false;\n }", "public function updateShippingAddress() {\n Log::debug(\"Entering updateShipping\");\n DB::transaction(function () {\n $order = $this->getOrderData();\n if (isset($order)) {\n // If set shipping addres same as billing\n if (isset($_POST['useBillingAddress'])) {\n $useBilling = $_POST['useBillingAddress'];\n if ($useBilling == \"1\") {\n $order->shipping_address = $order->billing_address;\n }\n // Not using billing address\n } else {\n // update the existing billing adress or create a new one\n $address = $order->shippingAddress;\n // if no existing address or changing from billing address\n if (!isset($address) || $order->billing_address == $order->shipping_address)\n $address = new Address();\n\n $address = $this->fillOrderAddress($address);\n $address->save();\n $order->shipping_address = $address->id;\n }\n $order->save();\n }\n });\n }", "protected function _setDestinationAddress($address) {\n\t\t//$shippingAddress = $quote->getShippingAddress();\n\t\t//$street = $address->getStreet();\n\t\t$street = array();\n\t\t$street1 = isset($street[0]) ? $street[0] : null;\n\t\t$street2 = isset($street[1]) ? $street[1] : null;\n\t\t$city = $address->getCity();\n\t\t$zip = preg_replace('/[^0-9\\-]*/', '', $address->getPostcode());\n\t\t$state = Mage::getModel('directory/region')->load($address->getRegionId())->getCode(); \n\t\t$country = $address->getCountry();\n\t\t \n\t\tif(($city && $state) || $zip) {\n\t\t\t$address = $this->_newAddress($street1, $street2, $city, $state, $zip, $country);\n\t\t\treturn $this->_request->setDestinationAddress($address);\n\t\t} else {\n\t\t\treturn false;\n\t\t}\n\t}", "function postcodenl_civicrm_pre($op, $objectName, $id, &$params) {\n CRM_Postcodenl_Updater::pre($op, $objectName, $id, $params);\n if ($objectName == 'Address' && isset($params['country_id']) && $params['country_id'] == 1152) {\n // skip_geocode is an optional parameter through the api.\n // manual_geo_code is on the contact edit form. They do the same thing....\n if (empty($params['skip_geocode']) && empty($params['manual_geo_code'])) {\n CRM_Core_BAO_Address::addGeocoderData($params);\n }\n }\n}", "public function beforeSave($options = array()) {\r\n\t\t$now = date(\"Y-m-d H:i:s\", time());\r\n\t\t$this->data['DeliveryAddress']['last_update'] = $now;\r\n\t\t\t\t\r\n\t\t// format postal code\r\n\t\t$this->data['DeliveryAddress']['postal_code'] = strtoupper($this->data['DeliveryAddress']['postal_code']);\r\n\t\t\r\n\t}", "public function setAutoResponderToAddressField($value) { $this->_autoResponderToAddressField = $value; }", "function getGeocodeData($address) {\n $address = urlencode($address);\n $googleMapUrl = \"https://maps.googleapis.com/maps/api/geocode/json?address={$address}&key=AIzaSyCXB6yLq41R_CSfl2saDa1pqqOutnamespace OCFram\\Blog\\Model;PwVNnI\";\n $geocodeResponseData = file_get_contents($googleMapUrl);\n $responseData = json_decode($geocodeResponseData, true);\n if($responseData['status']=='OK') {\n $latitude = isset($responseData['results'][0]['geometry']['location']['lat']) ? $responseData['results'][0]['geometry']['location']['lat'] : \"\";\n $longitude = isset($responseData['results'][0]['geometry']['location']['lng']) ? $responseData['results'][0]['geometry']['location']['lng'] : \"\";\n $formattedAddress = isset($responseData['results'][0]['formatted_address']) ? $responseData['results'][0]['formatted_address'] : \"\";\n if($latitude && $longitude && $formattedAddress) {\n $geocodeData = $latitude . \";\" . $longitude;\n return $geocodeData;\n } else {\n return false;\n }\n } else {\n echo \"ERROR: {$responseData['status']}\";\n return false;\n }\n }", "public function setAddress($address);", "public function setAddress($address);", "public function saveAddress(Address $address)\n {\n return $this->address()->save($address);\n }", "public function setRawAddressAttribute($value)\n {\n $this->attributes['raw_address'] = $value;\n\n if($data = Geo::geocodeAddress($value))\n foreach($data as $key => $val)\n $this->attributes[$key] = $val;\n }", "public function collectAddressData()\n {\n try {\n $components = collect($this->response->address_components);\n\n $this->address_data = $components->filter(function ($element) {\n $types = collect($element->types);\n\n return $types->search('street_number') !== false ||\n $types->search('route') !== false ||\n $types->search('locality') !== false ||\n $types->search('administrative_area_level_1') !== false || // province, normalement, short et long form\n $types->search('country') !== false ||\n $types->search('postal_code') !== false;\n })->mapWithKeys(function ($item) {\n return [$item->types[0] => $item->long_name];\n });\n } catch (\\Exception $e) {\n $this->address_data = null;\n }\n\n return $this;\n }", "public static function geodecode_addr($addr_infos, $addr_hash = false, $bypass_cache=false) {\n\n $addr_filter = array(\n 'street_number',\n 'route',\n 'postal_code',\n 'locality',\n 'area_level_2',\n 'area_level_1',\n 'country',\n );\n $addr_data = array_sort($addr_infos, $addr_filter);\n $addr_data = array_filter(array_map('trim',$addr_data));\n\n // build addr_str (add area_level ?)\n $addr_str .= $addr_data['street_number']?\"{$addr_data['street_number']} \":'';\n $addr_str .= $addr_data['route']?\"{$addr_data['route']}, \":'';\n $addr_str .= $addr_data['postal_code']?\"{$addr_data['postal_code']} \":'';\n $addr_str .= $addr_data['locality']?\"{$addr_data['locality']}, \":'';\n $addr_str .= $addr_data['country']?\"{$addr_data['country']}\":'';\n\n if(!$addr_hash)\n $addr_hash = strtolower(md5(strtoupper($addr_str))); // hash the strtoup for better cache optimization\n\n $verif_hash = array('geodetic_hash' => $addr_hash);\n $cached = sql::row(self::cache_table, $verif_hash);\n if($cached && !$bypass_cache) {\n return array(\n 'geodetic_lat' => $cached['geodetic_lat'],\n 'geodetic_lon' => $cached['geodetic_lon'],\n 'return_code' => geotools::CACHED,\n );\n }\n\n $data = array(\n 'geodetic_hash' => $addr_hash,\n 'geodetic_addr' => $addr_str,\n );\n $result = array(\n 'geodetic_lat' => null,\n 'geodetic_lon' => null,\n 'return_code' => geotools::OK,\n );\n try {\n $geodetic = self::geodecode_request($addr_str);\n $result['geodetic_lat'] = $geodetic['lat'];\n $result['geodetic_lon'] = $geodetic['lon'];\n } catch(Exception $e){\n if($e->getMessage() == geotools::OVER_QUERY_LIMIT)\n $result['return_code'] = geotools::OVER_QUERY_LIMIT; // to recompute later\n else\n $result['return_code'] = geotools::NO_RESULT;\n }\n\n // Update cache\n sql::insert(\"ks_geodecode_cache\", array_merge($data, $result));\n\n return $result;\n }", "public function save_address( $post_id ) {\n\t\t\t//check for empty post id\n\t\t\tif ( empty( $post_id ) ) {\n\t\t\t\t$post_id = $_POST[ 'post_ID' ];\n\t\t\t}\n\t\t\tif ( empty( $post_id ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t//verify nonce for address\n\t\t\t$address_nonce = !empty( $_POST[ 'restaurant_address_nonce' ] ) ? $_POST[ 'restaurant_address_nonce' ] : '';\n\t\t\tif ( empty( $address_nonce ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tif ( !wp_verify_nonce( $_POST[ 'restaurant_address_nonce' ], 'rt_restaurant_address_nonce' ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t//fetch value of address\n\t\t\t$address = isset( $_POST[ 'restaurant_add' ] ) ? $_POST[ 'restaurant_add' ] : '';\n\t\t\tif ( empty( $address ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t//sanitize address values\n\t\t\tforeach ( $address as $key => $value ) {\n\t\t\t\t$address[ $key ] = sanitize_text_field( $value );\n\t\t\t}\n\n\t\t\t/**\n\t\t\t * Filter to change address value\n\t\t\t *\n\t\t\t * @since 0.1\n\t\t\t *\n\t\t\t * @param string $var Name of filter\n\t\t\t * @param array $address\n\t\t\t */\n\t\t\t$address = apply_filters( 'rt_restaurant_save_address', $address );\n\n\t\t\t/**\n\t\t\t * Action to run code before saving address\n\t\t\t * \n\t\t\t * @param array $address\n\t\t\t */\n\t\t\tdo_action( 'rt_restaurants_before_save_address', $address );\n\n\t\t\t//add or update address post meta\n\t\t\tupdate_post_meta( $post_id, '_restaurant_address', $address );\n\t\t}", "#[Route('/geocode/{address}', name: 'user.geocode', methods: ['GET', 'POST'])]\n public function index(\n GeocodeAddressParser $geocodeAddress,\n Request $request,\n EntityManagerInterface $entityManager,\n UsersProfileAddressHandler $addressHandler,\n string|null $address = null,\n //?string $address = null,\n ): Response {\n// {\n// return new Response(status: 404);\n// }\n\n $UsersProfileAddressDTO = new UsersProfileAddressDTO();\n $UsersProfileAddressDTO->setDesc($address);\n\n if (!empty($address))\n {\n /* Если передан идентификатор адреса */\n if (preg_match('{^[0-9a-f]{8}(?:-[0-9a-f]{4}){3}-[0-9a-f]{12}$}Di', $address))\n {\n $GeocodeAddress = $entityManager->getRepository(GeocodeAddress::class)->find($address);\n } elseif ($request->isMethod('GET'))\n {\n /** @var GeocodeAddress $var */\n $GeocodeAddress = $geocodeAddress->getGeocode($address);\n }\n\n $UsersProfileAddressDTO->setAddress($GeocodeAddress);\n $UsersProfileAddressDTO->setLatitude($GeocodeAddress->getLatitude());\n $UsersProfileAddressDTO->setLongitude($GeocodeAddress->getLongitude());\n $UsersProfileAddressDTO->setDesc($GeocodeAddress->getAddress());\n $UsersProfileAddressDTO->setHouse(($GeocodeAddress->getHouse() !== null));\n\n if ($this->getProfileUid())\n {\n $UsersProfileAddressDTO->setProfile($this->getProfileUid());\n }\n }\n\n $form = $this->createForm(UsersProfileAddressForm::class, $UsersProfileAddressDTO, [\n 'action' => $this->generateUrl('UsersAddress:user.geocode', ['address' => $UsersProfileAddressDTO->getAddress()]),\n ]);\n\n $form->handleRequest($request);\n\n\n /* */\n if ($form->isSubmitted() && $form->has('geocode'))\n {\n /* Если пользователь авторизован - прикрепляем адрес */\n if ($this->getProfileUid() && $form->isValid() )\n {\n $UsersProfileAddress = $addressHandler->handle($UsersProfileAddressDTO);\n\n if ($UsersProfileAddress instanceof UsersProfileAddress)\n {\n return new JsonResponse(\n [\n 'type' => 'success',\n 'header' => 'Ваш адрес',\n 'message' => $UsersProfileAddressDTO->getDesc(),\n 'status' => 200,\n ]\n );\n }\n\n return new JsonResponse(\n [\n 'type' => 'danger',\n 'header' => 'Адрес местоположения',\n 'message' => 'Невозможно определить адрес местоположения',\n 'status' => 400,\n ],\n 400\n );\n }\n\n return new JsonResponse(\n [\n 'type' => 'success',\n 'header' => 'Ваш адрес',\n 'message' => $UsersProfileAddressDTO->getDesc(),\n 'status' => 200,\n ]\n );\n }\n\n return $this->render([\n 'form' => $form->createView(),\n ]);\n }", "public static function address($address){\n $addre = Address::where('user_id',Auth::id())->where('address_type',$address['address_type'])->first();\n if ($addre){\n $addre->update($address);\n }else{\n Address::create($address);\n }\n }", "function geolocate($address)\r\n\t{\r\n\t\t$lat = 0;\r\n\t\t$lng = 0;\r\n\t\t\r\n\t\t$data_location = \"http://maps.google.com/maps/api/geocode/json?address=\".str_replace(\" \", \"+\", $address).\"&sensor=false\";\r\n\t\t\r\n\t\tif ($this->region!=\"\" && strlen($this->region)==2) { $data_location .= \"&region=\".$this->region; }\r\n\t\t$data = file_get_contents($data_location);\r\n\t\tusleep(200000);\r\n\t\t\r\n\t\t// turn this on to see if we are being blocked\r\n\t\t// echo $data;\r\n\t\t\r\n\t\t$data = json_decode($data);\r\n\t\t\r\n\t\tif ($data->status==\"OK\") {\r\n\t\t\t$lat = $data->results[0]->geometry->location->lat;\r\n\t\t\t$lng = $data->results[0]->geometry->location->lng;\r\n\t\t}\r\n\t\t\r\n\t\t// concatenate lat/long coordinates\r\n\t\t$coords['lat'] = $lat;\r\n\t\t$coords['lng'] = $lng;\r\n\t\t\r\n\t\treturn $coords;\r\n\t}", "public function wc_address_book_checkout_update() {\n\n\t\tglobal $woocommerce;\n\n\t\t$name = $_POST['name'];\n\t\t$address_book = $this->get_address_book();\n\n\t\t$customer_id = get_current_user_id();\n\t\t$shipping_countries = $woocommerce->countries->get_shipping_countries();\n\n\t\t$response = array();\n\n\t\t// Get address field values.\n\t\tif ( 'add_new' !== $name ) {\n\n\t\t\tforeach ( $address_book[ $name ] as $field => $value ) {\n\n\t\t\t\t$field = preg_replace( '/^[^_]*_\\s*/', 'shipping_', $field );\n\n\t\t\t\t$response[ $field ] = $value;\n\t\t\t}\n\t\t} else {\n\n\t\t\t// If only one country is available for shipping, include it in the blank form.\n\t\t\tif ( 1 === count( $shipping_countries ) ) {\n\t\t\t\t$response['shipping_country'] = key( $shipping_countries );\n\t\t\t}\n\t\t}\n\n\t\techo wp_json_encode( $response );\n\n\t\tdie();\n\t}", "function bmlt_geocode (\t$in_address,\t///< The address, in a single string, to be sent to the geocoder.\n $in_isPublished ///< TRUE, if the meeting is published.\n )\n {\n global $region_bias;\n $ret = null;\n $status = null;\n $uri = 'https://maps.googleapis.com/maps/api/geocode/xml?key=' . $GLOBALS['gkey'] . '&address='.urlencode ( $in_address );\n if ( $region_bias )\n {\n $uri .= '&region='.strtolower(trim($region_bias));\n }\n\n $xml = simplexml_load_file ( $uri );\n \n if ( isset ( $xml ) )\n {\n if ( $xml->status == 'OK' )\n {\n $ret = array ( 'original' => $in_address, 'result' => bmlt_parse_gecode_result ( $xml->result, $in_isPublished ) );\n $retry = false;\n }\n elseif ( ( $xml->status == 'OVER_QUERY_LIMIT' ) || ($xml->status == 'OVER_DAILY_LIMIT') )\n {\n die ( 'Over Google Maps API Query Limit' . \". \" . $xml->error_message );\n }\n elseif ($xml->status == 'REQUEST_DENIED')\n {\n die ( 'Problem with API Key ('.htmlspecialchars ( $uri ).')' . \". \" . $xml->error_message );\n }\n elseif ($xml->status == 'INVALID_REQUEST')\n {\n die ( 'Invalid Geocode URL ('.htmlspecialchars ( $uri ).')' . \". \" . $xml->error_message );\n }\n }\n return $ret;\n }", "public function update(Address $address)\n\t{\n\t\t//\n\t}", "public function extractPostCodeForShippingRequest($addressObject)\n {\n $idState = $addressObject->id_state;\n $countryName = pSQL($addressObject->country);\n\n $regionName = State::getNameById($idState);\n\n $address = array(\n 'country' => $countryName,\n 'region' => $regionName,\n 'city' => pSQL($addressObject->city),\n 'address' => pSQL($addressObject->address1) . (($addressObject->address2) ? ' ' . pSQL($addressObject->address2) : ''),\n 'postcode' => pSQL($addressObject->postcode)\n );\n\n\n if ($this->isEnabledAutocompleteForPostcode($countryName)) {\n $dpdPostcodeAddress = new DpdGeopostDpdPostcodeAddress();\n $dpdPostcodeAddress->loadDpdAddressByAddressId($addressObject->id);\n $currentHash = $this->generateAddressHash($address);\n\n if (\n !empty($dpdPostcodeAddress->id_address) &&\n $currentHash == $dpdPostcodeAddress->hash\n ) {\n return $dpdPostcodeAddress->auto_postcode;\n }\n\n if (\n empty($dpdPostcodeAddress->id_address) ||\n $currentHash != $dpdPostcodeAddress->hash\n ) {\n $postcodeRelevance = new stdClass();\n $postCode = $this->search($address, $postcodeRelevance);\n\n $dpdPostcodeAddress->auto_postcode = $postCode;\n $dpdPostcodeAddress->id_address = $addressObject->id;\n\n $dpdPostcodeAddress->hash = $currentHash;\n if ($this->isValid($postCode, $postcodeRelevance)) {\n $dpdPostcodeAddress->relevance = 1;\n\n $addressObject->postcode = $postCode;\n $addressObject->save();\n\n } else {\n $dpdPostcodeAddress->relevance = 0;\n }\n\n if(!empty($dpdPostcodeAddress->dpd_postcode_id)){\n $dpdPostcodeAddress->id = $dpdPostcodeAddress->dpd_postcode_id;\n }\n $dpdPostcodeAddress->save();\n } else {\n return $dpdPostcodeAddress->auto_postcode;\n }\n\n\n } else {\n $postCode = $addressObject->postcode;\n }\n\n return $postCode;\n }", "private function doSearch($address = null) {\n\n\t\t// clear any ambiguous address we have in the session\n\t\t$this->Session->delete('addressChoices');\n\t\t\n\t\t// Check to make sure they've entered an address before we do a lookup\n\t\t$rawSearchAddress = trim($address);\n\n\t\tif ($rawSearchAddress == 'Enter address' || empty($rawSearchAddress)) {\n\t\t\t$this->Session->setFlash(\"Please enter an address in the search box.\");\n\t\t\t$this->redirect(array('action' => 'index'));\n\t\t}\n\t\t\n\t\t// Check to see if they've entered at least an alpha char.\n\t\t// Looking up just numbers on google returns odd results.\n\t\t/*\n\t\t\tTODO: This sort of validation really needs to be moved to the model!\n\t\t\t* We can use the $validate property of the model class\n\t\t*/\n\t\tif (!preg_match('/[a-zA-Z]+/', $address)) {\n\t\t\t$this->Session->setFlash('That does not appear to be a proper address. Please try again.');\n\t\t\t$this->redirect(array('action' => 'index'));\n\t\t}\n\t\t\n\t\t$searchAddress = ucwords($address);\n\t\t$zone = $this->Zone->get_zone($searchAddress);\n\t\n\t\t// Try to get a result first before adding London ON, etc. to the end (below)\n\t\t$zone_name = null;\n\t\tif( isset($zone[0]) ) {\n\t\t\t$zone_name = $zone[0]->zone_name;\n\t\t\t$searchAddress = $zone[0]->address;\n\t\t}\n\t\n\t\tif( !$zone_name ) {\n\t\t\t//if zone is empty, try to append city\n\t\t\t$zone_name = null;\n\t\t\t$cities = array('London', 'Byron', 'Lambeth', 'Hyde Park');\n\t\t\n\t\t\tforeach($cities as $city) {\n\t\t\t\tif (empty($zone)) {\n\t\t\t\t\t$specificSearchAddress = $searchAddress . ', ' . $city . ', ON';\n\t\t\t\t\t$zone = $this->Zone->get_zone($specificSearchAddress);\n\t\t\n\t\t\t\t\t$zone_name = null;\n\t\t\t\t\tif( isset($zone[0]) ) {\n\t\t\t\t\t\t$zone_name = $zone[0]->zone_name;\n\t\t\t\t\t\t$searchAddress = $zone[0]->address;\n\t\t\t\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t}\n\t\n\t\tif ($this->Zone->are_results_ambiguous()) {\n\t\t\t// pass array to view so we can display it there\n\t\t\t$this->Session->write('addressChoices', $zone);\n\n\t\t\t// redirect them back to search page with their search filled in\n\t\t\t$this->redirect(array('action' => 'index', '?' => array('a' => $rawSearchAddress)));\n\t\t}\n \n\t\tif(!empty($zone_name)) {\n\t\t\t$this->UserData->write($searchAddress, $zone_name);\n\t\t\t$this->redirect(array(\"controller\" => \"zones\", \"action\" => \"view\", $zone_name));\n\t\t} else {\n\t\t\t$this->Session->setFlash(\"Your address was not found. Please verify that you have typed it correctly and search again.\");\n\t\t}\t\t\t\n\t}", "public function geocode($value);", "function form_map($name, $value, $parameters, $cp) {\n\n if (!$value)\n $value = get_setting('website_address');\n\n Layout::addJavascript(\"\n\n var map, stepDisplay, marker, old_position, old_address = '\" . $value . \"';\n\n function initMap(){\n\n $('#map_canvas').css('height', '500px');\n $('#reset_map').show();\n\n var myOptions = { zoom: 13, mapTypeId: google.maps.MapTypeId.ROADMAP, };\n map = new google.maps.Map(document.getElementById('map_canvas'), myOptions );\n\n address = $('#addr').val()\n geocoder = new google.maps.Geocoder();\n geocoder.geocode( { 'address': address}, function(results, status) {\n var location = results[0].geometry.location\n old_position = location\n map.setCenter( location );\n addMarker( location )\n });\n\n }\n\n function resetLocation(){\n $('#addr').val( old_address )\n address = old_address\n geocoder = new google.maps.Geocoder();\n geocoder.geocode( { 'address': address}, function(results, status) {\n var location = results[0].geometry.location\n old_position = location\n map.setCenter( location );\n addMarker( location )\n });\n }\n\n function addMarker( location ){\n if( marker )\n marker.setMap(null)\n marker = new google.maps.Marker({ position: location, map: map, draggable: true });\n\n google.maps.event.addListener(marker, 'dragstart', function() {\n //map.closeInfoWindow();\n });\n\n google.maps.event.addListener(marker, 'dragend', function(event) {\n updateLocation( event.latLng )\n });\n }\n\n function updateLocation(location){\n var p = location.toString()\n var latlngStr = p.split(',');\n var lat = latlngStr[0].substr(1)\n var lng = latlngStr[1].substr(0,latlngStr[1].length-1)\n\n $('#location').val(lat + ',' + lng);\n\n geocoder.geocode({'latLng': location}, function(results, status) {\n if (status == google.maps.GeocoderStatus.OK)\n if (results[0]){\n\n var address = results[0].formatted_address\n var address_components = new Array();\n for( var i in results[0].address_components )\n address_components[results[0].address_components[i].types] = results[0].address_components[i].long_name\n\n $('#addr').val(results[0].formatted_address)\n }\n\n });\n\n }\n\n \");\n\n $html = '<script type=\"text/javascript\" src=\"http://maps.google.com/maps/api/js?sensor=false\"></script>';\n $html .= '<div id=\"map_canvas\"><a href=\"javascript:initMap();\">Click to init the map</a></div>';\n $html .= '<input type=\"hidden\" id=\"location\" name=\"extra3\"/><br>address <input type=\"text\" name=\"extra2\" style=\"width:76%;\" id=\"addr\" value=\"' . $value . '\" onchange=\"initMap()\"/> <a href=\"javascript:initMap();\">Refresh</a>';\n $html .= '<div id=\"reset_map\" style=\"display:none;\"><br><a href=\"javascript:resetLocation();\">Reset Address</a><br></div>';\n return $html;\n }", "public function geocoding($address) \n {\n $encodeAddress = urlencode($address);\n $url = \"http://maps.google.com/maps/geo?q=\".$encodeAddress.\"&output=csv&key=\".$this->googleMapKey;\n \n if(function_exists('curl_init')) {\n $data = $this->getContent($url);\n } else {\n $data = file_get_contents($url);\n }\n \n\t\t$csvSplit = preg_split(\"/,/\",$data);\n $status = $csvSplit[0];\n\n if (strcmp($status, \"200\") == 0) {\n $return = $csvSplit; // successful geocode, $precision = $csvSplit[1],$lat = $csvSplit[2],$lng = $csvSplit[3];\n } else {\n $return = null; // failure to geocode\n }\n\n return $return;\n }", "private function ignoreAddressValidation()\n {\n $this->_quote->getBillingAddress()->setShouldIgnoreValidation(true);\n if (!$this->_quote->getIsVirtual()) {\n $this->_quote->getShippingAddress()->setShouldIgnoreValidation(true);\n if (!$this->_config->getValue('requireBillingAddress')\n && !$this->_quote->getBillingAddress()->getEmail()\n ) {\n $this->_quote->getBillingAddress()->setSameAsBilling(1);\n }\n }\n }", "public function setAddress($value)\n {\n $this->_address = $value;\n }", "private function SaveBillingAddress()\n\t{\n\t\tif(isset($_SESSION['CHECKOUT']['CHECKOUT_TYPE']) && $_SESSION['CHECKOUT']['CHECKOUT_TYPE'] == 'express') {\n\t\t\t$redirectOnError = getConfig('ShopPath').'/checkout.php?action=express';\n\t\t}\n\t\telse {\n\t\t\t$redirectOnError = getConfig('ShopPath').'/checkout.php?action=checkout';\n\t\t}\n\n\t\t// If guest checkout is not enabled and the customer isn't signed in then send the customer\n\t\t// back to the beginning of the checkout process.\n\t\tif(!GetConfig('GuestCheckoutEnabled') && !CustomerIsSignedIn()) {\n\t\t\tredirect($redirectOnError);\n\t\t}\n\n\t\t// If the customer isn't signed in then they've just entered an address that we need to validate\n\t\tif(!CustomerIsSignedIn()) {\n\t\t\t$errors = array();\n\t\t\t// An invalid address was entered, show the form again\n\t\t\t$addressDetails = $this->ValidateGuestCheckoutAddress('billing', $errors);\n\t\t\tif(!$addressDetails) {\n\t\t\t\t$this->ChooseBillingAddress($errors);\n\t\t\t\treturn;\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\t// We've just selected an address\n\t\t\tif(isset($_GET['address_id'])) {\n\t\t\t\t$addressDetails = (int)$_GET['address_id'];\n\t\t\t}\n\t\t}\n\n\t\t// There was a problem saving the selected billing address\n\t\tif(!$this->SetOrderBillingAddress($addressDetails)) {\n\t\t\t$this->ChooseBillingAddress();\n\t\t\treturn;\n\t\t}\n\n\t\t// If we're automatically creating accounts for customers then we need to save those details too\n\t\tif(!CustomerIsSignedIn() && GetConfig('GuestCheckoutCreateAccounts')) {\n\t\t\t$password = substr(md5(uniqid(true)), 0, 8);\n\t\t\t$autoAccount = 1;\n\t\t\t$_SESSION['CHECKOUT']['CREATE_ACCOUNT'] = 1;\n\t\t\t$_SESSION['CHECKOUT']['ACCOUNT_DETAILS'] = array(\n\t\t\t\t'email' => $addressDetails['shipemail'],\n\t\t\t\t'password' => $password,\n\t\t\t\t'firstname' => $addressDetails['shipfirstname'],\n\t\t\t\t'lastname' => $addressDetails['shiplastname'],\n\t\t\t\t'company' => '',\n\t\t\t\t'phone' => $addressDetails['shipphone'],\n\t\t\t\t'autoAccount' => $autoAccount\n\t\t\t);\n\t\t}\n\n\t\tif($this->getQuote()->isDigital()) {\n\t\t\t@ob_end_clean();\n\t\t\theader(sprintf(\"location:%s/checkout.php?action=confirm_order\", $GLOBALS['ShopPath']));\n\t\t}\n\t\telse {\n\t\t\t// Are we shipping to the same address?\n\t\t\tif(isset($_POST['ship_to_billing'])) {\n\t\t\t\tif(!$this->SetOrderShippingAddress($addressDetails, true)) {\n\t\t\t\t\t$this->ChooseShippingAddress();\n\t\t\t\t\treturn;\n\t\t\t\t}\n\n\t\t\t\t// Now they need to choose the shipping provider for their order\n\t\t\t\t@ob_end_clean();\n\t\t\t\theader(\"Location: \".GetConfig('ShopPath').\"/checkout.php?action=choose_shipper\");\n\t\t\t\texit;\n\t\t\t}\n\n\t\t\t// Otherwise, we just move to the next step\n\t\t\t@ob_end_clean();\n\t\t\theader(sprintf(\"location:%s/checkout.php?action=choose_shipping_address\", $GLOBALS['ShopPath']));\n\t\t}\n\t\texit;\n\t}", "protected function postSave($id, $addr, $request)\n {\n $messages = [\n 'required' => 'Please enter a valid address and click \"Lookup Addresses\"',\n ];\n $rules = [];\n $languages = \\App\\Language::all();\n foreach ($languages as $l) {\n $rules['addr_' . $l->code] = 'required';\n }\n\n $validator = \\Validator::make($request->all(), $rules, $messages);\n if ($validator->fails()) {\n return \\Redirect::to('admin/church/' . $id . '/address/' . (($addr->id) ? $addr->id : 0))\n ->withInput()\n ->withErrors($validator);\n } else {\n\n if ($addr->id < 1) {\n $addr->church_id = $id;\n $addr->save();\n }\n\n foreach ($languages as $l) {\n $label = \\App\\ChurchAddressLabel::where('church_address_id', $addr->id)\n ->where('language', $l->code)\n ->first();\n if (!$label) {\n $label = new \\App\\ChurchAddressLabel;\n $label->church_address_id = $addr->id;\n $label->language = $l->code;\n }\n $addrField = 'addr_' . $l->code;\n $label->addr = $request->$addrField;\n $label->save();\n }\n\n $addr->updateLatLongFromAddress();\n if ($request->primary) {\n $addr->makePrimary();\n } else {\n $addr->ifOnlyMakePrimary();\n }\n\n // redirect\n $request->session()->flash('message', 'Address saved!');\n return \\Redirect::to('admin/church/edit/' . $id);\n }\n }", "public function validate()\n {\n if ($this->addressA->getCountryCode() !== $this->addressB->getCountryCode()) {\n $this->invalidate();\n return false;\n }\n\n if ($this->addressA->getZip() !== $this->addressB->getZip()) {\n $this->invalidate();\n return false;\n }\n\n if ($this->addressA->getCity() !== $this->addressB->getCity()) {\n $this->invalidate();\n return false;\n }\n\n if ($this->addressA->getStreet() !== $this->addressB->getStreet()) {\n $this->invalidate();\n return false;\n }\n\n if ($this->addressA->getAddressAdditional() !== $this->addressB->getAddressAdditional()) {\n $this->invalidate();\n return false;\n }\n\n return true;\n }", "public function setMainAddress($data){\n\t\tglobal $dbh;\n\t\t$fields = array(\n\t\t\t\"nombre\",\n\t\t\t\"receptorNombre\",\n\t\t\t\"receptorApellido\",\n\t\t\t\"nombreEmpresa\",\n\t\t\t\"facturacion\",\n\t\t\t\"principal\",\n\t\t\t\"idCliente\",\n\t\t\t\"direccion\",\n\t\t\t\"fono\",\n\t\t\t\"cel\",\n\t\t\t\"idZona\",\n\t\t\t\"id\"\n\t\t);\n\t\t$query = \"UPDATE direccion SET nombre=?,receptorNombre=?,receptorApellido=?,nombreEmpresa=?,facturacion=?,principal=?,idCliente=?,direccion=?,fono=?,cel=?,idZona=? WHERE id=?;\";\n\t\t$update = array();\n\t\t$old = $this->getMainAddress();\n\t\tif( $data!=null && is_array($data) ){\n\t\t\tforeach( $fields as $field ){\n\t\t\t\t$update[$field] = null;\n\t\t\t\tif( isset($data[$field]) && !empty($data[$field]) ){\n\t\t\t\t\t$update[$field] = $data[$field];\n\t\t\t\t} else {\n\t\t\t\t\t$update[$field] = $old[$field];\n\t\t\t\t}\n\t\t\t}\n\t\t\t$res = $dbh->query($query,$update);\n\t\t\treturn $res;\n\t\t}\n\t\treturn false;\n\t}", "public function modifyAddress($formdata) {\r\n\r\n\t\t\t//Make sure this is a user before continuing\r\n\t\t\tif ($_SESSION['CID'] > 0) {\r\n\r\n\t\t\t\t//Instantiate our form validator, and validate the user input\r\n\t\t\t\t$valid = new Validate($formdata);\r\n\t\t\t\t$valid->name('first')->required(\"You must provide your first name.\");\r\n\t\t\t\t$valid->name('last')->required(\"You must provide your last name.\");\r\n\t\t\t\t$valid->name('phone')->required(\"You must provide your phone number.\")->phone(\"The number you have provided does not match a valid phone number format.\");\r\n\t\t\t\t$formdata['phone'] = $valid->getParsed(); //Get the phone number parsed in our format\r\n\t\t\t\t$valid->name('address1')->required(\"You must provide a street address.\");\r\n\t\t\t\t$valid->name('city')->required(\"You must provide a city.\")->minLength(2, \"The city you have provided is not valid.\");\r\n\t\t\t\t$valid->name('state')->requiredWhenCountryHasZones(\"You must provide a state.\");\r\n\t\t\t\t$valid->name('zip')->required(\"You must provide a zip code.\")->minLength(5, \"Valid zip codes contain 5 or more digits.\")->maxLength(10, \"The zip code you entered is invalid.\");\r\n\t\t\t\t$valid->name('country')->required(\"You must provide a country.\");\r\n\t\t\t\t$validate = $valid->validate();\r\n\r\n\t\t\t\t$formdata['default_shipping'] = ($formdata['default_shipping'] == 1 ? 1 : 0);\r\n\t\t\t\t$formdata['default_billing'] = ($formdata['default_billing'] == 1 ? 1 : 0);\r\n\r\n\t\t\t\t//If our form validates correctly so far\r\n\t\t\t\tif (empty($validate)) {\r\n\r\n\r\n\t\t\t\t\t//We need to check if the state is required, or if they are in a country where we should omit the state\r\n\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"SELECT COUNT(*) AS total FROM bs_zones WHERE countries_id = ?\");\r\n\t\t\t\t\t$sql->execute(array($formdata['country']));\r\n\t\t\t\t\t$result = $sql->fetch(PDO::FETCH_ASSOC);\r\n\r\n\t\t\t\t\tif ($result['total'] <= 0) {\r\n\t\t\t\t\t\t$formdata['state'] = NULL;\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\t//We need to see if a specific address edit id was given to us from the form. If an edit id is present,\r\n\t\t\t\t\t//we are updating that address. If the edit id is 0, we are inserting a new address\r\n\t\t\t\t\tif (!empty($formdata['address_id'])) {\r\n\r\n\t\t\t\t\t\t//Check to make sure the address exists\r\n\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"SELECT COUNT(id) AS total FROM bs_customer_addresses\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tWHERE public_id = ? AND cid = ?\");\r\n\t\t\t\t\t\t$sql->execute(array($formdata['address_id'], $_SESSION['CID']));\r\n\t\t\t\t\t\t$row = $sql->fetch(PDO::FETCH_ASSOC);\r\n\r\n\r\n\t\t\t\t\t\t//If the address does exist, and it belongs to this customer, let them update it\r\n\t\t\t\t\t\tif ($row['total'] > 0) {\r\n\r\n\t\t\t\t\t\t\t//If the customer is setting this as a default address, we first have to disable any other\r\n\t\t\t\t\t\t\t//defaults on their account of the same type\r\n\t\t\t\t\t\t\tif ($formdata['default_shipping'] == 1) {\r\n\t\t\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"UPDATE bs_customer_addresses SET default_shipping = 0 WHERE cid = ?\");\r\n\t\t\t\t\t\t\t\t$sql->execute(array($_SESSION['CID']));\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tif ($formdata['default_billing'] == 1) {\r\n\t\t\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"UPDATE bs_customer_addresses SET default_billing = 0 WHERE cid = ?\");\r\n\t\t\t\t\t\t\t\t$sql->execute(array($_SESSION['CID']));\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t//Update the address\r\n\t\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"UPDATE bs_customer_addresses\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tSET\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcompany = :company,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tfirst_name = :first,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tlast_name = :last,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstreet_address = :address1,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tsuburb = :address2,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tpostcode = :zip,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcity = :city,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstate = :state,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcountry = :country,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tphone = :phone,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tfax = :fax,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tdefault_shipping = :default_shipping,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tdefault_billing = :default_billing\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tWHERE cid = :cid\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tAND public_id = :id\");\r\n\r\n\t\t\t\t\t\t\t$sql->execute(array(\":cid\" => $_SESSION['CID'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":id\" => $formdata['address_id'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":company\" => $formdata['company'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":first\" => $formdata['first'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":last\" => $formdata['last'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":address1\" => $formdata['address1'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":address2\" => $formdata['address2'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":zip\" => $formdata['zip'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":city\" => $formdata['city'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":state\" => $formdata['state'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":country\" => $formdata['country'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":phone\" => $formdata['phone'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":fax\" => $formdata['fax'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":default_shipping\" => $formdata['default_shipping'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":default_billing\" => $formdata['default_billing']));\r\n\r\n\t\t\t\t\t\t\t$_SESSION['successes'][] = \"Your address has successfully been updated.\";\r\n\r\n\t\t\t\t\t\t\t//Redirect them\r\n\t\t\t\t\t\t\t$link = new Page('my-account');\r\n\t\t\t\t\t\t\theader($_SERVER['SERVER_PROTOCOL'] . ' 302 Found', true, 302);\r\n\t\t\t\t\t\t\theader(\"Location: \".$link->getUrl());\r\n\t\t\t\t\t\t\texit;\r\n\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t//The address doesn't exist, or doesn't belong to this customer. Give them an unknown error\r\n\t\t\t\t\t\t\t$_SESSION['errors'][] = \"Your address could not be updated; An unknown error was encountered.\";\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t//Inserting a new address\r\n\t\t\t\t\t} else {\r\n\r\n\t\t\t\t\t\t//First we'll check to make sure this address isn't already on the customer's account\r\n\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"SELECT COUNT(id) AS total FROM bs_customer_addresses\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tWHERE cid = :cid\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND company = :company\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND first_name = :first\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND last_name = :last\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND street_address = :address1\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND suburb = :address2\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND postcode = :zip\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND city = :city\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND state = :state\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND country = :country\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND phone = :phone\r\n\t\t\t\t\t\t\t\t\t\t\t\t\tAND fax = :fax\");\r\n\t\t\t\t\t\t$sql->execute(array(\":cid\" => $_SESSION['CID'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":company\" => $formdata['company'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":first\" => $formdata['first'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":last\" => $formdata['last'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":address1\" => $formdata['address1'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":address2\" => $formdata['address2'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":zip\" => $formdata['zip'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":city\" => $formdata['city'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":state\" => $formdata['state'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":country\" => $formdata['country'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":phone\" => $formdata['phone'],\r\n\t\t\t\t\t\t\t\t\t\t\t\":fax\" => $formdata['fax']));\r\n\t\t\t\t\t\t$row = $sql->fetch(PDO::FETCH_ASSOC);\r\n\r\n\t\t\t\t\t\t//Make sure this address is not already on the account\r\n\t\t\t\t\t\tif ($row['total'] <= 0 OR $row['total'] == NULL) {\r\n\t\t\t\t\t\t\t//If the customer is setting this as a default address, we first have to disable any other\r\n\t\t\t\t\t\t\t//defaults on their account of the same type\r\n\t\t\t\t\t\t\tif ($formdata['default_shipping'] == 1) {\r\n\t\t\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"UPDATE bs_customer_addresses SET default_shipping = 0 WHERE cid = ?\");\r\n\t\t\t\t\t\t\t\t$sql->execute(array($_SESSION['CID']));\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\tif ($formdata['default_billing'] == 1) {\r\n\t\t\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"UPDATE bs_customer_addresses SET default_billing = 0 WHERE cid = ?\");\r\n\t\t\t\t\t\t\t\t$sql->execute(array($_SESSION['CID']));\r\n\t\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\t$sql = Connection::getHandle()->prepare(\"INSERT INTO bs_customer_addresses\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(public_id, cid, company, first_name, last_name,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tstreet_address, suburb, postcode,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tcity, state, country, phone, fax,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tdefault_shipping, default_billing)\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tVALUES\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t(:public_id, :cid, :company, :first, :last,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t:address1, :address2, :zip,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t:city, :state, :country, :phone, :fax,\r\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t:default_shipping, :default_billing)\");\r\n\t\t\t\t\t\t\t$sql->execute(array(\":public_id\" => $this->getUniquePublicId(),\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":cid\" => $_SESSION['CID'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":company\" => $formdata['company'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":first\" => $formdata['first'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":last\" => $formdata['last'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":address1\" => $formdata['address1'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":address2\" => $formdata['address2'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":zip\" => $formdata['zip'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":city\" => $formdata['city'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":state\" => $formdata['state'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":country\" => $formdata['country'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":phone\" => $formdata['phone'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":fax\" => $formdata['fax'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":default_shipping\" => $formdata['default_shipping'],\r\n\t\t\t\t\t\t\t\t\t\t\t\t\":default_billing\" => $formdata['default_billing']));\r\n\r\n\t\t\t\t\t\t\t$_SESSION['successes'][] = \"Your address has successfully been added.\";\r\n\r\n\t\t\t\t\t\t\t//Redirect them\r\n\t\t\t\t\t\t\t$link = new Page('my-account');\r\n\t\t\t\t\t\t\theader($_SERVER['SERVER_PROTOCOL'] . ' 302 Found', true, 302);\r\n\t\t\t\t\t\t\theader(\"Location: \".$link->getUrl());\r\n\t\t\t\t\t\t\texit;\r\n\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t//This address already exists for this customer\r\n\t\t\t\t\t\t\t$_SESSION['errors'][] = \"This address already exists for your account.\";\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t//If there were validation errors\r\n\t\t\t\t} else {\r\n\r\n\t\t\t\t\tforeach($validate as $key => $error) {\r\n\t\t\t\t\t\t$_SESSION['errors'][] = $error;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t//Otherwise, they are not a user and we have an unknown error\r\n\t\t\t} else {\r\n\r\n\t\t\t\t//Check if they were updating or adding, and throw an error depending\r\n\t\t\t\tif (!empty($formdata['address_id'])) {\r\n\t\t\t\t\t$_SESSION['errors'][] = \"Your address could not be updated; An unknown error was encountered.\";\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$_SESSION['errors'][] = \"Your address could not be added; An unknown error was encountered.\";\r\n\t\t\t\t}\r\n\r\n\t\t\t}\r\n\r\n\t\t\t$_SESSION['validate'] = $formdata;\r\n\r\n\t\t\tif (!empty($formdata['address_id'])) {\r\n\t\t\t\t$_SESSION['instructions'] = \"Please click \\\"Update Address\\\" again to fix the following errors. \";\r\n\t\t\t} else {\r\n\t\t\t\t$_SESSION['instructions'] = \"Please click \\\"Add An Address\\\" again to fix the following errors. \";\r\n\t\t\t}\r\n\r\n\t\t\t//Redirect them\r\n\t\t\t$link = new Page('my-account');\r\n\t\t\theader($_SERVER['SERVER_PROTOCOL'] . ' 302 Found', true, 302);\r\n\t\t\theader(\"Location: \".$link->getUrl());\r\n\t\t\texit;\r\n\t\t}", "function geocode($address){\n \n // url encode the address\n $address = urlencode($address);\n \n // google map geocode api url\n $url = \"http://maps.google.com/maps/api/geocode/json?address={$address}\";\n \n // get the json response\n $resp_json = file_get_contents($url);\n \n // decode the json\n $resp = json_decode($resp_json, true);\n ;\n // response status will be 'OK', if able to geocode given address \n if($resp['status']=='OK'){\n \n // get the important data\n $lati = $resp['results'][0]['geometry']['location']['lat'];\n $longi = $resp['results'][0]['geometry']['location']['lng'];\n $formatted_address = $resp['results'][0]['formatted_address'];\n \n // verify if data is complete\n if($lati && $longi && $formatted_address){\n \n // put the data in the array\n $data_arr = array(); \n \n array_push(\n $data_arr, \n $lati, \n $longi, \n $formatted_address\n );\n \n return $data_arr;\n \n }else{\n return false;\n }\n \n }else{\n return false;\n }\n}", "function calculate_coords() {\n if (!empty($this->value['latitude']) && !empty($this->value['longitude'])) {\n // If there are already coordinates, there's no work for us.\n return TRUE;\n }\n // @@@ Switch to mock location object and rely on location more?\n\n if ($this->options['type'] == 'postal' || $this->options['type'] == 'postal_default') {\n // Force default for country.\n if ($this->options['type'] == 'postal_default') {\n $this->value['country'] = variable_get('site_default_country', 'us');\n }\n\n // Zip code lookup.\n if (!empty($this->value['postal_code']) && !empty($this->value['country'])) {\n $coord = location_latlon_rough($this->value);\n if ($coord) {\n $this->value['latitude'] = $coord['lat'];\n $this->value['longitude'] = $coord['lon'];\n }\n else {\n return false;\n }\n }\n else {\n // @@@ Implement full address lookup?\n return false;\n }\n }\n if (empty($this->value['latitude']) || empty($this->value['longitude'])) {\n return false;\n }\n return true;\n }", "public function beforeSave() {\n $userId = isset(Yii::app()->user) ? Yii::app()->user->id : '';\n $this->address = CommonProcess::createAddressString(\n $this->province_id, $this->district_id, $this->ward_id, $this->street_id, $this->house_numbers);\n $this->address_vi = CommonProcess::removeSign(\n $this->first_name . ' ' .\n $this->username . ' ' .\n $this->phone . ' ' .\n $this->email . ' ' .\n $this->address);\n $this->formatDate('birthday');\n $this->formatDate('date_of_issue');\n $this->formatDate('date_in');\n// // Format birthday value\n// $date = $this->birthday;\n// $this->birthday = CommonProcess::convertDateTimeToMySqlFormat(\n// $date, DomainConst::DATE_FORMAT_3);\n// if (empty($this->birthday)) {\n// $this->birthday = CommonProcess::convertDateTimeToMySqlFormat(\n// $date, DomainConst::DATE_FORMAT_4);\n// }\n// if (empty($this->birthday)) {\n// $this->birthday = $date;\n// }\n if ($this->isNewRecord) { // Add\n // Handle password\n $this->temp_password = CommonProcess::generateTempPassword();\n $this->password_hash = CommonProcess::hashPassword(\n $this->password_hash, $this->temp_password);\n\n // Handle username\n if ($this->role_id == Roles::getRoleByName(Roles::ROLE_CUSTOMER)->id) {\n // Do nothing\n } else {\n $this->username = self::generateUsername($this->first_name);\n }\n \n // Handle created by\n if (empty($this->created_by)) {\n $this->created_by = $userId;\n }\n // Handle created date\n $this->created_date = CommonProcess::getCurrentDateTimeWithMySqlFormat();\n } else { // Update\n }\n return parent::beforeSave();\n }", "private function convertAddressToGeodata($orga, $address) {\n $apiKey = $this->getContainer()->getParameter('googleMapsApiKey');\n $api = self::googleApiUrl . \"?key=$apiKey\";\n $geo = file_get_contents(\"$api&address=\".urlencode($address) . '&sensor=false');\n\n // Convert the JSON to an array\n $geo = json_decode($geo, true);\n //die(var_dump($geo['status']));\n if ($geo['status'] == 'OK') {\n // Get Lat & Long\n $latitude = $geo['results'][0]['geometry']['location']['lat'];\n $longitude = $geo['results'][0]['geometry']['location']['lng'];\n \n $orga->setGeolocation($latitude .','.$longitude);\n }\n }", "function get_map_coordinates($address, $force_refresh = false) {\n\n $address_hash = md5( $address );\n\n $coordinates = get_transient( $address_hash );\n\n if ($force_refresh || $coordinates === false) {\n\n \t$args = array( 'address' => urlencode( $address ), 'sensor' => 'false' );\n \t$url = add_query_arg( $args, 'http://maps.googleapis.com/maps/api/geocode/json' );\n \t$response \t= wp_remote_get( $url );\n\n \tif( is_wp_error( $response ) )\n \t\treturn;\n\n \t$pmc_data = wp_remote_retrieve_body( $response );\n\n \tif( is_wp_error( $pmc_data ) )\n \t\treturn;\n\n\t\tif ( $response['response']['code'] == 200 ) {\n\n\t\t\t$pmc_data = json_decode( $pmc_data );\n\n\t\t\tif ( $pmc_data->status === 'OK' ) {\n\n\t\t\t \t$coordinates = $pmc_data->results[0]->geometry->location;\n\n\t\t\t \t$cache_value['lat'] \t= $coordinates->lat;\n\t\t\t \t$cache_value['lng'] \t= $coordinates->lng;\n\t\t\t \t$cache_value['address'] = (string) $pmc_data->results[0]->formatted_address;\n\n\t\t\t \t// cache coordinates for 3 months\n\t\t\t \tset_transient($address_hash, $cache_value, 3600*24*30*3);\n\t\t\t \t$pmc_data = $cache_value;\n\n\t\t\t} elseif ( $pmc_data->status === 'ZERO_RESULTS' ) {\n\t\t\t \treturn __( 'No location found for the entered address.', 'pw-maps' );\n\t\t\t} elseif( $pmc_data->status === 'INVALID_REQUEST' ) {\n\t\t\t \treturn __( 'Invalid request. Did you enter an address?', 'pw-maps' );\n\t\t\t} else {\n\t\t\t\treturn __( 'Something went wrong while retrieving your map, please ensure you have entered the short code correctly.', 'pw-maps' );\n\t\t\t}\n\n\t\t} else {\n\t\t \treturn __( 'Unable to contact Google API service.', 'pw-maps' );\n\t\t}\n\n } else {\n // return cached results\n $pmc_data = $coordinates;\n }\n\n return $pmc_data;\n}", "public function getCoordinates(Address $address)\n {\n $type = NULL;\n\n //set latitude and longitude of new user\n //remove bis, ter from address street for localization research because it makes the research inaccurate \n $base = strtolower(trim($address->getStreet1().' '.$address->getZipCity()->getZipCode().' '.$address->getZipCity()->getCity())) ; \n \n if(preg_match('/^\\d+/',$base)){\n $type = 'housenumber';\n }elseif(preg_match('/^hameau/',$base)){\n $type = 'locality';\n }elseif(preg_match('/^(allée|allee|rue|impasse|square|avenue)/',$base)){\n $type = 'street';\n }\n\n //replace strings for better score\n $base = preg_replace('/\\s(bis|ter)\\s/',' ',$base);\n $base = preg_replace('/^(\\d+)(bis|ter)\\s/','${1} ',$base);\n $base = preg_replace('/\\,/',' ',$base);\n $base = preg_replace('/\\s(st)e?\\s/',' saint ',$base);\n $base = preg_replace('/\\s(dr)\\s/',' docteur ',$base);\n $base = preg_replace('/\\s(jo|j\\.o)\\s/',' jeux olympiques ',$base);\n\n $arrayParams = array( \n 'q' => $base,\n //'postcode' => $address->getZipCity()->getZipCode(),\n 'lat'=>'45.19251',\n 'lon'=>'5.72756',\n 'limit' => 2 \n ); \n if($type){\n $arrayParams['type'] = $type;\n }\n\n $res = $this->api->get('https://api-adresse.data.gouv.fr/','search/',$arrayParams);\n\n if($res['code'] == 200){ \n $features = $res['results']['features']; \n\n if( count($features) > 1){ \n if($features[0]['properties']['score'] > $features[1]['properties']['score'] ){\n $location = $features[0]; \n }else{\n $location = $features[1]; \n }\n }elseif(count($features) == 1){ \n $location = $features[0]; \n }else{\n return array('latitude'=>NULL ,'longitude'=>NULL, 'closest'=>array('label'=>'Aucune'));\n } \n\n $score = $location['properties']['score'];\n if($score <= 0.67){ \n if($score >= 0.60 && isset($location['properties']['oldcity'])){// if the address matches a former deprecated city name\n return array('latitude'=>$location['geometry']['coordinates'][1] ,'longitude'=>$location['geometry']['coordinates'][0]);\n }\n if($score >= 0.58){\n $similarityStreet = similar_text(strtolower($address->getStreet1()),strtolower($location['properties']['name']),$prec);\n if(! ($location['properties']['type'] == 'municipality')){//if municipality, name is city\n if($prec >= 50){\n return array('latitude'=>$location['geometry']['coordinates'][1] ,'longitude'=>$location['geometry']['coordinates'][0]);\n }\n }\n }\n return array('latitude'=>NULL ,'longitude'=>NULL,'closest' => $location['properties']);\n }else{\n return array('latitude'=>$location['geometry']['coordinates'][1] ,'longitude'=>$location['geometry']['coordinates'][0]);\n }\n }else{\n throw new \\Exception('geolocalization_api_failed : '.$res['results']['description']);\n }\n\n }", "public function setAddress($address)\n {\n if (!is_string($address) && ($address !== null)) {\n throw GeocodingException::invalidGeocoderRequestAddress();\n }\n\n $this->address = $address;\n }", "function getGeo($address) {\n\t\tif(!empty($address)){\n\t\t\t//build a string with each part of the address\n\t $formattedAddress = str_replace(' ','+',$address);\n\t\t\t//Send request and receive json data by address\n\t\t\t$geocodeFromAddr = file_get_contents('http://maps.googleapis.com/maps/api/geocode/json?address='.urlencode($formattedAddress).'&sensor=false');\n\t\t\t$output = json_decode($geocodeFromAddr);\n\t\t\t//Check if it was a valid address\n\t\t\tif(empty($output->results)) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t\t//Get latitude and longitute from json data\n\t\t\t$geocode['lat'] = $output->results[0]->geometry->location->lat;\n\t\t\t$geocode['lng'] = $output->results[0]->geometry->location->lng;\n\t\t\t$address_data = $output->results[0]->address_components;\n\t\t\tfor ($i = 0; $i < sizeof($address_data); $i++) {\n\t\t\t\tif ($address_data[$i]->types[0] == \"locality\") {\n\t\t\t\t\t$geocode['city'] = $address_data[$i]->long_name;\n\t\t\t\t}\n\t\t\t\tif ($address_data[$i]->types[0] == \"administrative_area_level_1\") {\n\t\t\t\t\t$geocode['state'] = $address_data[$i]->long_name;\n\t\t\t\t}\n\t\t\t}\n\t\t\t//Return latitude, longitude, city, and state of the given address\n\t\t\tif(!empty($geocode) && !empty($geocode['city']) && !empty($geocode['state'])){\n\t\t\t\treturn $geocode;\n\t\t\t}else{\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}else{\n\t\t\treturn false;\n\t\t}\n\t}", "private function setPostalCode()\n {\n \tif ( ! isset( $_POST['postal_code'] ) ) {\n \t\t$this->data['error']['postal_code'] = 'Please provide your postal or zip code.';\n $this->error = true;\n return;\n }\n \n $pc = trim( $_POST['postal_code'] );\n\t\n \n // Make sure the country is set\n if ( ! isset( $this->data['country'] ) ) {\n $pc_obj = new PostalCode( $pc );\n if ( $pc_obj->isValid() ) {\n $this->data['postal_code'] = $pc_obj->get();\n return;\n }\n \n $zip_obj = new ZipCode( $pc );\n if ( $zip_obj->isValid() ) {\n $this->data['postal_code'] = $zip_obj->get();\n return;\n }\n }\n \n if ( $this->data['country'] == 'CA' ) {\n $pc_obj = new PostalCode( $pc );\n if ( ! $pc_obj->isValid() ) {\n\t\t\t\t$this->data['error']['postal_code'] = 'Please provide a valid postal code.';\n $this->error = true;\n return;\n }\n $this->data['postal_code'] = $pc_obj->get();\n }\n elseif ( $this->data['country'] == 'US' ) {\n $zip_obj = new ZipCode( $pc );\n if ( ! $zip_obj->isValid() ) {\n\t\t\t\t$this->data['error']['postal_code'] = 'Please provide a valid zip code.';\n $this->error = true;\n return;\n }\n $this->data['postal_code'] = $zip_obj->get();\n }\n }", "function geocode($address){\n \n // url encode the address\n $address = urlencode($address);\n \n // google map geocode api url\n $url = \"https://maps.google.com/maps/api/geocode/json?address=\".$address.\"&key=AIzaSyBUmXudJDRuXR6ZiUxuiskGnf13pwTvAa0\";\n \n // get the json response\n $resp_json = file_get_contents($url);\n \n // decode the json\n $resp = json_decode($resp_json, true);\n \n // response status will be 'OK', if able to geocode given address \n if($resp['status']=='OK'){\n \n // get the important data\n $lati = $resp['results'][0]['geometry']['location']['lat'];\n $longi = $resp['results'][0]['geometry']['location']['lng'];\n $formatted_address = $resp['results'][0]['formatted_address'];\n \n // verify if data is complete\n if($lati && $longi && $formatted_address){\n \n // put the data in the array\n $data_arr = array(); \n \n array_push(\n $data_arr,\n $lati, \n $longi, \n $formatted_address\n );\n \n return $data_arr;\n \n }else{\n return false;\n }\n \n }else{\n return false;\n }\n }", "public function updateAction()\n {\n /**\n * Fetch given address hash\n */\n $addressHash = $this->getRequest()->getParam('address_key');\n\n /**\n * Only if hash were given\n */\n if ( $addressHash ) {\n\n /**\n * Fetch all addresses in session\n */\n $allAddresses = Mage::getSingleton('core/session')->getKlarnaAddresses();\n\n /**\n * Look for a matching hash\n */\n foreach ($allAddresses as $address) {\n if ( $address['hash'] == $addressHash ) {\n\n /**\n * Fetch quote\n */\n $quote = Mage::getModel('checkout/cart')->getQuote();\n\n /**\n * Update billing address\n */\n if ( $quote && $quote->getBillingAddress() ) {\n\n $quote->getBillingAddress()\n ->setFirstname($address['fname'])\n ->setLastname($address['lname'])\n ->setCompany($address['company'])\n ->setStreet($address['street'])\n ->setPostcode($address['zip'])\n ->setCity($address['city'])\n ->setCountry(Mage::helper('klarna')->klarnaCountryToMagento($address['country']))\n ->save();\n }\n\n /**\n * Update shipping address\n */\n if ( $quote && $quote->getShippingAddress() ) {\n\n $quote->getShippingAddress()\n ->setFirstname($address['fname'])\n ->setLastname($address['lname'])\n ->setCompany($address['company'])\n ->setStreet($address['street'])\n ->setPostcode($address['zip'])\n ->setCity($address['city'])\n ->setCountry(Mage::helper('klarna')->klarnaCountryToMagento($address['country']))\n ->save();\n }\n\n /**\n * Return successful response\n */\n return $this->jsonReponse(Mage::helper('klarna/json')->success(array('success' => true)));\n }\n }\n }\n\n /**\n * Return the json error\n */\n return $this->jsonReponse(Mage::helper('klarna/json')->error($this->__('Unable to set address')));\n }", "function saveAddress($formvalues, $prefix){\n\t\n\t\tif(isset($formvalues[$prefix.'addressupdateid'])){\n\t\t\t$query = \"UPDATE places SET name = '\".$formvalues[$prefix.'name'].\"', telephone = '\".$formvalues[$prefix.'tel'].\"', village = '\".$formvalues[$prefix.'village'].\"', subcounty = '\".$formvalues[$prefix.'subcounty'].\"', county = '\".$formvalues[$prefix.'county'].\"', parish = '\".$formvalues[$prefix.'parish'].\"', town = '\".$formvalues[$prefix.'town'].\"', district = '\".$formvalues[$prefix.'district'].\"', plotnumber = '\".$formvalues[$prefix.'plotno'].\"', lc1chairman = '\".$formvalues[$prefix.'lc1cm'].\"', lc1telephone = '\".$formvalues[$prefix.'lc1tel'].\"', lc2chairman = '\".$formvalues[$prefix.'lc2cm'].\"', lc2telephone = '\".$formvalues[$prefix.'lc2tel'].\"', lastupdatedby = \".$_SESSION['userid'].\", lastupdatedate = now() WHERE id = '\".$formvalues[$prefix.'addressupdateid'].\"'\";\n\t\t\t\n\t\t} else {\n\t\t\t$query = \"INSERT INTO places (name, telephone, village, subcounty, county, parish, town, district, plotnumber, lc1chairman, lc1telephone, lc2chairman, lc2telephone, createdby, datecreated) VALUES ('\".$formvalues[$prefix.'name'].\"', '\".$formvalues[$prefix.'tel'].\"', '\".$formvalues[$prefix.'village'].\"', '\".$formvalues[$prefix.'subcounty'].\"', '\".$formvalues[$prefix.'county'].\"', '\".$formvalues[$prefix.'parish'].\"', '\".$formvalues[$prefix.'town'].\"', '\".$formvalues[$prefix.'district'].\"', '\".$formvalues[$prefix.'plotno'].\"', '\".$formvalues[$prefix.'lc1cm'].\"', '\".$formvalues[$prefix.'lc1tel'].\"', '\".$formvalues[$prefix.'lc2cm'].\"', '\".$formvalues[$prefix.'lc2tel'].\"', \".$_SESSION['userid'].\", NOW())\";\n\t\t\n\t\t}\n\t\t\n\t\t$result = mysql_query($query);\n\t\t$addressid = \"\";\n\t\t# check if any errors have occured during the saving the activities to the database\n\t\tif (mysql_error() == \"\") {\n\t\t\t# no errors occured, so return the last inserted id\n\t\t\t$addressid = mysql_insert_id();\n\t\t\t\n\t\t\tif(isset($formvalues[$prefix.'addressupdateid'])){\n\t\t\t\t$addressid = $formvalues[$prefix.'addressupdateid'];\n\t\t\t}\n\t\t} else {\n\t\t\t# add the error message to the string\n\t\t\t$_SESSION['error'] = \"ERROR: Couldnot insert address for \".$formvalues[$prefix.'village'].\". Please try again. DETAILS: \".mysql_error();\n\t\t}\n\t\treturn $addressid;\n\t\n}", "function saveAddressData($new = FALSE, $addressType = 0) {\n\t\t$newData = array();\n\n\t\t// Set basic data\n\t\tif (empty($addressType)) $addressType = 0;\n\t\tif ($this->piVars['ismainaddress'] == 'on') {\n\t\t\t$newData['tx_commerce_is_main_address'] = 1;\n\t\t\t// Remove all \"is main address\" flags from addresses that are assigned to this user\n\t\t\t$GLOBALS['TYPO3_DB']->exec_UPDATEquery(\n\t\t\t\t'tt_address',\n\t\t\t\t'pid=' . $this->conf['addressPid'] . ' AND tx_commerce_fe_user_id=' . $this->user['uid'] . ' AND tx_commerce_address_type_id=' . $addressType,\n\t\t\t\tarray('tx_commerce_is_main_address' => 0)\n\t\t\t);\n\t\t} else {\n\t\t\t$newData['tx_commerce_is_main_address'] = 0;\n\t\t}\n\n\t\t$newData['tstamp'] = time();\n\n\t\tif ($this->debug) {\n\t\t\tdebug($newData,'newdata');\n\t\t}\n\n\t\tforeach($this->fieldList as $name) {\n\t\t\t$newData[$name] = t3lib_div::removeXSS(strip_tags($this->piVars[$name]));\n\t\t\tif (!$new) {\n\t\t\t\t$this->addresses[intval($this->piVars['addressid']) ][$name] = t3lib_div::removeXSS(strip_tags($this->piVars[$name]));\n\t\t\t}\n\t\t}\n\n\n\t\t// Hook to process new/changed address\n\t\t$hookObjectsArr = array();\n\t\tif (is_array($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['commerce/pi4/class.tx_commerce_pi4.php']['saveAddress'])) {\n\t\t\tforeach($GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['commerce/pi4/class.tx_commerce_pi4.php']['saveAddress'] as $classRef) {\n\t\t\t\t$hookObjectsArr[] = &t3lib_div::getUserObj($classRef);\n\t\t\t}\n\t\t}\n\n\t\tif ($new) {\n\t\t\t$newData['tx_commerce_fe_user_id'] = $this->user['uid'];\n\t\t\t$newData['tx_commerce_address_type_id'] = $addressType;\n\t\t\t$newData['pid'] = $this->conf['addressPid'];\n\n\t\t\tforeach($hookObjectsArr as $hookObj) {\n\t\t\t\tif (method_exists($hookObj, 'beforeAddressSave')) {\n\t\t\t\t\t$hookObj->beforeAddressSave($newData, $this);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$GLOBALS['TYPO3_DB']->exec_INSERTquery(\n\t\t\t\t'tt_address',\n\t\t\t\t$newData\n\t\t\t);\n\t\t\t$newUid = $GLOBALS['TYPO3_DB']->sql_insert_id();\n\n\t\t\tforeach($hookObjectsArr as $hookObj) {\n\t\t\t\tif (method_exists($hookObj, 'afterAddressSave')) {\n\t\t\t\t\t$hookObj->afterAddressSave($newUid, $newData, $this);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$this->addresses = $this->getAddresses($this->user['uid']);\n\t\t} else {\n\t\t\tforeach($hookObjectsArr as $hookObj) {\n\t\t\t\tif (method_exists($hookObj, 'beforeAddressEdit')) {\n\t\t\t\t\t$hookObj->beforeAddressEdit((int)$this->piVars['addressid'], $newData, $this);\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$sWhere = 'uid=' . intval($this->piVars['addressid']) . \" AND tx_commerce_fe_user_id = \" . $GLOBALS[\"TSFE\"]->fe_user->user[\"uid\"] . ' ';\n\n\t\t\t$GLOBALS['TYPO3_DB']->exec_UPDATEquery(\n\t\t\t\t'tt_address',\n\t\t\t\t$sWhere,\n\t\t\t\t$newData\n\t\t\t);\n\n\t\t\tforeach($hookObjectsArr as $hookObj) {\n\t\t\t\tif (method_exists($hookObj, 'afterAddressEdit')) {\n\t\t\t\t\t$hookObj->afterAddressEdit((int)$this->piVars['addressid'], $newData, $this);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "function helperReverseGeocode($lat, $lng) {\n\t\t$addressData = array();\n\t\t$lng = floatval($lat);\n\t\t$lng = floatval($lat);\n\n\t\tif ($key == '' || $lng == 0 || $lat == 0 ) {\n\t\t\treturn $addressData;\n\t\t}\n\n\t\t$coords\t\t= $lat . ',' . $lng;\n\t\t$url\t\t\t= 'http://maps.google.com/maps/geo?q='.$coords.'&output=json&oe=utf8&sensor=false&key='.$this->config['mapKey'];\n\t\t$address\t= json_decode(t3lib_div::getURL($url));\n\n\t\t// get the response\n\t\tif ($address->Status->code == '200' && count($address->Placemark) > 0) {\n\t\t\t$addressObj = $address->Placemark[0];\n\n\t\t\t$addressData['all']\t\t\t\t\t= $addressObj->address;\n\t\t\t$addressData['country']\t\t\t= $addressObj->AddressDetails->Country->CountryName;\n\t\t\t$addressData['countryshort']= $addressObj->AddressDetails->Country->CountryNameCode;\n\t\t\t$addressData['region']\t\t\t= $addressObj->AddressDetails->Country->AdministrativeArea->AdministrativeAreaName;\n\t\t\t$addressData['subarea']\t\t\t= $addressObj->AddressDetails->Country->AdministrativeArea->SubAdministrativeArea->SubAdministrativeAreaName;\n\t\t\t$addressData['city']\t\t\t\t= $addressObj->AddressDetails->Country->AdministrativeArea->SubAdministrativeArea->Locality->LocalityName;\n\t\t\t$addressData['zip']\t\t\t\t\t= $addressObj->AddressDetails->Country->AdministrativeArea->SubAdministrativeArea->Locality->PostalCode->PostalCodeNumber;\n\t\t\t$addressData['address']\t\t\t= $addressObj->AddressDetails->Country->AdministrativeArea->SubAdministrativeArea->Locality->Thoroughfare->ThoroughfareName;\n\t\t}\n\n\t\treturn $addressData;\n\t}", "public function processEdit( Mage_Payment_Model_Recurring_Profile $profile, Varien_Object $input )\n\t{\n\t\t$customer = Mage::helper('tokenbase')->getCurrentCustomer();\n\t\t\n\t\tif( $profile->getShippingAddressInfo() != array() ) {\n\t\t\t$origAddr\t= Mage::getModel('sales/quote_address')->load( $profile->getInfoValue('shipping_address_info', 'address_id') );\n\t\t\t$newAddrId\t= intval( $input->getData('shipping_address_id') );\n\t\t\t\n\t\t\t/**\n\t\t\t * Has the address changed?\n\t\t\t */\n\t\t\tif( $origAddr && $newAddrId != $origAddr->getCustomerAddressId() ) {\n\t\t\t\t/**\n\t\t\t\t * New address or existing?\n\t\t\t\t * \n\t\t\t\t * If new:\n\t\t\t\t * - store as customer address\n\t\t\t\t * - convert to quote address\n\t\t\t\t * - add to profile\n\t\t\t\t * \n\t\t\t\t * If existing:\n\t\t\t\t * - convert to quote address\n\t\t\t\t * - add to profile\n\t\t\t\t */\n\t\t\t\t\n\t\t\t\t/**\n\t\t\t\t * Existing address\n\t\t\t\t */\n\t\t\t\tif( $newAddrId > 0 ) {\n\t\t\t\t\t$newAddr = Mage::getModel('customer/address')->load( $newAddrId );\n\t\t\t\t\t\n\t\t\t\t\tif( !$customer || $newAddr->getCustomerId() != $customer->getId() ) {\n\t\t\t\t\t\tMage::throwException( $this->__('An error occurred. Please try again.') );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t/**\n\t\t\t\t * New address\n\t\t\t\t */\n\t\t\t\telse {\n\t\t\t\t\t$newAddr = Mage::getModel('customer/address');\n\t\t\t\t\t$newAddr->setCustomerId( $customer->getId() );\n\t\t\t\t\t\n\t\t\t\t\t$data = $input->getData('shipping');\n\t\t\t\t\t\n\t\t\t\t\t$addressForm = Mage::getModel('customer/form');\n\t\t\t\t\t$addressForm->setFormCode('customer_address_edit');\n\t\t\t\t\t$addressForm->setEntity( $newAddr );\n\t\t\t\t\t\n\t\t\t\t\t$addressData = $addressForm->extractData( $addressForm->prepareRequest( $data ) );\n\t\t\t\t\t$addressErrors = $addressForm->validateData( $addressData );\n\t\t\t\t\t\n\t\t\t\t\tif( $addressErrors !== true ) {\n\t\t\t\t\t\tMage::throwException( implode( ' ', $addressErrors ) );\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t$addressForm->compactData( $addressData );\n\t\t\t\t\t$addressErrors = $newAddr->validate();\n\t\t\t\t\t\n\t\t\t\t\t$newAddr->setSaveInAddressBook( true );\n\t\t\t\t\t$newAddr->implodeStreetAddress();\n\t\t\t\t\t$newAddr->save();\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t/**\n\t\t\t\t * Update the shipping address on our record\n\t\t\t\t */\n\t\t\t\t$origAddr->importCustomerAddress( $newAddr );\n\t\t\t\t\n\t\t\t\t$shippingAddr = $origAddr->getData();\n\t\t\t\t$this->_cleanupArray( $shippingAddr );\n\t\t\t\t$profile->setShippingAddressInfo( $shippingAddr );\n\t\t\t}\n\t\t}\n\t\t\n\t\t/**\n\t\t * Has the payment card changed?\n\t\t */\n\t\t$tokenbaseId = intval( $input->getData('tokenbase_id') );\n\t\tif( $tokenbaseId > 0 && $tokenbaseId != $profile->getInfoValue('additional_info', 'tokenbase_id') ) {\n\t\t\t$card = Mage::getModel('tokenbase/card')->load( $tokenbaseId );\n\t\t\t\n\t\t\tif( $card && $card->getId() == $tokenbaseId && ( $customer->getId() == 0 || $card->hasOwner( $customer->getId() ) ) ) {\n\t\t\t\t$adtl = $profile->getAdditionalInfo();\n\t\t\t\t$adtl['tokenbase_id'] = $tokenbaseId;\n\t\t\t\t\n\t\t\t\t/**\n\t\t\t\t * Update billing address to match the card\n\t\t\t\t */\n\t\t\t\t$billingAddr\t= $profile->getBillingAddressInfo();\n\t\t\t\t\n\t\t\t\t$copyKeys\t\t= array( 'street', 'firstname', 'lastname', 'city', 'region', 'region_id', 'postcode', 'country_id', 'telephone', 'fax' );\n\t\t\t\tforeach( $copyKeys as $key ) {\n\t\t\t\t\t$billingAddr[ $key ] = $card->getAddress( $key );\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t$profile->setBillingAddressInfo( $billingAddr );\n\t\t\t\t$profile->setAdditionalInfo( $adtl );\n\t\t\t\t\n\t\t\t\tMage::helper('tokenbase')->log( $profile->getMethodCode(), sprintf( 'Changed tokenbase ID for RP #%s to %s', $profile->getReferenceId(), $adtl['tokenbase_id'] ) );\n\t\t\t}\n\t\t\telse {\n\t\t\t\tMage::throwException( $this->__('Payment record not found. Please try again.') );\n\t\t\t}\n\t\t}\n\t\t\n\t\t/**\n\t\t * Has the next billing date changed?\n\t\t */\n\t\t$nextBilled = Mage::getModel('core/date')->gmtTimestamp( $input->getData('next_billed') );\n\t\tif( $input->getData('next_billed') != '' && $nextBilled > 0 && $nextBilled != $profile->getInfoValue('additional_info', 'next_cycle') ) {\n\t\t\t$adtl = $profile->getAdditionalInfo();\n\t\t\t$adtl['next_cycle'] = $nextBilled;\n\t\t\t\n\t\t\t$profile->setAdditionalInfo( $adtl );\n\t\t\t\n\t\t\tMage::helper('tokenbase')->log( $profile->getMethodCode(), sprintf( 'Changed next billing cycle for RP #%s to %s', $profile->getReferenceId(), date( 'j-F Y h:i', Mage::getModel('core/date')->timestamp( $adtl['next_cycle'] ) ) ) );\n\t\t}\n\t\t\n\t\tMage::dispatchEvent( 'tokenbase_recurringprofile_edit_before_save', array( 'profile' => $profile, 'input' => $input ) );\n\t\t\n\t\t$profile->save();\n\t\t\n\t\treturn $profile;\n\t}", "protected function _initBillingAddress($shouldIgnoreBillingValidation = null)\n {\n /**\n *\n * @note Check if it is necessary to validate billing address information\n *\n */\n if (!$shouldIgnoreBillingValidation) {\n /**\n *\n * @note Import customer default billing address\n *\n */\n $this->getQuote()->getBillingAddress()->importCustomerAddressData(\n $this->getCustomerSession()->getCustomer()->getDefaultBillingAddress()->getDataModel()\n );\n }\n else {\n /**\n *\n * @note Skip billing address validation\n *\n */\n $this->getQuote()->getBillingAddress()->setData('should_ignore_validation', true);\n\n /**\n *\n * @note Add customer generic data to billing address\n * @note For some reason, if this generic customer data is not set to the quote billing address, the order billing information breaks when someone tries to watch it on frontend/backend\n *\n */\n $customerSession = $this->getCustomerSession();\n $customer = $customerSession->getCustomerDataObject();\n if ($customer->getId()) {\n $this->getQuote()->getBillingAddress()->setCustomerId($customer->getId());\n $this->getQuote()->getBillingAddress()->setEmail($customer->getEmail());\n $this->getQuote()->getBillingAddress()->setFirstname($customer->getFirstname());\n $this->getQuote()->getBillingAddress()->setLastname($customer->getLastname());\n }\n }\n }", "public function setAddress($address) {\n\n $this->address = htmlspecialchars(strip_tags($address), ENT_QUOTES, 'utf-8');\n \n if (empty(trim($this->address))) {\n $this->valid = false;\n }\n\n }", "public function setAddress(?string $value): void {\n $this->getBackingStore()->set('address', $value);\n }", "private function getLatLng() {\n\t\tif( $this->getAutomaticLocation() && ( $this->isChanged() || ( !$this->getLat() && !$this->getLng() ) ) ) {\n\t\t\t$addressStr = $this->getAddLine1() . ' ' . $this->getStreetName() . ',' . $this->getTown();\n\t\t\t$addressStr.= ( $this->getCity() ) ? ',' . $this->getCity() : '';\n\t\t\t$addressStr.= ( $this->getRegion() ) ? ',' . $this->getRegion() : '';\n\t\t\t$addressStr.= ',' . $this->getPostalCode() . ',' . $this->getCountryCode();\n\t\t\t$req = sprintf( 'http://maps.googleapis.com/maps/api/geocode/json?address=%s&sensor=false', urlencode( $addressStr ) );\n\t\t\tif( !( $response = @file_get_contents( $req ) ) ) {\n\t\t\t\tthrow new Exception( sprintf( 'Unable to contact (%s)', $req ) );\n\t\t\t}\n\t\t\t$geoCode = json_decode( $response );\n// Do a switch here based on the possible status messages returned\n\t\t\tif( is_object( $geoCode ) ) {\n\t\t\t\tswitch( $geoCode->status ) {\n\t\t\t\t\tcase static::API_RESPONSE_ZERO_RESULTS:\n\t\t\t\t\t\t// ZERO RESULTS\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase static::API_RESPONSE_OK:\n\t\t\t\t\t\t$o = new StdClass();\n\t\t\t\t\t\t$o->Lat = $geoCode->results[0]->geometry->location->lat;\n\t\t\t\t\t\t$o->Lng = $geoCode->results[0]->geometry->location->lng;\n\t\t\t\t\t\treturn $o;\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tthrow new Exception( sprintf( 'Invalid response (%s) from (%s)', $response, $req ) );\n\t\t\t}\n\t\t} else {\n\t\t\t$o = new StdClass();\n\t\t\t$o->Lat = $this->getLat();\n\t\t\t$o->Lng = $this->getLng();\n\t\t\treturn $o;\n\t\t}\n\t}", "public function setLocalAddress(string $address): void {}", "public function update($adress)\n {\n $this->store($adress);\n\n }", "public function cassAddress()\n {\n //TODO - Figure out what this is doing\n $address = new UpsAddress();\n $address->setAddressLine1($this->shipping_line1);\n $address->setAddressLine2($this->shipping_line2);\n $address->setCity($this->shipping_city);\n $address->setStateProvinceCode($this->shipping_state);\n $address->setPostalCode($this->shipping_zip);\n\n //todo: Refactor to leverage DI so that we can actually test this.\n $mrtk = new Satori();\n $mrtk->create(0);\n try {\n //Just return a success result if service is down\n $mrtk->connect(config('app.host_config.mailRoomToolKit'), 5150, 5);\n $certifyResponse = $mrtk->certifyAddress($address);\n } catch (Exception $e) {\n (new Log())->logError('Core', 'Could not connect to MRTK');\n // setup success response\n $certifyResponse['status'] = 0;\n $certifyResponse['address'] = $address;\n }\n\n if (intval($certifyResponse['status']) > 100 || in_array($certifyResponse['status'], array(92,93))) {\n throw new Exception($certifyResponse['message']);\n } else {\n $this->shipping_line1 = $certifyResponse['address']->getAddressLine1();\n $this->shipping_line2 = $certifyResponse['address']->getAddressLine2();\n $this->shipping_city = $certifyResponse['address']->getCity();\n $this->shipping_state = $certifyResponse['address']->getStateProvinceCode();\n $this->shipping_zip = $certifyResponse['address']->getPostalCode();\n $this->save();\n }\n }", "function geocode($address)\n{\n\n // url encode the address\n $address = urlencode($address);\n\n // google map geocode api url\n $url = \"https://maps.googleapis.com/maps/api/geocode/json?key=AIzaSyDZwgb_z_wFGqrzvxbrLri_CXJRjklDoTM&address={$address}\";\n\n // get the json response\n $resp_json = file_get_contents($url);\n\n // decode the json\n $resp = json_decode($resp_json, true);\n // response status will be 'OK', if able to geocode given address\n if ($resp['status'] == 'OK') {\n\n // get the important data\n $lati = $resp['results'][0]['geometry']['location']['lat'];\n $longi = $resp['results'][0]['geometry']['location']['lng'];\n\n // verify if data is complete\n if ($lati && $longi) {\n // put the data in the array\n $data_arr = array();\n\n array_push(\n $data_arr,\n $lati,\n $longi\n );\n\n return $data_arr;\n\n } else {\n return false;\n }\n\n } else {\n return false;\n }\n}", "public function updateCustomerAddressAction() {\n if(!Mage::app()->getRequest()->isAjax()){\n $this->norouteAction();\n exit;\n }\n\n $postData = $this->getRequest()->getPost();\n parse_str($postData['form'], $billing);\n\n $customer = $this->_getCustomer();\n\n $address = new Varien_Object();\n $address->addData(\n array(\n 'state' => $billing['state'],\n 'city' => $billing['city'],\n 'street' => $billing['street'],\n 'zip_code' => $billing['zipcode'],\n 'firstname' => $billing['firstname'],\n 'lastname' => $billing['lastname'],\n 'telephone' => $billing['telephone'],\n 'phone_number' => $billing['telephone'],\n 'country_code' => $billing['country_id'],\n )\n );\n\n $response = Mage::getModel(\"payments/api\")->updateBilling($customer->getId(), $address);\n $this->getResponse()->setBody(Mage::helper('core')->jsonEncode(array('token' => $response)));\n }", "public function getAddress()\n {\n $address = null;\n if ($data = $this->getLocationData()) {\n $address = Address::create();\n $address->update($data);\n $address->ID = 0; //ensure not in db\n }\n\n return $address;\n }", "public function execute(\\Magento\\Framework\\Event\\Observer $observer)\n {\n if ($this->_coreRegistry->registry(self::VIV_CURRENTLY_SAVED_ADDRESS)) {\n $this->_coreRegistry->unregister(self::VIV_CURRENTLY_SAVED_ADDRESS);\n }\n\n /** @var $customerAddress Address */\n $customerAddress = $observer->getCustomerAddress();\n if ($customerAddress->getId()) {\n $this->_coreRegistry->register(self::VIV_CURRENTLY_SAVED_ADDRESS, $customerAddress->getId());\n } else {\n $configAddressType = $this->_customerAddress->getTaxCalculationAddressType();\n $forceProcess = $configAddressType == AbstractAddress::TYPE_SHIPPING\n ? $customerAddress->getIsDefaultShipping()\n : $customerAddress->getIsDefaultBilling();\n if ($forceProcess) {\n $customerAddress->setForceProcess(true);\n } else {\n $this->_coreRegistry->register(self::VIV_CURRENTLY_SAVED_ADDRESS, 'new_address');\n }\n }\n }", "function helperGeocodeAddress($address='', $zip='', $city='', $country='') {\n\t\t$geocode\t= array();\n\t\t$coords\t\t= array();\n\t\t$search\t\t= false;\n\n\t\tif ($address != '') {\n\t\t\t$geocode[] = $address;\n\t\t\t$search = true;\n\t\t}\n\t\tif ($zip != '') {\n\t\t\t$geocode[] = $zip;\n\t\t\t$search = true;\n\t\t}\n\t\tif ($city != '') {\n\t\t\t$geocode[] = $city;\n\t\t\t$search = true;\n\t\t}\n\t\tif ($country != '') {\n\t\t\t$geocode[] = $country;\n\t\t} else {\n\t\t\t$geocode[] = $this->config['defaultCountry'];\n\t\t}\n\n\t\t// just if there are some values additional to the country\n\t\tif ($search) {\n\t\t\t$geocode = implode(',', $geocode);\n\n\t\t\t// call google service\n\t\t\t$url = 'http://maps.google.com/maps/geo?q='.urlencode($geocode).'&output=csv&key='.$this->config['mapKey'];\n\t\t\t$response=stripslashes(t3lib_div::getURL($url));\n\n\t\t\t// determain the result\n\t\t\t$response = explode(',', $response);\n\n\t\t\t// if there is a result\n\t\t\t$coords['status'] \t= $response[0];\n\t\t\t$coords['accuracy']\t= $response[1];\n\t\t\t$coords['lat']\t\t\t= $response[2];\n\t\t\t$coords['lng']\t\t\t= $response[3];\n\t\t} else {\n\t\t\t\t$coords['status']\t= 601;\n\t\t}\n\n\t\treturn $coords;\n\t}", "public function dmap_get_coordinates( $address, $force_refresh = false ) {\n\n\t $address_hash = md5( $address );\n\n\t $coordinates = get_transient( $address_hash );\n\n\t if ($force_refresh || $coordinates === false) {\n\n\t \t$args = array( 'address' => urlencode( $address ), 'sensor' => 'false' );\n\t \t$url = add_query_arg( $args, 'http://maps.googleapis.com/maps/api/geocode/json' );\n\t \t$response \t= wp_remote_get( $url );\n\n\t \tif( is_wp_error( $response ) )\n\t \t\treturn;\n\n\t \t$data = wp_remote_retrieve_body( $response );\n\n\t \tif( is_wp_error( $data ) )\n\t \t\treturn;\n\n\t\t\tif ( $response['response']['code'] == 200 ) {\n\n\t\t\t\t$data = json_decode( $data );\n\n\t\t\t\tif ( $data->status === 'OK' ) {\n\n\t\t\t\t \t$coordinates = $data->results[0]->geometry->location;\n\n\t\t\t\t \t$cache_value['lat'] \t= $coordinates->lat;\n\t\t\t\t \t$cache_value['lng'] \t= $coordinates->lng;\n\t\t\t\t \t$cache_value['address'] = (string) $data->results[0]->formatted_address;\n\n\t\t\t\t \tset_transient($address_hash, $cache_value, 3600*24*30*3);\n\t\t\t\t \t$data = $cache_value;\n\n\t\t\t\t} elseif ( $data->status === 'ZERO_RESULTS' ) {\n\n\t\t\t\t \treturn;\n\n\t\t\t\t} elseif( $data->status === 'INVALID_REQUEST' ) {\n\n\t\t\t\t \treturn;\n\n\t\t\t\t} else {\n\n\t\t\t\t\treturn;\n\t\t\t\t\n\t\t\t\t}\n\n\t\t\t} else {\n\n\t\t\t \treturn;\n\n\t\t\t}\n\n\t } else {\n\n\t $data = $coordinates;\n\t }\n\n\t return $data;\n\n\t}", "public function setTaxByAddressCountry()\n {\n if ($this->invoiceAddressId != 0 && $this->invoiceAddress->country) {\n LocationHelper::setLocation($this->invoiceAddress->country);\n } elseif ($this->address->country) {\n LocationHelper::setLocation($this->address->country);\n }\n }", "protected function get_geocoder_data($address_string){\n\n\t\t// Get Google geocoder API key\n\t\t$api_key = get_option('site_options')['GOOGLE_MAPS_GEOCODER_KEY'] ?? false;\n\n\t\tif (!$api_key){\n\t\t\terror_log('Missing Google Geocoder API key!');\n\t\t\treturn false;\n\t\t}\n\n\t\t$base_url = 'https://maps.googleapis.com/maps/api/geocode/json';\n\n\t\t$params = [\n\t\t\t'address' => $address_string,\n\t\t\t'key' => $api_key\n\t\t];\n\n\t\t$request_url = $base_url . '?' . http_build_query($params);\n\n\t\t$response = file_get_contents($request_url);\n\n\t\tif ($response){\n\t\t\treturn json_decode($response, true);\n\t\t}\n\n\t}", "protected function checkAndCreateNewLocation(Postcode $postcode)\n {\n $correction = new Correction();\n $correction->setMunicipalityManager($this->municipalityManager);\n $correction->setZipCodeManager($this->zipcodeManager);\n $correction->setCityManager($this->cityManager);\n $correction->setProvinceManager($this->provinceManager);\n\n if ($postcode->getCity() === 'Geffen' && $postcode->getProvinceCode() === 'NB') {\n $postcode->setMunicipality('Oss');\n } else if (($postcode->getCity() === 'Vinkel' || $postcode->getCity() === 'Nuland') && $postcode->getProvinceCode() === 'NB') {\n $postcode->setMunicipality('\\'s‑Hertogenbosch');\n }\n\n $slug = $this->slugifier->manipulate($postcode->getCity());\n $municipality = $this->municipalityManager->getRepository()->findOneByTitle($postcode->getMunicipality());\n\n $entity = $this->cityManager->getRepository()->findOneBy(['municipality' => $municipality, 'title' => $postcode->getCity()]);\n\n if ($entity != null) {\n return false;\n }\n\n $entity = $this->cityManager->getRepository()->findOneBySlug($slug);\n\n if ($entity != null) {\n $slug = $this->slugifier->manipulate($postcode->getCity() . '-' . $postcode->getProvinceCode());\n\n $entity = $this->cityManager->getRepository()->findOneBySlug($slug);\n\n if ($entity != null) {\n return false;\n }\n }\n\n /**\n * @var $c City\n */\n $c = $this->copyFields(new City(), $postcode);\n $c->setTitle($postcode->getCity());\n\n $c->setSlug($slug);\n $c->setSourceLocationTypeId($postcode->getCityId());\n $c->setMunicipality($municipality);\n\n $c = $correction->correct($c, $postcode);\n\n if ($municipality != null) {\n $this->cityManager->persistAndFlush($c);\n } else {\n return false;\n }\n\n return true;\n }", "public function store(Request $request)\n {\n if(!empty($request->get('id'))){\n\n $long = $request->get('long');\n $lat = $request->get('lat');\n\n $data = Data::where('id', '=', $request->get('id'))->first();\n\n if($data->cep != $request->get('cep')){\n $endpoint = 'https://www.google.com/maps/search/' . $request->street . '+' . $request->number . '+' . $request->neighborhood . '+' . $request->city . '+' . $request->state;\n $endpoint = str_replace(' ', '%20', $endpoint);\n\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $endpoint);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_CUSTOMREQUEST, \"GET\");\n $response = curl_exec($ch);\n\n preg_match(\"/APP_INITIALIZATION_STATE=\\[\\[\\[(-?\\d+\\.\\d+),(-?\\d+\\.\\d+),(-?\\d+\\.\\d+)\\]/m\", $response, $group);\n\n $long = $group[2];\n $lat = $group[3];\n }\n\n Data::where('id', '=', $request->get('id'))->update(\n [\n 'status' => $request->get('status'),\n 'street' => $request->get('street'),\n 'number' => $request->get('number'),\n 'neighborhood' => $request->get('neighborhood'),\n 'city' => $request->get('city'),\n 'state' => $request->get('state'),\n 'cep' => $request->get('cep'),\n 'whatsapp' => $request->get('whatsapp'),\n 'lat' => $lat,\n 'long' => $long,\n ]\n );\n\n return redirect()->back()->with('success', 'Atualizado com sucesso ...'); \n }\n\n $data = new Data();\n $data->user_id = Auth::user()->id;\n $data->fill($request->all());\n\n $endpoint = 'https://www.google.com/maps/place/' . $data->street . '+' . $data->number . '+' . $data->neighborhood . '+' . $data->city . '+' . $data->state;\n $endpoint = str_replace(' ', '+', $endpoint);\n\n $ch = curl_init();\n curl_setopt($ch, CURLOPT_URL, $endpoint);\n curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);\n curl_setopt($ch, CURLOPT_CUSTOMREQUEST, \"GET\");\n $response = curl_exec($ch);\n\n preg_match(\"/APP_INITIALIZATION_STATE=\\[\\[\\[(-?\\d+\\.\\d+),(-?\\d+\\.\\d+),(-?\\d+\\.\\d+)\\]/m\", $response, $group);\n\n $data->long = $group[2];\n $data->lat = $group[3];\n\n $data->save();\n \n return redirect()->back()->with('success', 'Atualizado com sucesso'); \n }", "public function setAddress($address)\n {\n $this->set('address', $address);\n }", "public function geocode(\\DataContainer $dc)\n\t{\n\t\tif ($dc->activeRecord->address && (!$dc->activeRecord->latitude || !$dc->activeRecord->longitude))\n\t\t{\n\t\t\t$objLocation = new Location();\n\t\t\t$objLocation->setAddress($dc->activeRecord->address);\n\t\t\tif ($objLocation->geocode()) {\n\t\t\t\t$this->Database->prepare(\"UPDATE tl_peerless_dealers SET latitude=?, longitude=? WHERE id=?\")\n\t\t\t\t\t ->execute($objLocation->get('latitude'), $objLocation->get('longitude'), $dc->id);\n\t\t\t\t$dc->activeRecord->latitude = $objLocation->get('latitude');\n\t\t\t\t$dc->activeRecord->longitude = $objLocation->get('longitude');\n\t\t\t}\n\t\t}\n\t}", "private function get_address()\n\t{\n\t\treturn $this->m_address;\n\t}", "function getOverrideAddress()\n {\n global $customer_id, $sendto;\n\n if (!empty($_GET['markflow']) && tep_session_is_registered('customer_id')) {\n // From now on for this user we will edit addresses on the\n // osc install, not by going to PayPal.\n tep_session_register('paypal_ec_markflow');\n $_SESSION['paypal_ec_markflow'] = 1;\n\n // find the users default address id\n if (!empty($sendto)) {\n $address_id = $sendto;\n } else {\n $default_address_id_query = tep_db_query('SELECT customers_default_address_id\n FROM ' . TABLE_CUSTOMERS . '\n WHERE customers_id = \\'' . $customer_id . '\\'');\n if (tep_db_num_rows($default_address_id_query) > 0) {\n // grab the data\n $default_address_id_arr = tep_db_fetch_array($default_address_id_query);\n $address_id = $default_address_id_arr['customers_default_address_id'];\n } else {\n // couldn't find an address.\n return false;\n }\n }\n\n // now grab the address from the database and set it\n $address_query = tep_db_query('SELECT entry_firstname, entry_lastname,\n entry_street_address, entry_suburb, entry_city, entry_postcode,\n entry_country_id, entry_zone_id\n FROM ' . TABLE_ADDRESS_BOOK . '\n WHERE address_book_id = \\'' . $address_id . '\\' AND\n customers_id = \\'' . $customer_id . '\\'\n LIMIT 1');\n\n // see if we found a record, if not well we have nothing to override with\n if (tep_db_num_rows($address_query) > 0) {\n // grab the data\n $address_arr = tep_db_fetch_array($address_query);\n\n // get the state/prov code\n $state_query = tep_db_query('SELECT zone_code\n FROM ' . TABLE_ZONES . '\n WHERE zone_id = \\'' . $address_arr['entry_zone_id'] . '\\'');\n if (tep_db_num_rows($state_query) > 0) {\n $state_code_arr = tep_db_fetch_array($state_query);\n } else {\n $state_code_arr['zone_code'] = '';\n }\n $address_arr['zone_code'] = $state_code_arr['zone_code'];\n\n // get the country code\n // ISO 3166 standard country code\n $country_query = tep_db_query('SELECT countries_iso_code_2\n FROM ' . TABLE_COUNTRIES . '\n WHERE countries_id = \\'' . $address_arr['entry_country_id'] . '\\'');\n if (tep_db_num_rows($country_query) > 0) {\n $country_code_arr = tep_db_fetch_array($country_query);\n } else {\n // default to go old US\n $country_code_arr['countries_iso_code_2'] = 'US';\n }\n $address_arr['countries_iso_code_2'] = $country_code_arr['countries_iso_code_2'];\n\n // return address data.\n return $address_arr;\n }\n }\n\n return false;\n }", "public function getAddress(): Address {\n return $this->address;\n }", "function save_address($data)\n\t{\n\t\t$data['field_data'] = serialize($data['field_data']);\n\t\t// update or insert\n\t\tif(!empty($data['id']))\n\t\t{\n\t\t\t$this->db->where('id', $data['id']);\n\t\t\t$this->db->update('merchants_address_bank', $data);\n\t\t\t//echo $this->db->last_query(); die; \n\t\t\treturn $data['id'];\n\t\t} else {\n\t\t\t$this->db->insert('merchants_address_bank', $data);\n\t\t\treturn $this->db->insert_id();\n\t\t}\n\t}", "public function save()\n {\n return $this->address_srl ? $this->repo->update($this) : $this->repo->insert($this);\n }", "public function _on_memberUpdateAddress($member, $data) {\n\t\tif(is_object($member))\n\t\t\t$member->save($data);\n\t}", "public function setAddress(?CustomerAddressFilter $address): void\n {\n $this->address = $address;\n }", "function update_cart_address($address_field,$address_id){\n\n $this->update([$address_field => $address_id]);\n }" ]
[ "0.6613657", "0.64926976", "0.6405162", "0.62133306", "0.6064842", "0.5922549", "0.5882071", "0.586366", "0.57337755", "0.5721799", "0.56671995", "0.5666921", "0.56067896", "0.5605652", "0.5604655", "0.5583857", "0.5567286", "0.5539541", "0.55149835", "0.5508257", "0.5478944", "0.5472662", "0.5469526", "0.5468095", "0.54474765", "0.54317945", "0.54280543", "0.5424589", "0.54126555", "0.53836656", "0.5369527", "0.535677", "0.5344521", "0.53323793", "0.53323793", "0.5327394", "0.53268594", "0.5325223", "0.5321211", "0.531819", "0.5315471", "0.5312387", "0.53096056", "0.530239", "0.5279551", "0.52762276", "0.52754235", "0.5272307", "0.52654874", "0.5245137", "0.5240594", "0.522579", "0.52085245", "0.51985675", "0.5193314", "0.5184069", "0.5177665", "0.51767933", "0.5160762", "0.5146566", "0.5140421", "0.5131789", "0.51228786", "0.5109404", "0.51056105", "0.50986826", "0.5096034", "0.50954473", "0.50947416", "0.5092282", "0.5090441", "0.5085613", "0.5083523", "0.5053216", "0.503354", "0.50301665", "0.5030124", "0.5030075", "0.50279003", "0.50259906", "0.5024684", "0.5012793", "0.50049925", "0.49981335", "0.49961707", "0.49899986", "0.49887836", "0.49853975", "0.4984233", "0.49811247", "0.49748814", "0.49725503", "0.49707916", "0.49704754", "0.49700645", "0.49585542", "0.49581727", "0.4957445", "0.4956771", "0.49523035" ]
0.61790985
4
Sets the update messages for the units custom post type.
function updated_messages( $messages ) { global $post_ID, $post; $messages['units'] = array( 0 => '', // Unused. Messages start at index 1. 1 => __('Unit updated.'), 2 => __('Unit updated.'), 3 => __('Custom field deleted.'), 4 => __('Unit updated.'), 5 => isset($_GET['revision']) ? sprintf( __('Unit restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false, 6 => __('Unit published.'), 7 => __('Unit saved.'), 8 => __('Unit submitted. <a target="_blank" href="%s">Preview Unit</a>'), 9 => sprintf( __('Unit scheduled for: <strong>%1$s</strong>.'), date_i18n( __( 'M j, Y @ G:i' ), strtotime( $post->post_date ) ) ), 10 => __('Unit draft updated.') ); return $messages; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function post_type_updated_messages( $messages ) {\r\n global $post, $post_ID;\r\n\r\n $name = ucwords( str_replace( '_', ' ', $this->post_type_name ) );\r\n $plural = $name . 's';\r\n\r\n $messages[$this->post_type_name] = array(\r\n 0 => '', // Unused. Messages start at index 1.\r\n 1 => sprintf( __(\"$name updated. <a href='%s'>View $name</a>\"), esc_url( get_permalink($post_ID) ) ),\r\n 2 => __(\"Custom field updated.\"),\r\n 3 => __(\"Custom field deleted.\"),\r\n 4 => __(\"$name updated.\"),\r\n // translators: %s: date and time of the revision\r\n 5 => isset($_GET['revision']) ? sprintf( __(\"$name restored to revision from %s\"), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\r\n 6 => sprintf( __(\"$name published. <a href='%s'>View $name</a>\"), esc_url( get_permalink($post_ID) ) ),\r\n 7 => __(\"$name saved.\"),\r\n 8 => sprintf( __(\"$name submitted. <a target='_blank' href='%s'>Preview book</a>\"), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\r\n 9 => sprintf( __(\"$name scheduled for: <strong>%1$s</strong>. <a target='_blank' href='%2$s'>Preview book</a>\"),\r\n // translators: Publish box date format, see php.net/date\r\n date_i18n( __( 'M j, Y @ G:i' ), strtotime( $post->post_date ) ), esc_url( get_permalink($post_ID) ) ),\r\n 10 => sprintf( __(\"$name draft updated. <a target='_blank' href='%s'>Preview book</a>\"), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\r\n );\r\n\r\n return $messages;\r\n }", "public function custom_post_type_post_update_messages( $messages ) {\n\n\t\t\t$custom_post_type = get_post_type( get_the_ID() );\n\n\t\t\tif ( 'astra_adv_header' == $custom_post_type ) {\n\n\t\t\t\t$obj = get_post_type_object( $custom_post_type );\n\t\t\t\t$singular_name = $obj->labels->singular_name;\n\t\t\t\t$messages[ $custom_post_type ] = array(\n\t\t\t\t\t0 => '', // Unused. Messages start at index 1.\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t1 => sprintf( __( '%s updated.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t2 => sprintf( __( 'Custom %s updated.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t3 => sprintf( __( 'Custom %s deleted.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t4 => sprintf( __( '%s updated.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %1$s: singular custom post type name ,%2$s: date and time of the revision */\n\t\t\t\t\t5 => isset( $_GET['revision'] ) ? sprintf( __( '%1$s restored to revision from %2$s', 'astra-addon' ), $singular_name, wp_post_revision_title( (int) $_GET['revision'], false ) ) : false, // phpcs:ignore WordPress.Security.NonceVerification.Recommended\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t6 => sprintf( __( '%s published.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t7 => sprintf( __( '%s saved.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t8 => sprintf( __( '%s submitted.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t9 => sprintf( __( '%s scheduled for.', 'astra-addon' ), $singular_name ),\n\t\t\t\t\t/* translators: %s: singular custom post type name */\n\t\t\t\t\t10 => sprintf( __( '%s draft updated.', 'astra-addon' ), $singular_name ),\n\t\t\t\t);\n\t\t\t}\n\n\t\t\treturn $messages;\n\t\t}", "function rw_post_updated_messages( $messages ) {\n\n\t\t$post = get_post();\n\t\t$post_type = get_post_type( $post );\n\t\t$post_type_object = get_post_type_object( $post_type );\n\t\t\n\t\tif ( !get_transient( get_current_user_id().'publisherror' ) ){\n\t\t\treturn $messages;\n\t\t}\n\t\telse {\n\t\t\t$messages['post'][6] = '';\n\t\t}\n\t\t\n\t\treturn $messages;\n}", "public function talks_updated_messages( $messages = array() ) {\n\t\t\tglobal $post;\n\n\t\t\t// Bail if not posting/editing a talk.\n\t\t\tif ( ! wct_is_admin() ) {\n\t\t\t\treturn $messages;\n\t\t\t}\n\n\t\t\t/**\n\t\t\t * @param array list of updated messages\n\t\t\t */\n\t\t\t$messages[ $this->post_type ] = apply_filters( 'wct_admin_updated_messages', array(\n\t\t\t\t 0 => '', // Unused. Messages start at index 1.\n\t\t\t\t 1 => sprintf( __( 'Talk updated. <a href=\"%s\">View Talk</a>', 'wordcamp-talks' ), esc_url( wct_talks_get_talk_permalink( $post ) ) ),\n\t\t\t\t 2 => __( 'Custom field updated.', 'wordcamp-talks' ),\n\t\t\t\t 3 => __( 'Custom field deleted.', 'wordcamp-talks' ),\n\t\t\t\t 4 => __( 'Talk updated.', 'wordcamp-talks'),\n\t\t\t\t 5 => isset( $_GET['revision'] ) ? sprintf( __( 'Talk restored to revision from %s', 'wordcamp-talks' ), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t\t\t 6 => sprintf( __( 'Talk published. <a href=\"%s\">View Talk</a>', 'wordcamp-talks' ), esc_url( wct_talks_get_talk_permalink( $post ) ) ),\n\t\t\t\t 7 => __( 'Talk saved.', 'wordcamp-talks' ),\n\t\t\t\t 8 => sprintf( __( 'Talk submitted. <a target=\"_blank\" href=\"%s\">Preview Talk</a>', 'wordcamp-talks' ), esc_url( add_query_arg( 'preview', 'true', wct_talks_get_talk_permalink( $post ) ) ) ),\n\t\t\t\t 9 => sprintf(\n\t\t\t\t \t\t__( 'Talk scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview Talk</a>', 'wordcamp-talks' ),\n\t\t\t\t\t\tdate_i18n( _x( 'M j, Y @ G:i', 'Talk Publish box date format', 'wordcamp-talks' ), strtotime( $post->post_date ) ),\n\t\t\t\t\t\tesc_url( wct_talks_get_talk_permalink( $post ) )\n\t\t\t\t\t),\n\t\t\t\t10 => sprintf( __( 'Talk draft updated. <a target=\"_blank\" href=\"%s\">Preview Talk</a>', 'wordcamp-talks' ), esc_url( add_query_arg( 'preview', 'true', wct_talks_get_talk_permalink( $post ) ) ) ),\n\t\t\t) );\n\n\t\t\treturn $messages;\n\t\t}", "function post_updated_messages($messages)\n {\n }", "function post_updated_messages( $messages ) {\n\t\t$post = get_post();\n\t\t$post_type_object = get_post_type_object( 'locale' );\n\n\t\t$messages['locale'] = array(\n\t\t\t0 => '', // Unused. Messages start at index 1.\n\t\t\t1 => __( 'Locale updated.', 'wp-i18n-team-crawler' ),\n\t\t\t2 => __( 'Custom field updated.', 'wp-i18n-team-crawler' ),\n\t\t\t3 => __( 'Custom field deleted.', 'wp-i18n-team-crawler' ),\n\t\t\t4 => __( 'Locale updated.', 'wp-i18n-team-crawler' ),\n\t\t\t/* translators: %s: date and time of the revision */\n\t\t\t5 => isset( $_GET['revision'] ) ? sprintf( __( 'Locale restored to revision from %s', 'wp-i18n-team-crawler' ), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t\t6 => __( 'Locale published.', 'wp-i18n-team-crawler' ),\n\t\t\t7 => __( 'Locale saved.', 'wp-i18n-team-crawler' ),\n\t\t\t8 => __( 'Locale submitted.', 'wp-i18n-team-crawler' ),\n\t\t\t9 => sprintf(\n\t\t\t\t__( 'Locale scheduled for: <strong>%1$s</strong>.', 'wp-i18n-team-crawler' ),\n\t\t\t\t// translators: Publish box date format, see http://php.net/date\n\t\t\t\tdate_i18n( __( 'M j, Y @ G:i', 'wp-i18n-team-crawler' ), strtotime( $post->post_date ) )\n\t\t\t),\n\t\t\t10 => __( 'Locale draft updated.', 'wp-i18n-team-crawler' )\n\t\t);\n\n\t\tif ( $post_type_object->publicly_queryable ) {\n\t\t\t$permalink = get_permalink( $post->ID );\n\n\t\t\t$view_link = sprintf( ' <a href=\"%s\">%s</a>', esc_url( $permalink ), __( 'View locale', 'wp-i18n-team-crawler' ) );\n\t\t\t$messages['locale' ][1] .= $view_link;\n\t\t\t$messages['locale' ][6] .= $view_link;\n\t\t\t$messages['locale' ][9] .= $view_link;\n\n\t\t\t$preview_permalink = add_query_arg( 'preview', 'true', $permalink );\n\t\t\t$preview_link = sprintf( ' <a target=\"_blank\" href=\"%s\">%s</a>', esc_url( $preview_permalink ), __( 'Preview locale', 'wp-i18n-team-crawler' ) );\n\t\t\t$messages['locale' ][8] .= $preview_link;\n\t\t\t$messages['locale' ][10] .= $preview_link;\n\t\t}\n\n\t\treturn $messages;\n\t}", "function my_updated_messages( $messages ) {\n\tglobal $post, $post_ID;\n\t$messages['product'] = array(\n\t\t0 => '',\n\t\t1 => sprintf( __('Product updated. <a href=\"%s\">View product</a>'), esc_url( get_permalink($post_ID) ) ),\n\t\t2 => __('Custom field updated.'),\n\t\t3 => __('Custom field deleted.'),\n\t\t4 => __('Product updated.'),\n\t\t5 => isset($_GET['revision']) ? sprintf( __('Product restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t6 => sprintf( __('Product published. <a href=\"%s\">View product</a>'), esc_url( get_permalink($post_ID) ) ),\n\t\t7 => __('Product saved.'),\n\t\t8 => sprintf( __('Product submitted. <a target=\"_blank\" href=\"%s\">Preview product</a>'), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\n\t\t9 => sprintf( __('Product scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview product</a>'), date_i18n( __( 'M j, Y @ G:i' ), strtotime( $post->post_date ) ), esc_url( get_permalink($post_ID) ) ),\n\t\t10 => sprintf( __('Product draft updated. <a target=\"_blank\" href=\"%s\">Preview product</a>'), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\n\t);\n\treturn $messages;\n}", "public function onPostUpdatePostMessages(Event $event): void\n {\n $this->container->get(IOInterface::class)->write($this->postMessages);\n }", "function update_messages( $event_messages ) {\n\t\tglobal $post, $post_ID;\n\t\t\n\t\t/* Set some simple messages for editing slides, no post previews needed. */\n\t\t$event_messages['event'] = array( \n\t\t\t0\t=> '',\n\t\t\t1\t=> 'Event updated.',\n\t\t\t2\t=> 'Custom field updated.',\n\t\t\t2\t=> 'Custom field deleted.',\n\t\t\t4\t=> 'Event updated.',\n\t\t\t5\t=> isset($_GET['revision']) ? sprintf( 'Event restored to revision from %s', wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t\t6\t=> 'Event added to calendar.',\n\t\t\t7\t=> 'Event saved.',\n\t\t\t8\t=> 'Event added to calendar.',\n\t\t\t9\t=> sprintf( 'Event scheduled for: <strong>%1$s</strong>.' , strtotime( $post->post_date ) ),\n\t\t\t10\t=> 'Event draft updated.',\n\t\t);\n\t\treturn $event_messages;\n\t}", "public function custom_bulk_admin_notices() {\n\t\tglobal $post_type, $pagenow;\n\t\tif($pagenow == 'edit.php' && $post_type == 'post' && isset($_REQUEST['built']) && (int) $_REQUEST['built']) {\n\t\t\t$message = sprintf( _n( 'Post flat file built.', '%s post flat files built.', $_REQUEST['built'] ), number_format_i18n( $_REQUEST['built'] ) );\n\t\t\techo \"<div class=\\\"updated\\\"><p>{$message}</p></div>\";\n\t\t}\n\t}", "function volpress_update_messages( $messages ) {\n\tglobal $post, $post_ID;\n\t$messages['volpress_vol'] = array(\n\t0 => '', // Unused. Messages start at index 1.\n\t1 => sprintf( __('Volunteer Event updated. <a href=\"%s\">View volunteer Event</a>', 'your_text_domain'), esc_url( get_permalink($post_ID) ) ),\n\t2 => __('Custom field updated.', 'your_text_domain'),\n\t3 => __('Custom field deleted.', 'your_text_domain'),\n\t4 => __('Volunteer Event updated.', 'your_text_domain'),\n\t/* translators: %s: date and time of the revision */\n\t5 => isset($_GET['revision']) ? sprintf( __('Volunteer Event restored to revision from %s', 'your_text_domain'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t6 => sprintf( __('Volunteer Event published. <a href=\"%s\">View Volunteer Event</a>', 'your_text_domain'), esc_url( get_permalink($post_ID) ) ),\n\t7 => __('Volunteer Event saved.', 'your_text_domain'),\n\t8 => sprintf( __('Volunteer Event submitted. <a target=\"_blank\" href=\"%s\">Preview volunteer Event</a>', 'your_text_domain'), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\n\t9 => sprintf( __('Volunteer Event scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview volunteer Event</a>', 'your_text_domain'),\n\t\t// translators: Publish box date format, see http://php.net/date\n\t\tdate_i18n( __( 'M j, Y @ G:i' ), strtotime( $post->post_date ) ), esc_url( get_permalink($post_ID) ) ),\n\t10 => sprintf( __('Volunteer Event draft updated. <a target=\"_blank\" href=\"%s\">Preview volunteer</a>', 'your_text_domain'), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\n\t);\n\n\treturn $messages;\n}", "function ffw_media_updated_messages( $messages ) {\n\tglobal $post, $post_ID;\n\n\t$url1 = '<a href=\"' . get_permalink( $post_ID ) . '\">';\n\t$url2 = ffw_media_get_label_singular();\n\t$url3 = '</a>';\n\n\t$messages['FFW_media'] = array(\n\t\t1 => sprintf( __( '%2$s updated. %1$sView %2$s%3$s.', 'FFW_media' ), $url1, $url2, $url3 ),\n\t\t4 => sprintf( __( '%2$s updated. %1$sView %2$s%3$s.', 'FFW_media' ), $url1, $url2, $url3 ),\n\t\t6 => sprintf( __( '%2$s published. %1$sView %2$s%3$s.', 'FFW_media' ), $url1, $url2, $url3 ),\n\t\t7 => sprintf( __( '%2$s saved. %1$sView %2$s%3$s.', 'FFW_media' ), $url1, $url2, $url3 ),\n\t\t8 => sprintf( __( '%2$s submitted. %1$sView %2$s%3$s.', 'FFW_media' ), $url1, $url2, $url3 )\n\t);\n\n\treturn $messages;\n}", "function my_updated_messages($messages) {\n\tglobal $post, $post_ID;\n\t$messages['listing'] = array(\n\t\t0 => '',\n\t\t1 => sprintf( __('Listing updated. <a href=\"%s\">View Listing</a>'), esc_url(get_permalink($post_ID)) ),\n\t\t2 => __('Custom field updated.'),\n\t\t3 => __('Custom field deleted.'),\n\t\t4 => __('Listing updated.'),\n\t\t5 => isset($_GET['revision']) ? sprintf( __('Listing restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t6 => sprintf( __('Listing published. <a href=\"%s\">View Listing</a>'), esc_url(get_permalink($post_ID)) ),\n\t\t7 => __('Listing saved.'),\n\t\t8 => sprintf( __('Listing submitted. <a target=\"_blank\" href=\"%s\">Preview listing</a>'), esc_url(add_query_arg('preview', 'true', get_permalink($post_ID))) ),\n\t\t9 => sprintf( __('Listing scheduled for : <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview listing</a>'), date_i18n( __('M j, Y @ G:i'), strtotime($post->post_date) ), esc_url(get_permalink($post_ID)) ),\n\t\t10 => sprintf( __('Listing draft updated. <a target=\"_blank\" href=\"%s\">Preview listing</a>'), esc_url(add_query_arg('preview', 'true', get_permalink($post_ID))) ),\n\t);\n\treturn $messages;\n}", "public function testUpdateReplenishmentCustomFields()\n {\n }", "public function talks_updated_bulk_messages( $bulk_messages = array(), $bulk_counts = array() ) {\n\t\t\t// Bail if not posting/editing a talk\n\t\t\tif ( ! wct_is_admin() ) {\n\t\t\t\treturn $bulk_messages;\n\t\t\t}\n\n\t\t\t$bulk_messages[ $this->post_type ] = apply_filters( 'wct_admin_updated_bulk_messages', array(\n\t\t\t\t'updated' => _n( '%s talk updated.', '%s talks updated.', $bulk_counts['updated'], 'wordcamp-talks' ),\n\t\t\t\t'locked' => _n( '%s talk not updated; somebody is editing it.', '%s talks not updated; somebody is editing them.', $bulk_counts['locked'], 'wordcamp-talks' ),\n\t\t\t\t'deleted' => _n( '%s talk permanently deleted.', '%s talks permanently deleted.', $bulk_counts['deleted'], 'wordcamp-talks' ),\n\t\t\t\t'trashed' => _n( '%s talk moved to the Trash.', '%s talks moved to the Trash.', $bulk_counts['trashed'], 'wordcamp-talks' ),\n\t\t\t\t'untrashed' => _n( '%s talk restored from the Trash.', '%s talks restored from the Trash.', $bulk_counts['untrashed'], 'wordcamp-talks' ),\n\t\t\t) );\n\n\t\t\treturn $bulk_messages;\n\t\t}", "protected function _set_custom_stuff()\n\t{\n\t\t//setup our custom error messages\n\t\t$this->setCustomMessages($this->_custom_messages);\n\t}", "protected function _set_custom_stuff() {\n //setup our custom error messages\n // $this->setCustomMessages( $this->_custom_messages );\n }", "public static function updated_messages( $messages ) {\n\t\tglobal $post;\n\n\t\t$messages['simple_sponsor'] = array(\n\t\t\t0 => '', // Unused. Messages start at index 1.\n\t\t\t1 => sprintf( __('Sponsor updated. <a href=\"%s\">View sponsor</a>', self::$text_domain ), esc_url( get_permalink($post->ID) ) ),\n\t\t\t2 => __('Custom field updated.', self::$text_domain ),\n\t\t\t3 => __('Custom field deleted.', self::$text_domain ),\n\t\t\t4 => __('Sponsor updated.', self::$text_domain ),\n\t\t\t/* translators: %s: date and time of the revision */\n\t\t\t5 => isset($_GET['revision']) ? sprintf( __('Sponsor restored to revision from %s', self::$text_domain ), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t\t6 => sprintf( __('Sponsor published. <a href=\"%s\">View sponsor</a>', self::$text_domain ), esc_url( get_permalink($post->ID) ) ),\n\t\t\t7 => __('Sponsor saved.', self::$text_domain ),\n\t\t\t8 => sprintf( __('Sponsor submitted. <a target=\"_blank\" href=\"%s\">Preview sponsor</a>', self::$text_domain ), esc_url( add_query_arg( 'preview', 'true', get_permalink($post->ID) ) ) ),\n\t\t\t9 => sprintf( __('Sponsor scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview sponsor</a>', self::$text_domain ),\n\t\t\t // translators: Publish box date format, see http://php.net/date\n\t\t\t date_i18n( __( 'M j, Y @ G:i' ), strtotime( $post->post_date ) ), esc_url( get_permalink($post->ID) ) ),\n\t\t\t10 => sprintf( __('Sponsor draft updated. <a target=\"_blank\" href=\"%s\">Preview sponsor</a>', self::$text_domain ), esc_url( add_query_arg( 'preview', 'true', get_permalink($post->ID) ) ) ),\n\t\t);\n\n\t\treturn $messages;\n\t}", "public static function bulk_admin_notices() {\n\t\tglobal $post_type, $pagenow;\n\n\t\tif ( 'edit.php' !== $pagenow || 'shop_subscription' !== $post_type || ! isset( $_REQUEST['bulk_action'] ) || 'remove_personal_data' !== wc_clean( $_REQUEST['bulk_action'] ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$changed = isset( $_REQUEST['changed'] ) ? absint( $_REQUEST['changed'] ) : 0;\n\t\t$message = sprintf( _n( 'Removed personal data from %d subscription.', 'Removed personal data from %d subscriptions.', $changed, 'woocommerce-subscriptions' ), number_format_i18n( $changed ) );\n\t\techo '<div class=\"updated\"><p>' . esc_html( $message ) . '</p></div>';\n\t}", "public static function postUpdatedMessages ($messages) {\n global $post, $post_ID;\n $link = esc_url( get_permalink($post_ID) );\n\n $messages['travelcard'] = array(\n 0 => '',\n 1 => sprintf( __('Card updated. <a href=\"%s\">View card</a>'), $link ),\n 2 => __('Custom field updated.'),\n 3 => __('Custom field deleted.'),\n 4 => __('Card updated.'),\n 5 => isset($_GET['revision']) ? sprintf( __('Card restored to revision from %s'), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n 6 => sprintf( __('Card published. <a href=\"%s\">View card</a>'), $link ),\n 7 => __('Card saved.'),\n 8 => sprintf( __('Card submitted. <a target=\"_blank\" href=\"%s\">Preview card</a>'), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\n 9 => sprintf( __('Card scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview card</a>'), date_i18n( __( 'M j, Y @ G:i' ), strtotime( $post->post_date ) ), $link ),\n 10 => sprintf( __('Card draft updated. <a target=\"_blank\" href=\"%s\">Preview card</a>'), esc_url( add_query_arg( 'preview', 'true', get_permalink($post_ID) ) ) ),\n );\n return $messages;\n }", "function Admin_Messages_admin_update($args)\n{\n // Get parameters from whatever input we need. All arguments to this\n // function should be obtained from pnVarCleanFromInput(), getting them\n // from other places such as the environment is not allowed, as that makes\n // assumptions that will not hold in future versions of PostNuke\n list($mid,\n\t $objectid,\n $title,\n $content,\n $language,\n $active,\n $expire,\n $oldtime,\n $changestartday,\n $whocanview) = pnVarCleanFromInput('mid',\n\t\t 'objectid',\n 'title',\n 'content',\n 'language',\n 'active',\n 'expire',\n 'oldtime',\n 'changestartday',\n 'whocanview');\n\n // User functions of this type can be called by other modules. If this\n // happens then the calling module will be able to pass in arguments to\n // this function through the $args parameter. Hence we extract these\n // arguments *after* we have obtained any form-based input through\n // pnVarCleanFromInput().\n extract($args);\n \n // At this stage we check to see if we have been passed $objectid, the\n // generic item identifier. This could have been passed in by a hook or\n // through some other function calling this as part of a larger module, but\n // if it exists it overrides $mid\n //\n // Note that this module couuld just use $objectid everywhere to avoid all\n // of this munging of variables, but then the resultant code is less\n // descriptive, especially where multiple objects are being used. The\n // decision of which of these ways to go is up to the module developer\n if (!empty($objectid)) {\n $mid = $objectid;\n } \n\n // Confirm authorisation code. This checks that the form had a valid\n // authorisation code attached to it. If it did not then the function will\n // proceed no further as it is possible that this is an attempt at sending\n // in false data to the system\n if (!pnSecConfirmAuthKey()) {\n pnSessionSetVar('errormsg', _BADAUTHKEY);\n pnRedirect(pnModURL('Admin_Messages', 'admin', 'view'));\n return true;\n }\n\n // Notable by its absence there is no security check here. This is because\n // the security check is carried out within the API function and as such we\n // do not duplicate the work here\n\n // The API function is called. Note that the name of the API function and\n // the name of this function are identical, this helps a lot when\n // programming more complex modules. The arguments to the function are\n // passed in as their own arguments array.\n //\n // The return value of the function is checked here, and if the function\n // suceeded then an appropriate message is posted. Note that if the\n // function did not succeed then the API function should have already\n // posted a failure message so no action is required\n if(pnModAPIFunc('Admin_Messages',\n 'admin',\n 'update',\n array('mid' => $mid,\n 'title' => $title,\n 'content' => $content,\n 'language' => $language,\n 'active' => $active,\n 'expire' => $expire,\n 'oldtime' => $oldtime,\n 'changestartday' => $changestartday,\n 'whocanview' => $whocanview))) {\n // Success\n pnSessionSetVar('statusmsg', _ADMINMESSAGESUPDATED);\n }\n\n // This function generated no output, and so now it is complete we redirect\n // the user to an appropriate page for them to carry on their work\n pnRedirect(pnModURL('Admin_Messages', 'admin', 'view'));\n\n // Return\n return true;\n}", "function Admin_Messages_admin_modify($args)\n{\n // Get parameters from whatever input we need. All arguments to this\n // function should be obtained from pnVarCleanFromInput(), getting them\n // from other places such as the environment is not allowed, as that makes\n // assumptions that will not hold in future versions of PostNuke\n list($mid,\n $objectid)= pnVarCleanFromInput('mid',\n 'objectid');\n\n \n // Admin functions of this type can be called by other modules. If this\n // happens then the calling module will be able to pass in arguments to\n // this function through the $args parameter. Hence we extract these\n // arguments *after* we have obtained any form-based input through\n // pnVarCleanFromInput().\n extract($args);\n\n // At this stage we check to see if we have been passed $objecmid, the\n // generic item identifier. This could have been passed in by a hook or\n // through some other function calling this as part of a larger module, but\n // if it exists it overrides $mid\n //\n // Note that this module couuld just use $objecmid everywhere to avoid all\n // of this munging of variables, but then the resultant code is less\n // descriptive, especially where multiple objects are being used. The\n // decision of which of these ways to go is up to the module developer\n if (!empty($objecmid)) {\n $mid = $objecmid;\n } \n\n // Create output object - this object will store all of our output so that\n // we can return it easily when required\n\t$pnRender =& new pnRender('Admin_Messages');\n\n\t// As Admin output changes often, we do not want caching.\n\t$pnRender->caching = false;\n\n // The user API function is called. This takes the item ID which we\n // obtained from the input and gets us the information on the appropriate\n // item. If the item does not exist we post an appropriate message and\n // return\n $item = pnModAPIFunc('Admin_Messages',\n 'user',\n 'get',\n array('mid' => $mid));\n\n if ($item == false) {\n return pnVarPrepHTMLDisplay(_ADMINMESSAGESNOSUCHITEM);\n }\n\n // Security check - important to do this as early as possible to avoid\n // potential security holes or just too much wasted processing. However,\n // in this case we had to wait until we could obtain the item name to\n // complete the instance information so this is the first chance we get to\n // do the check\n if (!pnSecAuthAction(0, 'Admin_Messages::item', \"$item[title]::$mid\", ACCESS_EDIT)) {\n return pnVarPrepHTMLDisplay(_MODULENOAUTH);\n }\n\n\t// Assign the item\n\t$pnRender->assign($item);\n\n // Return the output that has been generated by this function\n return $pnRender->fetch('admin_messages_admin_modify.htm');\n}", "public function add_admin_notices() {\n // add_action( 'admin_notices', array( 'Hotmembers3\\Membership_Areas_Controller', 'perform_on_post') );\n }", "public function register_hooks() {\n\t\tadd_action( 'admin_init', [ $this, 'intercept_save_update_notification' ] );\n\t}", "public function updated_message() {\n\t\t$tab = Template::current_tab();\n\n\t\t// Show updated notice.\n\t\tadd_action( 'beehive_admin_top_notices', function () use ( $tab ) {\n\t\t\tswitch ( $tab ) {\n\t\t\t\tcase 'tracking':\n\t\t\t\t\t$this->notice( __( 'Tracking ID updated successfully.', 'ga_trans' ), 'success', true );\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t$this->notice( __( 'Changes were saved successfully.', 'ga_trans' ), 'success', true );\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t} );\n\t}", "function gp3_custom_post_types_messages($messages) {\n\tglobal $post, $post_ID;\n\t$messages['project'] = array(\n\t\t0 => '', // Unused. Messages start at index 1.\n\t\t1 => sprintf(__('Project updated. <a href=\"%s\">View project</a>', 'gp3ptt'), esc_url(get_permalink($post_ID))),\n\t\t2 => __('Custom field updated.', 'gp3ptt'),\n\t\t3 => __('Custom field deleted.', 'gp3ptt'),\n\t\t4 => __('Project updated.', 'gp3ptt'),\n\t\t/* translators: %s: date and time of the revision */\n\t\t5 => isset($_GET['revision']) ? sprintf(__('Project restored to revision from %s', 'gp3ptt'), wp_post_revision_title((int) $_GET['revision'], false)) : false,\n\t\t6 => sprintf(__('Project published. <a href=\"%s\">View project</a>', 'gp3ptt'), esc_url(get_permalink($post_ID))),\n\t\t7 => __('Project saved.', 'gp3ptt'),\n\t\t8 => sprintf(__('Project submitted. <a target=\"_blank\" href=\"%s\">Preview project</a>', 'gp3ptt'), esc_url(add_query_arg('preview', 'true', get_permalink($post_ID)))),\n\t\t9 => sprintf(__('Project scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview project</a>', 'gp3ptt'),\n\t\t\t// translators: Publish box date format, see http://php.net/date\n\t\t\tdate_i18n(__('M j, Y @ G:i'), strtotime($post->post_date)), esc_url(get_permalink($post_ID))),\n\t\t10 => sprintf(__('Project draft updated. <a target=\"_blank\" href=\"%s\">Preview project</a>', 'gp3ptt'), esc_url(add_query_arg( 'preview', 'true', get_permalink($post_ID)))),\n\t);\n\treturn $messages;\n}", "public function init() {\n\t\tif (is_admin()) {\n\t\t\tadd_action('admin_init', array($this, 'autoupdate'));\n\n\t\t\t$pages = array(\n\t\t\t\t'post',\n\t\t\t\t'post-new',\n\t\t\t);\n\t\t\tif (in_array(self::$page_base, $pages)) {\n\t\t\t\tadd_action('add_meta_boxes', array($this, 'add_meta_box'));\n\t\t\t\tadd_action('save_post', array($this, 'save_meta_data'));\n\t\t\t}\n\n\t\t\tif ('plugins' === self::$page_base)\n\t\t\t\tadd_action('in_plugin_update_message-'.basename(dirname(__FILE__)).'/'.basename(__FILE__), array($this, 'update_message'), 10, 2);\n\t\t} else {\n\t\t\tadd_action('wp_enqueue_scripts', array($this, 'enqueue_additional_css_file'));\n\t\t\tadd_action('wp_print_styles', array($this, 'print_additional_css'));\n\t\t}\n\t}", "protected function _applyPostInstallationMessages()\n\t{\n\t\t// Make sure it's Joomla! 3.2.0 or later\n\t\tif (!version_compare(JVERSION, '3.2.0', 'ge'))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t// Make sure there are post-installation messages\n\t\tif (empty($this->postInstallationMessages))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t// Get the extension ID for our component\n\t\t$db = JFactory::getDbo();\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('extension_id')\n\t\t\t->from('#__extensions')\n\t\t\t->where($db->qn('type') . ' = ' . $db->q('component'))\n\t\t\t->where($db->qn('element') . ' = ' . $db->q($this->componentName));\n\t\t$db->setQuery($query);\n\n\t\ttry\n\t\t{\n\t\t\t$ids = $db->loadColumn();\n\t\t}\n\t\tcatch (Exception $exc)\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\tif (empty($ids))\n\t\t{\n\t\t\treturn;\n\t\t}\n\n\t\t$extension_id = array_shift($ids);\n\n\t\tforeach ($this->postInstallationMessages as $message)\n\t\t{\n\t\t\t$message['extension_id'] = $extension_id;\n\t\t\t$this->addPostInstallationMessage($message);\n\t\t}\n\t}", "public function intercept_save_update_notification() {\n\t\tglobal $pagenow;\n\n\t\tif ( $pagenow !== 'admin.php' || ! YoastSEO()->helpers->current_page->is_yoast_seo_page() ) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Variable name is the same as the global that is set by get_settings_errors.\n\t\t$wp_settings_errors = get_settings_errors();\n\n\t\tforeach ( $wp_settings_errors as $key => $wp_settings_error ) {\n\t\t\tif ( ! $this->is_settings_updated_notification( $wp_settings_error ) ) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tself::$settings_saved = true;\n\t\t\tunset( $wp_settings_errors[ $key ] );\n\t\t\t// Overwrite the global with the list excluding the Changed saved message.\n\t\t\t$GLOBALS['wp_settings_errors'] = $wp_settings_errors;\n\t\t\tbreak;\n\t\t}\n\t}", "private function hooks() {\n\n\t\t\t/** Actions *******************************************************************/\n\n\t\t\t// Build the submenus.\n\t\t\tadd_action( 'admin_menu', array( $this, 'admin_menus' ), 10 );\n\n\t\t\t// Loading the talks edit screen\n\t\t\tadd_action( 'load-edit.php', array( $this, 'load_edit_talk' ) );\n\n\t\t\t// Make sure Editing a plugin's taxonomy highlights the plugin's nav\n\t\t\tadd_action( 'load-edit-tags.php', array( $this, 'taxonomy_highlight' ) );\n\n\t\t\t// Add metaboxes for the post type\n\t\t\tadd_action( \"add_meta_boxes_{$this->post_type}\", array( $this, 'add_metaboxes' ), 10, 1 );\n\t\t\t// Save metabox inputs\n\t\t\tadd_action( \"save_post_{$this->post_type}\", array( $this, 'save_metaboxes' ), 10, 3 );\n\n\t\t\t// Display upgrade notices\n\t\t\tadd_action( 'admin_notices', array( $this, 'admin_notices' ) );\n\n\t\t\t// Register the settings\n\t\t\tadd_action( 'admin_init', array( $this, 'register_admin_settings' ) );\n\n\t\t\tadd_action( 'load-settings_page_wc_talks', array( $this, 'settings_load' ) );\n\n\t\t\t// Talks columns (in post row)\n\t\t\tadd_action( \"manage_{$this->post_type}_posts_custom_column\", array( $this, 'column_data' ), 10, 2 );\n\n\t\t\t// Maybe neutralize quick edit\n\t\t\tadd_action( 'post_row_actions', array( $this, 'talk_row_actions' ), 10, 2 );\n\n\t\t\t// Do some global stuff here (custom css rule)\n\t\t\tadd_action( 'admin_head', array( $this, 'admin_head' ), 10 );\n\n\t\t\t/** Filters *******************************************************************/\n\n\t\t\t// Updated message\n\t\t\tadd_filter( 'post_updated_messages', array( $this, 'talks_updated_messages' ), 10, 1 );\n\t\t\tadd_filter( 'bulk_post_updated_messages', array( $this, 'talks_updated_bulk_messages' ), 10, 2 );\n\n\t\t\t// Redirect\n\t\t\tadd_filter( 'redirect_post_location', array( $this, 'redirect_talk_location' ), 10, 2 );\n\n\t\t\t// Filter the WP_List_Table views to include custom views.\n\t\t\tadd_filter( \"views_edit-{$this->post_type}\", array( $this, 'talk_views' ), 10, 1 );\n\n\t\t\t// temporarly remove bulk edit\n\t\t\tadd_filter( \"bulk_actions-edit-{$this->post_type}\", array( $this, 'talk_bulk_actions' ), 10, 1 );\n\n\t\t\t// Talks column headers.\n\t\t\tadd_filter( \"manage_{$this->post_type}_posts_columns\", array( $this, 'column_headers' ) );\n\n\t\t\t// Add a link to About & settings page in plugins list\n\t\t\tadd_filter( 'plugin_action_links', array( $this, 'modify_plugin_action_links' ), 10, 2 );\n\n\t\t\t/** Specific case: ratings ****************************************************/\n\n\t\t\t// Only sort by rates & display people who voted if ratings is not disabled.\n\t\t\tif ( ! wct_is_rating_disabled() ) {\n\t\t\t\tadd_action( \"manage_edit-{$this->post_type}_sortable_columns\", array( $this, 'sortable_columns' ), 10, 1 );\n\n\t\t\t\t// Manage votes\n\t\t\t\tadd_filter( 'wct_admin_get_meta_boxes', array( $this, 'ratings_metabox' ), 9, 1 );\n\t\t\t\tadd_action( 'load-post.php', array( $this, 'maybe_delete_rate' ) );\n\n\t\t\t\t// Custom feedback\n\t\t\t\tadd_filter( 'wct_admin_updated_messages', array( $this, 'ratings_updated' ), 10, 1 );\n\n\t\t\t\t// Help tabs\n\t\t\t\tadd_filter( 'wct_get_help_tabs', array( $this, 'rates_help_tabs' ), 11, 1 );\n\t\t\t}\n\t\t}", "public function updated_messages($messages) {\n\t\t$revision = isset($_GET['revision']) ? intval($_GET['revision']) : null;\n\n\t\tglobal $post, $post_ID;\n\t\t$messages['el_events'] = array(\n\t\t\t0 => '', // Unused. Messages start at index 1.\n\t\t\t1 => __('Event updated.','event-list').' <a href=\"'.esc_url(get_permalink($post_ID)).'\">'.__('View event','event-list').'</a>',\n\t\t\t2 => '', // Custom field updated is not required (no custom fields)\n\t\t\t3 => '', // Custom field deleted is not required (no custom fields)\n\t\t\t4 => __('Event updated.','event-list'),\n\t\t\t5 => is_null($revision) ? false : sprintf(__('Event restored to revision from %1$s','event-list'), wp_post_revision_title($revision, false)),\n\t\t\t6 => __('Event published.','event-list').' <a href=\"'.esc_url(get_permalink($post_ID)).'\">'.__('View event','event-list').'</a>',\n\t\t\t7 => __('Event saved.'),\n\t\t\t8 => __('Event submitted.','event-list').' <a target=\"_blank\" href=\"'.esc_url(add_query_arg('preview', 'true', get_permalink($post_ID))).'\">'.__('Preview event','event-list').'</a>',\n\t\t\t9 => sprintf(__('Event scheduled for: %1$s>','event-list'), '<strong>'.date_i18n(__('M j, Y @ G:i'), strtotime($post->post_date)).'</strong>').\n\t\t\t ' <a target=\"_blank\" href=\"'.esc_url(get_permalink($post_ID)).'\">'.__('Preview event','event-list').'</a>',\n\t\t\t10 => __('Event draft updated.','event-list').' <a target=\"_blank\" href=\"'.esc_url(add_query_arg('preview', 'true', get_permalink($post_ID))).'\">'.__('Preview event','event-list').'</a>',\n\t\t);\n\t\treturn $messages;\n\t}", "function wp_get_auto_update_message()\n {\n }", "protected function _postUpdate()\n\t{\n\t}", "public function admin_notices()\n\t\t{\n\t\t\t$screen = get_current_screen();\n\t\t\tif (!current_user_can('manage_options') || $screen->id == $this->hook_suffix):\n\t\t\t\treturn;\n\t\t\tendif;\n\n\t\t\t$smtpPasswordUndefined = ( !$this->get_option('password') && ( !defined('MAILGUN_PASSWORD') || !MAILGUN_PASSWORD ) );\n\t\t\t$smtpActiveNotConfigured = ( $this->get_option('useAPI') === '0' && $smtpPasswordUndefined );\n\t\t\t$apiRegionUndefined = ( !$this->get_option('region') && ( !defined('MAILGUN_REGION') || !MAILGUN_REGION ) );\n\t\t\t$apiKeyUndefined = ( !$this->get_option('apiKey') && ( !defined('MAILGUN_APIKEY') || !MAILGUN_APIKEY ));\n\t\t\t$apiActiveNotConfigured = ( $this->get_option('useAPI') === '1' && ( $apiRegionUndefined || $apiKeyUndefined ) );\n\n\t\t\tif ($apiActiveNotConfigured || $smtpActiveNotConfigured):\n?>\n\t\t\t\t<div id='mailgun-warning' class='notice notice-warning is-dismissible'>\n\t\t\t\t\t<p>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tprintf(\n\t\t\t\t\t\t\t\t__('Mailgun now supports multiple regions! The U.S. region will be used by default, but you can choose the EU region. You can configure your Mailgun settings in your wp-config.php file or <a href=\"%1$s\">here</a>',\n\t\t\t\t\t\t\t\t\t'mailgun'),\n\t\t\t\t\t\t\t\tmenu_page_url('mailgun', false)\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t?>\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n<?php\n\t\t\tendif;\n\n\t\t\tif ($this->get_option('override-from') === '1' &&\n\t\t\t\t(!$this->get_option('from-name') || !$this->get_option('from-address'))\n\t\t\t):\n\t\t\t\t?>\n\t\t\t\t<div id='mailgun-warning' class='notice notice-warning is-dismissible'>\n\t\t\t\t\t<p>\n\t\t\t\t\t\t<strong>\n\t\t\t\t\t\t\t<?php _e('Mailgun is almost ready. ', 'mailgun'); ?>\n\t\t\t\t\t\t</strong>\n\t\t\t\t\t\t<?php\n\t\t\t\t\t\t\tprintf(\n\t\t\t\t\t\t\t\t__('\"Override From\" option requires that \"From Name\" and \"From Address\" be set to work properly! <a href=\"%1$s\">Configure Mailgun now</a>.',\n\t\t\t\t\t\t\t\t\t'mailgun'),\n\t\t\t\t\t\t\t\tmenu_page_url('mailgun', false)\n\t\t\t\t\t\t\t);\n?>\n\t\t\t\t\t</p>\n\t\t\t\t</div>\n<?php\n\t\t\tendif;\n\t\t}", "function save_unit_meta_boxes( $post_id ) {\n\t\t/*\n\t\t* If we arent doing an autosave we merge all the extra fields with their corresponding post data.\n\t\t* Next we check to make sure we are saving a unit vs a post or page so we dont make the geocoding \n\t\t* request when we dont need to. Once we geocode the address, we save the long/lat in the DB. Next we \n\t\t* check to see if we are chaging the property from rented to available and if so, we set that date time\n\t\t* so we can calculate the listing age later on.\n\t\t*/\n\t\t\n\t\tif ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return;\n\t\t\n\t\t//Check to make sure we are on a \"Units\" page so we dont geocode on every page save//\n\t\tif (isset($_POST['unitsMetaBoxUpdate']) && $_POST['unitsMetaBoxUpdate'] == 'yesPlease') {\n\n\t\t\t$post_data = array_merge($this->extra_fields, $_POST);\n\t\t\t\n\t\t\tforeach( $this->extra_fields as $key => $value ) {\n\t\t\t\tupdate_post_meta( $post_id, $key, $post_data[$key]);\n\t\t\t}\n\t\t\t\n\t\t\t$address = $post_data['address'].\" \".$post_data['city'].\", \".$post_data['state'].\" \".$post_data['zip'];\n\n\t\t\t$geoCode = $this->_geo_code( $address, $post_data );\n\n\t\t\tupdate_post_meta( $post_id, 'lat', $geoCode['lat']);\n\t\t\tupdate_post_meta( $post_id, 'lon', $geoCode['lon']);\n\n\t\t\t//Lets see if user is making the unit available for rent.//\n\t\t\t//1) Check previous status\n\t\t\t$prevStatus = $_POST['previousStatus'];\n\t\t\t//2) Check if posted value is avail && previousStatus is rented\n\n\t\t\tif ($prevStatus == 'Rented' && $_POST['status'] == 'For Rent') {\n\t\t\t\tupdate_post_meta( $post_id, 'last_avail_date', strtotime('now'));\n\t\t\t} else {\n\t\t\t\tupdate_post_meta( $post_id, 'last_avail_date', $_POST['last_avail_date']);\n\t\t\t}\n\t\t\t\n\t\t}\n\t}", "public function initMessages()\n {\n $this->messages = [\n 'alpha' => '{{name}} must only contain alphabetic characters.',\n 'alnum' => '{{name}} must only contain alpha numeric characters and dashes.',\n 'noWhitespace' => '{{name}} must not contain white spaces.',\n 'length' => '{{name}} must length between {{minValue}} and {{maxValue}}.',\n 'email' => 'Please make sure you typed a correct email address.'\n ];\n }", "public function product_update_post()\n\t\t\t\t{\n\t\t\t\t}", "public function updated_messages($messages)\n {\n global $post, $post_ID;\n\n $messages[$this->token] = [\n 0 => '', // Unused. Messages start at index 1.\n 1 => sprintf(__('Quiz updated. %sView page%s.', $this->token), '<a href=\"' . esc_url(get_permalink($post_ID)) . '\">', '</a>'),\n 4 => __('Quiz updated.', $this->token),\n /* translators: %s: date and time of the revision */\n 5 => isset($_GET['revision']) ? sprintf(__('Quiz restored to revision from %s.', $this->token), wp_post_revision_title((int) $_GET['revision'], false)) : false,\n 6 => sprintf(__('Quiz published. %sView quiz%s.', $this->token), '<a href=\"' . esc_url(get_permalink($post_ID)) . '\">', '</a>'),\n 7 => __('Quiz saved.', $this->token),\n 8 => sprintf(__('Quiz submitted. %sPreview quiz%s.', $this->token), '<a target=\"_blank\" href=\"' . esc_url(add_query_arg('preview', 'true', get_permalink($post_ID))) . '\">', '</a>'),\n 9 => sprintf(__('Quiz scheduled for: %1$s. %2$sPreview quiz%3$s.', $this->token), '<strong>' . date_i18n(__('M j, Y @ G:i', $this->token), strtotime($post->post_date)) . '</strong>', '<a target=\"_blank\" href=\"' . esc_url(get_permalink($post_ID)) . '\">', '</a>'),\n 10 => sprintf(__('Quiz draft updated. %sPreview quiz%s.', $this->token), '<a target=\"_blank\" href=\"' . esc_url(add_query_arg('preview', 'true', get_permalink($post_ID))) . '\">', '</a>'),\n ];\n\n return $messages;\n }", "protected function applyCustomSettings()\n {\n $this->disable(array('read_counter', 'edit_counter', 'deleted_at', 'version', 'creator_user_id', 'created_at'));\n \n $this['updated_at']->setMetaWidgetClassName('ullMetaWidgetDate');\n \n //configure subject\n $this['subject']\n ->setLabel('Subject')\n ->setWidgetAttribute('size', 50)\n ->setMetaWidgetClassName('ullMetaWidgetLink');\n \n //configure body\n $this['body']\n ->setMetaWidgetClassName('ullMetaWidgetFCKEditor')\n ->setLabel('Text');\n \n // configure access level\n $this['ull_wiki_access_level_id']->setLabel(__('Access level', null, 'ullWikiMessages'));\n \n $this['is_outdated']->setLabel(__('Is outdated', null, 'ullWikiMessages'));\n \n // configure tags\n $this['duplicate_tags_for_search']\n ->setLabel('Tags')\n ->setMetaWidgetClassName('ullMetaWidgetTaggable');\n \n if ($this->isCreateOrEditAction())\n {\n $this->disable(array('id', 'updator_user_id', 'updated_at'));\n } \n\n if ($this->isListAction())\n {\n $this->disableAllExcept(array('id', 'subject'));\n $this->enable(array('updator_user_id', 'updated_at'));\n } \n }", "public function runPostHooks() {\n $postHooks = $this->controller->getProperty('postHooks','');\n $this->controller->loadHooks('postHooks');\n $fields = $this->dictionary->toArray();\n $fields['register.user'] =& $this->user;\n $fields['register.profile'] =& $this->profile;\n $fields['register.usergroups'] = $this->userGroups;\n $this->controller->postHooks->loadMultiple($postHooks,$fields);\n\n /* process hooks */\n if ($this->controller->postHooks->hasErrors()) {\n $errors = array();\n $hookErrors = $this->controller->postHooks->getErrors();\n foreach ($hookErrors as $key => $error) {\n $errors[$key] = str_replace('[[+error]]',$error,$this->controller->getProperty('errTpl'));\n }\n $this->modx->toPlaceholders($errors,'error');\n\n $errorMsg = $this->controller->postHooks->getErrorMessage();\n $this->modx->toPlaceholder('message',$errorMsg,'error');\n }\n }", "protected function afterUpdate() {\n\t}", "protected function setPostInstallationMessage(array $options)\n\t{\n $defaultOptions = array(\n 'type' => 'message',\n 'title_key' => '',\n 'description_key' => '',\n 'language_extension' => 'com_cajobboard',\n 'language_client_id' => '1',\n 'condition_file' => '',\n 'condition_method' => '',\n 'version_introduced' => '1.0',\n 'enabled' => '1',\n );\n\n foreach ($options as $key => $value)\n {\n $defaultOptions[$key] = $value;\n }\n\n array_push($this->postInstallationMessages, $defaultOptions);\n }", "public function testUpdateOrderCustomFields()\n {\n }", "function update($units, $total){}", "function woocommerce_rrp_add_bulk_admin_notices() {\n\t\t\tglobal $post_type, $pagenow;\n\t\t\t\n\t\t\tif($pagenow == 'edit.php' && $post_type == 'product' && isset($_REQUEST['price_setted_to_rrp']) && (int) $_REQUEST['price_setted_to_rrp']) {\n\t\t\t\t$message = sprintf( _n( 'Product price setted to RRP.', '%s product prices setted to RRP.', $_REQUEST['price_setted_to_rrp'] ), number_format_i18n( $_REQUEST['price_setted_to_rrp'] ) );\n\t\t\t\techo \"<div class=\\\"updated\\\"><p>{$message}</p></div>\";\n\t\t\t}\n\t\t}", "public static function admin_notices () {\n if( $GLOBALS['hook_suffix'] !== 'plugins.php' ) return;\n\n // could init our plugin, no notice to display\n if( did_action('p2p_wmpl_init') ) return;\n\n // wpml not installed and activated\n if( ! defined('ICL_SITEPRESS_VERSION') )\n $message = sprintf( __('Posts 2 Posts - WPML integration plugin is enabled but not effective. It requires <a href=\"%s\" target=\"_blank\">WPML</a> in order to work.', 'p2p_wpml'), 'http://wpml.org/' );\n\n // p2p not installed and activated\n else\n $message = sprintf( __('Posts 2 Posts - WPML integration plugin is enabled but not effective. It requires <a href=\"%s\" target=\"_blank\">Posts 2 Posts</a> in order to work.', 'p2p_wpml'), 'http://wordpress.org/plugins/posts-to-posts/' );\n ?>\n <div class=\"message error\">\n <p><?php echo $message; ?></p>\n </div>\n <?php\n\n }", "function admin_update_custom_settings() {\n\t// handle the general settings \n\tif(isset($_REQUEST['command']) && $_REQUEST['command'] == 'update_general_settings' && wp_verify_nonce( $_POST['check_ftp'], 'check_ftp' ) ):\n\n\t \t//set the zanders ftp options\n\t \t$message .= update_option('zanders_ftp_server',isset($_POST['zanders_ftp_server']) ? $_POST['zanders_ftp_server'] : '') ? \"<p><strong>Updated Server URL</strong></p>\" : \"\" ;\n\t \t$message .= update_option('zanders_ftp_port',isset($_POST['zanders_ftp_port']) ? $_POST['zanders_ftp_port'] : '') ? \"<p><strong>Updated Server Port</strong></p>\" : \"\" ;\n\t \t$message .= update_option('zanders_ftp_username',isset($_POST['zanders_ftp_server']) ? $_POST['zanders_ftp_username'] : '') ? \"<p><strong>Updated Username</strong></p>\" : \"\" ;\n\t \t$message .= update_option('zanders_ftp_password',isset($_POST['zanders_ftp_password']) ? $_POST['zanders_ftp_password'] : '') ? \"<p><strong>Updated Password</strong></p>\" : \"\" ;\n\n\t \tif($message):\n\t \t\t$_SESSION['message'] .= \"<div class='updated dismissable'>\";\n\t \t\t$_SESSION['message'] .= $message;\n\t \t\t$_SESSION['message'] .= \"</div>\";\n\n \t\tendif;\n\n\t\theader('Location: ' . $_REQUEST['returl'], true, 301);\n\t\tdie();\n\tendif;\n\t//handle the file settings\n\tif(isset($_REQUEST['command']) && $_REQUEST['command'] == 'update_download_files' && wp_verify_nonce( $_POST['check_download_files'], 'check_download_files' ) ):\n\n\t \t//set the zanders ftp options\n\t \t$message .= update_option('zanders_ftp_local_folder',isset($_POST['zanders_ftp_local_folder']) ? $_POST['zanders_ftp_local_folder'] : '') ? \"<p><strong>Updated Local Directory</strong></p>\" : \"\" ;\n\t \t$message .= update_option('zanders_ftp_remote_folder',isset($_POST['zanders_ftp_remote_folder']) ? $_POST['zanders_ftp_remote_folder'] : '') ? \"<p><strong>Updated Remote Directory</strong></p>\" : \"\" ;\n\n\t \tif($message):\n\t \t\t$_SESSION['message'] .= \"<div class='updated dismissable'>\";\n\t \t\t$_SESSION['message'] .= $message;\n\t \t\t$_SESSION['message'] .= \"</div>\";\n \t\tendif;\n\n\t\theader('Location: ' . $_REQUEST['returl'], true, 301);\n\t\tdie();\n\tendif;\t\n\n}", "public function admin_notices()\n {\n if ( get_transient( 'lbry_notices' ) ) {\n $notices = get_transient( 'lbry_notices' );\n foreach ( $notices as $key => $notice ) {\n $this->create_admin_notice( $notice );\n }\n delete_transient( 'lbry_notices' );\n }\n }", "public function messages(array $messages): void {\r\n $this -> message -> set($messages);\r\n }", "protected function afterUpdate()\n {\n }", "protected function afterUpdate()\n {\n }", "protected function setupUpdateOperation()\n {\n $plugin = $this->crud->getEntryWithLocale($this->crud->getCurrentEntryId());\n\n $fields = $plugin->options;\n\n CRUD::addField(['name' => 'fields', 'type' => 'hidden', 'value' => collect($fields)->implode('name', ',')]);\n\n foreach ($fields as $field) {\n CRUD::addField($field);\n }\n }", "function ua_webtide_add_jobs_meta_boxes( $post_type, $post ) {\n add_meta_box( 'mc-wt-job-notifications', 'MailChimp Notifications', 'ua_webtide_print_jobs_meta_boxes', 'jobs', 'side', 'core' );\n \n}", "function wppb_check_epf_rf_cptpms_update( $ep_r_posts, $cpt, $cpt_meta, $internal_id, $array_after_update ){\r\n\tforeach ( $ep_r_posts as $key => $value ){\r\n\t\tif ( $value->post_type == $cpt ){\r\n\t\t\t$post_meta = get_post_meta( $value->ID, $cpt_meta, true );\r\n\r\n\t\t\tif ( !empty( $post_meta ) ){\r\n\t\t\t\tforeach ( $post_meta as $this_post_meta_key => $this_post_meta_value ){\r\n\t\t\t\t\tif ( $this_post_meta_value['id'] == $internal_id ){\r\n\t\t\t\t\t\t$post_meta[$this_post_meta_key]['field'] = wppb_field_format( $array_after_update['field-title'], $array_after_update['field'] );\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\t\r\n\t\t\t\tupdate_post_meta( $value->ID, $cpt_meta, $post_meta );\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n}", "public function after_update() {}", "public function postUpdateCallback()\n {\n $this->performPostUpdateCallback();\n }", "public function postUpdateCallback()\n {\n $this->performPostUpdateCallback();\n }", "function top_lot_updated_messages( $messages ) {\n\tglobal $post;\n\n\t$permalink = get_permalink( $post );\n\n\t$messages['top-lot'] = array(\n\t\t0 => '', // Unused. Messages start at index 1.\n\t\t/* translators: %s: post permalink */\n\t\t1 => sprintf( __( 'Top Lot updated. <a target=\"_blank\" href=\"%s\">View Top Lot</a>', 'wordplate' ), esc_url( $permalink ) ),\n\t\t2 => __( 'Custom field updated.', 'wordplate' ),\n\t\t3 => __( 'Custom field deleted.', 'wordplate' ),\n\t\t4 => __( 'Top Lot updated.', 'wordplate' ),\n\t\t/* translators: %s: date and time of the revision */\n\t\t5 => isset( $_GET['revision'] ) ? sprintf( __( 'Top Lot restored to revision from %s', 'wordplate' ), wp_post_revision_title( (int) $_GET['revision'], false ) ) : false,\n\t\t/* translators: %s: post permalink */\n\t\t6 => sprintf( __( 'Top Lot published. <a href=\"%s\">View Top Lot</a>', 'wordplate' ), esc_url( $permalink ) ),\n\t\t7 => __( 'Top Lot saved.', 'wordplate' ),\n\t\t/* translators: %s: post permalink */\n\t\t8 => sprintf( __( 'Top Lot submitted. <a target=\"_blank\" href=\"%s\">Preview Top Lot</a>', 'wordplate' ), esc_url( add_query_arg( 'preview', 'true', $permalink ) ) ),\n\t\t/* translators: 1: Publish box date format, see https://secure.php.net/date 2: Post permalink */\n\t\t9 => sprintf( __( 'Top Lot scheduled for: <strong>%1$s</strong>. <a target=\"_blank\" href=\"%2$s\">Preview Top Lot</a>', 'wordplate' ),\n\t\tdate_i18n( __( 'M j, Y @ G:i', 'wordplate' ), strtotime( $post->post_date ) ), esc_url( $permalink ) ),\n\t\t/* translators: %s: post permalink */\n\t\t10 => sprintf( __( 'Top Lot draft updated. <a target=\"_blank\" href=\"%s\">Preview Top Lot</a>', 'wordplate' ), esc_url( add_query_arg( 'preview', 'true', $permalink ) ) ),\n\t);\n\n\treturn $messages;\n}", "protected function setMessageType()\n {\n $type = array();\n if ($this->alternativeExists()) {\n $type[] = 'alt';\n }\n if ($this->inlineImageExists()) {\n $type[] = 'inline';\n }\n if ($this->attachmentExists()) {\n $type[] = 'attach';\n }\n $this->message_type = implode('_', $type);\n if ($this->message_type == '') {\n //The 'plain' message_type refers to the message having a single body element, not that it is plain-text\n $this->message_type = 'plain';\n }\n }", "public function admin_enqueue()\r\n {\r\n if (isset($_GET['page']) && $_GET['page'] === 'notifications') {\r\n wp_localize_script('giga-messenger-bots', 'messages', $this->messages);\r\n wp_localize_script('giga-messenger-bots', 'answers', $this->message->content);\r\n }\r\n }", "protected function setSuccessfulEditMessage()\n\t{\n\t\t$message = str_replace( array(\"%succeed%\", \"%total%\"), array( \"<strong>\".$this->nUpdated.\"</strong>\", \"<strong>\".$this->nSelected.\"</strong>\" ), \"%succeed% out of %total% records updated successfully.\");\n\t\t$this->setMessage( $message );\n\t\t\n\t\tif( $this->nUpdated != $this->nSelected ) {\n\t\t\t$message = str_replace( \"%failed%\", \"<strong>\".($this->nSelected - $this->nUpdated).\"</strong>\" , \"%failed% records failed.\");\n\t\t\t$this->setMessage( $message );\n\t\t}\n\t}", "public function setMessages(array $messages) {\n $this->messages = $messages;\n }", "public function admin_scripts() {\n global $wp_query, $post;\n\n $screen = get_current_screen();\n $screen_id = $screen ? $screen->id : '';\n\n // Meta boxes\n if ( in_array( $screen_id, array( 'product', 'edit-product' ) ) ) {\n\n wp_enqueue_style( 'wc-admin-label-meta-box', $this->plugin_url() . '/assets/css/label-metabox.css', array( 'woocommerce_admin_styles' ) );\n wp_enqueue_media();\n wp_enqueue_script( 'wc-admin-label-meta-box', $this->plugin_url() . '/assets/js/label-metabox.js', array( 'wc-admin-product-meta-boxes', 'media-models' ) );\n\n $params = array(\n 'post_id' => isset( $post->ID ) ? $post->ID : '',\n 'plugin_url' => WC()->plugin_url(),\n 'ajax_url' => admin_url( 'admin-ajax.php' ),\n 'woocommerce_placeholder_img_src' => wc_placeholder_img_src(),\n 'i18n_choose_image' => esc_js( __( 'Choose an image', 'wc-label-gallery' ) ),\n );\n\n wp_localize_script( 'wc-admin-label-meta-box', 'wc_admin_label_meta_box', $params );\n }\n\n }", "function tn_prepare_messages() {\n\n\t$_messages = TN_Messages::get_instance();\n\n\t$messages = $_messages->get_messages();\n\n\tif( $messages ) :\n\n\t\tadd_action( 'tn_messages', function() use ( $messages ) { \n\n\t\t\tforeach( $messages as $key => $message ) {\n\t\t\t\t// we add data-message - useful if element is eg cloned to pull it downscreen\n\t\t\t\tif( isset( $message['success'] ) ) : ?>\n\t\t\t\t\t<div data-message=\"<?php echo ++$key; ?>\" class=\"tn_message success\"><?php echo $message['success']; ?></div>\n\t\t\t\t<?php elseif ( isset( $message['error'] ) ) : ?>\n\t\t\t\t\t<div data-message=\"<?php echo ++$key; ?>\" class=\"tn_message error\"><?php echo $message['error']; ?></div>\t\n\t\t\t\t<?php endif; \n\t\t\t}\n\n\t\t});\n\n\tendif;\n}", "function Admin_Messages_admin_updateconfig()\n{\n // Security check - important to do this as early as possible to avoid\n // potential security holes or just too much wasted processing\n if (!pnSecAuthAction(0, 'Admin_Messages::', '::', ACCESS_ADMIN)) {\n return pnVarPrepHTMLDisplay(_MODULENOAUTH);\n }\n\n // Get parameters from whatever input we need. All arguments to this\n // function should be obtained from pnVarCleanFromInput(), getting them\n // from other places such as the environment is not allowed, as that makes\n // assumptions that will not hold in future versions of PostNuke\n $itemsperpage = pnVarCleanFromInput('itemsperpage');\n\n // Confirm authorisation code. This checks that the form had a valid\n // authorisation code attached to it. If it did not then the function will\n // proceed no further as it is possible that this is an attempt at sending\n // in false data to the system\n if (!pnSecConfirmAuthKey()) {\n pnSessionSetVar('errormsg', _BADAUTHKEY);\n pnRedirect(pnModURL('Admin_Messages', 'admin', 'view'));\n return true;\n }\n\n // Update module variables. Note that depending on the HTML structure used\n // to obtain the information from the user it is possible that the values\n // might be unset, so it is important to check them all and assign them\n // default values if required\n if (empty($itemsperpage)) {\n $itemsperpage = 10;\n }\n pnModSetVar('Admin_Messages', 'itemsperpage', $itemsperpage);\n\n // Let any other modules know that the modules configuration has been updated\n pnModCallHooks('module','updateconfig','Admin_Messages', array('module' => 'Admin_Messages'));\n\n\t// the module configuration has been updated successfuly\n\tpnSessionSetVar('statusmsg', _CONFIGUPDATED);\n\n // This function generated no output, and so now it is complete we redirect\n // the user to an appropriate page for them to carry on their work\n pnRedirect(pnModURL('Admin_Messages', 'admin', 'view'));\n\n // Return\n return true;\n}", "public function testUpdateUnsuccessfulReason()\n {\n }", "public function update_items($updates = []) {\n\t\tforeach ($updates as $update) {\n\n\t\t\t// Update all the relevant post meta\n\n\t\t\t// Update the author\n\t\t\tif (isset($update['author']) && !empty($update['author'])) {\n\n\t\t\t\t$author_name = $update['author'][0];\n\n\t\t\t\t// split string, take everything after ,\\s and place at the start followed by space\n\t\t\t\t$keywords = preg_split(\"/,\\s+/\", $author_name);\n\t\t\t\t$author_name = implode(' ', array_reverse($keywords));\n\n\t\t\t\t$args = [\n\t\t\t\t\t'post_type'\t\t\t=> 'tribe_organizer',\n\t\t\t\t\t'post_status' \t\t=> 'publish',\n\t\t\t\t\t'posts_per_page' \t=> 1,\n\t\t\t\t\t'order' \t\t\t=> 'ASC',\n\t\t\t\t\t'fields'\t\t\t=> 'ids',\n\t\t\t\t\t'title' \t\t\t=> $author_name,\n\t\t\t\t]; \n\n\t\t\t\t$posts = get_posts( $args );\n\n\t\t\t\t// If we dont, we need to create a new organizer in the post table\n\t\t\t\tif (empty($posts)) {\n\n\t\t\t\t\t$new_author_args = [\n\t\t\t\t\t\t'post_title' \t=> $author_name,\n\t\t\t\t\t\t'post_status' \t=> 'publish',\n\t\t\t\t\t\t'post_type' \t=> 'tribe_organizer',\n\t\t\t\t\t];\n\n\t\t\t\t\t$new_author = wp_insert_post( $new_author_args );\n\n\t\t\t\t\t// Let WP error handling take over\n\t\t\t\t\tif (is_wp_error( $new_author)) {\n\t\t\t\t\t\treturn $new_author;\n\t\t\t\t\t}\n\n\t\t\t\t\t$posts[0] = $new_author;\n\t\t\t\t}\n\n\t\t\t\t// Get the post content so that we can replace values for gutenburg editor\n\t\t\t\t$content = get_post_field('post_content', $update['post']);\n\n\t\t\t\t// Searching for \n\t\t\t\t// <!-- wp:tribe/event-organizer /-->\n\t\t\t\t// Replacing with\n\t\t\t\t// <!-- wp:tribe/event-organizer {\"organizer\":711} /-->\n\n\t\t\t\t$updated_post_content = str_replace( \n\t\t\t\t\t'<!-- wp:tribe/event-organizer /-->', \n\t\t\t\t\t'<!-- wp:tribe/event-organizer {\"organizer\": ' . $posts[0] . '} /-->',\n\t\t\t\t\t$content\n\t\t\t\t);\n\n\t\t\t\t// Update the title and content\n\t\t\t\twp_update_post( [\n\t\t\t\t\t'ID' => $update['post'],\n\t\t\t\t\t'post_title' => $update['title'],\n\t\t\t\t\t'post_content' => $updated_post_content,\n\t\t\t\t] );\n\n\t\t\t\tif (!empty($posts[0])) {\n\t\t\t\t\t// we can just update this posts's author with the new organizer\n\t\t\t\t\tupdate_post_meta($update['post'], '_EventOrganizerID', $posts[0]);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t// Save the product image\n\t\t\tif (isset($update['image']) && !empty($update['image'])) {\n\t\t\t\tupdate_post_meta($update['post'], 'amazon_product_image_url', $update['image']);\n\t\t\t}\n\n\t\t\t// Update the release date\n\t\t\tif (isset($update['release']) && !empty($update['release'])) {\n\t\t\t\t$release_date = new DateTime($update['release']);\n\n\t\t\t\tif (is_object($release_date)) {\n\t\t\t\t\tupdate_post_meta($update['post'], '_EventStartDate', $release_date->format('Y-m-d H:i:s'));\n\t\t\t\t\tupdate_post_meta($update['post'], '_EventEndDate', $release_date->format('Y-m-d H:i:s'));\n\t\t\t\t\tupdate_post_meta($update['post'], '_EventStartDateUTC', $release_date->format('Y-m-d H:i:s'));\n\t\t\t\t\tupdate_post_meta($update['post'], '_EventEndDateUTC', $release_date->format('Y-m-d H:i:s'));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "public function display_admin_messages() {\n $key = isset($_REQUEST['cs_message']) ? stripslashes($_REQUEST['cs_message']) : false;\n\n if ( $key !== false ) {\n $msg = $this->get_message( $key );\n\n global $CSCore;\n $CSCore->admin_message( $msg['type'], $key, $msg['text'], $this->options_page_slug );\n }\n }", "public function afterUpdate()\n {\n // $this->getDI()\n // ->getMail()\n // ->send([\"[email protected]\" => \"Admin GamanAds\"],\"Update Adspace\", 'updateadspace',\n // [ 'emailBody'=> \"Update Adspace : <b>$this->ad_url</b> from Client Id : <b>$this->client_id</b> Client Name: <b>$this->client_name</b>\"]);\n }", "public function SetCustomVars()\n\t\t{\n\t\t\t$this->_variables['displayname'] = array(\"name\" => GetLang($this->_languagePrefix.\"DisplayName\"),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang('DisplayNameHelp'),\n\t\t\t \"default\" => $this->GetName(),\n\t\t\t \"required\" => true\n\t\t\t);\n\n\t\t\t$this->_variables['MerchantId'] = array(\"name\" => GetLang($this->_languagePrefix.\"MerchantId\"),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang($this->_languagePrefix.'MerchantIdHelp'),\n\t\t\t \"default\" => '',\n\t\t\t \"required\" => true\n\t\t\t);\n\t\t\t$this->_variables['MerchantEmail'] = array(\"name\" => GetLang($this->_languagePrefix.\"MerchantEmail\"),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang($this->_languagePrefix.'MerchantEmailHelp'),\n\t\t\t \"default\" => '',\n\t\t\t \"required\" => true\n\t\t\t);\n\t\t\t$this->_variables['CallbackId'] = array(\"name\" => GetLang($this->_languagePrefix.\"CallbackId\"),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang($this->_languagePrefix.'CallbackIdHelp'),\n\t\t\t \"default\" => '',\n\t\t\t \"required\" => true\n\t\t\t);\n\t\t\t$this->_variables['SecretWord'] = array(\"name\" => GetLang($this->_languagePrefix.\"SecretWord\"),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang($this->_languagePrefix.'SecretWordHelp'),\n\t\t\t \"default\" => '',\n\t\t\t \"required\" => true\n\t\t\t);\n\t\t}", "public function action_load_customizations() {\n\n\t\t$post_type = get_current_screen()->post_type;\n\t\tif ( post_type_supports( $post_type, self::$supports_key ) ) {\n\t\t\tadd_action( 'post_submitbox_misc_actions', array( self::$instance, 'render_unpublish_ui' ), 1 );\n\t\t\tadd_action( 'admin_enqueue_scripts', array( self::$instance, 'enqueue_scripts_styles' ) );\n\t\t\tadd_action( 'save_post_' . $post_type, array( self::$instance, 'action_save_unpublish_timestamp' ) );\n\t\t}\n\n\t}", "public function afterUpdate()\n {\n //only clean and change custom fields if they have been set\n if (!empty($this->customFields)) {\n $this->deleteAllCustomFields();\n $this->saveCustomFields();\n }\n }", "function statusMessagesOn()\n\t{\n\t\t$this->bStatusMessages = true;\n\t}", "protected function update_1607080950()\n\t{\n\t\tglobal $wpdb;\n\t\t\n\t\trequire_once( ABSPATH .'wp-admin/install-helper.php' );\n\t\t\n\t\tmaybe_add_column( \n\t\t\t\"{$wpdb->wistify_queue}\",\n\t\t\t\"queue_errors\",\n\t\t\t\"ALTER TABLE {$wpdb->wistify_queue} ADD `queue_errors` LONGTEXT NULL DEFAULT NULL AFTER `queue_locked`;\" \n\t\t);\n\t\t\n\t\treturn __( 'Ajout d\\'une colonne de report des erreurs dans la file de mail', 'tify' );\n\t}", "function hook_convention_member_updated($member)\n{\n \\Drupal::messenger()->addMessage(t(\"Member %first %last has been updated.\", ['first' => $member['first_name'], 'last' => $member['last_name']]));\n}", "public function admin_notices() {\n\n\t\tif ( $notices = $this->get_notices() ) {\n\t\t\tforeach ( $notices as $notice ) {\n\t\t\t\t$notice->render();\n\t\t\t}\n\t\t}\n\n\t}", "function supporter_bulk_upgrades_setting() {\r\n\t\t\t$supporter_bulk_upgrades_message = stripslashes( get_site_option('supporter_bulk_upgrades_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_message = 'You can upgrade multiple blogs at a lower cost by purchasing Supporter credits below. After purchasing your credits just come back to this page, search for your blogs via the tool at the bottom of the page, and upgrade them. Each blog is upgraded for one year';\r\n\t\t\t}\r\n\r\n\t\t\t$supporter_bulk_upgrades_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_payment_message = 'Depending on your payment method it may take just a few minutes (Credit Card or PayPal funds) or it may take several days (eCheck) for your Supporter credits to become available.';\r\n\t\t\t}\r\n\t\t\t$supporter_bulk_upgrades_1_single_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_1_single_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_1_single_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_1_single_payment_message = 'Upgrade CREDITS blogs for AMOUNT CURRENCY for one year:';\r\n\t\t\t}\r\n\t\t\t$supporter_bulk_upgrades_2_single_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_2_single_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_2_single_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_2_single_payment_message = 'Upgrade CREDITS blogs for AMOUNT CURRENCY for one year:';\r\n\t\t\t}\r\n\t\t\t$supporter_bulk_upgrades_3_single_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_3_single_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_3_single_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_3_single_payment_message = 'Upgrade CREDITS blogs for AMOUNT CURRENCY for one year:';\r\n\t\t\t}\r\n\t\t\t$supporter_bulk_upgrades_1_recurring_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_1_recurring_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_1_recurring_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_1_recurring_payment_message = 'Upgrade CREDITS blogs for AMOUNT CURRENCY for one year (renews each year):';\r\n\t\t\t}\r\n\t\t\t$supporter_bulk_upgrades_2_recurring_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_2_recurring_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_2_recurring_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_2_recurring_payment_message = 'Upgrade CREDITS blogs for AMOUNT CURRENCY for one year (renews each year):';\r\n\t\t\t}\r\n\t\t\t$supporter_bulk_upgrades_3_recurring_payment_message = stripslashes( get_site_option('supporter_bulk_upgrades_3_recurring_payment_message') );\r\n\t\t\tif ( empty( $supporter_bulk_upgrades_3_recurring_payment_message ) ) {\r\n\t\t\t\t$supporter_bulk_upgrades_3_recurring_payment_message = 'Upgrade CREDITS blogs for AMOUNT CURRENCY for one year (renews each year):';\r\n\t\t\t}\r\n\t?>\r\n <tr valign=\"top\"> \r\n <th scope=\"row\"><?php _e('Bulk Upgrades PayPal Payment Type') ?></th> \r\n <td><select name=\"supporter_bulk_upgrades_paypal_payment_type\">\r\n <option value=\"single\" <?php if (get_site_option( \"supporter_bulk_upgrades_paypal_payment_type\" ) == 'single') echo 'selected=\"selected\"'; ?>><?php _e('Single') ?></option>\r\n <option value=\"recurring\" <?php if (get_site_option( \"supporter_bulk_upgrades_paypal_payment_type\" ) == 'recurring') echo 'selected=\"selected\"'; ?>><?php _e('Recurring') ?></option>\r\n </select>\r\n <br />\r\n <?php _e('Recurring = PayPal Subscription') ?></td> \r\n </tr>\r\n <tr valign=\"top\"> \r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option One') ?></th> \r\n <td><select name=\"supporter_bulk_upgrades_1_credits\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_1_credits = get_site_option( \"supporter_bulk_upgrades_1_credits\" );\r\n\t\t\t\t\t$counter = 0;\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 900; $counter += 1) {\r\n echo '<option value=\"' . $counter . '\"' . ($counter == $supporter_bulk_upgrades_1_credits ? ' selected' : '') . '>' . $counter . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n <?php\r\n echo ' ' . __('Credits') . ' ' . __('for') . ' ';\r\n\t\t\t\t?>\r\n <select name=\"supporter_bulk_upgrades_1_whole_cost\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_1_whole_cost = get_site_option( \"supporter_bulk_upgrades_1_whole_cost\" );\r\n\t\t\t\t\t$counter = 0;\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 900; $counter += 1) {\r\n echo '<option value=\"' . $counter . '\"' . ($counter == $supporter_bulk_upgrades_1_whole_cost ? ' selected' : '') . '>' . $counter . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n .\r\n\t\t\t\t<select name=\"supporter_bulk_upgrades_1_partial_cost\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_1_partial_cost = get_site_option( \"supporter_bulk_upgrades_1_partial_cost\" );\r\n\t\t\t\t\t$counter = 0;\r\n echo '<option value=\"00\"' . ('00' == $supporter_bulk_upgrades_1_partial_cost ? ' selected' : '') . '>00</option>' . \"\\n\";\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 99; $counter += 1) {\r\n\t\t\t\t\t\tif ( $counter < 10 ) {\r\n\t\t\t\t\t\t\t$number = '0' . $counter;\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t$number = $counter;\r\n\t\t\t\t\t\t}\r\n echo '<option value=\"' . $number . '\"' . ($number == $supporter_bulk_upgrades_1_partial_cost ? ' selected' : '') . '>' . $number . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n <br /><?php _e('One credit allows for one blog to be upgraded for one year.'); ?></td> \r\n </tr>\r\n <tr valign=\"top\"> \r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option Two') ?></th> \r\n <td><select name=\"supporter_bulk_upgrades_2_credits\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_2_credits = get_site_option( \"supporter_bulk_upgrades_2_credits\" );\r\n\t\t\t\t\t$counter = 0;\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 900; $counter += 1) {\r\n echo '<option value=\"' . $counter . '\"' . ($counter == $supporter_bulk_upgrades_2_credits ? ' selected' : '') . '>' . $counter . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n <?php\r\n echo ' ' . __('Credits') . ' ' . __('for') . ' ';\r\n\t\t\t\t?>\r\n <select name=\"supporter_bulk_upgrades_2_whole_cost\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_2_whole_cost = get_site_option( \"supporter_bulk_upgrades_2_whole_cost\" );\r\n\t\t\t\t\t$counter = 0;\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 900; $counter += 1) {\r\n echo '<option value=\"' . $counter . '\"' . ($counter == $supporter_bulk_upgrades_2_whole_cost ? ' selected' : '') . '>' . $counter . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n .\r\n\t\t\t\t<select name=\"supporter_bulk_upgrades_2_partial_cost\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_2_partial_cost = get_site_option( \"supporter_bulk_upgrades_2_partial_cost\" );\r\n\t\t\t\t\t$counter = 0;\r\n echo '<option value=\"00\"' . ('00' == $supporter_bulk_upgrades_2_partial_cost ? ' selected' : '') . '>00</option>' . \"\\n\";\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 99; $counter += 1) {\r\n\t\t\t\t\t\tif ( $counter < 10 ) {\r\n\t\t\t\t\t\t\t$number = '0' . $counter;\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t$number = $counter;\r\n\t\t\t\t\t\t}\r\n echo '<option value=\"' . $number . '\"' . ($number == $supporter_bulk_upgrades_2_partial_cost ? ' selected' : '') . '>' . $number . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n <br /><?php _e('One credit allows for one blog to be upgraded for one year.'); ?></td> \r\n </tr>\r\n <tr valign=\"top\"> \r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option Three') ?></th> \r\n <td><select name=\"supporter_bulk_upgrades_3_credits\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_3_credits = get_site_option( \"supporter_bulk_upgrades_3_credits\" );\r\n\t\t\t\t\t$counter = 0;\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 900; $counter += 1) {\r\n echo '<option value=\"' . $counter . '\"' . ($counter == $supporter_bulk_upgrades_3_credits ? ' selected' : '') . '>' . $counter . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n <?php\r\n echo ' ' . __('Credits') . ' ' . __('for') . ' ';\r\n\t\t\t\t?>\r\n <select name=\"supporter_bulk_upgrades_3_whole_cost\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_3_whole_cost = get_site_option( \"supporter_bulk_upgrades_3_whole_cost\" );\r\n\t\t\t\t\t$counter = 0;\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 900; $counter += 1) {\r\n echo '<option value=\"' . $counter . '\"' . ($counter == $supporter_bulk_upgrades_3_whole_cost ? ' selected' : '') . '>' . $counter . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n .\r\n\t\t\t\t<select name=\"supporter_bulk_upgrades_3_partial_cost\">\r\n\t\t\t\t<?php\r\n\t\t\t\t\t$supporter_bulk_upgrades_3_partial_cost = get_site_option( \"supporter_bulk_upgrades_3_partial_cost\" );\r\n\t\t\t\t\t$counter = 0;\r\n echo '<option value=\"00\"' . ('00' == $supporter_bulk_upgrades_3_partial_cost ? ' selected' : '') . '>00</option>' . \"\\n\";\r\n\t\t\t\t\tfor ( $counter = 1; $counter <= 99; $counter += 1) {\r\n\t\t\t\t\t\tif ( $counter < 10 ) {\r\n\t\t\t\t\t\t\t$number = '0' . $counter;\r\n\t\t\t\t\t\t} else {\r\n\t\t\t\t\t\t\t$number = $counter;\r\n\t\t\t\t\t\t}\r\n echo '<option value=\"' . $number . '\"' . ($number == $supporter_bulk_upgrades_3_partial_cost ? ' selected' : '') . '>' . $number . '</option>' . \"\\n\";\r\n\t\t\t\t\t}\r\n ?>\r\n </select>\r\n <br /><?php _e('One credit allows for one blog to be upgraded for one year.'); ?></td> \r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_message\" type=\"text\" rows=\"10\" wrap=\"soft\" id=\"supporter_bulk_upgrades_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed - This message is displayed at the top of the \"Bulk Upgrades\" page.') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_payment_message\" type=\"text\" rows=\"5\" wrap=\"soft\" id=\"supporter_bulk_upgrades_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option One Single Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_1_single_payment_message\" type=\"text\" rows=\"3\" wrap=\"soft\" id=\"supporter_bulk_upgrades_1_single_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_1_single_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?>\r\n <br /><?php echo '\"CREDITS\"' . ' ' . _('Will be replaced by the number of credits chosen above') ?>\r\n <br /><?php echo '\"AMOUNT\"' . ' ' . _('Will be replaced by the amount chosen above') ?>\r\n <br /><?php echo '\"CURRENCY\"' . ' ' . _('Will be replaced by the currency chosen above') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option Two Single Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_2_single_payment_message\" type=\"text\" rows=\"3\" wrap=\"soft\" id=\"supporter_bulk_upgrades_2_single_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_2_single_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?>\r\n <br /><?php echo '\"CREDITS\"' . ' ' . _('Will be replaced by the number of credits chosen above') ?>\r\n <br /><?php echo '\"AMOUNT\"' . ' ' . _('Will be replaced by the amount chosen above') ?>\r\n <br /><?php echo '\"CURRENCY\"' . ' ' . _('Will be replaced by the currency chosen above') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option Three Single Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_3_single_payment_message\" type=\"text\" rows=\"3\" wrap=\"soft\" id=\"supporter_bulk_upgrades_3_single_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_3_single_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?>\r\n <br /><?php echo '\"CREDITS\"' . ' ' . _('Will be replaced by the number of credits chosen above') ?>\r\n <br /><?php echo '\"AMOUNT\"' . ' ' . _('Will be replaced by the amount chosen above') ?>\r\n <br /><?php echo '\"CURRENCY\"' . ' ' . _('Will be replaced by the currency chosen above') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option One Recurring Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_1_recurring_payment_message\" type=\"text\" rows=\"3\" wrap=\"soft\" id=\"supporter_bulk_upgrades_1_recurring_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_1_recurring_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?>\r\n <br /><?php echo '\"CREDITS\"' . ' ' . _('Will be replaced by the number of credits chosen above') ?>\r\n <br /><?php echo '\"AMOUNT\"' . ' ' . _('Will be replaced by the amount chosen above') ?>\r\n <br /><?php echo '\"CURRENCY\"' . ' ' . _('Will be replaced by the currency chosen above') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option Two Recurring Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_2_recurring_payment_message\" type=\"text\" rows=\"3\" wrap=\"soft\" id=\"supporter_bulk_upgrades_2_recurring_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_2_recurring_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?>\r\n <br /><?php echo '\"CREDITS\"' . ' ' . _('Will be replaced by the number of credits chosen above') ?>\r\n <br /><?php echo '\"AMOUNT\"' . ' ' . _('Will be replaced by the amount chosen above') ?>\r\n <br /><?php echo '\"CURRENCY\"' . ' ' . _('Will be replaced by the currency chosen above') ?></td>\r\n </tr>\r\n <tr valign=\"top\">\r\n <th scope=\"row\"><?php _e('Bulk Upgrades Option Three Recurring Payment Message') ?></th>\r\n <td>\r\n <textarea name=\"supporter_bulk_upgrades_3_recurring_payment_message\" type=\"text\" rows=\"3\" wrap=\"soft\" id=\"supporter_bulk_upgrades_3_recurring_payment_message\" style=\"width: 95%\"/><?php echo $supporter_bulk_upgrades_3_recurring_payment_message; ?></textarea>\r\n <br /><?php _e('Required - HTML allowed') ?>\r\n <br /><?php echo '\"CREDITS\"' . ' ' . _('Will be replaced by the number of credits chosen above') ?>\r\n <br /><?php echo '\"AMOUNT\"' . ' ' . _('Will be replaced by the amount chosen above') ?>\r\n <br /><?php echo '\"CURRENCY\"' . ' ' . _('Will be replaced by the currency chosen above') ?></td>\r\n </tr>\r\n <?php\r\n}", "public function add_hooks() {\n\t\tadd_action( 'pre_post_update', array( $this, 'migrate_location' ) );\n\t\tadd_action( 'save_post', array( $this, 'queue_save_post_actions' ), PHP_INT_MAX, 2 );\n\t\tadd_action( 'wpml_pb_resave_post_translation', array( $this, 'resave_post_translation_in_shutdown' ), 10, 1 );\n\t\tadd_action( 'icl_st_add_string_translation', array( $this, 'new_translation' ), 10, 1 );\n\t\tadd_action( 'wpml_pb_finished_adding_string_translations', array( $this, 'process_pb_content_with_hidden_strings_only' ), 9, 2 );\n\t\tadd_action( 'wpml_pb_finished_adding_string_translations', array( $this, 'save_translations_to_post' ), 10 );\n\t\tadd_action( 'wpml_pro_translation_completed', array( $this, 'cleanup_strings_after_translation_completed' ), 10, 3 );\n\n\t\tadd_filter( 'wpml_tm_translation_job_data', array( $this, 'rescan' ), 9, 2 );\n\n\t\tadd_action( 'wpml_pb_register_all_strings_for_translation', [ $this, 'register_all_strings_for_translation' ] );\n\t\tadd_filter( 'wpml_pb_register_strings_in_content', [ $this, 'register_strings_in_content' ], 10, 3 );\n\t\tadd_filter( 'wpml_pb_update_translations_in_content', [ $this, 'update_translations_in_content'], 10, 2 );\n\n\t\tadd_action( 'wpml_start_GB_register_strings', [ $this, 'initialize_string_clean_up' ], 10, 1 );\n\t\tadd_action( 'wpml_end_GB_register_strings', [ $this, 'clean_up_strings' ], 10, 1 );\n\t}", "public function admin_notices() {\n\t\t\t$notices = wct_get_global( 'feedback' );\n\n\t\t\tif ( empty( $notices['admin_notices'] ) ) {\n\t\t\t\treturn;\n\t\t\t}\n\t\t\t?>\n\t\t\t<div class=\"update-nag\">\n\t\t\t\t<?php foreach ( $notices['admin_notices'] as $notice ) : ?>\n\t\t\t\t\t<p><?php echo $notice; ?></p>\n\t\t\t\t<?php endforeach ;?>\n\t\t\t</div>\n\t\t\t<?php\n\t\t}", "function setMessage($text, $type = \"default\") {\n\tglobal $systemMessages;\n\t$systemMessages[$type][] = $text;\n}", "function wp_get_translation_updates()\n {\n }", "protected function afterUpdating()\n {\n }", "function InstallPostMessage() {\n\t\treturn $this->Lang('postinstall');\n\t}", "public function adminNotices ()\n {\n\n if ( $this->errors ) {\n\n $this->handleNotices ( $this->errors, 'error' );\n\n }\n if ( $this->notices ) {\n\n $this->handleNotices ( $this->notices, 'update-nag' );\n\n }\n if ( $this->updates ) {\n\n $this->handleNotices ( $this->updates );\n\n }\n\n }", "public function setMetaboxes() {\n $metaboxTemp = new Metabox();\n\n $args = array(\n // ## Certification ##\n array(\n 'id' => self::MTB_CERT,\n 'title' => 'Certification Type',\n 'callback' => array($metaboxTemp, 'certification'),\n 'screen' => self::POST_TYPE_BADGES,\n 'context' => 'side',\n 'priority' => 'high',\n ),\n // ## Target ##\n array(\n 'id' => self::MTB_TARGET,\n 'title' => 'Target Type',\n 'callback' => array($metaboxTemp, 'target'),\n 'screen' => self::POST_TYPE_BADGES,\n 'context' => 'side',\n 'priority' => 'high',\n ),\n );\n\n $this->settings->loadMetaBoxes($args);\n }", "public function SetCustomVars()\n\t\t{\n\t\t\t$this->_variables['displayname'] = array(\"name\" => GetLang($this->_languagePrefix.'DisplayName'),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang('DisplayNameHelp'),\n\t\t\t \"default\" => $this->GetName(),\n\t\t\t \"required\" => true\n\t\t\t);\n\n\t\t\t$this->_variables['productid'] = array(\"name\" => GetLang($this->_languagePrefix.'ProductId'),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang($this->_languagePrefix.'ProductIdHelp'),\n\t\t\t \"default\" => \"\",\n\t\t\t \"required\" => true\n\t\t\t);\n\n\t\t\t$this->_variables['sharedsecret'] = array(\"name\" => GetLang($this->_languagePrefix.'SharedSecret'),\n\t\t\t \"type\" => \"textbox\",\n\t\t\t \"help\" => GetLang($this->_languagePrefix.'SharedSecretHelp'),\n\t\t\t \"default\" => \"\",\n\t\t\t \"required\" => true\n\t\t\t);\n\t\t}", "private function admin_page_notices() {\n\t\tif ( ! isset( $_POST['_wpnonce'] ) || ! wp_verify_nonce( sanitize_key( wp_unslash( $_POST['_wpnonce'] ) ), 'gu_settings' ) ) {\n\t\t\treturn;\n\t\t}\n\t\t$display = isset( $_POST['install_api_plugin'] ) && '1' === $_POST['install_api_plugin'];\n\t\tif ( $display ) {\n\t\t\techo '<div class=\"updated\"><p>';\n\t\t\tesc_html_e( 'Git Updater API plugin installed.', 'git-updater' );\n\t\t\techo '</p></div>';\n\t\t}\n\t}", "public function on_loco_admin_notices(){\n $this->inline = true;\n $this->flush();\n }", "function wck_update_meta(){\r\n\t\tcheck_ajax_referer( \"wck-update-entry\" );\r\n\t\tif( !empty( $_POST['meta'] ) )\r\n\t\t\t$meta = sanitize_text_field( $_POST['meta'] );\r\n\t\telse \r\n\t\t\t$meta = '';\r\n\t\tif( !empty( $_POST['id'] ) )\r\n\t\t\t$id = absint($_POST['id']);\r\n\t\telse \r\n\t\t\t$id = '';\r\n\t\tif( isset( $_POST['element_id'] ) )\r\n\t\t\t$element_id = absint( $_POST['element_id'] );\r\n\t\telse \r\n\t\t\t$element_id = 0;\r\n\t\tif( !empty( $_POST['values'] ) && is_array( $_POST['values']) )\r\n\t\t\t$values = array_map( 'wppb_sanitize_value', $_POST['values'] );\r\n\t\telse\r\n\t\t\t$values = array();\r\n\t\t\r\n\t\t// Security checks\r\n\t\tif( true !== ( $error = self::wck_verify_user_capabilities( $this->args['context'], $meta, $id ) ) ) {\r\n\t\t\theader( 'Content-type: application/json' );\r\n\t\t\tdie( json_encode( $error ) );\r\n\t\t}\r\n\t\t\r\n\t\t$values = apply_filters( \"wck_update_meta_filter_values_{$meta}\", $values, $element_id );\r\n\t\t\r\n\t\t/* check required fields */\r\n\t\t$errors = self::wck_test_required( $this->args['meta_array'], $meta, $values, $id );\r\n\t\tif( $errors != '' ){\r\n\t\t\theader( 'Content-type: application/json' );\r\n\t\t\tdie( json_encode( $errors ) );\r\n\t\t}\r\n\t\t\r\n\t\tif( $this->args['context'] == 'post_meta' )\r\n\t\t\t$results = get_post_meta($id, $meta, true);\r\n\t\telse if ( $this->args['context'] == 'option' )\r\n\t\t\t$results = get_option( apply_filters( 'wck_option_meta' , $meta, $values, $element_id ) );\r\n\t\t\r\n\t\t$results[$element_id] = $values;\r\n\r\n\t\t/* make sure this does not output anything so it won't break the json response below\r\n\t\twill keep it do_action for compatibility reasons\r\n\t\t */\r\n\t\tob_start();\r\n\t\t\tdo_action( 'wck_before_update_meta', $meta, $id, $values, $element_id );\r\n\t\t$wck_before_update_meta = ob_get_clean(); //don't output it\r\n\t\t\r\n\r\n\t\tif( $this->args['context'] == 'post_meta' )\r\n\t\t\tupdate_post_meta($id, $meta, $results);\r\n\t\telse if ( $this->args['context'] == 'option' )\r\n\t\t\tupdate_option( apply_filters( 'wck_option_meta' , $meta, $results, $element_id ), wp_unslash( $results ) );\r\n\t\t\r\n\t\t/* if unserialize_fields is true update the coresponding post metas for every element of the form */\r\n\t\tif( $this->args['unserialize_fields'] && $this->args['context'] == 'post_meta' ){\r\n\t\t\t\r\n\t\t\t$meta_suffix = $element_id + 1;\t\r\n\t\t\tif( !empty( $values ) ){\r\n\t\t\t\tforeach( $values as $name => $value ){\r\n\t\t\t\t\tupdate_post_meta($id, $meta.'_'.$name.'_'.$meta_suffix, $value);\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$entry_content = $this->wck_refresh_entry( $meta, $id, $element_id );\t\t\r\n\r\n\t\theader( 'Content-type: application/json' );\r\n\t\tdie( json_encode( array( 'entry_content' => $entry_content ) ) );\r\n\t}", "public function testUpdateExternalShipmentCustomFields()\n {\n }", "private function define_admin_hooks() {\n\n\t\t$plugin_admin = MailChimp_WooCommerce_Admin::instance();\n\n\t\t$this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_styles');\n\t\t$this->loader->add_action('admin_enqueue_scripts', $plugin_admin, 'enqueue_scripts');\n\n\t\t// Add menu item\n\t\t$this->loader->add_action('admin_menu', $plugin_admin, 'add_plugin_admin_menu');\n\n\t\t// Add Settings link to the plugin\n\t\t$plugin_basename = plugin_basename( plugin_dir_path( __DIR__ ) . $this->plugin_name . '.php');\n\t\t$this->loader->add_filter('plugin_action_links_' . $plugin_basename, $plugin_admin, 'add_action_links');\n\n\t\t// make sure we're listening for the admin init\n\t\t$this->loader->add_action('admin_init', $plugin_admin, 'options_update');\n\n\t\t// put the menu on the admin top bar.\n\t\t//$this->loader->add_action('admin_bar_menu', $plugin_admin, 'admin_bar', 100);\n\n $this->loader->add_action('plugins_loaded', $plugin_admin, 'update_db_check');\n $this->loader->add_action('admin_init', $plugin_admin, 'setup_survey_form');\n $this->loader->add_action('admin_footer', $plugin_admin, 'inject_sync_ajax_call');\n\n // update MC store information when woocommerce general settings are saved\n $this->loader->add_action('woocommerce_settings_save_general', $plugin_admin, 'mailchimp_update_woo_settings');\n \n // update MC store information if \"WooCommerce Multi-Currency Extension\" settings are saved\n if ( class_exists( 'WOOMULTI_CURRENCY_F' ) ) {\n $this->loader->add_action('villatheme_support_woo-multi-currency', $plugin_admin, 'mailchimp_update_woo_settings');\n }\n }", "public function executeAdminNotify()\n {\n if ( in_array( $this->getParameter( 'option_name' ), array( 'bookly_sms_notify_low_balance', 'bookly_sms_notify_weekly_summary' ) ) ) {\n update_option( $this->getParameter( 'option_name' ), $this->getParameter( 'value' ) );\n }\n wp_send_json_success();\n }", "function after_update() {}", "function thrive_dashboard_add_message($message)\n{\n $messages = get_option('td_messages', array());\n\n if (is_string($message)) {\n $message = array(\n 'text' => $message,\n 'css_class' => 'info'\n );\n }\n\n $messages[] = $message;\n update_option('td_messages', $messages);\n}", "protected function setMessageType()\n {\n }", "function before_update() {}", "function applyCustomUpdates()\n\t{\n\t\tglobal $ilCtrlStructureReader;\n\n\t\t$ilCtrlStructureReader->setIniFile($this->setup->getClient()->ini);\n\n\t\tinclude_once \"./Services/Database/classes/class.ilDBUpdate.php\";\n\t\tinclude_once \"./Services/AccessControl/classes/class.ilRbacAdmin.php\";\n\t\tinclude_once \"./Services/AccessControl/classes/class.ilRbacReview.php\";\n\t\tinclude_once \"./Services/AccessControl/classes/class.ilRbacSystem.php\";\n\t\tinclude_once \"./Services/Tree/classes/class.ilTree.php\";\n\t\tinclude_once \"./Services/Xml/classes/class.ilSaxParser.php\";\n\t\tinclude_once \"./Services/Object/classes/class.ilObjectDefinition.php\";\n\n\t\t// referencing db handler in language class\n\t\t$ilDB = $this->setup->getClient()->db;\n\t\t$this->lng->setDbHandler($ilDB);\n\n\t\t// run dbupdate\n\t\t$dbupdate = new ilDBUpdate($ilDB);\n\t\t$dbupdate->applyCustomUpdates();\n\n\t\tif ($dbupdate->updateMsg == \"no_changes\")\n\t\t{\n\t\t\t$message = $this->lng->txt(\"no_changes\").\". \".$this->lng->txt(\"database_is_uptodate\");\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$sep = \"\";\n\t\t\tforeach ($dbupdate->updateMsg as $row)\n\t\t\t{\n\t\t\t\tif ($row[\"msg\"] == \"update_applied\")\n\t\t\t\t{\n\t\t\t\t\t$a_message.= $sep.$row[\"nr\"];\n\t\t\t\t\t$sep = \", \";\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$e_message.= \"<br/>\".$this->lng->txt($row[\"msg\"]).\": \".$row[\"nr\"];\n\t\t\t\t}\n\t\t\t}\n\t\t\tif ($a_message != \"\")\n\t\t\t{\n\t\t\t\t$a_message = $this->lng->txt(\"update_applied\").\": \".$a_message;\n\t\t\t}\n\t\t}\n\n\t\tilUtil::sendInfo($a_message.$e_message, true);\n\t\tilUtil::redirect(\"setup.php?cmd=displayDatabase\");\n\t}", "public function admin_notices() {\r\n\t\tif ( get_option( 'thread_comments' ) != '1' ) {\r\n\r\n\t\t$html = sprintf(\r\n\t\t __('@Reply Two requires threaded comments to function properly. <a href=\"%s\">Update Settings Now</a>', 'at-reply-two'),\r\n\t\t admin_url('options-discussion.php')\r\n\t\t);\r\n\t\t\t?>\r\n\t\t\t<div class=\"error\">\r\n\t\t\t\t<p><?php echo $html; ?></p>\r\n\t\t\t</div>\r\n\t\t\t<?php\r\n\t\t}\r\n\r\n\t}", "public function add_post_metaboxes() {\n\t\tif( empty( $this->push_syndicate_settings['selected_post_types'] ) )\n\t\t\treturn;\n\n\t\tif( !$this->current_user_can_syndicate() )\n\t\t\treturn;\n\n\t\t$selected_post_types = $this->push_syndicate_settings[ 'selected_post_types' ];\n\t\tforeach( $selected_post_types as $selected_post_type ) {\n\t\t\tadd_meta_box( 'syndicatediv', __( ' Syndicate ' ), array( $this, 'add_syndicate_metabox' ), $selected_post_type, 'side', 'high' );\n\t\t\t//add_meta_box( 'syndicationstatusdiv', __( ' Syndication Status ' ), array( $this, 'add_syndication_status_metabox' ), $selected_post_type, 'normal', 'high' );\n\t\t}\n\n\t}", "protected function send_plugin_theme_email($type, $successful_updates, $failed_updates)\n {\n }" ]
[ "0.6877475", "0.6567271", "0.6310768", "0.624991", "0.6169963", "0.6168723", "0.5782762", "0.564999", "0.5647439", "0.5593254", "0.5571341", "0.55684596", "0.5518046", "0.54790485", "0.547759", "0.54534394", "0.54157263", "0.52883714", "0.5254608", "0.5242985", "0.52407515", "0.5182665", "0.51656026", "0.5145373", "0.51343066", "0.5101458", "0.50711834", "0.50434035", "0.50388557", "0.5022221", "0.5001506", "0.4998029", "0.49913788", "0.497786", "0.49757302", "0.49739167", "0.49724263", "0.49655744", "0.49450815", "0.49289963", "0.49143097", "0.4914108", "0.4912239", "0.49096972", "0.49062148", "0.49034432", "0.49003336", "0.4900069", "0.4872556", "0.4870497", "0.4870497", "0.48671263", "0.48642287", "0.48617002", "0.48611313", "0.48609", "0.48609", "0.48536012", "0.48458433", "0.4844605", "0.48317987", "0.48233125", "0.4811171", "0.48061192", "0.48032907", "0.48019293", "0.47833323", "0.47833282", "0.4783084", "0.47825643", "0.47790226", "0.47659266", "0.47615328", "0.4760936", "0.47578552", "0.4747591", "0.47303018", "0.4716785", "0.47124594", "0.47109017", "0.47072232", "0.47025052", "0.4701903", "0.46993598", "0.4698396", "0.46951205", "0.4693727", "0.46895707", "0.46842673", "0.4684143", "0.46787134", "0.46741983", "0.46707064", "0.4666814", "0.4661225", "0.4658076", "0.46523523", "0.46464774", "0.46441", "0.46434227" ]
0.6879671
0
Check if the user has overwritten the default templates and loads them is they have. If not, we default to the templates included in the plugin.
function load_templates( $template ) { if ( is_singular( 'units' ) ) { if ( $overridden_template = locate_template( 'single-units.php' ) ) { $template = $overridden_template; } else { $template = plugin_dir_path( __file__ ) . 'templates/single-units.php'; } } elseif ( is_archive( 'units' ) ) { if ( $overridden_template = locate_template( 'archive-units.php' ) ) { $template = $overridden_template; } else { $template = plugin_dir_path( __file__ ) . 'templates/archive-units.php'; } } load_template( $template ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function defaultTemplate(){\n $this->addLocations(); // add addon files to pathfinder\n return array($this->template_file);\n }", "function load_plugin_templates() : void {\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/subscriber-only-message.php';\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/split-content-message.php';\n\trequire_once plugin_dir_path( __FILE__ ) . '../templates/messages/banner-message.php';\n}", "private function _load_template()\n\t\t{\n\t\t\t//check for a custom template\n\t\t\t$template_file = 'views/'.$this->template_file.'.tpl';\n\n\n\t\t\tif(file_exists($template_file) && is_readable($template_file))\n\t\t\t{\n\t\t\t\t$path = $template_file;\n\t\t\t}\n\t\t\telse if(file_exists($default_file = 'views/error/index.php') && is_readable($default_file))\n\t\t\t{\n\t\t\t\t$path = $default_file;\n\t\t\t}\n\n\t\t\t//If the default template is missing, throw an error\n\t\t\telse\n\t\t\t{\n\t\t\t\tthrow new Exception(\"No default template found\");\n\t\t\t}\n\n\n\t\t\t//Load the contents of the file and return them\n\t\t\t$this->_template = file_get_contents($path);\n\n\t\t}", "public function loadTemplate()\n\t\t{\n\t\t}", "private function setTemplate(){\n if (isset($this->data['template']) && !empty($this->data['template'])){\n $template = APP_ROOT.'/app/templates/'.trim($this->data['template']).'.tpl';\n if (file_exists($template)){\n $this->template = $template;\n return;\n }\n }\n //default\n $this->template = APP_ROOT.'/app/templates/default.tpl';\n }", "public function loadTemplate()\n\t{\n\t\t$t_location = \\IPS\\Request::i()->t_location;\n\t\t$t_key = \\IPS\\Request::i()->t_key;\n\t\t\n\t\tif ( $t_location === 'block' and $t_key === '_default_' and isset( \\IPS\\Request::i()->block_key ) )\n\t\t{\n\t\t\t/* Find it from the normal template system */\n\t\t\tif ( isset( \\IPS\\Request::i()->block_app ) )\n\t\t\t{\n\t\t\t\t$plugin = \\IPS\\Widget::load( \\IPS\\Application::load( \\IPS\\Request::i()->block_app ), \\IPS\\Request::i()->block_key, mt_rand() );\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$plugin = \\IPS\\Widget::load( \\IPS\\Plugin::load( \\IPS\\Request::i()->block_plugin ), \\IPS\\Request::i()->block_key, mt_rand() );\n\t\t\t}\n\t\t\t\n\t\t\t$location = $plugin->getTemplateLocation();\n\t\t\t\n\t\t\t$templateBits = \\IPS\\Theme::master()->getRawTemplates( $location['app'], $location['location'], $location['group'], \\IPS\\Theme::RETURN_ALL );\n\t\t\t$templateBit = $templateBits[ $location['app'] ][ $location['location'] ][ $location['group'] ][ $location['name'] ];\n\t\t\t\n\t\t\tif ( ! isset( \\IPS\\Request::i()->noencode ) OR ! \\IPS\\Request::i()->noencode )\n\t\t\t{\n\t\t\t\t$templateBit['template_content'] = htmlentities( $templateBit['template_content'], ENT_DISALLOWED, 'UTF-8', TRUE );\n\t\t\t}\n\t\t\t\n\t\t\t$templateArray = array(\n\t\t\t\t'template_id' \t\t\t=> $templateBit['template_id'],\n\t\t\t\t'template_key' \t\t\t=> 'template_' . $templateBit['template_name'] . '.' . $templateBit['template_id'],\n\t\t\t\t'template_title'\t\t=> $templateBit['template_name'],\n\t\t\t\t'template_desc' \t\t=> null,\n\t\t\t\t'template_content' \t\t=> $templateBit['template_content'],\n\t\t\t\t'template_location' \t=> null,\n\t\t\t\t'template_group' \t\t=> null,\n\t\t\t\t'template_container' \t=> null,\n\t\t\t\t'template_rel_id' \t\t=> null,\n\t\t\t\t'template_user_created' => null,\n\t\t\t\t'template_user_edited' => null,\n\t\t\t\t'template_params' \t => $templateBit['template_data']\n\t\t\t);\n\t\t}\n\t\telse\n\t\t{\n\t\t\ttry\n\t\t\t{\n\t\t\t\tif ( \\is_numeric( $t_key ) )\n\t\t\t\t{\n\t\t\t\t\t$template = \\IPS\\cms\\Templates::load( $t_key, 'template_id' );\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$template = \\IPS\\cms\\Templates::load( $t_key );\n\t\t\t\t}\n\t\t\t}\n\t\t\tcatch( \\OutOfRangeException $ex )\n\t\t\t{\n\t\t\t\t\\IPS\\Output::i()->json( array( 'error' => true ) );\n\t\t\t}\n\n\t\t\tif ( $template !== null )\n\t\t\t{\n\t\t\t\t$templateArray = array(\n\t 'template_id' \t\t\t=> $template->id,\n\t 'template_key' \t\t\t=> $template->key,\n\t 'template_title'\t\t=> $template->title,\n\t 'template_desc' \t\t=> $template->desc,\n\t 'template_content' \t\t=> ( isset( \\IPS\\Request::i()->noencode ) AND \\IPS\\Request::i()->noencode ) ? $template->content : htmlentities( $template->content, ENT_DISALLOWED, 'UTF-8', TRUE ),\n\t 'template_location' \t=> $template->location,\n\t 'template_group' \t\t=> $template->group,\n\t 'template_container' \t=> $template->container,\n\t 'template_rel_id' \t\t=> $template->rel_id,\n\t 'template_user_created' => $template->user_created,\n\t 'template_user_edited' => $template->user_edited,\n\t 'template_params' \t => $template->params\n\t );\n\t\t\t}\n\t\t}\n\n\t\tif ( \\IPS\\Request::i()->show == 'json' )\n\t\t{\n\t\t\t\\IPS\\Output::i()->json( $templateArray );\n\t\t}\n\t\telse\n\t\t{\n\t\t\t\\IPS\\Output::i()->sendOutput( \\IPS\\Theme::i()->getTemplate( 'global', 'core' )->blankTemplate( \\IPS\\Theme::i()->getTemplate( 'templates', 'cms', 'admin' )->viewTemplate( $templateArray ) ), 200, 'text/html', \\IPS\\Output::i()->httpHeaders );\n\t\t}\n\t}", "function zr_template_load( $template ){ \n\tif( !is_user_logged_in() && zr_options('maintaince_enable') ){\n\t\t$template = ZRPATH . 'includes/maintaince/maintaince.php';\n\t}\n\treturn $template;\n}", "function youpztStore_get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {\n if ( $args && is_array( $args ) ) {\n extract( $args );\n }\n\n $located = youpztStore_locate_template( $template_name, $template_path, $default_path );\n\n if ( ! file_exists( $located ) ) {\n //_doing_it_wrong( __FUNCTION__, sprintf( '<code>%s</code> does not exist.', $located ), '2.1' );\n return;\n }\n\n // Allow 3rd party plugin filter template file from their plugin.\n $located = apply_filters('youpztStore_get_template', $located, $template_name, $args, $template_path, $default_path );\n\n include( $located );\n\n}", "protected function setDefaultTemplate()\n {\n $defaultTemplate = $this->config->getKey('default_template');\n $this->setTemplate($defaultTemplate);\n }", "function stage_get_fallback_template($chosen_key, $default_key = null, $data = array())\n{\n // Does the file exist -> return\n $path = Settings::getFallbackTemplatePath($chosen_key, $default_key);\n return stage_render_template($path, $data);\n}", "function youpztStore_locate_template( $template_name, $template_path = '', $default_path = '' ) {\n if ( ! $template_path ) {\n $template_path =UPSTORE_TEMPLATE_DIR;\n }\n\n if ( ! $default_path ) {\n $default_path =UPSTORE_PLUGIN_DIR.'/templates/';\n }\n\n // Look within passed path within the theme - this is priority.\n $template = locate_template(\n array(\n trailingslashit( $template_path ) . $template_name,\n $template_name\n )\n );\n\n // Get default template/\n if ( ! $template) {\n $template = $default_path . $template_name;\n }\n\n // Return what we found.\n return $template;\n}", "function getDefault($url){\n \n\t \n\t \n\t $path = explode('/', $url);\n\t \t \n\t $temp = $path[$this -> getPos($url)];\n\t \n\t if($temp != ''){\n\t \n\t\t$file = DIR_TEMPLATE.'/'.$temp.'.php';\n\t\t\n\t if (is_readable($file)) {\n\n //include the alternative template\n\t\t $template = $file;\n\t\t\n\t\t}else{\n\t\t\n\t\t //include the default template\n\t\t $template = DIR_TEMPLATE.'/default.php';\n\t\t\n\t\t}\n }else{\n \n\t\t //include the default template\n\t\t $template = DIR_TEMPLATE.'/default.php';\n\n }\t \n \n return $template;\n \n }", "function emp_locate_template( $template_name, $load=false, $args = array() ) {\n\t//First we check if there are overriding tempates in the child or parent theme\n\t$located = locate_template(array('plugins/events-manager-pro/'.$template_name));\n\tif( !$located ){\n\t\t$dir_location = plugin_dir_path(__FILE__);\n\t\tif ( file_exists( $dir_location.'templates/'.$template_name) ) {\n\t\t\t$located = $dir_location.'templates/'.$template_name;\n\t\t}\n\t}\n\t$located = apply_filters('emp_locate_template', $located, $template_name, $load, $args);\n\tif( $located && $load ){\n\t\tif( is_array($args) ) extract($args);\n\t\tinclude($located);\n\t}\n\treturn $located;\n}", "function load_newsletter_template($template) {\n global $post;\n\n // Is this a futurninews post?\n if ($post->post_type == \"futurninews\"){\n\n $plugin_path = plugin_dir_path( __FILE__ );\n\n $template_name = 'single-newsletter.php';\n\n // checks if there is a single template in themefolder, or it doesn't exist in the plugin\n if($template === get_stylesheet_directory() . '/' . $template_name\n || !file_exists($plugin_path . $template_name)) {\n\n // returns \"single.php\" or \"single-my-custom-post-type.php\" from theme directory.\n return $template;\n }\n\n // If not, return futurninews custom post type template.\n return $plugin_path . $template_name;\n }\n\n //This is not futurninews, do nothing with $template\n return $template;\n}", "function LoadTemplate( $name )\n{\n if ( file_exists(\"$name.html\") ) return file_get_contents(\"$name.html\");\n if ( file_exists(\"templates/$name.html\") ) return file_get_contents(\"templates/$name.html\");\n if ( file_exists(\"../templates/$name.html\") ) return file_get_contents(\"../templates/$name.html\");\n}", "private function load_template()\r\n\t{\r\n\t\tif(! $this -> loaded)\r\n\t\t{\r\n\t\t\t$controller = $this -> sp -> targetdir().\"/\".sp_StaticProjector::templates_dir.\"/\".$this->name.\"_controller.php\";\r\n\t\t\tsp_StaticRegister::push_object(\"sp\", $this -> sp);\r\n\t\t\t\r\n\t\t\tif(!file_exists($controller))\r\n\t\t\t{\r\n $controller = $this -> sp -> coretemplatesdir().\"/\".$this->name.\"_controller.php\";\r\n if(! file_exists($controller)) {\r\n $controller = $this -> sp -> coretemplatesdir().\"/default_controller.php\";\r\n }\r\n\t\t\t\t/*if($this -> name == \"default\")\r\n\t\t\t\t{\r\n\t\t\t\t\t$default_controller = $this -> sp -> defaultsdir().\"/default_controller.php\";\r\n\t\t\t\t\t@copy($default_controller, $controller);\r\n\t\t\t\t\tchmod($controller,sp_StaticProjector::file_create_rights);\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\t$base_code = file_get_contents($this -> sp -> defaultsdir().\"/new_controller.txt\");\r\n\t\t\t\t\t$controller_code = str_replace(\"%controller_name%\", $this->name.\"_controller\", $base_code);\r\n\t\t\t\t\tfile_put_contents($controller, $controller_code);\r\n\t\t\t\t}*/\r\n\t\t\t}\r\n\t\t\trequire_once($controller);\r\n\r\n\t\t\t$template = $this -> sp -> targetdir().\"/\".sp_StaticProjector::templates_dir.\"/\".$this->name.\"_template.php\";\r\n\t\t\tif(!file_exists($template))\r\n\t\t\t{\r\n $template = $this -> sp -> coretemplatesdir().\"/\".$this->name.\"_template.php\";\r\n if(! file_exists($template)) {\r\n $template = $this -> sp -> coretemplatesdir().\"/default_template.php\";\r\n }\r\n\t\t\t\t/*if($this -> name == \"default\")\r\n\t\t\t\t{\r\n\t\t\t\t\t$default_template = $this -> sp -> defaultsdir().\"/default_template.php\";\r\n\t\t\t\t\t@copy($default_template, $template);\r\n\t\t\t\t\tchmod($template,sp_StaticProjector::file_create_rights);\r\n\t\t\t\t}\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\t$chunks_code = \"\";\r\n\t\t\t\t\t$chunk_base = file_get_contents($this -> sp -> defaultsdir().\"/new_template_chunk.txt\");\r\n\t\t\t\t\tforeach($this -> sp -> get_config() -> default_templates_chunks() as $chunk)\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$chunks_code .= str_replace(\"%chunk_name%\",$chunk,$chunk_base);\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t\t$template_base = file_get_contents($this -> sp -> defaultsdir().\"/new_template.txt\");\r\n\t\t\t\t\t$template_code = str_replace(\"%template_name%\", $this -> name.\"_template\", $template_base);\r\n\t\t\t\t\t$template_code = str_replace(\"%template_chunks%\", $chunks_code, $template_code);\r\n\t\t\t\t\tfile_put_contents($template, $template_code);\r\n\t\t\t\t}*/\r\n\t\t\t}\r\n\t\t\trequire_once($template);\r\n\t\t\tsp_StaticRegister::pop_object(\"sp\");\r\n\t\t\t\r\n\t\t\t$this -> loaded = true;\r\n\t\t}\r\n\t}", "function astra_addon_get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {\n\n\t\t$located = astra_addon_locate_template( $template_name, $template_path, $default_path );\n\n\t\tif ( ! file_exists( $located ) ) {\n\t\t\t/* translators: 1: file location */\n\t\t\t_doing_it_wrong( __FUNCTION__, esc_html( sprintf( __( '%s does not exist.', 'astra-addon' ), '<code>' . $located . '</code>' ) ), '1.0.0' );\n\t\t\treturn;\n\t\t}\n\n\t\t// Allow 3rd party plugin filter template file from their plugin.\n\t\t$located = apply_filters( 'astra_addon_get_template', $located, $template_name, $args, $template_path, $default_path );\n\n\t\tdo_action( 'astra_addon_before_template_part', $template_name, $template_path, $located, $args );\n\n\t\tinclude $located;\n\n\t\tdo_action( 'astra_addon_after_template_part', $template_name, $template_path, $located, $args );\n\t}", "function sat_load_templates( $original_template ) \n{\n /*\n get_query_var( $var, $default )\n \n Retrieves public query variable in the WP_Query class of the global $wp_query object.\n\n $var (string) (required) The variable key to retrieve. Default: None\n \n $default (mixed) (optional) Value to return if the query variable is not set. \n Default: empty string\n\n returns $default if var is not set\n */\n //when a page loads, if it is not equal to 'task', return nothing and exits function immediatly.\n if ( get_query_var( 'post_type' ) !== 'task' ) \n {\n return;\n }\n\n /*\n is_search();\n\n This Conditional Tag checks if search result page archive is being displayed. This is a boolean function, meaning it returns either TRUE or FALSE.\n\n is_archive();\n\n This Conditional Tag checks if any type of Archive page is being displayed. An Archive is a Category, Tag, Author, Date, Custom Post Type or Custom Taxonomy based pages. This is a boolean function, meaning it returns either TRUE or FALSE\n\n is_archive() does not accept any parameters. If you want to check if this is the archive of a custom post type, use is_post_type_archive( $post_type )\n */\n //using Conditional Tags to trigger code if page is an archive or search page\n if ( is_archive() || is_search() ) \n {\n //If the user adds custom-archive page for 'task'-custom post-type to their site's current theme by adding archive-task.php to the root file of the theme, use it!\n if ( file_exists( get_stylesheet_directory(). '/archive-task.php' ) ) \n {\n return get_stylesheet_directory() . '/archive-task.php';\n }\n\n //If not use the archive-task.php file located within this plugin's file directory\n else \n {\n return plugin_dir_path( __FILE__ ) . 'templates/archive-task.php';\n }\n\n } \n\n /*\n is_singular( $post_types );\n\n This conditional tag checks if a singular post is being displayed, which is the case when one of the following returns true: is_single(), is_page() or is_attachment(). If the $post_types parameter is specified, the function will additionally check if the query is for one of the post types specified.\n\n $post_types (string/array) (optional) Post type or types to check in current query. Default: None\n */\n\n //using Conditional Tags to trigger code if page is a single post\n elseif(is_singular('task')) \n {\n //If the user adds custom-single post for 'task'-custom post-type to their site's current theme by adding archive-task.php to the root file of the theme, use it!\n if ( file_exists( get_stylesheet_directory(). '/single-task.php' ) ) \n {\n return get_stylesheet_directory() . '/single-task.php';\n } \n\n //If not use the single-task.php file located within this plugin's file directory\n else \n {\n return plugin_dir_path( __FILE__ ) . 'templates/single-task.php';\n }\n }\n\n else\n {\n \t\treturn get_page_template();\n }\n\n return $original_template;\n}", "function youpzt_store_load_template($template_path){\n if (is_page('shop')) {\n return $template_path = UPSTORE_PLUGIN_DIR.'/templates/shop.php';\n }elseif (is_page('youpzt-store')) {\n return $template_path = UPSTORE_PLUGIN_DIR.'/templates/youpzt-store.php';\n }elseif (is_single()&&get_post_type()=='product') {\n return $template_path = UPSTORE_PLUGIN_DIR.'/templates/single-product.php';\n }else{\n return $template_path; \n }\n}", "function init() {\n require config('template_path') . '/template.php';\n}", "public function populateDefaultTemplateSets()\n {\n $root_dir = Core::getRootDir();\n\n $data_folder = \"$root_dir/modules/form_builder/default_template_sets\";\n $dh = opendir($data_folder);\n\n if (!$dh) {\n return array(false, \"You appear to be missing the default_template_sets folder, or your \\$g_root_dir settings is invalid.\");\n }\n\n $template_set_files = array();\n while (($file = readdir($dh)) !== false) {\n $parts = pathinfo($file);\n if ($parts[\"extension\"] !== \"json\") {\n continue;\n }\n\n $template_set = json_decode(file_get_contents(\"$data_folder/$file\"));\n $schema = json_decode(file_get_contents(\"$root_dir/modules/form_builder/schemas/template_set-1.0.0.json\"));\n $response = Schemas::validateSchema($template_set, $schema);\n\n if ($response[\"is_valid\"]) {\n $template_set_files[$file] = $template_set;\n } else {\n // TODO\n }\n }\n\n // now install the template sets. Ensure the \"default-*.json\" one is set first\n TemplateSets::importTemplateSetData($template_set_files[$this->defaultTemplateSet]);\n\n foreach ($template_set_files as $filename => $template_set) {\n if ($filename === $this->defaultTemplateSet) {\n continue;\n }\n TemplateSets::importTemplateSetData($template_set);\n }\n }", "function init()\n{\n require config('template_path') . '/template.php';\n}", "public function Load() : void\n {\n do_action('template_redirect');\n\n $this->Template === self::VIRTUAL_PAGE_TEMPLATE ? $Template = self::VIRTUAL_PAGE_TEMPLATE : $Template = locate_template(array_filter($this->Templates));\n $filtered = apply_filters('template_include', apply_filters('WP_Plugin_virtual_page_template', $Template));\n if(empty($filtered) || file_exists($filtered))\n {\n $Template = $filtered;\n }\n if(!empty($Template) && file_exists($Template)) \n {\n add_action('wp_enqueue_scripts',function (){$this->Define_Resources();});\n require_once $Template;\n }\n }", "protected function installDefaultPageTemplates($bundle)\n {\n // Configuration templates\n $dirPath = $this->container->getParameter('kernel.project_dir') . '/config/kunstmaancms/pagetemplates/';\n $skeletonDir = sprintf('%s/Resources/config/pagetemplates/', GeneratorUtils::getFullSkeletonPath('/common'));\n\n // Only copy templates over when the folder does not exist yet...\n if (!$this->filesystem->exists($dirPath)) {\n $files = [\n 'default-one-column.yml',\n 'default-two-column-left.yml',\n 'default-two-column-right.yml',\n 'default-three-column.yml',\n ];\n foreach ($files as $file) {\n $this->filesystem->copy($skeletonDir . $file, $dirPath . $file, false);\n GeneratorUtils::replace('~~~BUNDLE~~~', $bundle->getName(), $dirPath . $file);\n }\n }\n\n // Twig templates\n $dirPath = $this->getTemplateDir($bundle) . '/Pages/Common/';\n\n $skeletonDir = sprintf('%s/Resources/views/Pages/Common/', GeneratorUtils::getFullSkeletonPath('/common'));\n\n if (!$this->filesystem->exists($dirPath)) {\n $files = [\n 'one-column-pagetemplate.html.twig',\n 'two-column-left-pagetemplate.html.twig',\n 'two-column-right-pagetemplate.html.twig',\n 'three-column-pagetemplate.html.twig',\n ];\n foreach ($files as $file) {\n $this->filesystem->copy($skeletonDir . $file, $dirPath . $file, false);\n }\n $this->filesystem->copy($skeletonDir . 'view.html.twig', $dirPath . 'view.html.twig', false);\n }\n\n $contents = file_get_contents($dirPath . 'view.html.twig');\n\n $twigFile = \"{% extends 'Layout/layout.html.twig' %}\\n\";\n\n if (strpos($contents, '{% extends ') === false) {\n GeneratorUtils::prepend(\n $twigFile,\n $dirPath . 'view.html.twig'\n );\n }\n }", "function defaultTemplate() {\n\t\t$l = $this->api->locate('addons',__NAMESPACE__,'location');\n\t\t$addon_location = $this->api->locate('addons',__NAMESPACE__);\n\t\t$this->api->pathfinder->addLocation($addon_location,array(\n\t\t\t//'js'=>'templates/js',\n\t\t\t//'css'=>'templates/css',\n //'template'=>'templates',\n\t\t))->setParent($l);\n\n //return array('view/lister/tags');\n return parent::defaultTemplate();\n }", "function emscvupload_locate_template( $template_names, $load = false, $require_once = true, $atts=array() ) {\n\tglobal $emscvupload_template_folder;\n\n\t// No file found yet\n\t$located = false;\n\n\t// Try to find a template file\n\tforeach ( (array) $template_names as $template_name ) {\n\n\t\t// Continue if template is empty\n\t\tif ( empty( $template_name ) )\n\t\t\tcontinue;\n\n\t\t// Trim off any slashes from the template name\n\t\t$template_name = ltrim( $template_name, '/' );\n\n\t\t// Check child theme first\n\t\tif ( file_exists( trailingslashit( get_stylesheet_directory() ) . $emscvupload_template_folder . $template_name ) ) {\n\t\t\t$located = trailingslashit( get_stylesheet_directory() ) . $emscvupload_template_folder . $template_name;\n\t\t\tbreak;\n\n\t\t// Check parent theme next\n\t\t} elseif ( file_exists( trailingslashit( get_template_directory() ) . $emscvupload_template_folder . $template_name ) ) {\n\t\t\t$located = trailingslashit( get_template_directory() ) . $emscvupload_template_folder . $template_name;\n\t\t\tbreak;\n\n\t\t// Check theme compatibility last\n\t\t} elseif ( file_exists( trailingslashit( emscvupload_get_templates_dir() ) . $template_name ) ) {\n\t\t\t$located = trailingslashit( emscvupload_get_templates_dir() ) . $template_name;\n\t\t\tbreak;\n\t\t}\n\t}\n\n\tif ( ( true == $load ) && ! empty( $located ) )\n\t\temscvupload_load_template( $located, $require_once, $atts );\n\n\treturn $located;\n}", "function reloadDefaultEmailTemplates($args, &$request) {\n\t\t$this->validate();\n\n\t\t$site =& $request->getSite();\n\t\t$locale = $request->getUserVar('locale');\n\n\t\tif (in_array($locale, $site->getInstalledLocales())) {\n\t\t\t$emailTemplateDao =& DAORegistry::getDAO('EmailTemplateDAO');\n\t\t\t$emailTemplateDao->deleteDefaultEmailTemplatesByLocale($locale);\n\t\t\t$emailTemplateDao->installEmailTemplateData($emailTemplateDao->getMainEmailTemplateDataFilename($locale));\n\n\t\t\t$user =& $request->getUser();\n\n\t\t\timport('classes.notification.NotificationManager');\n\t\t\t$notificationManager = new NotificationManager();\n\t\t\t$notificationManager->createTrivialNotification($user->getId());\n\t\t}\n\n\t\t$request->redirect(null, null, 'languages');\n\t}", "public function loadTemplate() {\n if ( current_filter() !== 'template_redirect' ) {\n return FALSE;\n }\n if ( $this->preLoad() ) {\n return $this->loadFile( $this->getTemplate(), TRUE );\n }\n\n return FALSE;\n }", "function cmdeals_get_template($template_name, $require_once = true) {\n\tglobal $cmdeals;\n\tif (file_exists( STYLESHEETPATH . '/' . WPDEALS_TEMPLATE_URL . $template_name )) load_template( STYLESHEETPATH . '/' . WPDEALS_TEMPLATE_URL . $template_name, $require_once ); \n\telseif (file_exists( STYLESHEETPATH . '/' . $template_name )) load_template( STYLESHEETPATH . '/' . $template_name , $require_once); \n\telse load_template( $cmdeals->plugin_path() . '/cmdeals-templates/' . $template_name , $require_once);\n}", "public function get_default_template() {\n\t\t\t$file = file_get_contents( dirname( __FILE__ ).'/assets/template.html' );\n\t\t\treturn $file;\n\t\t}", "public static function register_templates() {\n if (version_compare(floatval(get_bloginfo('version')), '4.7', '<')) {\n // 4.6 and older\n add_filter('page_attributes_dropdown_pages_args', array(get_called_class(), 'register_project_templates'));\n } else {\n // Add a filter to the wp 4.7 version attributes metabox\n add_filter('theme_page_templates', array(get_called_class(), 'add_new_template'));\n }\n // Add a filter to the save post to inject out template into the page cache\n add_filter('wp_insert_post_data', array(get_called_class(), 'register_project_templates'));\n // Add a filter to the template include to determine if the page has our \n // template assigned and return it's path\n add_filter('template_include', array(get_called_class(), 'view_project_template'));\n }", "function s2_get_template($rawTemplateId, $defaultPath = false)\n{\n global $request_uri;\n\n if ($defaultPath === false) {\n $defaultPath = S2_ROOT . '_include/templates/';\n }\n\n $path = false;\n $templateId = preg_replace('#[^0-9a-zA-Z\\._\\-]#', '', $rawTemplateId);\n\n $return = ($hook = s2_hook('fn_get_template_start')) ? eval($hook) : null;\n if ($return) {\n return $return;\n }\n\n if (!$path) {\n if (file_exists(S2_ROOT . '_styles/' . S2_STYLE . '/templates/' . $templateId)) {\n $path = S2_ROOT . '_styles/' . S2_STYLE . '/templates/' . $templateId;\n } elseif (file_exists($defaultPath . $templateId)) {\n $path = $defaultPath . $templateId;\n } else {\n throw new Exception(sprintf(Lang::get('Template not found'), $defaultPath . $templateId));\n }\n }\n\n ob_start();\n include $path;\n $template = ob_get_clean();\n\n $style_filename = '_styles/' . S2_STYLE . '/' . S2_STYLE . '.php';\n $assetPack = require S2_ROOT . $style_filename;\n\n if (!($assetPack instanceof \\S2\\Cms\\Asset\\AssetPack)) {\n throw new Exception(sprintf('File \"%s\" must return an AssetPack object.', $style_filename));\n }\n\n ($hook = s2_hook('fn_get_template_pre_includes_merge')) ? eval($hook) : null;\n\n $styles = $assetPack->getStyles(\n S2_PATH . '/_styles/' . S2_STYLE . '/',\n new \\S2\\Cms\\Asset\\AssetMerge(S2_CACHE_DIR, '/_cache/', S2_STYLE . '_styles.css', \\S2\\Cms\\Asset\\AssetMerge::FILTER_CSS, defined('S2_DEBUG'))\n );\n $scripts = $assetPack->getScripts(\n S2_PATH . '/_styles/' . S2_STYLE . '/',\n new \\S2\\Cms\\Asset\\AssetMerge(S2_CACHE_DIR, '/_cache/', S2_STYLE . '_scripts.js', \\S2\\Cms\\Asset\\AssetMerge::FILTER_JS, defined('S2_DEBUG'))\n );\n\n $template = str_replace(['<!-- s2_styles -->', '<!-- s2_scripts -->'], [$styles, $scripts], $template);\n\n if ((strpos($template, '</a>') !== false) && isset($request_uri)) {\n $template = preg_replace_callback('#<a href=\"([^\"]*)\">([^<]*)</a>#',\n static function ($matches) use ($request_uri) {\n $real_request_uri = s2_link($request_uri);\n\n [, $url, $text] = $matches;\n\n if ($url == $real_request_uri) {\n return '<span>' . $text . '</span>';\n }\n\n if ($url && strpos($real_request_uri, $url) === 0) {\n return '<a class=\"current\" href=\"' . $url . '\">' . $text . '</a>';\n }\n\n return '<a href=\"' . $url . '\">' . $text . '</a>';\n },\n $template\n );\n }\n\n ($hook = s2_hook('fn_get_template_end')) ? eval($hook) : null;\n return $template;\n}", "function defaultTemplate() {\n//\t\t$l = $this->api->locate('addons',__NAMESPACE__,'location');\n//\t\t$addon_location = $this->api->locate('addons',__NAMESPACE__);\n//\t\t$this->api->pathfinder->addLocation($addon_location,array(\n//\t\t\t'js'=>'templates/js',\n//\t\t\t'css'=>'templates/css',\n// 'template'=>'templates',\n//\t\t))->setParent($l);\n\n return array('view/draw');\n }", "function bok_locate_template( $template_names, $load = false, $require_once = true, $template_vars ) {\n\t// No file found yet\n\t$located = false;\n\n\t// Try to find a template file\n\tforeach ( (array) $template_names as $template_name ) {\n\n\t\t// Continue if template is empty\n\t\tif ( empty( $template_name ) )\n\t\t\tcontinue;\n\n\t\t// Trim off any slashes from the template name\n\t\t$template_name = ltrim( $template_name, '/' );\n\n\t\t// Check child theme first\n\t\tif ( file_exists( trailingslashit( get_stylesheet_directory() ) . 'multi-rating/' . $template_name ) ) {\n\t\t\t$located = trailingslashit( get_stylesheet_directory() ) . 'multi-rating/' . $template_name;\n\t\t\tbreak;\n\n\t\t\t// Check parent theme next\n\t\t} elseif ( file_exists( trailingslashit( get_template_directory() ) . 'multi-rating/' . $template_name ) ) {\n\t\t\t$located = trailingslashit( get_template_directory() ) . 'multi-rating/' . $template_name;\n\t\t\tbreak;\n\n\t\t\t// Check theme compatibility last\n\t\t} elseif ( file_exists( trailingslashit( bok_get_templates_dir() ) . $template_name ) ) {\n\t\t\t$located = trailingslashit( bok_get_templates_dir() ) . $template_name;\n\t\t\tbreak;\n\t\t}\n\t}\n\n\tif ( ( true == $load ) && ! empty( $located ) ) {\n\t\tbok_load_template( $located, $require_once, $template_vars );\n\t}\n\n\treturn $located;\n}", "function st_get_template($file,$data = array()){\r $file = ST_DIR.'/templates/'.$file;\r if(file_exists($file)){\r include($file); return true;\r }\r return false;\r}", "function s3_storage_load_template($name, array $_vars)\n{\n $template = locate_template($name, false, false);\n\n // Use the default template if the theme doesn't have it\n if (!$template) {\n $template = dirname(__FILE__) . '/../templates/' . $name . '.php';\n }\n\n // Load the template\n extract($_vars);\n require $template;\n}", "function ffd_get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {\r\n\tif ( ! empty( $args ) && is_array( $args ) ) {\r\n\t\textract( $args ); // @codingStandardsIgnoreLine\r\n\t}\r\n\r\n\t$located = ffd_locate_template( $template_name, $template_path, $default_path );\r\n\r\n\tif ( ! file_exists( $located ) ) {\r\n\t\t/* translators: %s template */\r\n\t\treturn;\r\n\t}\r\n\r\n\t// Allow 3rd party plugin filter template file from their plugin.\r\n\t$located = apply_filters( 'ffd_get_template', $located, $template_name, $args, $template_path, $default_path );\r\n\r\n\tdo_action( 'ffd_before_template_part', $template_name, $template_path, $located, $args );\r\n\r\n\tinclude $located;\r\n\r\n\tdo_action( 'ffd_after_template_part', $template_name, $template_path, $located, $args );\r\n}", "function ffd_locate_template( $template_name, $template_path = '', $default_path = '' ) {\r\n\tif ( ! $template_path ) {\r\n\t\t$template_path = FFD()->template_path();\r\n\t}\r\n\r\n\tif ( ! $default_path ) {\r\n\t\t$default_path = FFD()->plugin_path() . '/templates/';\r\n\t}\r\n\r\n\t// Look within passed path within the theme - this is priority.\r\n\t$template = locate_template(\r\n\t\tarray(\r\n\t\t\ttrailingslashit( $template_path ) . $template_name,\r\n\t\t\t$template_name,\r\n\t\t)\r\n\t);\r\n\r\n\t// Get default template/.\r\n\tif ( ! $template || FFD_TEMPLATE_DEBUG_MODE ) {\r\n\t\t$template = $default_path . $template_name;\r\n\t}\r\n\r\n\t// Return what we found.\r\n\treturn apply_filters( 'ffd_locate_template', $template, $template_name, $template_path );\r\n}", "function cmdeals_template_loader( $template ) {\n\tglobal $cmdeals;\n\t\n\tif ( is_single() && get_post_type() == 'daily-deals' ) {\n\t\t\n\t\t$template = locate_template( array( 'single-daily-deals.php', WPDEALS_TEMPLATE_URL . 'single-daily-deals.php' ) );\n\t\t\n\t\tif ( ! $template ) $template = $cmdeals->plugin_path() . '/cmdeals-templates/single-daily-deals.php';\n\t\t\n\t}\n\telseif ( is_tax('deal-categories') ) {\n\t\t\n\t\t$template = locate_template( array( 'taxonomy-deal-categories.php', WPDEALS_TEMPLATE_URL . 'taxonomy-deal-categories.php' ) );\n\t\t\n\t\tif ( ! $template ) $template = $cmdeals->plugin_path() . '/cmdeals-templates/taxonomy-deal-categories.php';\n\t}\n\telseif ( is_tax('deal-tags') ) {\n\t\t\n\t\t$template = locate_template( array( 'taxonomy-deal-tags.php', WPDEALS_TEMPLATE_URL . 'taxonomy-deal-tags.php' ) );\n\t\t\n\t\tif ( ! $template ) $template = $cmdeals->plugin_path() . '/cmdeals-templates/taxonomy-deal-tags.php';\n\t}\n\telseif ( is_post_type_archive('daily-deals') || is_page( get_option('cmdeals_store_page_id') )) {\n\n\t\t$template = locate_template( array( 'archive-daily-deals.php', WPDEALS_TEMPLATE_URL . 'archive-daily-deals.php' ) );\n\t\t\n\t\tif ( ! $template ) $template = $cmdeals->plugin_path() . '/cmdeals-templates/archive-daily-deals.php';\n\t\t\n\t}\n elseif ( is_page( get_option('cmdeals_featured_page_id') ) ) {\n\t\t\n\t\t$template = locate_template( array( 'featured-store.php', WPDEALS_TEMPLATE_URL . 'featured-store.php' ) );\n\t\t\n\t\tif ( ! $template ) $template = $cmdeals->plugin_path() . '/cmdeals-templates/featured-store.php';\n \n\t\t\n\t}\n\t\n\treturn $template;\n\n}", "function bp_gtm_load_template_filter($found_template, $templates) {\n global $bp;\n\n if ($bp->current_action == $bp->gtm->slug || $bp->current_component == $bp->gtm->slug) {\n foreach ((array) $templates as $template) {\n $path = is_child_theme() ? TEMPLATEPATH : STYLESHEETPATH; // different path to themes files\n if (file_exists($path . '/' . $template)) {\n $filtered_templates[] = $path . '/' . $template;\n } else if (file_exists(STYLESHEETPATH . '/gtm/' . $template)) {\n $filtered_templates[] = STYLESHEETPATH . '/gtm/' . $template;\n } else {\n if (($position = strpos($template, '/')) !== false)\n $template = substr($template, $position + 1);\n $filtered_templates[] = plugin_dir_path(__FILE__) . 'templates/gtm/' . $template;\n }\n }\n $found_template = $filtered_templates[0];\n\n return apply_filters('bp_gtm_load_template_filter', $found_template);\n } else {\n return $found_template;\n }\n}", "private function loadTemplate() {\n\t\t\tinclude('template.inc.php');\n\t\t\t$this->mainTemplate = new Template();\n\t\t\t$this->mainTemplate->readTpl('main');\n\t\t}", "function carton_locate_template( $template_name, $template_path = '', $default_path = '' ) {\n\tglobal $carton;\n\n\tif ( ! $template_path ) $template_path = $carton->template_url;\n\tif ( ! $default_path ) $default_path = $carton->plugin_path() . '/templates/';\n\n\t// Look within passed path within the theme - this is priority\n\t$template = locate_template(\n\t\tarray(\n\t\t\ttrailingslashit( $template_path ) . $template_name,\n\t\t\t$template_name\n\t\t)\n\t);\n\n\t// Get default template\n\tif ( ! $template )\n\t\t$template = $default_path . $template_name;\n\n\t// Return what we found\n\treturn apply_filters('carton_locate_template', $template, $template_name, $template_path);\n}", "function wac_locate_template( $template_name, $template_path = '', $default_path = '' ) {\n\tglobal $woo_auction;\n\tif(!$template_path){\n\t\t$template_path = $woo_auction->theme_template_path();\n\t}\n\tif(!$default_path){\n\t\t$default_path = $woo_auction->plugin_path() . '/templates/';\n\t}\n\t\n\t// Look within passed path within the theme - this is priority.\n\t$template = locate_template(\n\t\tarray(\n\t\t\ttrailingslashit($template_path) . $template_name,\n\t\t\t$template_name,\n\t\t)\n\t);\n\t\n\t// Get default template/\n\tif (!$template){\n\t\t$template = $default_path . $template_name;\n\t}\n\n\t// Return what we found.\n\treturn apply_filters('wac_locate_template',$template,$template_name,$template_path );\n}", "protected function _loadTemplates()\n {\n $this->_tpl = array();\n $dir = Solar_Class::dir($this, 'Data');\n $list = glob($dir . '*.php');\n foreach ($list as $file) {\n \n // strip .php off the end of the file name to get the key\n $key = substr(basename($file), 0, -4);\n \n // load the file template\n $this->_tpl[$key] = file_get_contents($file);\n \n // we need to add the php-open tag ourselves, instead of\n // having it in the template file, becuase the PEAR packager\n // complains about parsing the skeleton code.\n // \n // however, only do this on non-view files.\n if (substr($key, 0, 4) != 'view') {\n $this->_tpl[$key] = \"<?php\\n\" . $this->_tpl[$key];\n }\n }\n }", "function bp_tol_maybe_replace_template( $templates, $slug, $name ) {\n\n\t\t//handling slugs and loading our custom templates : \n\t\t//would check specific member also for custom templates for each member\n\n\t\tswitch ($slug) {\n\t\t\tcase 'members/single/home':\n\t\t\t\t$templates = array( 'members/single/index.php' );\n\t\t\t\tbreak;\n\t\t\t\n\t\t\tcase 'members/index':\n\t\t\t\t$templates = array( 'members/index.php' );\n\t\t\t\tbreak;\n\n\t\t\tdefault:\n\t\t\t\t$templates = array( 'members/single/index.php' );\n\t\t\t\tbreak;\n\t\t}\n\n\t return $templates;\n\t}", "public function loadTemplate(){\n\t\t$tpl = $this->template;\n\t\t$file = $this->path . DIRECTORY_SEPARATOR . $tpl . '.tmpl.php';\n\t\t$exists = file_exists($file);\n\t\t// Wenn Template vorhanden\n\t\tif( $exists ){\n\n\t\t\tob_start();\n\t\t\tinclude $file;\n\t\t\t$output = ob_get_contents();\n\t\t\tob_end_clean();\n\n\t\t\treturn $output;\n\t\t}else{\n\t\t\treturn 'Datei nicht gefunden!';\n\t\t}\n\t}", "function useTemplate($path_to_root_dir)\n{\n global $area, $path_to_root_dir, $error_msg_text, $sys_msg_text;\n $sys_info = getSysInfo();\n \n //this is the first place where we see that sys-tables don't exist!!\n if ($sys_info['no_tables']) {\n $link_text = __('PolyPager found the database. Very good. <br/>But: it seems that it does not yet have its database configured. By clicking on the following link you can assure that all the tables that PolyPager needs to operate are being created (if they have not been already).<br/>');\n $link_href = \"admin/?&cmd=create\";\n global $area;\n if ($area == '_admin') {\n $link_href = './?&cmd=create';\n }\n if ($area == '_gallery') {\n $link_href = '../../admin/?&cmd=create';\n }\n $error_msg_text[] = '<span id=\"no_tables_warning\">'.$link_text.'<a href=\"'.$link_href.'\">click here to create the tables.</a></span>';\n }\n if (utf8_strpos($sys_info['skin'], 'picswap')>-1) {\n $skin = 'picswap';\n } else {\n $skin = $sys_info['skin'];\n }\n $template_dirpath = $path_to_root_dir.\"/style/skins/\".$skin;\n $template_filepath = $template_dirpath.\"/template.php\";\n if (file_exists($template_filepath)) {\n @include($template_filepath);\n } else if (file_exists($template_dirpath)) {\n if ($area == '_admin') {\n $sys_msg_text[] = 'The template.php file in the '.$skin.'-directory couldn\\'t be found';\n }\n // we fall silently back to the template file\n @include($template_dirpath.\"/template.php.template\");\n } else {\n $sys_msg_text[] = __('Warning: No template could be found for the selected skin.');\n @include($path_to_root_dir.\"/style/skins/polly/template.php.template\");\n }\n}", "function deals_get_template($template_name, $require_once = true) {\n\tif (file_exists( STYLESHEETPATH . '/' . DEALS_TEMPLATE . $template_name )) load_template( STYLESHEETPATH . '/' . DEALS_TEMPLATE . $template_name, $require_once ); \n\telseif (file_exists( STYLESHEETPATH . '/' . $template_name )) load_template( STYLESHEETPATH . '/' . $template_name , $require_once); \n\telse load_template( DEALS_TEMPLATE_DIR . $template_name , $require_once);\n}", "static function loadOverrideFiles() {\n\t\tob_start();\n\n\t\t$folder = KenedoPlatform::p()->getDirCustomizationSettings();\n\t\t$files = (is_dir($folder)) ? KenedoFileHelper::getFiles( $folder, '.php$', false, true) : array();\n\n\t\tif (count($files)) {\n\t\t\t$settingDisplayErrors = ini_set('display_errors',1);\n\t\t\tforeach ($files as $file) {\n\t\t\t\trequire_once($file);\n\t\t\t}\n\t\t\tini_set('display_errors',$settingDisplayErrors);\n\t\t}\n\n\t\t$folder = KenedoPlatform::p()->getDirCustomization() .'/system_overrides';\n\t\t$files = (is_dir($folder)) ? KenedoFileHelper::getFiles( $folder, '.php$', false, true) : array();\n\n\t\tif (count($files)) {\n\t\t\t$settingDisplayErrors = ini_set('display_errors',1);\n\t\t\tforeach ($files as $file) {\n\t\t\t\trequire_once($file);\n\t\t\t}\n\t\t\tini_set('display_errors',$settingDisplayErrors);\n\t\t}\n\n\t\t// And drop any output done.\n\t\tob_end_clean();\n\n\t}", "public function loadUsersTemplate(): void\n {\n /**\n * Filter responsible for adding the custom template for users listing.\n *\n * @since 1.0.0\n */\n add_action('template_redirect', [$this, 'userListTemplate']);\n }", "function astra_locate_template( $template_name, $template_path = '', $default_path = '' ) { // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedFunctionFound\n\t_deprecated_function( __FUNCTION__, '3.6.2', 'astra_addon_locate_template()' );\n\treturn astra_addon_locate_template( $template_name, $template_path = '', $default_path = '' );\n}", "function catch_plugin_template($template) {\n\t\n // If tp-file.php is the set template\n if( is_page_template('cg-search.php') )\n \t{\n // Update path(must be path, use WP_PLUGIN_DIR and not WP_PLUGIN_URL) \n $template = WP_PLUGIN_DIR . '/hyp3rl0cal-wordpress-plugin/cg-search.php';\n \t}\n \t\n // If tp-file.php is the set template\n if( is_page_template('cg-directory.php') )\n \t{\n // Update path(must be path, use WP_PLUGIN_DIR and not WP_PLUGIN_URL) \n $template = WP_PLUGIN_DIR . '/hyp3rl0cal-wordpress-plugin/cg-directory.php';\n \t} \t\n \n // Return\n return $template;\n}", "public function loadTemplate(){\n if($this->hasErrors()) return false;\n $template = $this->findTemplate();\n $this->updateBuffer();\n do_action($this->prefix('before_include_template'), $this);\n include($template);\n do_action($this->prefix('after_include_template'), $this);\n $this->updateBuffer();\n\n return self::$buffer === false ? $this->hasErrors() == false && $template !== false : $this->updateBuffer();\n }", "function rf_get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {\n if ( ! empty( $args ) && is_array( $args ) ) {\n extract( $args );\n }\n\n $located = rf_locate_template( $template_name, $template_path, $default_path );\n\n if ( ! file_exists( $located ) ) {\n _doing_it_wrong( __FUNCTION__, sprintf( __( '%s does not exist.', 'woocommerce' ), '<code>' . $located . '</code>' ), '2.1' );\n return;\n }\n\n // Allow 3rd party plugin filter template file from their plugin.\n $located = apply_filters( 'rf_get_template', $located, $template_name, $args, $template_path, $default_path );\n include( $located );\n}", "public function override_template( $located, $template_name, $args, $template_path, $default_path ) {\n\t\tif ( strpos( $located, 'checkout/form-checkout.php' ) !== false ) {\n\t\t\t$located = wc_locate_template(\n\t\t\t\t'checkout/swedbank-pay/form-checkout.php',\n\t\t\t\t$template_path,\n\t\t\t\tdirname( __FILE__ ) . '/../templates/'\n\t\t\t);\n\t\t}\n\n\t\treturn $located;\n\t}", "public function use_default_form_template( $located, $template_name, $args, $template_path, $default_path ) {\n if ( 'woocommerce-bookings' === $template_path ) {\n $located = $default_path . $template_name;\n }\n return $located;\n }", "function wac_get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {\n\tif (!empty($args) && is_array($args)){\n\t\textract($args);\n\t}\n\n\t$located = wac_locate_template($template_name,$template_path,$default_path );\n\n\tif (!file_exists($located)){\n\t\twc_doing_it_wrong( __FUNCTION__, sprintf( __( '%s does not exist.','woo-auction' ), '<code>' . $located . '</code>' ), '2.1' );\n\t\treturn;\n\t}\n\n\t// Allow 3rd party plugin filter template file from their plugin.\n\t$located = apply_filters('wac_get_template',$located,$template_name,$args,$template_path,$default_path);\n\t\n\tinclude($located);\n}", "function fiorello_mikado_is_default_wp_template() {\n\t\treturn is_archive() || is_search() || is_404() || ( is_front_page() && is_home() );\n\t}", "public function findTemplate(){\n if($this->hasErrors()) return false;\n $located = false;\n if(!$this->hasErrors()){\n $module_file = trailingslashit($this->location).$this->type.'.php';\n $file = trailingslashit($this->module).trailingslashit($this->location).$this->type.'.php';\n switch(true){\n //Check Stylesheet directory first (Child Theme)\n case file_exists(trailingslashit(get_stylesheet_directory()).trailingslashit(self::TEMPLATE_DIRECTORY).$file):\n $located = trailingslashit(get_stylesheet_directory()).trailingslashit(self::TEMPLATE_DIRECTORY).$file;\n break;\n //Check Template directory Second (Parent Theme)\n case file_exists(trailingslashit(get_template_directory()).trailingslashit(self::TEMPLATE_DIRECTORY).$file):\n $located = trailingslashit(get_template_directory()).trailingslashit(self::TEMPLATE_DIRECTORY).$file;\n break;\n //Check filtered custom template directory, if it's set.\n case (apply_filters($this->prefix('custom_template_directory_root'), '', $this) !== '' && file_exists(trailingslashit(apply_filters($this->prefix('custom_template_directory_root'), '', $this)).$file)):\n $located = trailingslashit($this->prefix('custom_template_directory_root')).$file;\n break;\n //If nothing else exists, go ahead and get the default\n default:\n $file = trailingslashit(ModuleLoader::getModuleDir($this->module)).$module_file;\n if($this->fileExists($file)) $located = $file;\n break;\n }\n }\n\n return $located;\n }", "public function renderDefault() {\n\t\t$this->onlyForAdmins();\n\t\t$this->template->instances = $this->configManager->getInstances($this->fileName);\n\t}", "function try_include()\r\n{\r\n\tglobal $admin, $ignore_admin;\r\n\r\n\t$params = func_get_args();\r\n\r\n\tforeach ($params as $tpl)\r\n\t{\r\n\t\tif ($admin and $ignore_admin!==1)\r\n\t\t{\r\n\t\t\t$fileh = EE_ADMIN_PATH.\"templates/\".$tpl.'.tpl';\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t$fileh = EE_PATH.\"templates/\".$tpl.'.tpl';\r\n\t\t}\r\n\r\n\t\t$fileh = get_custom_or_core_file_name($fileh);\r\n\r\n\t\tif (file_exists($fileh) and filesize($fileh)>0)\r\n\t\t{\r\n\t\t\t// don't look in DB because of it's about real template\r\n\t\t\treturn parse_tpl($tpl);\r\n\t\t}\r\n\t}\r\n}", "public function template_loader( $template ) {\r\n\t\tglobal $wp_query;\r\n\t\t\r\n\t\t$find = array();\r\n\t\t$files = array();\r\n\r\n\t\tif ( isset ( $wp_query->query_vars[ 'backers' ] ) && is_singular( 'download' ) ) {\r\n\t\t\t$files = apply_filters( 'atcf_crowdfunding_templates_backers', array( 'single-campaign-backers.php' ) );\r\n\t\t} else if ( is_singular( 'download' ) ) {\r\n\t\t\t$files = apply_filters( 'atcf_crowdfunding_templates_campaign', array( 'single-campaign.php', 'single-download.php', 'single.php' ) );\r\n\t\t} else if ( is_post_type_archive( 'download' ) ) {\r\n\t\t\t$files = apply_filters( 'atcf_crowdfunding_templates_archive', array( 'archive-campaigns.php', 'archive-download.php', 'archive.php' ) );\r\n\t\t}\r\n\r\n\t\tforeach ( $files as $file ) {\r\n\t\t\t$find[] = $file;\r\n\t\t\t$find[] = $this->template_url . $file;\r\n\t\t}\r\n\r\n\t\tif ( ! empty( $files ) ) {\r\n\t\t\t$template = locate_template( $find );\r\n\r\n\t\t\tif ( ! $template ) \r\n\t\t\t\t$template = $this->plugin_dir . '/templates/' . $file;\r\n\t\t}\r\n\r\n\t\treturn $template;\r\n\t}", "function my_page_templates_function()\r\n{\t\r\n\tinclude(TEMPL_MONETIZE_FOLDER_PATH.'templatic-generalization/general_settings.php');\r\n\t\r\n}", "public static function afficher() {\r\n $filevue = \"application/templates/\" . Page::getInstance()->template . \".template.php\";\r\n\r\n if (file_exists($filevue)) {\r\n require_once $filevue;\r\n } else {\r\n die(\"template non renseigne\");\r\n }\r\n }", "protected function setTemplatePaths() {}", "public function resolve_template() {\n\n\t\t/**\n\t\t * Returns the available template paths for column settings\n\t\t *\n\t\t * @param array $paths Template paths\n\t\t * @param string $template Current template path\n\t\t */\n\t\t$paths = apply_filters( 'ac/view/templates', [ AC()->get_dir() . 'templates' ], $this->template );\n\n\t\tforeach ( $paths as $path ) {\n\t\t\t$file = $path . '/' . $this->template . '.php';\n\n\t\t\tif ( is_readable( $file ) ) {\n\t\t\t\tinclude $file;\n\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\n\t\treturn false;\n\t}", "function myplugin_woocommerce_locate_template( $template, $template_name, $templates_directory ) {\n\t$original_template = $template;\n\n\tif ( ! $templates_directory ) {\n\t\t$templates_directory = WC()->template_url;\n\t}\n\n // Plugin's custom templates/ directory\n\t$plugin_path = myplugin_get_plugin_path() . '/templates/';\n\n\t// Look within passed path within the theme - this is priority.\n\t$template = locate_template(\n\t\tarray(\n\t\t\t$templates_directory . $template_name,\n\t\t\t$template_name,\n\t\t)\n\t);\n\n\t// Get the template from this plugin under /templates/ directory, if it exists.\n\tif ( ! $template && file_exists( $plugin_path . $template_name ) ) {\n\t\t$template = $plugin_path . $template_name;\n\t}\n\n\t// Use default template if not found a suitable template under plugin's /templates/ directory.\n\tif ( ! $template ) {\n\t\t$template = $original_template;\n\t}\n\n\t// Return what we found.\n\treturn $template;\n}", "private function registerTemplates()\n {\n if (!isset($this->config['templates']) || !count($this->config['templates'])) {\n return;\n }\n\n $templatesToAdd = [];\n foreach ($this->config['templates'] as $templateName) {\n $templatesToAdd[ sanitize_title_with_dashes($templateName) ] = $templateName;\n }\n\n add_filter('theme_page_templates', function ($templates) use ($templatesToAdd) {\n foreach ($templatesToAdd as $slug => $name) {\n $templates[ $slug ] = $name;\n }\n return $templates;\n });\n }", "function moderateTemplates() {\n\tglobal $communityPaths,$communitySettings;\n\n\t$templates = readJsonFile($communityPaths['community-templates-info']);\n\n\tif ( ! $templates ) return;\n\tforeach ($templates as $template) {\n\t\t$template['Compatible'] = versionCheck($template);\n\t\tif ( $template[\"DeprecatedMaxVer\"] && version_compare($communitySettings['unRaidVersion'],$template[\"DeprecatedMaxVer\"],\">\") )\n\t\t\t$template['Deprecated'] = true;\n\n\t\t$template['ModeratorComment'] = $template['CaComment'] ?: $template['ModeratorComment'];\n\t\t$o[] = $template;\n\t}\n\twriteJsonFile($communityPaths['community-templates-info'],$o);\n\tpluginDupe($o);\n}", "public function loadTemplates() {\n // Get database hooks.\n $doctrine = $this->container->get('doctrine');\n $slideTemplateRepository = $doctrine->getRepository('Os2DisplayCoreBundle:SlideTemplate');\n $screenemplateRepository = $doctrine->getRepository('Os2DisplayCoreBundle:ScreenTemplate');\n $entityManager = $doctrine->getManager();\n\n // Get parameters.\n $path = $this->container->get('kernel')->getRootDir() . '/../web/';\n $serverAddress = $this->container->getParameter('absolute_path_to_server');\n\n // Locate templates in /web/bundles/\n $templates = $this->findTemplates($path . 'bundles/');\n\n foreach ($templates['slides'] as $config) {\n $dir = explode('/web/', pathinfo($config, PATHINFO_DIRNAME));\n $this->loadSlideTemplate($config, $slideTemplateRepository, $entityManager, $dir[1], $serverAddress, $path);\n }\n\n foreach ($templates['screens'] as $config) {\n $dir = explode('/web/', pathinfo($config, PATHINFO_DIRNAME));\n $this->loadScreenTemplate($config, $screenemplateRepository, $entityManager, $dir[1], $serverAddress, $path);\n }\n\n // Get all templates from the database, and push update to screens.\n $existingTemplates = $screenemplateRepository->findAll();\n $middlewareService = $this->container->get('os2display.middleware.communication');\n foreach ($existingTemplates as $template) {\n foreach ($template->getScreens() as $screen) {\n $middlewareService->pushScreenUpdate($screen);\n }\n }\n }", "function load_template($_template_file, $load_once = \\true, $args = array())\n {\n }", "function display_template($template) {\n\n $file_name = $template;\n\n if ( locate_template( $file_name ) ) :\n $template = locate_template( $file_name );\n else :\n $template = dirname( __FILE__ ) . '/../templates/' . $file_name;\n endif;\n\n if ( $template ) :\n load_template( $template, false );\n endif;\n}", "function edd_pup_template(){\r\n\r\n\t$template = edd_get_option( 'edd_pup_template' );\r\n\r\n\tif ( ! isset( $template ) ) {\r\n\t\t$template = 'default';\r\n\t}\r\n\r\n\tif ( $template == 'inherit' ) {\r\n\t\treturn edd_get_option( 'email_template' );\r\n\t} else {\r\n\t\treturn $template;\r\n\t}\r\n}", "public function get_template( $located, $template_name, $args, $template_path, $default_path ) {\n $plugin_template_path = untrailingslashit( plugin_dir_path( __FILE__ ) ) . '/templates/woocommerce/' . $template_name;\n \n if ( file_exists( $plugin_template_path ) ) {\n $located = $plugin_template_path;\n }\n return $located;\n }", "function health_check_troubleshoot_theme_template( $default ) {\n\t\tif ( $this->self_fetching_theme ) {\n\t\t\treturn $default;\n\t\t}\n\n\t\tif ( ! $this->override_theme() ) {\n\t\t\treturn $default;\n\t\t}\n\n\t\tif ( empty( $this->current_theme_details ) ) {\n\t\t\t$this->self_fetching_theme = true;\n\t\t\t$this->current_theme_details = wp_get_theme( $this->current_theme );\n\t\t\t$this->self_fetching_theme = false;\n\t\t}\n\n\t\t// If no theme has been chosen, start off by troubleshooting as a default theme if one exists.\n\t\t$default_theme = $this->has_default_theme();\n\t\tif ( false === $this->current_theme ) {\n\t\t\tif ( $default_theme ) {\n\t\t\t\treturn $default_theme;\n\t\t\t}\n\t\t}\n\n\t\tif ( $this->current_theme_details->parent() ) {\n\t\t\treturn $this->current_theme_details->get_template();\n\t\t}\n\n\t\treturn $this->current_theme;\n\t}", "private function loadMasterTemplate() {\n\t\t//SOME_THEMES should be defined in SOME_PATH/includes/defines.php\n\t\t$path_and_file = SOME_THEMES.DS.$this->template.DS.$this->file.'.php';\n\t\tif (!file_exists($path_and_file)) {\n\t\t\tthrow new SomeFileNotFoundException(\"Master template file {$this->file} for {$this->template} not found\");\n\t\t}\n\t\t\n\t\tob_start();\n\t\t//$content = file_get_contents(SOME_THEMES.DS.'default'.DS.'index.php');\n\t\t$templatefile = $path_and_file;\n\t\trequire_once($templatefile);\n\t\t$content = ob_get_clean();\n\t\treturn $content;\n\t}", "function _ut_remove_default_vc_templates( $data ) {\r\n \r\n $data = array();\r\n \r\n return $data;\r\n \r\n}", "function rf_locate_template( $template_name, $template_path = '', $default_path = '' )\n{\n if ( ! $template_path ) {\n $template_path = RFFramework()->template_path();\n }\n\n if ( ! $default_path ) {\n $default_path = RFFramework()->path();\n }\n\n // Locate the template within the template structure\n $template = locate_template(\n array(\n trailingslashit( $template_path ) . $template_name\n )\n );\n\n if ( ! $template ) {\n $template = trailingslashit( $default_path ) . $template_name;\n }\n return $template;\n}", "public function template_loader( $template ) {\n\n\t\t\t$find = array(); // nope! not used\n\t\t\t$file = '';\n\n\t\t\tif ( is_tax( 'photo_category' ) ) {\n\n\t\t\t\t$term = get_queried_object();\n\n\t\t\t\t$file = 'taxonomy-' . $term->taxonomy . '.php';\n\t\t\t\t$find[] = 'taxonomy-' . $term->taxonomy . '-' . $term->slug . '.php';\n\t\t\t\t$find[] = $this->template_url . 'taxonomy-' . $term->taxonomy . '-' . $term->slug . '.php';\n\t\t\t\t$find[] = $file;\n\t\t\t\t$find[] = $this->template_url . $file;\n\t\t\t}\n\n\t\t\tif ( is_tax( 'photo_tag' ) ) {\n\n\t\t\t\t$term = get_queried_object();\n\n\t\t\t\t$file = 'taxonomy-' . $term->taxonomy . '.php';\n\t\t\t\t$find[] = 'taxonomy-' . $term->taxonomy . '-' . $term->slug . '.php';\n\t\t\t\t$find[] = $this->template_url . 'taxonomy-' . $term->taxonomy . '-' . $term->slug . '.php';\n\t\t\t\t$find[] = $file;\n\t\t\t\t$find[] = $this->template_url . $file;\n\t\t\t}\n\n\t\t\tif ( $file ) {\n\t\t\t\t$template = locate_template( $find );\n\t\t\t\tif ( ! $template ) $template = $this->plugin_path() . '/templates/' . $file;\n\t\t\t}\n\n\t\t\treturn $template;\n\t\t}", "function locate_template( $template, $template_name, $template_path ){\r\n\r\n\t\tswitch( $template_name ){\r\n\r\n\t\t\tcase 'form-fields/term-checklist-field.php':\r\n\t\t\t\twp_enqueue_script( 'jmfe-term-checklist-field' );\r\n\t\t\t\tbreak;\r\n\r\n\t\t\tdefault:\r\n\t\t\t\tif( file_exists( WPJM_FIELD_EDITOR_PLUGIN_DIR . '/templates/' . $template_name ) ){\r\n\t\t\t\t\t$template = WPJM_FIELD_EDITOR_PLUGIN_DIR . '/templates/' . $template_name;\r\n\t\t\t\t}\r\n\t\t\t\tbreak;\r\n\t\t}\r\n\r\n\t\treturn $template;\r\n\t}", "function hm_load_custom_templates( $template ) {\n\n\tglobal $wp_query, $hm_rewrite_rules, $hm_current_rewrite_rule;\n\n\t// Skip 404 template includes\n\tif ( is_404() && !isset( $hm_current_rewrite_rule[3]['post_query_properties']['is_404'] ) )\n\t\treturn;\n\n\t// Allow 404's to be overridden\n\tif ( is_404() && isset( $hm_current_rewrite_rule[3]['post_query_properties']['is_404'] ) && $hm_current_rewrite_rule[3]['post_query_properties']['is_404'] == false )\n\t\tstatus_header('200');\n\n\t// Show the correct template for the query\n\tif ( isset( $hm_current_rewrite_rule ) && $hm_current_rewrite_rule[4] === $wp_query->query ) {\n\n\t\t// Apply some post query stuff to wp_query\n\t\tif ( isset( $hm_current_rewrite_rule[3]['post_query_properties'] ) )\n\n\t\t\t// $post_query\n\t\t\tforeach( wp_parse_args( $hm_current_rewrite_rule[3]['post_query_properties'] ) as $property => $value )\n\t\t\t\t$wp_query->$property = $value;\n\n\t\tif ( !empty( $hm_current_rewrite_rule[2] ) ) {\n\n\t\t\tdo_action( 'hm_load_custom_template', $hm_current_rewrite_rule[2], $hm_current_rewrite_rule );\n\n\t\t\tif ( empty( $hm_current_rewrite_rule[3]['disable_canonical'] ) && $hm_current_rewrite_rule[1] )\n\t\t\t\tredirect_canonical();\n\n\t\t\tinclude( $hm_current_rewrite_rule[2] );\n\t\t\texit;\n\n\t\t// Allow redirect_canonical to be disabled\n\t\t} else if ( !empty( $hm_current_rewrite_rule[3]['disable_canonical'] ) ) {\n\t\t\tremove_action( 'template_redirect', 'redirect_canonical', 10 );\n\t\t}\n\n\t}\n\n\treturn $template;\n\n}", "protected function getDefaultTemplate()\n {\n return 'modules/XCExample/Recommendations/recommendation/body.twig';\n }", "function dg_choose_template( $template ) {\n\n\tif ( !is_admin() && is_home() ) {\n\t\t\n\t\t$new_template = locate_template( array( 'single.php' ) );\n\t\t\n\t\tif ( !empty( $new_template ) ) {\n\t\t\treturn $new_template;\n\t\t}\n\t}\n\n\treturn $template;\n}", "function astra_addon_locate_template( $template_name, $template_path = '', $default_path = '' ) {\n\n\t\tif ( ! $template_path ) {\n\t\t\t$template_path = 'astra-addon/';\n\t\t}\n\n\t\tif ( ! $default_path ) {\n\t\t\t$default_path = ASTRA_EXT_DIR . 'addons/';\n\t\t}\n\n\t\t/**\n\t\t * Look within passed path within the theme - this is priority.\n\t\t *\n\t\t * Note: Avoided directories '/addons/' and '/template/'.\n\t\t *\n\t\t * E.g.\n\t\t *\n\t\t * 1) Override Footer Widgets - Template 1.\n\t\t * Addon: {astra-addon}/addons/advanced-footer/template/layout-1.php\n\t\t * Theme: {child-theme}/astra-addon/advanced-footer/layout-1.php\n\t\t *\n\t\t * 2) Override Blog Pro - Template 2.\n\t\t * Addon: {astra-addon}/addons/blog-pro/template/blog-layout-2.php\n\t\t * Theme: {child-theme}/astra-addon/blog-pro/blog-layout-2.php.\n\t\t */\n\t\t$theme_template_name = str_replace( 'template/', '', $template_name );\n\t\t$template = locate_template(\n\t\t\tarray(\n\t\t\t\ttrailingslashit( $template_path ) . $theme_template_name,\n\t\t\t\t$theme_template_name,\n\t\t\t)\n\t\t);\n\n\t\t// Get default template.\n\t\tif ( ! $template || ASTRA_EXT_TEMPLATE_DEBUG_MODE ) {\n\t\t\t$template = $default_path . $template_name;\n\t\t}\n\n\t\t// Return what we found.\n\t\treturn apply_filters( 'astra_addon_locate_template', $template, $template_name, $template_path );\n\t}", "function ct_get_template_hierarchy( $template ) {\n \n // Get the template slug\n $template_slug = rtrim( $template, '.php' );//single\n $template = $template_slug . '.php'; //single.php\n\n //logit($template,'$template: ');\n //logit($template_slug,'$template_slug: ');\n\n //$locate = locate_template( array( 'plugin_templates/single.php' ) );\n //$locateString = 'plugin_template/' . $template;\n //logit($locateString,'$locateString: ');\n //logit($locate,'$locate: ');\n \n // Check if a custom template exists in the theme folder, if not, load the plugin template file\n if ( $theme_file = locate_template( array( 'cals_teams_templates/' . $template ) ) ) {\n $file = $theme_file;\n logit($file,'$file: ');\n\n }\n else {\n $file = CT_PLUGIN_BASE_DIR . '/includes/templates/' . $template;\n }\n \n //return apply_filters( 'rc_repl_template_' . $template, $file );\n return $file;\n}", "function carton_get_template( $template_name, $args = array(), $template_path = '', $default_path = '' ) {\n\tglobal $carton;\n\n\tif ( $args && is_array($args) )\n\t\textract( $args );\n\n\t$located = carton_locate_template( $template_name, $template_path, $default_path );\n\n\tdo_action( 'carton_before_template_part', $template_name, $template_path, $located );\n\n\tinclude( $located );\n\n\tdo_action( 'carton_after_template_part', $template_name, $template_path, $located );\n}", "public function template_loader( $template ) {\n\n\t\t\t$find = array( 'wolf-discography.php' ); // nope! not used\n\t\t\t$file = '';\n\n\t\t\tif ( is_single() && 'release' == get_post_type() ) {\n\n\t\t\t\t$file = 'single-release.php';\n\t\t\t\t$find[] = $file;\n\t\t\t\t$find[] = $this->template_url . $file;\n\n\t\t\t} elseif ( is_tax( 'band' ) || is_tax( 'label' ) || is_tax( 'release_genre' ) ) {\n\n\t\t\t\t$term = get_queried_object();\n\n\t\t\t\t$file \t= 'taxonomy-' . $term->taxonomy . '.php';\n\t\t\t\t$find[] \t= 'taxonomy-' . $term->taxonomy . '-' . $term->slug . '.php';\n\t\t\t\t$find[] \t= $this->template_url . 'taxonomy-' . $term->taxonomy . '-' . $term->slug . '.php';\n\t\t\t\t$find[] \t= $file;\n\t\t\t\t$find[] \t= $this->template_url . $file;\n\n\t\t\t} elseif ( is_post_type_archive( 'release' ) ) {\n\n\t\t\t\t$file = 'archive-release.php';\n\t\t\t\t$find[] = $file;\n\t\t\t\t$find[] = $this->template_url . $file;\n\n\t\t\t}\n\n\t\t\tif ( $file ) {\n\t\t\t\t$template = locate_template( $find );\n\t\t\t\tif ( ! $template ) $template = $this->plugin_path() . '/templates/' . $file;\n\t\t\t}\n\n\t\t\treturn $template;\n\t\t}", "function rc_tc_get_template_hierarchy( $template ) {\r\n \r\n echo ('<!-- Looking for Template ' . __( $template, 'nmmc' ) . '-->' );\r\n // Get the template slug\r\n $template_slug = rtrim( $template, '.php' );\r\n $template = $template_slug . '.php';\r\n echo ('<!-- Looking for Template ' . __( $template, 'nmmc' ) . '-->' );\r\n \r\n \r\n // Check if a custom template exists in the theme folder, if not, load the plugin template file\r\n if ( $theme_file = locate_template( array( 'plugin_template/' . $template ) ) ) {\r\n $file = $theme_file;\r\n }\r\n else {\r\n $file = RC_TC_BASE_DIR . '/templates/' . $template;\r\n }\r\n echo ('<!-- Use Template ' . __( $file, 'nmmc' ) . '-->' );\r\n return apply_filters( 'rc_repl_template_' . $template, $file );\r\n}", "public function Setup_Templates_List() : void\n {\n $this->Templates = apply_filters(\"WP_Plugin_virtual_pages_templates\",[\n ...array('page.php', 'index.php' ), ...(array) $this->Template]);\n }", "public function load_template_methods()\n\t{\n\t\tif (!$this->modtemplates)\n\t\t{\n\t\t\trequire_once(cms_join_path(dirname(__FILE__), 'module_support', 'modtemplates.inc.php'));\n\t\t\t$this->modtemplates = true;\n\t\t}\n\t}", "function dokan_get_template( $template_name, $args = array() ) {\n\n if ( file_exists( $template_name ) ) {\n extract( $args );\n\n include_once $template_name;\n }\n}", "public function loadTemplate($path);", "public function initTemplate() {}", "public function getTemplate(){\n\t\treturn $this->CustomTemplate ? $this->CustomTemplate : $this->config()->get('default_template');\n\t}", "function getTemplateFile ()\n\t{\n\t\t//\n\t\t// Allow the template to override a specific file. If this file exist\n\t\t// (the file in the template directory), it will be loaded, otherwise\n\t\t// the default (in the plugin directory) will be loaded\n\t\t//\n\t\t$renderer = 'templates/'.$this->getTemplate ().'/'.$this->getRenderer ();\n\t\tif (!(file_exists ($renderer)))\n\t\t{\n\t\t\t$renderer = 'framework/view/'.$this->getRenderer ();\n\t\t}\n\t\treturn $renderer;\n\t}", "protected function getDefaultTemplate()\n {\n return 'modules/XC/Velocity/payment.tpl';\n }", "public static function loadTemplateData()\n {\n $templateId = 0;\n $app = Factory::getApplication();\n\n if ($app->isClient('site'))\n {\n $currentTemplate = $app->getTemplate(true);\n $templateId = $currentTemplate->id ?? 0;\n\n\t\t\t/**\n\t\t\t * If a page/menu is assigned to a specific template\n\t\t\t * then get the template ID.\n\t\t\t */\n\t\t\t$activeMenu = $app->getMenu()->getActive();\n\n\t\t\tif (!empty($activeMenu) && !empty($activeMenu->template_style_id))\n\t\t\t{\n\t\t\t\t$templateId = $activeMenu->template_style_id;\n\t\t\t}\n }\n else\n {\n if ($app->input->get('option') === 'com_ajax' && $app->input->get('helix') === 'ultimate')\n {\n $templateId = $app->input->get('id', 0, 'INT');\n }\n }\n\n\t\tif (empty($templateId))\n\t\t{\n\t\t\t$templateId = $app->input->get('helix_id', 0, 'INT');\n\t\t}\n\n if($templateId)\n {\n $template = [];\n\n $draftKeyOptions = [\n 'option' => 'com_ajax',\n 'helix' => 'ultimate',\n 'status' => 'draft',\n 'id' => $templateId\n ];\n\n $draftKey = self::generateKey($draftKeyOptions);\n $cache = new HelixCache($draftKey);\n\n /**\n * Check the fetch destination. If it is iframe then load the settings\n * from draft, otherwise if it is document that means this request\n * comes from the original site visit. So load from saved cache.\n */\n $requestFromIframe = $app->input->get('helixMode', '') === 'edit';\n \n if ($cache->contains() && $requestFromIframe)\n {\n $template = $cache->loadData();\n }\n else\n {\n $keyOptions = [\n 'option' => 'com_ajax',\n 'helix' => 'ultimate',\n 'status' => 'init',\n 'id' => $templateId\n ];\n \n $key = self::generateKey($keyOptions);\n $cache->setCacheKey($key);\n \n if ($cache->contains())\n {\n $template = $cache->loadData();\n }\n else\n {\n $template = self::getTemplateStyle($templateId); \n }\n }\n\n\t\t\tif (isset($template->template) && !empty($template->template))\n\t\t\t{\n\t\t\t\tif (!empty($template->params) && \\is_string($template->params))\n\t\t\t\t{\n\t\t\t\t\t$template->params = new Registry($template->params);\n\t\t\t\t}\n\n\t\t\t\t/**\n\t\t\t\t * If params field is found empty in the database or cache then\n\t\t\t\t * read the default options.json file from the template and assign\n\t\t\t\t * the options as template params.\n\t\t\t\t */\n\t\t\t\telseif (empty($template->params))\n\t\t\t\t{\n\t\t\t\t\t$filePath = JPATH_ROOT . '/templates/' . $template->template . '/' . 'options.json';\n\n\t\t\t\t\tif (\\file_exists($filePath))\n\t\t\t\t\t{\n\t\t\t\t\t\t$defaultParams = \\file_get_contents($filePath);\n\t\t\t\t\t\t$template->params = new Registry($defaultParams);\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$template->params = new Registry;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn $template;\n\t\t\t}\n }\n\n $template = new \\stdClass;\n $template->template = 'system';\n $template->params = new Registry;\n\n return $template;\n }", "public function beforeTemplate(){\n\t\t//defaults to empty\n\t}", "private function load_wordpress_with_template()\n {\n global $wp_query;\n\n WP_CLI::get_runner()->load_wordpress();\n\n // Set up the main WordPress query.\n wp();\n\n $interpreted = [];\n foreach ($wp_query as $key => $value) {\n if (0 === stripos($key, 'is_') && $value) {\n $interpreted[] = $key;\n }\n }\n WP_CLI::debug('Main WP_Query: ' . implode(', ', $interpreted), 'redis-debug');\n\n define('WP_USE_THEMES', true);\n\n add_filter(\n 'template_include',\n function ($template) {\n $display_template = str_replace(dirname(get_template_directory()) . '/', '', $template);\n WP_CLI::debug(\"Theme template: {$display_template}\", 'redis-debug');\n return $template;\n },\n 999\n );\n\n // Template is normally loaded in global scope, so we need to replicate\n foreach ($GLOBALS as $key => $value) {\n global $$key;\n }\n\n // Load the theme template.\n ob_start();\n require_once(ABSPATH . WPINC . '/template-loader.php');\n ob_get_clean();\n }", "function dw_woo_adon_plugin_template( $template, $template_name, $template_path ) {\r\n\tglobal $woocommerce;\r\n\t$_template = $template;\r\n\tif ( ! $template_path ) \r\n\t\t$template_path = $woocommerce->template_url;\r\n\r\n\t$plugin_path = untrailingslashit( plugin_dir_path( __FILE__ ) ) . '/woocommerce/';\r\n\r\n\t// Look within passed path within the theme - this is priority\r\n\t$template = locate_template(\r\n\t\tarray(\r\n\t\t\t$template_path . $template_name,\r\n\t\t\t$template_name\r\n\t\t\t)\r\n\t\t);\r\n\r\n\tif( ! $template && file_exists( $plugin_path . $template_name ) )\r\n\t\t$template = $plugin_path . $template_name;\r\n\r\n\tif ( ! $template )\r\n\t\t$template = $_template;\r\n\r\n\treturn $template;\r\n}" ]
[ "0.68796265", "0.6864075", "0.6720494", "0.6702375", "0.66320956", "0.6627882", "0.66188306", "0.6613141", "0.6591195", "0.65862477", "0.6579832", "0.6513114", "0.64753884", "0.6458532", "0.6446248", "0.6442429", "0.64404786", "0.6395148", "0.6390259", "0.63387877", "0.6325982", "0.6322979", "0.6312554", "0.6299881", "0.62841344", "0.6266126", "0.6254094", "0.6251126", "0.6244974", "0.6243327", "0.6241111", "0.62289494", "0.6226251", "0.6186536", "0.61826783", "0.61768174", "0.61626524", "0.6157136", "0.61507887", "0.6146225", "0.61300784", "0.61295104", "0.61238265", "0.61187327", "0.6111413", "0.61076826", "0.61068314", "0.6104355", "0.60994995", "0.6095767", "0.6093681", "0.60907507", "0.60877603", "0.60644746", "0.6038142", "0.60201967", "0.6013116", "0.5997988", "0.59892005", "0.5981135", "0.5967493", "0.5965212", "0.5940686", "0.5936535", "0.5918055", "0.59135705", "0.5907874", "0.59022564", "0.59022385", "0.58900166", "0.5886481", "0.58761394", "0.5867534", "0.58613837", "0.5859514", "0.5849275", "0.58489186", "0.58437115", "0.58413565", "0.5839211", "0.5825155", "0.58166426", "0.58110255", "0.5810715", "0.5792154", "0.5779251", "0.5777309", "0.57538205", "0.575337", "0.57500935", "0.57382417", "0.5724992", "0.57231885", "0.57211494", "0.571876", "0.5718139", "0.57169753", "0.5714492", "0.5698518", "0.56938064" ]
0.7047659
0
Properly enqueues JS files into WP.
function load_admin_scripts() { wp_enqueue_script('media-upload'); wp_enqueue_script('thickbox'); wp_enqueue_script('jquery'); wp_register_script( 'wppm-admin-gallery', plugin_dir_url( __FILE__ ) . 'assets/js/admin-gallery.js', array( 'jquery', 'media-upload', 'thickbox' ) ); wp_enqueue_script( 'wppm-admin-gallery' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function enqueueScripts(){}", "static function enqueue_scripts(){\n\t\tself::include_css();\n\t\tself::include_js();\n\t}", "public function enqueue_scripts() {\n\n\t\tif ($this->js) {\n\t\t\tforeach ($this->js as $js) {\n\t\t\t\t$fileTitle = basename($js['link']);\n\t\t\t\t$fileTitle = str_replace('.js', '', $fileTitle);\n\t\t\t\t$fileTitle = preg_replace(\n\t\t\t\t\t'/[^0-9a-zA-Z]/',\n\t\t\t\t\t\"-\",\n\t\t\t\t\tstr_replace('@', '', $js['package']) . '-' . $fileTitle\n\t\t\t\t);\n\t\t\t\twp_enqueue_script($fileTitle, $js['link'], array(), $js['version']);\n\t\t\t}\n\t\t}\n\t}", "public function queue_scripts() {\n\t\t\tif ( $queue = WPO_WCPDF_Dropbox()->hooks->get_queued_files() ) {\n\t\t\t\twp_register_script(\n\t\t\t\t\t'dropbox-queue',\n\t\t\t\t\tplugins_url( 'js/dropbox-queue.js' , dirname(__FILE__) ),\n\t\t\t\t\tarray( 'jquery', 'thickbox' )\n\t\t\t\t);\n\t\t\t\twp_enqueue_script( 'dropbox-queue' );\n\t\t\t\twp_enqueue_style( 'thickbox' );\n\t\t\t}\n\t\t}", "function enqueue_scripts() {\n\t\tinclude $this->dir_path . 'scripts.php';\n\t}", "function admin_enqueue_script(){\n\t\tglobal $postmec;\n\t\t\n\t\tif($_GET['page'] == 'stores-management'){\n\t\t\twp_enqueue_script('jquery');\n\t\t\twp_enqueue_style( 'thickbox' ); // Stylesheet used by Thickbox\n\t\t\twp_enqueue_script( 'thickbox' );\n\t\t\twp_enqueue_script( 'media-upload' );\n\t\t\twp_register_script('store-media-upload', $postmec->get_postmec_url() . 'js/plugin.media-uploader.js', array('jquery', 'thickbox', 'media-upload'));\n\t\t\twp_enqueue_script('store-media-upload');\n\t\t\n\t\t\t//wp_register_script('media-uploader-activator', $commentbar->get_this_url() . 'js/uploader.activator.js', array('jquery'));\n\t\t\t//wp_enqueue_script('media-uploader-activator');\n\t\t}\n\t}", "function starkers_script_enqueuer() {\n\t\twp_register_script( 'site', get_template_directory_uri().'/js/scripts.min.js', array( 'jquery' ) );\n\t\twp_enqueue_script( 'site' );\n\n\t\twp_register_style( 'screen', get_stylesheet_directory_uri().'/style.css', '', '', 'screen' );\n\t\twp_enqueue_style( 'screen' );\n\t}", "public function enqueue_scripts() {\r\n\r\n\t\t}", "public function public_enqueue_scripts() {\n\n\t\twp_register_script('custom-event-polyfill', get_template_directory_uri() . '/js/polyfill/custom-event.min.js', array(), $this->version, true);\n\t\twp_register_script('promise-polyfill', get_template_directory_uri() . '/js/polyfill/promise.min.js', array(), $this->version, true);\n\t\t// wp_register_script('scroll-polyfill', get_template_directory_uri() . '/js/polyfill/smoothscroll.min.js', array(), $this->version, true);\n\n\t\twp_register_script('tinyAnimate', get_template_directory_uri() . '/js/utils/TinyAnimate.js', array(), $this->version, true);\n\t\twp_register_script('swipe', get_template_directory_uri() . '/js/utils/swipe.js', array(), $this->version, true);\n\t\twp_register_script('collection', get_template_directory_uri() . '/js/utils/collection.js', array(), $this->version, true);\n\t\twp_register_script('media-player', get_template_directory_uri() . '/js/utils/media-player.js', array('tinyAnimate', 'collection'), $this->version, true);\n\t\twp_register_script('media-player-v2', get_template_directory_uri() . '/js/utils/media-player-v2.js', array('tinyAnimate', 'collection'), $this->version, true);\n\t\twp_register_script('build', get_template_directory_uri() . '/js/utils/build.js', array(), $this->version, true);\n\t\twp_register_script('ajax', get_template_directory_uri() . '/js/utils/ajax.js', array(), $this->version, true);\n\t\twp_register_script('marquee', get_template_directory_uri() . '/js/utils/marquee.js', array(), $this->version, true);\n\t\twp_register_script('popup', get_template_directory_uri() . '/js/utils/popup.js', array('tinyAnimate'), $this->version, true);\n\t\twp_register_script('calendar', get_template_directory_uri() . '/js/utils/calendar.js', array(), $this->version, true);\n\t\twp_register_script('translation', get_template_directory_uri() . '/js/utils/translation.js', array(), $this->version, true);\n\t\twp_register_script('grid-system', get_template_directory_uri() . '/js/utils/grid-system.js', array('tinyAnimate'), $this->version, true);\n\t\twp_register_script('sticky', get_template_directory_uri() . '/js/utils/sticky.js', array(), $this->version, true);\n\t\twp_register_script('custom-dispatcher', get_template_directory_uri() . '/js/utils/custom-dispatcher.js', array(), $this->version, true);\n// \t\twp_enqueue_script('grid', get_template_directory_uri() . '/js/grid.js', array('grid-system'), $this->version, true);\n// \t\twp_enqueue_script('projects-grid', get_template_directory_uri() . '/js/projects.js', array('grid'), $this->version, true);\n// \t\twp_enqueue_script('project', get_template_directory_uri() . '/js/project.js', array('grid'), $this->version, true);\n// \t\twp_enqueue_script('image', get_template_directory_uri() . '/js/image.js', array('tinyAnimate'), $this->version, true);\n\t\t// wp_register_script('grid-slideshow', get_template_directory_uri() . '/js/grid-slideshow.js', array('media-player', 'swipe', 'build'), $this->version, true);\n\n\t\t// wp_enqueue_script('home', get_template_directory_uri() . '/js/home.js', array('grid-slideshow'), $this->version, true);\n\t\t// wp_enqueue_script('header', get_template_directory_uri() . '/js/header.js', array('popup', 'sticky', 'marquee'), $this->version, true);\n\t\t// wp_enqueue_script('single', get_template_directory_uri() . '/js/single.js', array('grid-slideshow'), $this->version, true);\n\t\t// wp_enqueue_script('bios', get_template_directory_uri() . '/js/bios.js', array('popup'), $this->version, true);\n\t\t// wp_enqueue_script('agenda', get_template_directory_uri() . '/js/agenda.js', array('popup', 'ajax', 'build', 'calendar', 'grid-slideshow'), $this->version, true);\n\t\t// wp_enqueue_script('intro', get_template_directory_uri() . '/js/intro.js', array('media-player'), $this->version, true);\n\n\t\twp_register_script('cookies', get_template_directory_uri() . '/js/utils/cookies.js', array(), $this->version, false);\n\n\t\twp_register_script('gmap', get_template_directory_uri() . '/js/utils/gmap.js', array('gmap-api'), $this->version, true);\n\n\t}", "public function enqueue_scripts() {\n\n\t}", "public function scripts(){\n //Enqueue scripts\n /**\n * wp_enqueue_script('sample-script',$this->directory_uri . '/sample.min.js',array('jquery'),false,false);\n * ...\n * ....\n */\n }", "public function enqueue_scripts()\n {\n }", "public function enqueue_scripts()\n {\n }", "public function enqueue_scripts()\n {\n }", "function enqueue() {\n\n\t$js_path = trailingslashit( get_template_directory() ) . 'assets/js/main.min.js';\n\t$css_path = trailingslashit( get_template_directory() ) . 'assets/css/main.min.css';\n\t$req_path = trailingslashit( get_template_directory() ) . 'assets/js/vendor.min.js';\n\n\twp_enqueue_script(\n\n\t\t'req_js',\n\t\ttrailingslashit( get_stylesheet_directory_uri() ) . 'assets/js/vendor.min.js',\n\t\tfalse,\n\t\tfilemtime($req_path),\n\t\ttrue\n\n\t);\n\n\twp_enqueue_script(\n\n\t\t'main_js',\n\t\ttrailingslashit( get_stylesheet_directory_uri() ) . 'assets/js/main.min.js',\n\t\tfalse,\n\t\tfilemtime($js_path),\n\t\ttrue\n\n\t);\n\n\twp_enqueue_style(\n\n\t\t'main_css',\n\t\ttrailingslashit( get_stylesheet_directory_uri() ) . 'assets/css/main.min.css',\n\t\tfalse,\n\t\tfilemtime($css_path),\n\t\t'all'\n\n\t);\n\n}", "function put_in_queue() {\n wp_enqueue_script('reviewsjs', plugins_url('/assets/js/reviews.js', __FILE__));\n wp_enqueue_style('reviewscss', plugins_url('/assets/css/reviews.css', __FILE__));\n }", "function queue_scripts() {\n\n if (!is_admin()) {\n\n // Deregister scripts.\n wp_deregister_script('jquery');\n\n\n // Scripts in header.\n wp_register_script('modernizr-js', get_stylesheet_directory_uri() . '/assets/js/vendor/modernizr-2.7.1.min.js', array(), '2.7.1', false);\n\n\n // Scripts in footer.\n wp_register_script('jquery', get_stylesheet_directory_uri() . '/assets/js/vendor/jquery-1.10.2.min.js', array(), '1.10.2', true);\n wp_register_script('main-js', get_stylesheet_directory_uri() . '/assets/js/main.min.js', array(), '', true);\n\n\n // Queue scripts.\n wp_enqueue_script('modernizr-js');\n // wp_enqueue_script('jquery');\n // wp_enqueue_script('main-js');\n\n }\n}", "private function enqueues(){\n\n\t\t\tadd_action( 'init', function(){\n\n\t\t\t\t//scripts:\n\t\t\t\t$url = Url::plugin( 'chef-sections', true ).'Assets/js/libs/';\n\t\t\t\t\n\t\t\t\tScript::register( 'isotope', $url.'isotope.min', false );\n\t\t\t\tScript::register( 'imagesloaded', $url.'imagesloaded.min', false );\n\t\t\t\tScript::register( 'autoload', $url.'autoload', false );\n\t\t\t\tScript::register( 'fitvids', $url.'fitvids.min', false );\n\n\t\t\t\t//sass:\n\t\t\t\tif( !Sass::ignore() ){\n\t\t\t\t\t\n\t\t\t\t\t$url = 'chef-sections/Assets/sass/front/';\n\t\t\t\t\t\n\t\t\t\t\tSass::register( 'sections-columns', $url.'_columns', false );\n\t\t\t\t\tSass::register( 'sections-collection', $url.'_collection', false );\n\t\t\t\t\tSass::register( 'sections-loader', $url.'_loader', false );\n\t\t\t\t\tSass::register( 'sections-socials', $url.'_socials', false );\n\t\t\t\t\tSass::register( 'sections-responsive', $url.'_responsive', false );\n\n\t\t\t\t}else{\n\n\t\t\t\t\t//we need to ignore sass and enqueue a regular css file:\n\t\t\t\t\tadd_action( 'wp_enqueue_scripts', function(){\n\n\t\t\t\t\t\twp_enqueue_style( 'chef_sections', Url::plugin( 'chef-sections', true ).'Assets/css/compiled.css' );\n\n\t\t\t\t\t});\n\n\t\t\t\t}\n\t\t\t});\n\t\t}", "public function enqueueScripts() {\n\t\t\twp_enqueue_script('jquery');\n//\t\t\twp_enqueue_script('owl', self::asset(\"node_modules/owl.carousel/dist/owl.carousel.min.js\"), ['jquery'], '1.0.0', ' all');\n// wp_enqueue_script('headroom', self::asset(\"node_modules/headroom.js/dist/headroom.min.js\"), ['jquery'], '1.0.0', ' all');\n// wp_enqueue_script('prettyPhoto', self::asset(\"js/vendor/jquery.prettyPhoto.js\"), ['jquery'], '1.0.0', ' all');\n//\t\t\twp_enqueue_script('navigo', self::asset(\"node_modules/navigo/lib/navigo.min.js\"), ['jquery'], '1.0.0', ' all')\\;\n\t\t\twp_enqueue_script('app', self::asset(\"js/app.min.js\"), ['jquery'], '1.0.0', ' all');\n\t\t}", "public function enqueue_scripts()\n {\n }", "public static function enqueue_scripts() {\n\t\tif ( ! static::$enqueued && wp_script_is( 'cmb2-scripts', 'enqueued' ) ) {\n\t\t\twp_enqueue_script( 'wplibs-form' );\n\t\t\tstatic::$enqueued = true;\n\t\t}\n\t}", "protected function enqueue_scripts()\n {\n\n }", "private function enqueue () {\n\n\t\t$this->add_action ('admin_enqueue_scripts', $this, 'enqueue_files' );\n\t}", "static function enqueue_scripts() {\n\t\tif ( ! static::matches_custom_format( get_post_format() ) ) {\n\t\t\treturn;\n\t\t}\n\n\t\t//scripts\n\t\twp_register_script( 'custom-event-preview-script', get_stylesheet_directory_uri() . '/assets/js/cpf-event-preview.min.js', array( 'jquery' ), CURRENT_THEME_VERSION, true );\n\t\twp_enqueue_script( 'custom-event-preview-script' );\n\t\twp_localize_script( 'custom-event-preview-script', 'evtPreviewData', self::event_preview_data() );\n\t}", "public function enqueue()\n {\n foreach ($this->assets as $name => $asset) {\n if (preg_match('/\\.js$/', $asset)) {\n wp_enqueue_script($name, $this->assetsUrl . $asset, [], false, true);\n }\n if (preg_match('/\\.css$/', $asset)) {\n wp_enqueue_style($name, $this->assetsUrl . $asset);\n }\n }\n }", "function prosody_plugin_queue_scripts ()\n{\n\n wp_enqueue_style(\n 'poem-css',\n plugin_dir_url( __FILE__ ) . 'css/poem.css',\n array(),\n null,\n false\n );\n\n wp_register_script(\n 'handlers.js',\n plugins_url('js/handlers.js', __FILE__),\n array(),\n null,\n true\n );\n // Localize the script to pass in the siteurl\n wp_localize_script('handlers.js', 'WPURLS', array( 'siteurl' => home_url() ));\n wp_enqueue_script( 'handlers.js' );\n}", "public function enqueue_scripts() {\n\n if ( ! isset( $this->plugin_screen_hook_suffix ) ) {\n return;\n }\n\n $screen = get_current_screen();\n\n if ( $screen->id == $this->plugin_screen_hook_suffix ) {\n\n wp_enqueue_script( 'thickbox' );\n wp_enqueue_style( 'thickbox' );\n wp_enqueue_script( 'media-upload' );\n wp_enqueue_script( 'jquery-ui-datepicker' );\n wp_enqueue_script( 'chartjs', plugin_dir_url( __FILE__ ) . 'js/vendor/Chart.min.js', array(), $this->version );\n wp_enqueue_script( 'wpp-chart', plugin_dir_url( __FILE__ ) . 'js/chart.js', array('chartjs'), $this->version );\n wp_register_script( 'wordpress-popular-posts-admin-script', plugin_dir_url( __FILE__ ) . 'js/admin.js', array('jquery'), $this->version, true );\n wp_localize_script( 'wordpress-popular-posts-admin-script', 'wpp_admin_params', array(\n 'nonce' => wp_create_nonce( \"wpp_admin_nonce\" )\n ));\n wp_enqueue_script( 'wordpress-popular-posts-admin-script' );\n\n }\n\n }", "public function enqueue_scripts() {\n\t\t$this->styles();\n\t\t$this->scripts();\n\t}", "function smash_enqueue_scripts() {\n\n\tglobal $wp_scripts;\n\n\t$js_assets = smash_get_scripts();\n\n\tforeach ( $js_assets AS $handle => $asset ) {\n\n\t\twp_enqueue_script( $handle, $asset[ 'file' ], $asset[ 'deps' ], $asset[ 'ver' ], $asset[ 'in_footer' ] );\n\n\t\t// checking for localize script args\n\t\tif ( array_key_exists( 'localize', $asset ) && ! empty( $asset[ 'localize' ] ) ) {\n\t\t\tforeach ( $asset[ 'localize' ] as $name => $args ) {\n\t\t\t\twp_localize_script( $handle, $name, $args );\n\t\t\t}\n\t\t}\n\n\t\tif ( array_key_exists( 'data', $asset ) ) {\n\t\t\tforeach ( $asset[ 'data' ] as $key => $value ) {\n\t\t\t\t$wp_scripts->add_data( $handle, $key, $value );\n\t\t\t}\n\t\t}\n\n\t}\n}", "public function enqueue_scripts() {\n\t\t/**\n\t\t * Filters the path to the admin JS script.\n\t\t *\n\t\t * @since 1.0.0\n\t\t *\n\t\t * @param string $path The path to the admin JS script.\n\t\t */\n\t\t$script_path = apply_filters( 'stellarwp/telemetry/' . Config::get_hook_prefix() . 'script_path', $this->get_asset_path() . 'resources/js/scripts.js' );\n\n\t\twp_enqueue_script(\n\t\t\tself::SCRIPT_HANDLE,\n\t\t\t$script_path,\n\t\t\t[ 'jquery' ],\n\t\t\tself::SCRIPT_VERSION,\n\t\t\ttrue\n\t\t);\n\t}", "public function enqueue_front_end_scripts() {}", "public function enqueue_scripts() {\n\n\t\t// Setup scripts array\n\t\t$scripts = array();\n\n\t\t// Always pull in jQuery for TinyMCE shortcode usage\n\t\tif ( bbp_use_wp_editor() ) {\n\t\t\t$scripts['bbpress-editor'] = array(\n\t\t\t\t'file' => 'js/editor.js',\n\t\t\t\t'dependencies' => array( 'jquery' )\n\t\t\t);\n\t\t}\n\n\t\t// Forum-specific scripts\n\t\tif ( bbp_is_single_forum() ) {\n\t\t\t$scripts['bbpress-forum'] = array(\n\t\t\t\t'file' => 'js/forum.js',\n\t\t\t\t'dependencies' => array( 'jquery' )\n\t\t\t);\n\t\t}\n\n\t\t// Topic-specific scripts\n\t\tif ( bbp_is_single_topic() ) {\n\n\t\t\t// Topic favorite/unsubscribe\n\t\t\t$scripts['bbpress-topic'] = array(\n\t\t\t\t'file' => 'js/topic.js',\n\t\t\t\t'dependencies' => array( 'jquery' )\n\t\t\t);\n\n\t\t\t// Hierarchical replies\n\t\t\tif ( bbp_thread_replies() ) {\n\t\t\t\t$scripts['bbpress-reply'] = array(\n\t\t\t\t\t'file' => 'js/reply.js',\n\t\t\t\t\t'dependencies' => array( 'jquery' )\n\t\t\t\t);\n\t\t\t}\n\t\t}\n\n\t\t// User Profile edit\n\t\tif ( bbp_is_single_user_edit() ) {\n\t\t\t$scripts['bbpress-user'] = array(\n\t\t\t\t'file' => 'js/user.js',\n\t\t\t\t'dependencies' => array( 'user-query' )\n\t\t\t);\n\t\t}\n\n\t\t// Filter the scripts\n\t\t$scripts = apply_filters( 'BBP_IOA_scripts', $scripts );\n\n\t\t// Enqueue the scripts\n\t\tforeach ( $scripts as $handle => $attributes ) {\n\t\t\tbbp_enqueue_script( $handle, $attributes['file'], $attributes['dependencies'], $this->version, 'screen' );\n\t\t}\n\t}", "public function enqueue_files ()\n\t{\n\t\t// Flowdrive\n\t\twp_register_style( 'flowdrive_admin_css', plugin_dir_url( __DIR__ ) . 'assets/css/flowdrive-admin.css', false, $this->version );\n\t\twp_enqueue_style( 'flowdrive_admin_css' );\n\t\t\n\t\t// wp_enqueue_script( $this, plugin_dir_url( __FILE__ ) . 'js/cloudoki-smmp-admin.js', array( 'jquery' ), $this->version, false );\n\t\t\n\t\t// Chosen\n\t\twp_register_style( 'chosen_admin_css', plugin_dir_url( __DIR__ ) . '../vendor/drmonty/chosen/css/chosen.min.css', false, $this->version );\n\t\twp_enqueue_style( 'chosen_admin_css' );\n\t\t\n\t\twp_register_script( 'chosen_admin_js', plugin_dir_url( __DIR__ ) . '../vendor/drmonty/chosen/js/chosen.jquery.min.js', ['jquery'], $this->version );\n\t\twp_enqueue_script( 'chosen_admin_js' );\n\t\t\n\t\t// wp_enqueue_script( $this, plugin_dir_url( __DIR__ ) . '../vendor/drmonty/chosen/js/chosen.jquery.min.js', array( 'jquery' ), $this->version, false );\n\t}", "public function enqueue_scripts()\n\t{\n\t\twp_register_script('peepso-activitystream', $this->plugin_url . 'asset/js/activitystream.js',\n\t\t\tarray('peepso'), PeepSo::PLUGIN_VERSION, TRUE);\n\t}", "public function enqueue_script() {\n\t\t$suffix = SCRIPT_DEBUG ? '' : '.min';\n\n\t\twp_enqueue_script(\n\t\t\t'gallery-types',\n\t\t\tplugins_url( \"assets/js/gallery-types-setting$suffix.js\", PLUGIN_FILE ),\n\t\t\t[ 'media-views' ],\n\t\t\t'20170217'\n\t\t);\n\t}", "function enqueueFiles()\n{\n wp_enqueue_style('style', get_stylesheet_uri(), array(), '1.22');\n wp_enqueue_script('script', get_template_directory_uri() . '/assets/js/custom.js', array(), '1.22');\n}", "public function enqueue_scripts()\n {\n if (is_singular($this->token)) {\n wp_register_style($this->token, esc_url($this->assets_url . 'css/chiroquiz.css'), [], CHIRO_QUIZ_PLUGIN_VERSION);\n wp_register_style('animate', esc_url($this->assets_url . 'css/animate.css'), [], CHIRO_QUIZ_PLUGIN_VERSION);\n wp_register_style('roboto', 'https://fonts.googleapis.com/css?family=Roboto:400,400italic,500,500italic,700,700italic,900,900italic,300italic,300');\n wp_register_style('robo-slab', 'https://fonts.googleapis.com/css?family=Roboto+Slab:400,700,300,100');\n wp_enqueue_style($this->token);\n wp_enqueue_style('animate');\n wp_enqueue_style('roboto');\n wp_enqueue_style('roboto-slab');\n\n wp_register_script('icheck', esc_url($this->assets_url . 'js/icheck.js'), ['jquery']);\n wp_register_script($this->token . '-js', esc_url($this->assets_url . 'js/scripts.js'), [\n 'jquery',\n 'icheck'\n ]);\n wp_enqueue_script('icheck');\n wp_enqueue_script($this->token . '-js');\n wp_register_script('platform-email-validator', esc_url($this->assets_url . 'js/platform-email-validator.js'), [\n 'jquery'\n ], CHIRO_QUIZ_PLUGIN_VERSION);\n wp_enqueue_script('platform-email-validator');\n\n $localize = [\n 'ajaxurl' => admin_url('admin-ajax.php'),\n ];\n wp_localize_script($this->token . '-js', 'ChiroQuiz', $localize);\n }\n }", "public function enqueue_scripts() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Fastnetmarketing_Admin_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Fastnetmarketing_Admin_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/fastnetmarketing-admin-admin.js', array( 'jquery' ), $this->version, false );\n\n\t}", "function jakob_script_enqueue() {\r\n wp_enqueue_style('customstyle', get_template_directory_uri().'/css/jakob.css', false, '1.0.0', 'all');\r\n wp_enqueue_script('customjs-jakob', get_template_directory_uri().'/js/jakob.js', array(), '1.0.0', true);\r\n wp_enqueue_script('customjs-contact', get_template_directory_uri().'/js/contact-form.js', array(), '1.0.0', true);\r\n wp_enqueue_script('font-awesome', 'https://use.fontawesome.com/releases/v5.0.4/js/all.js', array(), '1.0.0', true);\r\n}", "public function enqueue_scripts()\n\t{\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Prosvit_Extension_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Prosvit_Extension_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\t\twp_enqueue_script('script_select2', plugin_dir_url(__FILE__) . 'js/select2.min.js', array('jquery'), $this->version, false);\n\t\twp_enqueue_script($this->plugin_name, plugin_dir_url(__FILE__) . 'js/prosvit-extension-admin.js', array('jquery'), $this->version, false);\n\t}", "public static function register_javascript(array $queue = array())\r\n\t\t{\r\n\t\t\twp_enqueue_script('media-upload');\r\n\t\t\twp_enqueue_script('thickbox');\r\n\t\t\twp_enqueue_script('icf-flexible-wh', self::get_latest_version_url() . '/js/flexible_wh.js', array('jquery'), null, true);\r\n\r\n\t\t\tif (version_compare(get_bloginfo('version'), '3.3', '>=')) {\r\n\t\t\t\twp_enqueue_script('wplink');\r\n\t\t\t\twp_enqueue_script('wpdialogs-popup');\r\n\t\t\t\twp_enqueue_script('icf-active-editor', self::get_latest_version_url() . '/js/active_editor.js', array('jquery'), null, true);\r\n\t\t\t\twp_enqueue_script('icf-quicktags', self::get_latest_version_url() . '/js/quicktags.js', array('quicktags'), null, true);\r\n\t\t\t}\r\n\r\n\t\t\tif (!wp_script_is('icf-mobiscroll', 'registered')) {\r\n\t\t\t\twp_enqueue_script('icf-mobiscroll', self::get_latest_version_url() . '/js/mobiscroll/mobiscroll-1.6.min.js', array('jquery'));\r\n\t\t\t}\r\n\r\n\t\t\tif (!wp_script_is('icf-exvalidaion', 'registered')) {\r\n\t\t\t\twp_enqueue_script('icf-exvalidation', self::get_latest_version_url() . '/js/exvalidation/exvalidation.js', array('jquery'));\r\n\t\t\t}\r\n\r\n\t\t\tif (!wp_script_is('icf-exchecker', 'registered')) {\r\n\t\t\t\t$exchecker = 'exchecker-' . get_locale() . '.js';\r\n\r\n\t\t\t\tif (!is_readable(self::get_latest_version_dir() . '/js/exvalidation/' . $exchecker)) {\r\n\t\t\t\t\t$exchecker = 'exchecker-en_US.min.js';\r\n\t\t\t\t}\r\n\r\n\t\t\t\twp_enqueue_script('icf-exchecker', self::get_latest_version_url() . '/js/exvalidation/' . $exchecker, array('jquery'));\r\n\t\t\t}\r\n\r\n\t\t\tif (!wp_script_is('icf-common', 'registered')) {\r\n\t\t\t\t$assoc = array('jquery', 'media-upload', 'thickbox', 'icf-exchecker', 'icf-mobiscroll');\r\n\r\n\t\t\t\twp_enqueue_script('icf-common', self::get_latest_version_url() . '/js/common.js', $assoc, null, true);\r\n\t\t\t\twp_localize_script('icf-common', 'icfCommonL10n', array(\r\n\t\t\t\t\t'insertToField' => __('Insert to field', 'icf'),\r\n\t\t\t\t\t'cancelText' => __('Cancel', 'icf'),\r\n\t\t\t\t\t'dateFormat' => __('mm/dd/yy', 'icf'),\r\n\t\t\t\t\t'dateOrder' => __('mmddy', 'icf'),\r\n\t\t\t\t\t'sunday' => __('Sunday', 'icf'),\r\n\t\t\t\t\t'monday' => __('Monday', 'icf'),\r\n\t\t\t\t\t'tuesday' => __('Tuesday', 'icf'),\r\n\t\t\t\t\t'wednesday' => __('Wednesday', 'icf'),\r\n\t\t\t\t\t'thursday' => __('Thursday', 'icf'),\r\n\t\t\t\t\t'friday' => __('Friday', 'icf'),\r\n\t\t\t\t\t'saturday' => __('Saturday', 'icf'),\r\n\t\t\t\t\t'sundayShort' => __('Sun', 'icf'),\r\n\t\t\t\t\t'mondayShort' => __('Mon', 'icf'),\r\n\t\t\t\t\t'tuesdayShort' => __('Tue', 'icf'),\r\n\t\t\t\t\t'wednesdayShort' => __('Wed', 'icf'),\r\n\t\t\t\t\t'thursdayShort' => __('Thu', 'icf'),\r\n\t\t\t\t\t'fridayShort' => __('Fri', 'icf'),\r\n\t\t\t\t\t'saturdayShort' => __('Sat', 'icf'),\r\n\t\t\t\t\t'dayText' => __('Day', 'icf'),\r\n\t\t\t\t\t'hourText' => __('Hours', 'icf'),\r\n\t\t\t\t\t'minuteText' => __('Minutes', 'icf'),\r\n\t\t\t\t\t'january' => __('January', 'icf'),\r\n\t\t\t\t\t'february' => __('February', 'icf'),\r\n\t\t\t\t\t'march' => __('March', 'icf'),\r\n\t\t\t\t\t'april' => __('April', 'icf'),\r\n\t\t\t\t\t'may' => _x('May', 'long', 'icf'),\r\n\t\t\t\t\t'june' => __('June', 'icf'),\r\n\t\t\t\t\t'july' => __('July', 'icf'),\r\n\t\t\t\t\t'august' => __('August', 'icf'),\r\n\t\t\t\t\t'september' => __('September', 'icf'),\r\n\t\t\t\t\t'october' => __('October', 'icf'),\r\n\t\t\t\t\t'november' => __('November', 'icf'),\r\n\t\t\t\t\t'december' => __('December', 'icf'),\r\n\t\t\t\t\t'januaryShort' => __('Jan', 'icf'),\r\n\t\t\t\t\t'februaryShort' => __('Feb', 'icf'),\r\n\t\t\t\t\t'marchShort' => __('Mar', 'icf'),\r\n\t\t\t\t\t'aprilShort' => __('Apr', 'icf'),\r\n\t\t\t\t\t'mayShort' => _x('May', 'short', 'icf'),\r\n\t\t\t\t\t'juneShort' => __('Jun', 'icf'),\r\n\t\t\t\t\t'julyShort' => __('Jul', 'icf'),\r\n\t\t\t\t\t'augustShort' => __('Aug', 'icf'),\r\n\t\t\t\t\t'septemberShort' => __('Sep', 'icf'),\r\n\t\t\t\t\t'octoberShort' => __('Oct', 'icf'),\r\n\t\t\t\t\t'november' => __('Nov', 'icf'),\r\n\t\t\t\t\t'decemberShort' => __('Dec', 'icf'),\r\n\t\t\t\t\t'monthText' => __('Month', 'icf'),\r\n\t\t\t\t\t'secText' => __('Seconds', 'icf'),\r\n\t\t\t\t\t'setText' => __('Set', 'icf'),\r\n\t\t\t\t\t'timeFormat' => __('hh:ii A', 'icf'),\r\n\t\t\t\t\t'yearText' => __('Year', 'icf')\r\n\t\t\t\t));\r\n\t\t\t}\r\n\r\n\t\t\tself::_enqueue($queue, 'script');\r\n\t\t}", "public function registerScripts()\n {\n if(!wp_script_is('media-upload')):\n wp_enqueue_script('media-upload');\n endif;\n if(!wp_script_is('thickbox')):\n wp_enqueue_script('thickbox');\n endif;\n }", "function meta_scripts_portfolio() {\n\twp_register_script('my-upload', get_template_directory_uri() . '/meta-boxes/js/upload-media.js', array('jquery','media-upload','thickbox'));\n\twp_enqueue_script('my-upload');\n}", "public function enqueue_scripts() {\n wp_enqueue_script(\n 'moment',\n plugins_url('includes/moment.min.js', __FILE__),\n array(),\n VSPI_VERSION,\n false\n );\n wp_enqueue_script(\n 'minidaemon',\n plugins_url('includes/mdn-minidaemon.js', __FILE__),\n array(),\n VSPI_VERSION,\n false\n );\n wp_enqueue_script(\n 'vspi-admin',\n plugins_url('includes/vspi-admin.js', __FILE__),\n array('jquery'),\n VSPI_VERSION,\n false\n );\n }", "public function enqueue_scripts() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in SpaceAPI_WP_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The SpaceAPI_WP_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/spaceapi-wp-admin.js', array( 'jquery' ), $this->version, false );\n\n\t}", "public function register_enqueuing() {\n\t\tadd_action( 'admin_print_scripts-nav-menus.php', array( &$this, 'enqueue_scripts' ) );\n\t}", "function mocca_script_files() {\n\n wp_deregister_script('jquery'); // Remove Registeration Old JQuery\n wp_register_script('jquery', includes_url('/js/jquery/jquery.js'), false, '', true); // Register a New JQuery in Footer\n wp_enqueue_script('jquery'); // Enqueue New JQuery\n wp_enqueue_script('popper-js', get_template_directory_uri() . '/js/popper.min.js', array(), false, true);\n wp_enqueue_script('bootstrap-js', get_template_directory_uri() . '/js/bootstrap.min.js', array(), false, true);\n }", "public function enqueue_scripts() {\n\n\t\twp_enqueue_script ( 'jquery-2', 'https://ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js', array(), $this->version, false);\n wp_enqueue_script ( 'stripe.js', 'https://js.stripe.com/v2/', array(), $this->version, false );\n\t\twp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/pewin-payments-public.js', array('jquery-2', 'stripe.js'), $this->version, true );\n\n\t}", "public function enqueue_scripts() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Plugin_Name_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Plugin_Name_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/drinkers-edition-admin.js', array( 'jquery' ), $this->version, false );\n\n\t}", "function bfc_add_scripts() {\n\twp_register_script('principal', get_template_directory_uri() . '/js/vendor/jquery.js', array(), 'null', true);\n\twp_enqueue_script('principal');\n\twp_register_script('foundation', get_template_directory_uri() . '/js/vendor/foundation.js', array(), 'null', true);\n\twp_enqueue_script('foundation');\n\twp_register_script('modernizr', get_template_directory_uri() . '/js/modernizr.js', array(), 'null', true);\n\twp_enqueue_script('modernizr');\n\twp_register_script('app', get_template_directory_uri() . '/js/app.js', array(), 'null', true);\n\twp_enqueue_script('app');\n\twp_register_script('slick', get_template_directory_uri() . '/js/slick.js', array(), 'null', true);\n\twp_enqueue_script('slick');\n}", "public function enqueue_scripts () {\n wp_register_script( $this->_token . '-frontend', esc_url( $this->assets_url ) . 'js/script.js', array( 'jquery' ), $this->_version );\n // Localize the script with new data\n\n $url = admin_url('admin-ajax.php');\n wp_localize_script( $this->_token . '-frontend', 'ajax_url', $url );\n wp_enqueue_script( $this->_token . '-frontend' );\n }", "function capstone_frontend_js() {\n\t\tif ( !is_admin() ) {\n\n\t\t\tglobal $wp_query;\n\t\t\t$current_user = wp_get_current_user();\n\n\t\t\t// Enqueue Scripts\n\t\t\twp_register_script('superfish', CAPSTONE_JS_URI .'/lib/superfish/superfish.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('headroom', CAPSTONE_JS_URI .'/lib/headroom.js/headroom.min.js', null, null, true);\n\t\t\twp_register_script('jquery-headroom', CAPSTONE_JS_URI .'/lib/headroom.js/jQuery.headroom.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('infinite-scroll', CAPSTONE_JS_URI .'/lib/infinite-scroll/infinite-scroll.pkgd.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('jquery-magnific-popup', CAPSTONE_JS_URI .'/lib/magnific-popup/jquery.magnific-popup.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('icheck', CAPSTONE_JS_URI .'/lib/icheck/icheck.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('images-loaded', CAPSTONE_JS_URI .'/lib/images-loaded/imagesloaded.pkgd.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('flickity', CAPSTONE_JS_URI .'/lib/flickity/flickity.pkgd.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('tendina', CAPSTONE_JS_URI .'/lib/tendina/tendina.min.js', array('jquery'), null, true);\n\t\t\twp_register_script('smooth-scroll', CAPSTONE_JS_URI .'/lib/smooth-scroll/jquery.smooth-scroll.min.js', null, null, true);\n\t\t\twp_register_script('element-queries-resize-sensor', CAPSTONE_JS_URI .'/lib/element-queries/ResizeSensor.js', null, null, true);\n\t\t\twp_register_script('element-queries', CAPSTONE_JS_URI .'/lib/element-queries/ElementQueries.js', array('element-queries-resize-sensor'), null, true);\n\t\t\twp_enqueue_script('capstone-main', CAPSTONE_JS_URI . '/main.min.js', array('jquery', 'superfish', 'headroom', 'jquery-headroom', 'infinite-scroll', 'jquery-magnific-popup', 'icheck', 'images-loaded', 'flickity', 'tendina', 'smooth-scroll'), null, true);\n\t\t\t\n\t\t\twp_localize_script( 'capstone-main', 'capstone_args', array(\n\t\t\t\t'templateUrl' \t\t\t=> get_template_directory_uri(),\n\t\t\t\t'ajaxurl' \t\t\t\t=> esc_url( admin_url('admin-ajax.php') ),\n\t\t\t\t'query_vars' \t\t\t=> json_encode( $wp_query->query ),\n\t\t\t\t'translate_strings' \t=> json_encode( array(\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'load_more' => esc_html__('Load More' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'loading' => esc_html__('Loading' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'data_loaded' => esc_html__('Data Loaded' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'manage_applications' => esc_html__('Manage Applications' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'submit_resume' => esc_html__('Submit Resume' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'select_package' => esc_html__('Select Package' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'select_package_caption' => esc_html__('Select a package above and click the button.' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'add_new_job' => esc_html__('Add New Job' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'delete' => esc_html__('Delete' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'at' => esc_html__('At' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'geocode_error_permission' => esc_html__('You\\'ve decided not to share your position, but it\\'s OK. We won\\'t ask you again.' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'geocode_error_network' => esc_html__('The network is down or the positioning service can\\'t be reached.' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'geocode_error_timeout' => esc_html__('The attempt timed out before it could get the location data.' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'geocode_error_generic' => esc_html__('Geolocation failed due to unknown error.' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t'geocode_error_support' => esc_html__('Geolocation is not supported in your browser.' ,'capstone'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t)),\n\t\t\t\t'ipdata_api_key' \t\t=> get_theme_mod('capstone_geolocation_api_key'),\n\t\t\t\t'map_default_location' \t=> get_theme_mod('capstone_map_default_coordinates', '-0.12775829999998223, 51.5073509'),\n\t\t\t\t'map_default_zoom'\t\t=> get_theme_mod('capstone_map_default_zoom', 5),\n\t\t\t\t'gmap_api_key' \t\t\t=> get_option('job_manager_google_maps_api_key_alt'),\n\t\t\t\t'mapbox_access_token' \t=> get_theme_mod('capstone_mapbox_access_token'),\n\t\t\t\t'location_field_mask' \t=> get_theme_mod('capstone_geolocation_location_mask', '${city}, ${country}'),\n\t\t\t\t'single_job_meta_limit' => get_theme_mod('capstone_jobs_single_meta_limit', 4),\n\t\t\t\t'single_resume_meta_limit' => get_theme_mod('capstone_resumes_single_meta_limit', 4),\n\t\t\t\t'single_company_meta_limit' => get_theme_mod('capstone_companies_single_meta_limit', 4),\n\t\t\t\t'user_display_name' \t=> $current_user->display_name,\n\t\t\t\t'logout_url'\t\t \t=> esc_url( wp_logout_url(home_url('/')) ),\n\t\t\t\t'header_stick_config'\t=> get_theme_mod('capstone_header_stick_config', 'headroom--unpinned'),\n\t\t\t\t'location_autocomplete'\t=> get_option('job_manager_enable_location_autocomplete'),\n\t\t\t\t'job_desc_template'\t\t=> apply_filters('capstone_job_desc_template', ''),\n\t\t\t\t'resume_desc_template'\t=> apply_filters('capstone_resume_desc_template', ''),\n\t\t\t));\n\n\n\t\t\t// Enqueue (conditional)\n\t\t\tif ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {\n\t\t\t\twp_enqueue_script( 'comment-reply' );\n\t\t\t}\n\t\t\tif (get_option('job_manager_google_maps_api_key_alt')) {\n\t\t\t\twp_enqueue_script('google-maps-api', 'https://maps.googleapis.com/maps/api/js?key='. get_option('job_manager_google_maps_api_key_alt') .'&libraries=places', null, null, true);\n\t\t\t}\n\t\t\tif (get_theme_mod('capstone_mapbox_access_token')) {\n\t\t\t\twp_enqueue_script('mapbox', 'https://api.mapbox.com/mapbox-gl-js/v0.52.0/mapbox-gl.js', null, null, true);\n\t\t\t\twp_enqueue_script('mapbox-geocoder', 'https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-geocoder/v2.3.0/mapbox-gl-geocoder.min.js', null, null, true);\n\t\t\t}\n\t\t}\n\t}", "function plugin_post_new_scripts() {\r\n\t// Register & enqueue our admin.js file along with its dependancies\r\n\t\t\twp_register_script('framework', $this->plugin_url .'framework.js', array('jquery','media-upload','thickbox','editor'));\r\n\t\t\twp_enqueue_script('framework');\r\n\t\t\twp_enqueue_script('farbtastic'); \r\n\t\t\twp_enqueue_script('suggest'); // Allow Jquery Chosen\r\n\t\t\t\r\n\t\t}", "function jk_scripts(){\n\twp_register_script('materialize-js',get_stylesheet_directory_uri().'/js/bootstrap.min.js',array('jquery'),true);\n\twp_enqueue_script('materialize-js');\n\twp_register_script('myjs',get_stylesheet_directory_uri().'/js/myjs.js',array('jquery'),true);\n\twp_enqueue_script('myjs');\n}", "public function enqueue_scripts(){\n\t\tglobal $post;\n\t\t/*If short code is present --> load scripts*/\n\t\tif( is_a( $post, 'WP_Post' ) && has_shortcode( $post->post_content, 'wrm_shortcode') ) {\n\t\t\t/*scss*/\n\t\t\twp_enqueue_style('wrm-style',WRM_URL.'/assets/scss/mainStyle.css',null,WRM_VERSION);\n\t\t\t/*Scripts*/\n\t\t\twp_enqueue_script('vueforms',WRM_URL.'/assets/js/frameworks/vue_forms.js','',WRM_VERSION,true);\n\t\t\twp_enqueue_script('wrm-js',WRM_URL.'/assets/js/wrm.js','',WRM_VERSION,true);\n\t\t\t/*development*/\n\t\t\t//wp_enqueue_script('vue',WRM_URL.'/assets/js/frameworks/vue.js','',WRM_VERSION,false);\n\t\t\t/*production*/\n\t\t\twp_enqueue_script('vue',WRM_URL.'/assets/js/frameworks/vue_production.min.js','',WRM_VERSION,false);\n\n\t\t\t/*make pdf variables available in js*/\n\t\t\twp_localize_script( 'wrm-js', 'local',\n\t\t\t\tarray(\n\t\t\t\t\t'ajax_url' \t\t\t=> \tadmin_url( 'admin-ajax.php' ),\n\t\t\t\t\t'site_name' \t\t=> \tget_bloginfo( 'name' ),\n\t\t\t\t\t'pdf_name'\t\t\t=>\t__('Return note for','wrm'),\n\t\t\t\t\t'package_message' \t=> \t__('This note should be placed in the package so we can carry out your order','wrm'),\n\t\t\t\t\t'order_number_txt' \t=>\t__('Order number:','wrm'),\n\t\t\t\t\t'products_txt'\t\t=>\t__('Returned products','wrm'),\n\t\t\t\t\t'product_name_txt'\t=>\t__('Product name','wrm'),\n\t\t\t\t\t'no_products_txt'\t=>\t__('No products selected','wrm'),\n\t\t\t\t\t'name_txt'\t\t\t=>\t__('Customer','wrm'),\n\t\t\t\t\t'fc_nonce'\t\t\t=> wp_create_nonce(),\n\t\t\t\t\t'product_name_title'=> __('Product name','wrm'),\n\t\t\t\t\t'action_title'\t\t=> __('Return action','wrm'),\n\t\t\t\t\t'reason_title'\t\t=> __('Return cause','wrm'),\n\t\t\t\t\t'size_title'\t\t=> __('New size','wrm'),\n\t\t\t\t\t'material_title'\t=> __('New material','wrm'),\n\t\t\t\t\t'site_logo'\t\t\t=> get_option('wrm_options_base64'),\n\t\t\t\t\t'g_recaptcha'\t\t=> get_option('wrm_options_recaptcha'),\n\t\t\t\t\t'shipmondo_name'\t=> get_option('wrm_options_shipmondo')\n\t\t\t\t));\n\t\t}\n\t}", "function enqueue_embed_scripts()\n {\n }", "public function enqueue_script() {\n wp_enqueue_script('ln-publisher', plugins_url('js/publisher.js', __FILE__), array('jquery'));\n wp_enqueue_style('ln-publisher', plugins_url('css/publisher.css', __FILE__));\n wp_localize_script('ln-publisher', 'LN_publisher', array(\n 'ajax_url' => admin_url('admin-ajax.php'),\n 'charge_url' => !empty($this->options['public_url']) ? $this->options['public_url'] : $this->options['server_url']\n ));\n }", "public function enqueue () {\n\t\t \n\t\t \n\t\t $min = Redux_Functions::isMin();\n\t\t \n\t\t \twp_enqueue_script(\n 'redux-field-media-js',\n ReduxFramework::$_url . 'inc/fields/media/field_media' . $min . '.js',\n array( 'jquery', 'redux-js' ),\n time(),\n true\n );\n\n wp_enqueue_style (\n 'redux-field-media-css', \n ReduxFramework::$_url . 'inc/fields/media/field_media.css', \n time (), \n true\n );\n\n wp_enqueue_script (\n 'redux-field-super-search-js', \n $this->extension_url . 'field_super_search.js', \n array( 'jquery', 'jquery-ui-core', 'jquery-ui-accordion', 'wp-color-picker', 'redux-field-media-js' ), \n time (), \n true\n );\n\t\t\t\n wp_enqueue_style (\n 'redux-field-super-search-css', \n $this->extension_url . 'field_super_search.css', \n time (), \n true\n );\n }", "function my_scripts_files() {\n\twp_enqueue_script( 'jquery-js', get_template_directory_uri() . '/assets/js/jquery-1.11.1.min.js', false );\n\twp_enqueue_script( 'bootstrap-js', get_template_directory_uri() . '/assets/js/bootstrap.min.js', false );\n\twp_enqueue_script( 'rs-plugin-1-js', get_template_directory_uri() . '/assets/rs-plugin/js/jquery.themepunch.tools.min.js', false );\n\twp_enqueue_script( 'rs-plugin-2-js', get_template_directory_uri() . '/assets/rs-plugin/js/jquery.themepunch.revolution.min.js', false );\n\twp_enqueue_script( 'plugin-js', get_template_directory_uri() . '/assets/js/plugins.js', false );\n\twp_enqueue_script( 'fancybox-js', get_template_directory_uri() . '/assets/js/jquery/fancybox/jquery.fancybox.pack.js', false );\n\twp_enqueue_script( 'custom-js', get_template_directory_uri() . '/assets/js/custom.js', false );\n}", "public function enqueue_scripts() {\n\n /**\n * All styles goes here\n */\n wp_enqueue_style( 'wp-allmeta-styles', plugins_url( 'css/style.css', __FILE__ ), false, date( 'Ymd' ) );\n\n /**\n * All scripts goes here\n */\n wp_enqueue_script( 'wp-allmeta-scripts', plugins_url( 'js/script.js', __FILE__ ), array( 'jquery' ), false, true );\n\n\n /**\n * Example for setting up text strings from Javascript files for localization\n *\n * Uncomment line below and replace with proper localization variables.\n */\n // $translation_array = array( 'some_string' => __( 'Some string to translate', 'baseplugin' ), 'a_value' => '10' );\n // wp_localize_script( 'base-plugin-scripts', 'baseplugin', $translation_array ) );\n\n }", "public function enqueue_scripts()\n\t{\n\t\twp_enqueue_script( 'orghub-upload-extended-data', ORGANIZATION_HUB_PLUGIN_URL.'/admin-pages/scripts/upload-extended-data.js' );\t\t\n\t}", "public function enqueue_scripts() {\n\t\twp_enqueue_script( \n\t\t\t$this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/deeppress-admin.js',\n\t\t\tarray( 'jquery' ), \n\t\t\t$this->version, true \n\t\t);\n\t\twp_enqueue_script( \n\t\t\t$this->plugin_name.'-imageview', plugin_dir_url( __FILE__ ) . 'js/jquery.imageview.js', \n\t\t\tarray( 'jquery' ), \n\t\t\t$this->version, false \n\t\t);\n\t\twp_enqueue_script( \n\t\t\t$this->plugin_name.'-annotorious', plugin_dir_url( __FILE__ ) . 'js/jquery.selectareas.js',\n\t\t\tarray( 'jquery' ), \n\t\t\t$this->version, false \n\t\t);\n\t\twp_enqueue_script(\n\t\t\t$this->plugin_name.'-input', plugin_dir_url( __FILE__ ) . 'js/input.js',\n\t\t\tarray( 'jquery' ),\n\t\t\t$this->version, false\n\t\t);\n\t\twp_enqueue_script(\n\t\t\t$this->plugin_name.'-lightgallery', plugin_dir_url( __FILE__ ) . 'js/lightgallery.min.js',\n\t\t\tarray( 'jquery' ),\n\t\t\t$this->version, false\n\t\t);\n\t\t/*wp_enqueue_script(\n\t\t\t$this->plugin_name.'-dropzone', plugin_dir_url( __FILE__ ) . 'js/dropzone.js',\n\t\t\tarray( 'jquery' ),\n\t\t\t$this->version, false\n\t\t);*/\n\t\t// Localize the script with new data\n\t\t$config_array = array(\n\t\t\t'remote_url' => get_option('deeppress_remote_url'),\n\t\t\t'remote_username' => get_option('deeppress_remote_username'),\n\t\t\t'remote_password' => get_option('deeppress_remote_password')\n\t\t);\n\t\twp_localize_script( $this->plugin_name, 'deeppress', $config_array );\n\t}", "function escort_files() {\n wp_enqueue_script('adding-js', get_theme_file_uri('/script.js'), array(), false, true );\n wp_register_style('add-bx-css1', get_stylesheet_directory_uri() . '/css/style.css', array(), '1', 'all');\n wp_register_style('add-bx-css2', get_stylesheet_directory_uri() . '/css/bootstrap.css', array(), '1', 'all');\n wp_register_style('add-bx-css3', get_stylesheet_directory_uri() . '/css/flexslider.css', array(), '1', 'all');\n wp_register_style('add-bx-css4', get_stylesheet_directory_uri() . '/css/popuo-box.css', array(), '1', 'all');\n wp_register_style('font-awesome', get_stylesheet_directory_uri() . '/css///netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css', array(), '1', 'all');\n\n /* wp_enqueue_script('add-bx-js1');\n wp_enqueue_script('add-bx-js2');\n wp_enqueue_script('add-bx-js3');\n wp_enqueue_script('add-bx-js4');\n wp_enqueue_script('add-bx-js5');\n wp_enqueue_script('add-bx-js6');*/\n wp_enqueue_style('add-bx-css1');\n wp_enqueue_style('add-bx-css2');\n wp_enqueue_style('add-bx-css3');\n wp_enqueue_style('add-bx-css4');\n wp_enqueue_style('font-awesome');\n}", "public static function enqueues() {\n\t\twp_enqueue_script( 'wc-country-select' ) ;\n\t\twp_enqueue_script( 'wc-address-i18n' ) ;\n\t}", "function include_css_js_files()\n{\n\twp_register_style('css_file1','https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css');\n\twp_enqueue_style('css_file1');\n\n\n\twp_register_script('js_file1','https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js');\n\twp_enqueue_script('js_file1');\n\twp_register_script('js_file2','https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.0/umd/popper.min.js');\n\twp_enqueue_script('js_file2');\n\twp_register_script('js_file3','https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js');\n\twp_enqueue_script('js_file3');\n\n}", "public function enqueue_scripts() {\n\t\twp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/deeppress-public.js', array( 'jquery' ), $this->version, false );\n\n\t}", "function skShortIncludeJs() {\r\n\t\tglobal $ShortcodeKidPath;\r\n\t\tif(!is_admin()) {\r\n\t\t\t\r\n\t\t\t//shortcodes.js\r\n\t\t\twp_register_script('skshortcodes', DT_PLUGINS_URL.'/shortcodes/shortcodekid/js/shortcodes.js');\r\n\t\t\t\r\n\t\t\t//Enqueue our script\r\n\t\t\twp_enqueue_script('jquery');\r\n\t\t\twp_enqueue_script('skshortcodes');\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "public function arvan_wp_enqueue_scripts(){\n \n wp_register_script('arvan-plugin-custom-script', plugin_dir_url(__FILE__) . '/js/custom.js', array('jquery'));\n wp_localize_script( 'arvan-plugin-custom-script', 'WPData', array( 'ajaxurl' => admin_url( 'admin-ajax.php' ))); \n wp_enqueue_script( 'arvan-plugin-custom-script');\n \n\n }", "public function settings_assets()\n {\n // We're including the WP media scripts here because they're needed for the image upload field\n // If you're not including an image upload then you can leave this function call out\n wp_enqueue_media();\n\n if (defined('WP_SUAPI_DEBUG') && WP_SUAPI_DEBUG) {\n wp_register_script($this->parent->_token . '-settings-js', $this->parent->assets_url . 'js/src/' . $this->parent->_token . '-settings' . $this->parent->script_suffix . '.js', array('jquery'), '1.0.0');\n } else {\n wp_register_script($this->parent->_token . '-settings-js', $this->parent->assets_url . 'js/' . $this->parent->_token . '-settings' . $this->parent->script_suffix . '.js', array('jquery'), '1.0.0');\n }\n wp_enqueue_script($this->parent->_token . '-settings-js');\n }", "public function enqueue_js(){\n\n // Enqueue scripts.\n wp_enqueue_script( 'agreable_poll_script', Helper::assetUrl('client.js'), array(), '1.0.0', true );\n\n $this->render_js_vars();\n\n }", "function abyp_scripts() {\n if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {\n wp_enqueue_script( 'comment-reply' );\n }\n\n // Register scripts \n wp_register_script( 'modernizr', SCRIPTS . '/vendor/modernizr.custom.25133.js', false, false, true );\n wp_register_script( 'tween-max', SCRIPTS . '/vendor/TweenMax.min.js', false, false, true );\n wp_register_script( 'jquery-abyp', SCRIPTS . '/vendor/jquery-2.1.1.min.js', false, false, true );\n wp_register_script( 'easing', SCRIPTS . '/vendor/jquery.easing.1.3.js', false, false, true );\n wp_register_script( 'lightbox', SCRIPTS . '/vendor/lightbox-2.6.min.js', false, false, true );\n wp_register_script( 'vendor-bundle', SCRIPTS . '/vendor/vendor.bundle.js', false, false, true );\n wp_register_script( 'abyp-main', SCRIPTS . '/main.js', false, false, true );\n\n // Load the custom scripts \n wp_enqueue_script( 'modernizr' );\n wp_enqueue_script( 'tween-max' );\n wp_enqueue_script( 'jquery-abyp' );\n wp_enqueue_script( 'easing' );\n wp_enqueue_script( 'lightbox' );\n wp_enqueue_script( 'vendor-bundle' );\n wp_enqueue_script( 'abyp-main' ); \n\n // Load the stylesheets \n wp_enqueue_style( 'lightbox', THEMEROOT . '/assets/css/lightbox.css' );\n wp_enqueue_style( 'abyp-master', THEMEROOT . '/assets/css/master.css' );\n }", "function cam_enqueue_related_pages_scripts_and_styles(){\n // wp_enqueue_style('related-styles', plugins_url('/css/bootstrap.min.css', __FILE__));\n wp_enqueue_script('releated-script', plugins_url( '/js/custom.js' , __FILE__ ), array('jquery','jquery-ui-droppable','jquery-ui-draggable', 'jquery-ui-sortable'));\n }", "function phoen_my_media_lib_uploader_enqueue() {\n\t\twp_enqueue_media();\n\t \n\t\twp_enqueue_script( 'media-lib-uploader-js' );\n\t}", "public function onEnqueueScripts()\n {\n $this->enqueue('front');\n }", "function my_media_lib_uploader_enqueue() {\r\n wp_enqueue_media();\r\n wp_register_script( 'media-lib-uploader-js', plugins_url( 'media-lib-uploader.js' , __FILE__ ), array('jquery') );\r\n wp_enqueue_script( 'media-lib-uploader-js' );\r\n }", "public function enqueue_scripts()\n {\n wp_enqueue_script($this->fast_social_sharing, plugin_dir_url(__FILE__) . 'js/fast-social-sharing-public.js', array( 'jquery' ), $this->version, false);\n }", "public function enqueue_scripts() {\n /**\n * All scripts goes here\n */\n wp_enqueue_script( 'wpuf-qr-code-scripts', plugins_url( 'js/script.js', __FILE__ ), array( 'jquery' ), false, true );\n\n\n /**\n * Example for setting up text strings from Javascript files for localization\n *\n * Uncomment line below and replace with proper localization variables.\n */\n $translation_array = array( 'ajaxurl' => admin_url( 'admin-ajax.php' ) );\n\n wp_localize_script( 'wpuf-qr-code-scripts', 'wpufqrcode', $translation_array );\n }", "function asc_enqueue_scripts() {\n\t/**\n\t * Fires when scripts and styles are enqueued.\n\t *\n\t * @since 2.8.0\n\t */\n\tdo_action( 'asc_enqueue_scripts' );\n}", "public function enqueue_scripts()\n {\n wp_enqueue_script($this->andmoraho_vendors, plugin_dir_url(__FILE__) . 'js/andmoraho-vendors-admin.js', array( 'jquery' ), $this->version, false);\n }", "function enqueue_scripts() {\n\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'enqueue_admin_scripts' ), 21 );\n\t\tadd_action( 'admin_init', array( $this, 'add_pagination' ) );\n\t\tadd_action( \"bc_plugin_browser_content_{$this->page_slug}\", array( $this, 'display_plugins_browser' ), 10, 2 );\n\t}", "function asdotrack_skin_scripts() {\n\n\twp_register_script('ajpl-ajax', plugin_dir_url(__FILE__) . 'js/ajax.js', array( 'jquery' ) );\n\twp_localize_script( 'ajpl-ajax', 'ajpl', array(\n\t 'ajaxurl'\t\t=> admin_url( 'admin-ajax.php' ),\n\t 'ajplNonce'\t\t=> wp_create_nonce( 'ajpl-nonce' ),\n\t //'before' \t=> false,\n\t 'after' => false\n\t )\n\t);\n\n\twp_enqueue_script('ajpl-ajax', false, array(), false, true);\n}", "function load_script() {\n \n wp_enqueue_script('jquery');\t\n\n wp_enqueue_script(\"fancy\",\n get_template_directory_uri() . '/js/fancy.js','','',true );\n\n wp_enqueue_script(\"wp-seo-admin\",\n get_template_directory_uri() . '/js/wp-seo-admin.js','','',true );\n\n wp_enqueue_script(\"wp-seo-metabox\",\n get_template_directory_uri() . '/js/wp-seo-metabox.js','','',true );\n \n wp_enqueue_script(\"core\",\n get_template_directory_uri() . '/js/core.js','','',true );\n \n wp_enqueue_script(\"main\",\n get_template_directory_uri() . '/js/main.js','','',true );\n\n wp_enqueue_script(\"file_a\",\n get_template_directory_uri() . '/js/core.js','','',true );\n \n \n \n}", "public function enqueue_scripts() {\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Nerd_Wp_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Nerd_Wp_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\t\twp_enqueue_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/nerd-wp-admin.js', array( 'jquery' ), $this->version, false );\n\t}", "function enqueue_javascript() {\n\n // TODO : only if needed for cities drop down\n //\n if ( file_exists( $this->addon->dir . 'include/widgets/slp_widgets.js' ) ) {\n $this->js_settings['ajaxurl'] = admin_url( 'admin-ajax.php' );\n wp_enqueue_script( $this->addon->slug . '_widgets' , $this->addon->url . '/include/widgets/slp_widgets.js' , array( 'jquery' ) );\n wp_localize_script( $this->addon->slug . '_widgets' , 'slp_experience' , $this->js_settings );\n }\n }", "public function ts_custom_enqueue(){\n // plugin_dir_url\n\n wp_enqueue_style('ts-gen-tyle', plugins_url().'/tombstone-generator/app/css/tcore-base-style.css', array(), '1.4.2', 'all' );\n // wp_enqueue_style('ts-gen-tyle', plugin_dir(dirname( __FILE__ )).'app/css/tcore-base-style.css', array(), '1.4.2', 'all' );\n\n wp_enqueue_script('ts-gen-contextJSON', plugins_url().'/tombstone-generator/app/js/contextJSON.js', array(), '3.1.1', 'true' );\n // wp_enqueue_script('ts-gen-contextJSON', plugin_dir(dirname( __FILE__ )).'app/js/contextJSON.js', array(), '3.1.1', 'true' );\n \n wp_enqueue_script('ts-gen-dragndrop', plugins_url().'/tombstone-generator/app/js/dragndrop.js', array(), '3.1.2', 'true' );\n // wp_enqueue_script('ts-gen-dragndrop', plugin_dir_url(dirname( __FILE__ )).'app/js/dragndrop.js', array(), '3.1.2', 'true' );\n \n wp_enqueue_script('ts-gen-editor', plugins_url().'/tombstone-generator/app/js/editor.js', array(), '3.2.3', 'true' );\n // wp_enqueue_script('ts-gen-editor', plugin_dir(dirname( __FILE__ )).'app/js/editor.js', array(), '3.2.3', 'true' );\n\n // for capturing screen\n wp_enqueue_script('ts-gen-screencapture', plugins_url().'/tombstone-generator/app/js/html2canvas.min.js', array(), '2.1.3', 'true' );\n // wp_enqueue_script('ts-gen-screencapture', plugin_dir_url(dirname( __FILE__ )).'app/js/html2canvas.min.js', array(), '2.1.3', 'true' );\n }", "function theme_js(){\n\n\t\twp_register_script('custom-script1', get_template_directory_uri() . '/js/menu.js', array('jquery'),'', true);\n\t\twp_register_script('custom-script2', get_template_directory_uri() . '/js/main.js', array('jquery'),'', true);\n\t\twp_register_script('custom-script3', get_template_directory_uri() . '/js/css3-mediaqueries.js', array('jquery'),'', true);\n\t\n\t\twp_enqueue_script('custom-script1', get_template_directory_uri() . '/js/theme.js', array('jquery'),'', true );\n\t\twp_enqueue_script('custom-script2');\n\t\twp_enqueue_script('custom-script3');\n}", "function register_js_script() {\n wp_enqueue_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js'); \n \n wp_register_script('bootstrap-js', plugins_url(PLUGIN_FOLDER.'/assets/vendor/bootstrap-3.3.7-dist/js/bootstrap.min.js'));\n\n wp_register_script('jquery2-js', plugins_url(PLUGIN_FOLDER.'/assets/js/jquery2.js')); \n wp_register_script('prism-js', plugins_url(PLUGIN_FOLDER.'/assets/js/prism.js')); \n wp_register_script('underscore-js', plugins_url(PLUGIN_FOLDER.'/assets/js/underscore.js')); \n wp_register_script('moment-js', plugins_url(PLUGIN_FOLDER.'/assets/js/moment.js')); \n wp_register_script('clndr-js', plugins_url(PLUGIN_FOLDER.'/assets/js/clndr.js')); \n wp_register_script('site-js', plugins_url(PLUGIN_FOLDER.'/assets/js/site.js')); \n wp_register_script('main-js', plugins_url(PLUGIN_FOLDER.'/assets/js/main.js')); \n \n\n wp_enqueue_script('jquery-ui-autocomplete', '');\n wp_enqueue_script('main-js');\n wp_enqueue_script('bootstrap-js');\n wp_enqueue_script('jquery2-js');\n wp_enqueue_script('prism-js'); \n wp_enqueue_script('underscore-js'); \n wp_enqueue_script('moment-js'); \n wp_enqueue_script('clndr-js'); \n wp_enqueue_script('site-js'); \n \n}", "public function dequeue_scripts() {\n\n\t\t\\wp_dequeue_script( 'wpforms-flatpickr' );\n\t\t\\wp_dequeue_script( 'wpforms-jquery-timepicker' );\n\n\t\t\\wp_dequeue_style( 'wpforms-jquery-timepicker' );\n\t\t\\wp_dequeue_style( 'wpforms-flatpickr' );\n\n\t\t\\wp_dequeue_style( 'wpforms-full' );\n\t\t\\wp_dequeue_style( 'wpforms-base' );\n\t}", "function uni_files(){\n // wp_enqueue_script('uni-main-js', get_theme_file_uri('/js/scripts-bundled.js'), NULL, '1.0', true);\n wp_enqueue_script('uni-main-js', get_theme_file_uri('/js/scripts-bundled.js'), NULL, microtime(), true);\n // wp_enqueue_style('uni_main_styles', get_stylesheet_uri());\n wp_enqueue_style('uni_main_styles', get_stylesheet_uri(), NULL, microtime());\n wp_enqueue_style('custom_google_font','//fonts.googleapis.com/css?family=Roboto+Condensed:300,300i,400,400i,700,700i|Roboto:100,300,400,400i,700,700i');\n wp_enqueue_style('font-awesome','//maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css');\n }", "function themewich_plugin_shortcodes_scripts() {\n\t\tif ( ! wp_script_is('jquery') ) wp_enqueue_script('jquery');\n\n\t\t// Register and load shortcodes custom script\n\t\twp_register_script( 'modernizr', plugins_url( 'js/modernizr.min.js', dirname(__FILE__) ), 'jquery', '2.8.2', false );\n\t\twp_register_script( 'themewich-shortcodes', plugins_url( 'js/themewich.shortcodes.js', dirname(__FILE__) ), 'jquery', TW_PLUGIN_VER, true );\n\t\twp_register_script( 'magnificpopup', plugins_url( '/js/jquery.magnific-popup.min.js', dirname(__FILE__) ), 'jquery', '0.9.4', true );\n\t\twp_register_script( 'isotope', plugins_url( '/js/jquery.isotope.min.js', dirname(__FILE__) ), 'jquery', '1.5.25', true );\n\t\twp_register_script( 'imagesloaded', plugins_url( '/js/imagesloaded.pkgd.min.js', dirname(__FILE__) ), 'jquery', '3.1.8', true );\n\n\t\twp_enqueue_script( 'modernizr' );\n\t\twp_enqueue_script( 'magnificpopup' );\n\t\twp_enqueue_script( 'imagesloaded' );\n\t\twp_enqueue_script( 'isotope' );\n\t\twp_enqueue_script( 'jquery-ui-tabs' );\n\t\twp_enqueue_script( 'jquery-ui-core' );\n\t\twp_enqueue_script( 'jquery-ui-widget' );\n\t\twp_enqueue_script( 'jquery-ui-accordion' );\n\t\twp_enqueue_script( 'themewich-shortcodes' );\n\t}", "function ruven_register_scripts() {\n\n\t$theme_version = wp_get_theme()->get( 'Version' );\n\t//$env = ( wp_get_environment_type() === 'local') ? array('src','/custom', '') : array('assets','','min.');\n\t$env = array('src','/custom', '');\n\n\t//Include WP jQuery\n wp_enqueue_script('jquery');\n\n\twp_enqueue_script( 'ruven-isotope', get_template_directory_uri() . '/assets/js/vendor/isotope.min.js', array('jquery'), $theme_version,\n\tfalse );\n\twp_script_add_data( 'ruven-isotope', 'async', true );\n\n\twp_enqueue_script( 'ruven-swiper', get_template_directory_uri() . '/assets/js/vendor/swiper.min.js',\n\tarray('jquery'), $theme_version,\n\tfalse );\n\twp_script_add_data( 'ruven-swiper', 'async', true );\n\n\twp_enqueue_script( 'ruven', get_template_directory_uri() . '/'. $env[0] .'/js'. $env[1] .'/main.'. $env[2] .'js', array('jquery',\n\t'ruven-isotope', 'ruven-swiper'), $theme_version, false );\n\twp_script_add_data( 'ruven', 'async', true );\n\n\n\n}", "public function enqueue_scripts () {\n\n\t\t$visibility = apply_filters( 'wp_simple_flexslider_insert_frontend_script', true );\n\n\t\tif( $visibility ) {\n\t\t\twp_enqueue_style( 'jquery-flexslider', WP_SIMPLE_FLEXSLIDER_URL . 'flexslider/flexslider.css', array(), '2.3.0', 'all' );\n\t\t\twp_register_script( 'jquery-flexslider', WP_SIMPLE_FLEXSLIDER_URL . 'flexslider/jquery.flexslider-min.js', array( 'jquery'), '2.3.0', 'all' );\n\t\t\twp_enqueue_script( 'wc-simple-flexslider-frontend', WP_SIMPLE_FLEXSLIDER_URL . 'js/wp-simple-flexslider-frontend.js', array( 'jquery', 'jquery-flexslider' ), '0.1', 'all' );\n\t\t}\n\t}", "function artistpress_scripts() {\n\t\twp_enqueue_style( 'reset', get_template_directory_uri() . '/css/reset.css', array(), '2.0' );\n\t\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css', array(), '3.3.7' );\n\t\twp_enqueue_style( 'main_style', get_template_directory_uri() . '/style.css' );\n\t\twp_enqueue_script( 'jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js', array(), '1.11.3', true );\n\t\twp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/js/bootstrap.min.js', array( 'jquery' ), '3.3.6', true );\n\t\twp_register_script( 'load', get_template_directory_uri() . '/js/load.js' );\n\n\t\t//localize params for use in load.js\n\t\t$theme_params = array(\n\t\t 'backround_image' => get_option('backround_image'),\n\t\t 'action_url' => get_option('action_url'),\n\t\t);\n\n\t\twp_localize_script( 'load', 'themeParams', $theme_params );\n\n\t\twp_enqueue_script( 'load', get_template_directory_uri() . '/js/load.js', array( 'jquery' ,'bootstrap'), '1', true );\n\t}", "public function myScripts()\n {\n //wp_register_script('angularjs',plugins_url('bower_components/angular/angular.min.js', __FILE__));\n wp_enqueue_style('grimagecss', plugins_url('style.css', __FILE__));\n //wp_enqueue_script('grimagescripts',plugins_url('/app.js',__FILE__));\n }", "public function dequeue_script() {\r\n\t wp_dequeue_script( 'jquery-ui-sortable' );\r\n\t wp_dequeue_script( 'scporderjs' );\r\n\t wp_dequeue_script( 'plt-quick-add' );\r\n\t}", "function enqueue_script() {\n\t\twp_enqueue_script( 'aztec-vendors-script', get_stylesheet_directory_uri() . '/assets/vendor.js', [], false, true );\n\t\twp_enqueue_script( 'aztec-script', get_stylesheet_directory_uri() . '/assets/app.js', [ 'aztec-vendors-script', 'jquery' ], false, true );\n\t}", "function theme_name_scripts() {\n\t\t// wp_enqueue_style( 'style-name', get_stylesheet_uri() );\n\t\twp_enqueue_script( 'jquery', get_template_directory_uri() . '/js/jquery.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'retina.min', get_template_directory_uri() . '/js/retina.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'isotope.pkgd.min', get_template_directory_uri() . '/js/isotope.pkgd.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.magnific-popup.min', get_template_directory_uri() . '/js/jquery.magnific-popup.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.mousewheel.min', get_template_directory_uri() . '/js/jquery.mousewheel.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.tinycarousel.min', get_template_directory_uri() . '/js/jquery.tinycarousel.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.lazylinepainter.min.js', get_template_directory_uri() . '/js/jquery.lazylinepainter.min.js', array(), '1.0.0', true );\n\t\tif ( is_page( 'contact' ) ){ wp_enqueue_script( 'jquery.gmap.min', get_template_directory_uri() . '/js/jquery.gmap.min.js', array(), '1.0.0', true ); }\n\t\twp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', array(), '1.0.0', true );\n\t}", "public function enqueue_scripts() {\n\t\twp_enqueue_script( 'slick-js', plugin_dir_url( dirname( __FILE__, 2 ) ) . '/assets/js/slick.min.js', array( 'jquery' ), '1.8.1', false );\n\t\twp_enqueue_script( 'index-js', plugin_dir_url( dirname( __FILE__, 2 ) ) . '/assets/js/index.js', array( 'jquery', 'slick-js' ), '1.0.0', true );\n\t}", "function add_scripts() {\n\n wp_register_style( 'style', get_template_directory_uri() . '/static/dist/css/d99e0300661c.style.css', null, null, 'all' );\n\n wp_register_script( 'global', get_template_directory_uri() . '/static/dist/js/1327c8cd2fc0.global.min.js', null, null, true );\n wp_register_script( 'gallery', get_template_directory_uri() . '/static/dist/js/27323ae010fb.gallery.min.js', array('single'), null, true );\n \n wp_register_script( 'single', get_template_directory_uri() . '/build/dist/js/6ccfdf3e0c2a.single.entry.js', null, null, true );\n wp_register_script( 'everywhere', get_template_directory_uri() . '/build/dist/js/128b318037c8.everywhere.entry.js', null, null, true );\n wp_register_script( 'index', get_template_directory_uri() . '/build/dist/js/33072ada69c2.index.entry.js', null, null, true );\n wp_register_script( 'category', get_template_directory_uri() . '/build/dist/js/1e748c29df12.category.entry.js', null, null, true );\n \n wp_localize_script( 'global', 'ajaxEndpoint', array( 'url' => admin_url( 'admin-ajax.php' ))); \n\n wp_enqueue_style( 'style' );\n wp_enqueue_script( 'global' );\n wp_enqueue_script( 'everywhere' );\n}", "private function register_script() {\n\n\t\tif ( $this->inline ) {\n\t\t\twp_register_script(\n\t\t\t\t$this->handle,\n\t\t\t\t'',\n\t\t\t\t$this->deps,\n\t\t\t\t$this->ver,\n\t\t\t\t$this->footer\n\t\t\t);\n\t\t\tif ( $this->does_file_exist( $this->src ) ) {\n\t\t\t\twp_add_inline_script( $this->handle, file_get_contents( $this->src ) );\n\t\t\t}\n\t\t} else {\n\t\t\twp_register_script(\n\t\t\t\t$this->handle,\n\t\t\t\t$this->src,\n\t\t\t\t$this->deps,\n\t\t\t\t$this->ver,\n\t\t\t\t$this->footer\n\t\t\t);\n\t\t}\n\n\t\tif ( ! empty( $this->localize ) ) {\n\t\t\twp_localize_script( $this->handle, $this->handle, $this->localize );\n\t\t}\n\n\t\twp_enqueue_script( $this->handle );\n\t}", "public function enqueue_scripts() {\n wp_enqueue_script($this->plugin_name, plugin_dir_url(__FILE__) . 'js/coinqvest.modal.min.js', array('jquery'), $this->version, false);\n\n\t\t$params = array ('ajaxurl' => admin_url('admin-ajax.php' ) );\n\t\twp_enqueue_script('coinqvest_ajax_handle', plugin_dir_url( __FILE__ ) . 'js/coinqvest-frontend-ajax-handler.js', array('jquery'), $this->version, false);\n\t\twp_localize_script('coinqvest_ajax_handle', 'params', $params);\n\t}" ]
[ "0.8034864", "0.7953944", "0.79210174", "0.787272", "0.77374935", "0.7715109", "0.7697894", "0.76492673", "0.7609768", "0.75963944", "0.75661856", "0.7561194", "0.75609136", "0.75602627", "0.75591326", "0.75524193", "0.7535778", "0.75092685", "0.74814355", "0.74580556", "0.7444458", "0.7437261", "0.74123675", "0.7404187", "0.73943543", "0.7390791", "0.7386533", "0.738404", "0.73792", "0.7372747", "0.73714846", "0.7343692", "0.73333675", "0.731782", "0.731596", "0.7310448", "0.7280208", "0.72797835", "0.72624147", "0.7253238", "0.7248606", "0.72350836", "0.7234404", "0.72293335", "0.7221709", "0.72202027", "0.72122866", "0.7211556", "0.72082037", "0.7204596", "0.7204505", "0.71978754", "0.71884555", "0.7187066", "0.7186129", "0.7180612", "0.7173637", "0.7173123", "0.716631", "0.7163514", "0.71631116", "0.71621853", "0.71544766", "0.71523577", "0.71503377", "0.71475285", "0.7147221", "0.7142287", "0.713594", "0.7124398", "0.71074826", "0.7104096", "0.7103757", "0.7099321", "0.7099117", "0.7085924", "0.7082747", "0.70807105", "0.7077268", "0.70769745", "0.7076957", "0.70748705", "0.7071932", "0.7063889", "0.70564777", "0.7056311", "0.7054862", "0.7054768", "0.7053785", "0.70508564", "0.7049798", "0.7049643", "0.7049216", "0.70470136", "0.7046749", "0.70457184", "0.70452356", "0.70435864", "0.7042094", "0.7040006", "0.7035671" ]
0.0
-1
Properly enqueues stylesheets files into WP.
function load_admin_styles() { wp_enqueue_style('thickbox'); wp_enqueue_style( 'wppm-admin-styles', plugin_dir_url( __FILE__ ) . 'assets/css/admin.css', array(), '0.8' ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function enqueue_styles() {\n\n\t\tif ($this->css) {\n\t\t\tforeach ($this->css as $css) {\n\t\t\t\t$fileTitle = basename($css['link']);\n\t\t\t\t$fileTitle = str_replace('.css', '', $fileTitle);\n\t\t\t\t$fileTitle = preg_replace(\n\t\t\t\t\t'/[^0-9a-zA-Z]/',\n\t\t\t\t\t\"-\",\n\t\t\t\t\tstr_replace('@', '', $css['package']) . '-' . $fileTitle\n\t\t\t\t);\n\t\t\t\twp_enqueue_style($fileTitle, $css['link'], array(), $css['version'], 'all');\n\t\t\t}\n\t\t}\n\n\t}", "function enqueues() {\n\t\twp_register_style( 'ks-thematic-actions', plugin_dir_url( __FILE__ ) . 'style.css' );\n\t wp_enqueue_style( 'ks-thematic-actions' );\n\t}", "public function styles(){\n //Enqueue styles\n /**\n * wp_enqueue_style('sample-style',$this->directory_uri . '/sample.css');\n * ...\n * ....\n */\n }", "public function enqueueAssets()\n {\n wp_enqueue_style( WPADW_DOMAIN . '-admin-style', WPADW_URL . '/assets/style.css' );\n }", "function mocca_styles_files() {\n \n wp_enqueue_style('bootstrap-css', get_template_directory_uri() . '/css/bootstrap.min.css');\n wp_enqueue_style('fontawesome-css', get_template_directory_uri() . '/css/fontawesome-all.min.css');\n wp_enqueue_style('normalize-css', get_template_directory_uri() . '/css/normalize.css');\n wp_enqueue_style('main-css', get_template_directory_uri() . '/css/main.css');\n }", "function fincollect_styles() {\n wp_enqueue_style( 'fancybox', get_template_directory_uri() . '/assets/css/jquery.fancybox.css' );\n wp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.css' );\n wp_enqueue_style( 'main-style', get_stylesheet_uri() );\n }", "function load_stylesheets() {\n\n\twp_register_style('myCSS' , get_template_directory_uri() . '/style.css', array(), false, 'all');\n\twp_enqueue_style('myCSS');\n}", "public function kiwip_stylesheet_add_file(){\n\t\t//register\n\t\tforeach($this->stylesheet as $key){\n\t\t\twp_register_style('kiwip_shortcode-css-'.$key['stylesheetId'], $key['stylesheetURL']);\n\t\t}\n\t\t\n\t\t//load\n\t\tforeach($this->stylesheet as $eky){\n\t\t\twp_enqueue_style('kiwip_shortcode-css-'.$key['stylesheetId']);\n\t\t}\t\t\n\n\t\t// $this->debug($this->stylesheet); die();\n\t}", "public function enqueue_styles() {\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/deeppress-admin.css', array(), $this->version, 'all' );\n\t\twp_enqueue_style( \n\t\t\t$this->plugin_name.'-imageview', plugin_dir_url( __FILE__ ) . 'css/jquery.imageview.css', \n\t\t\tarray(), \n\t\t\t$this->version, 'all' \n\t\t);\n\t\twp_enqueue_style( \n\t\t\t$this->plugin_name.'-annotorious', plugin_dir_url( __FILE__ ) . 'css/jquery.selectareas.css', \n\t\t\tarray(), \n\t\t\t$this->version, 'all' \n\t\t);\n\t\twp_enqueue_style(\n\t\t\t$this->plugin_name.'-lightgallery', plugin_dir_url( __FILE__ ) . 'css/lightgallery.min.css',\n\t\t\tarray(),\n\t\t\t$this->version, 'all'\n\t\t);\n\n\t}", "function cbusds_styles()\n{\n\n wp_register_style('w3css', get_template_directory_uri() . '/css/w3.css', array(), '', 'all');\n wp_enqueue_style('w3css'); // Enqueue it!\n\n wp_register_style('normalize', get_template_directory_uri() . '/normalize.css', array(), '1.0', 'all');\n wp_enqueue_style('normalize'); // Enqueue it!\n\n wp_register_style('cbusdscss', get_template_directory_uri() . '/style.css', array(), '1.0', 'all');\n wp_enqueue_style('cbusdscss'); // Enqueue it!\n}", "function cm_load_styles() {\n wp_enqueue_style( 'style', get_stylesheet_uri() );\n wp_enqueue_style( 'font-awesome', get_stylesheet_directory_uri() . '/css/font-awesome.min.css' );\n wp_enqueue_style( 'bootstrap', get_stylesheet_directory_uri() . '/css/bootstrap.min.css' );\n wp_enqueue_style( 'main', get_stylesheet_directory_uri() . '/css/main.css' );\n}", "function re_add_my_stylesheet() {\n // Respects SSL, Style.css is relative to the current file\n wp_enqueue_style( 'variations', get_stylesheet_directory_uri() . '/assets/css/variations.css' );\n wp_enqueue_style( 'base', get_stylesheet_directory_uri() . '/assets/css/base.css' );\n wp_enqueue_style( 'flexslider', get_stylesheet_directory_uri() . '/assets/css/flexslider.css' );\n \n /* Themes */\n\n // wp_enqueue_style( 'westwaters', get_stylesheet_directory_uri() . '/westwaters/custom.css' ); \n wp_enqueue_style( 'jumplife', get_stylesheet_directory_uri() . '/jumplife/custom.css' );\n\n /* END Themes */\n\n wp_enqueue_style('font-awesome', '//netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.css');\n //wp_enqueue_script('smooth-scrolling', get_stylesheet_directory_uri() . '/assets/js/smooth-scrolling.js');\n wp_enqueue_script('flex-slider', get_stylesheet_directory_uri() . '/assets/js/jquery.flexslider-min.js');\n\n}", "function purpleBlog_resources() {\n\n\t/*-- stylesheets ---*/\n\twp_enqueue_style( 'style', get_stylesheet_uri() );\n\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/css/bootstrap.css' );\n\twp_enqueue_style( 'bootstrap_theme', get_template_directory_uri() . '/css/bootstrap-theme.css' );\n}", "public function enqueueStyles() {\n\t\t\twp_enqueue_style('app', self::asset(\"css/app.css\"), NULL, '1.0.0', 'all');\n\t\t}", "public function enqueue_styles() {\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/sanoa-links-linter-public.css', array(), $this->version, 'all' );\n\t}", "public function enqueue_styles() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Plugin_Name_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Plugin_Name_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/drinkers-edition-admin.css', array(), $this->version, 'all' );\n\n\t}", "function custom_files()\n{\n wp_enqueue_style(\"custom_css\", get_stylesheet_uri());\n}", "function rhd_enqueue_styles(){\n\tglobal $theme_opts;\n\n\twp_register_style( 'rhd-sitewide', content_url() . '/global/sitewide.css', array(), '1', 'all' );\n\twp_register_style( 'rhd-main', RHD_THEME_DIR . '/css/main.css', array(), '1', 'all' );\n\twp_register_style( 'rhd-enhanced', RHD_THEME_DIR . '/css/enhanced.css', array(), '1', 'all' );\n\twp_register_style( 'Slidebars', RHD_THEME_DIR . '/js/vendor/Slidebars/dist/slidebars.min.css', array(), null, 'all' );\n\n\t$normalize_deps = array();\n\t$normalize_deps[] = 'Slidebars';\n\n\tif ( !rhd_is_mobile() ) {\n\t\twp_enqueue_style( 'rhd-enhanced' );\n\t}\n\n\twp_register_style( 'normalize', RHD_THEME_DIR . '/css/normalize.css', $normalize_deps, null, 'all' );\n\n\twp_enqueue_style( 'rhd-main' );\n\twp_enqueue_style( 'rhd-sitewide' );\n\twp_enqueue_style( 'normalize' );\n\twp_enqueue_style( 'google-fonts' );\n}", "public function enqueue_styles() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Nimiq_Miner_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Nimiq_Miner_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/nimiq-miner-public.css', array(), $this->version, 'all' );\n\n\t}", "private function enqueue_style_css()\n\t{\n\t\twp_enqueue_style('style', get_stylesheet_uri(), array('main'));\n\t}", "function coc_styles() {\r\n\t\t\r\n\t\twp_enqueue_style( 'style1', get_template_directory_uri() . '../css/bootstrap.css',false,'1','all');\r\n\t\t\r\n\t\twp_enqueue_style( 'style2', get_stylesheet_uri() );\r\n\t\t\r\n\t\twp_enqueue_style( 'style3', get_template_directory_uri() . '../bootstrap/css/bootstrap.css',false,'1','all');\r\n\t\t\r\n\t\twp_enqueue_style( 'style4', get_template_directory_uri() . '../bootstrap/css/bootstrap.min.css',false,'1','all');\r\n\t\t\t\t\r\n\t}", "public function enqueue_styles() {\n\n\t\t// Setup styles array\n\t\t$styles = array();\n\n\t\t// LTR\n\t\t$styles['bbp-default'] = array(\n\t\t\t'file' => URL.'sprites/stylesheets/forums.css',\n\t\t\t'dependencies' => array()\n\t\t);\n\n\t\t// RTL helpers\n\t\tif ( is_rtl() ) {\n\t\t\t$styles['bbp-default-rtl'] = array(\n\t\t\t\t'file' => 'css/bbpress-rtl.css',\n\t\t\t\t'dependencies' => array( 'bbp-default' )\n\t\t\t);\n\t\t}\n\n\t\t// Filter the scripts\n\t\t$styles = apply_filters( 'BBP_IOA_styles', $styles );\n\n\t\t// Enqueue the styles\n\t\tforeach ( $styles as $handle => $attributes ) {\n\t\t\tbbp_enqueue_style( $handle, $attributes['file'], $attributes['dependencies'], $this->version, 'screen' );\n\t\t}\n\t}", "function enqueue_our_required_stylesheets(){\n\twp_enqueue_style('font-awesome', '//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css');\n\twp_enqueue_style('custom', get_stylesheet_directory_uri() . '/custom.css');\n}", "function inkthemes_enqueue_styles() {\n global $themeslug, $options;\n wp_register_style($themeslug . 'storecss', get_template_directory_uri() . '/admin/theme-page-style.css');\n wp_enqueue_style($themeslug . 'storecss');\n}", "function front_end_styles()\n{\n\twp_register_style( 'front-end-normalize', get_template_directory_uri() . '/css/reset.css', array(), null, 'all' );\n wp_register_style( 'front-end-styles', get_template_directory_uri() . '/css/styles.css', array(), null, 'all' );\n wp_register_style( 'front-end-plugins', get_template_directory_uri() . '/css/plugins.css', array(), null, 'all' );\n wp_register_style( 'front-end-media-queries', get_template_directory_uri() . '/css/media-queries.css', array(), null, 'all' );\n \n \n wp_enqueue_style( 'front-end-normalize' );\n wp_enqueue_style( 'front-end-styles' );\n wp_enqueue_style( 'front-end-plugins' );\n wp_enqueue_style( 'front-end-media-queries' );\n}", "function wp_enqueue_style() {\n\t}", "public function enqueue_styles() {\n\n\t\twp_register_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/all.css', array(), $this->version, 'all' );\n\t}", "public function enqueue_styles() {\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Nerd_Wp_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Nerd_Wp_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/contact-helpdesk-admin.css', array(),\n\t\t\t$this->version, 'all' );\n\t}", "public function enqueue_styles() {\n\t\t/**\n\t\t * Filters the path to the admin CSS styles.\n\t\t *\n\t\t * @since 1.0.0\n\t\t *\n\t\t * @param string $path The path to the CSS file.\n\t\t */\n\t\t$style_path = apply_filters( 'stellarwp/telemetry/' . Config::get_hook_prefix() . 'style_path', $this->get_asset_path() . 'resources/css/styles.css' );\n\n\t\twp_enqueue_style(\n\t\t\tself::SCRIPT_HANDLE,\n\t\t\t$style_path,\n\t\t\t[],\n\t\t\tself::SCRIPT_VERSION\n\t\t);\n\t}", "function hsbc_theme_stylesheets() {\r\n wp_enqueue_style( 'hsbc-theme-materialize-style', get_template_directory_uri() .'/assets/css/materialize.min.css', array(), null, 'all' );\r\n wp_enqueue_style( 'hsbc-theme-hsbc-style', get_template_directory_uri() .'/assets/css/hsbc.css', array('hsbc-theme-materialize-style'), null, 'all' );\r\n wp_enqueue_style( 'hsbc-theme-required-style', get_stylesheet_uri(), '', null, 'all' );\r\n}", "function files()\n{\n wp_enqueue_style( 'style', get_template_directory_uri().'/css/style.css', false, '1.0', 'all' );\n}", "function load_stylesheets()\n{\n // 1. Download bootstrap css from serwer (katalog otoedu)\n wp_register_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css', array(), false, 'all');\n wp_enqueue_style('bootstrap');\n\n // 2. Download style css from serwer (katalog otoedu)\n // It is my style (not bootstrap). That must be second position\n wp_register_style('style', get_template_directory_uri() . '/style.css', array(), false, 'all');\n wp_enqueue_style('style');\n}", "public function enqueue_styles_and_stuffs() {\n\t\t // libraries\n\t\t wp_enqueue_style( 'woocommerce_prettyPhoto_css' );\n\t\t\twp_enqueue_style( 'jquery-selectBox' );\n\t\t\twp_enqueue_style( 'yith-wcwl-font-awesome' );\n\n\t\t\t// main plugin style\n\t\t\tif ( ! wp_style_is( 'yith-wcwl-user-main', 'registered' ) ) {\n\t\t\t\twp_enqueue_style( 'yith-wcwl-main' );\n\t\t\t}\n\t\t\telse {\n\t\t\t\twp_enqueue_style( 'yith-wcwl-user-main' );\n\t\t\t}\n\n\t\t\t// theme specific style\n\t\t\tif( wp_style_is( 'yith-wcwl-theme', 'registered' ) ){\n\t\t\t wp_enqueue_style( 'yith-wcwl-theme' );;\n }\n\n\t\t\t// custom style\n\t\t\t$this->enqueue_custom_style();\n\t\t}", "function add_css() \n {\n if( $this->options['use-css-file'] ) {\n wp_register_style( 'bbquotations-style' , $this->plugin_url . 'bbquotations-style.css');\n wp_enqueue_style( 'bbquotations-style' );\n } \n }", "function css_files() {\n\t\twp_enqueue_style('escalate_network-admin-global', $this->plugin_url .'/css/styles-admin-global.css');\n\t}", "function enqueueClientFiles() {\n\t\t\tglobal $wp_styles;\n\n\t\t\tif ( ! is_admin() ) {\n\n\t\t\t\twp_enqueue_style(\n\t\t\t\t\t'titan-style',\n\t\t\t\t\tget_bloginfo( 'stylesheet_url' ),\n\t\t\t\t\t'',\n\t\t\t\t\tnull\n\t\t\t\t);\n\n\t\t\t\twp_enqueue_style(\n\t\t\t\t\t'titan-ie-style',\n\t\t\t\t\tget_template_directory_uri() . '/stylesheets/ie.css',\n\t\t\t\t\tarray( 'titan-style' ),\n\t\t\t\t\tnull\n\t\t\t\t);\n\t\t\t\t$wp_styles->add_data( 'titan-ie-style', 'conditional', 'lt IE 8' );\n\n\t\t\t\tif ( is_singular() ) {\n\t\t\t\t\twp_enqueue_script( 'comment-reply' );\n\t\t\t\t}\n\t\t\t}\n\t\t}", "function cherrypick_child_enqueue_css()\n{\n wp_register_style( 'theme-stylesheet', get_stylesheet_uri() );\n wp_enqueue_style( 'theme-stylesheet' );\n}", "public function enqueue_styles() {\n\t\twp_enqueue_style( 'slick-css', plugin_dir_url( dirname( __FILE__, 2 ) ) . '/assets/css/slick-theme.css', array(), '1.8.1' );\n\t\twp_enqueue_style( 'style-css', plugin_dir_url( dirname( __FILE__, 2 ) ) . '/assets/css/style.css', array(), '1.0.0' );\n\t}", "function mfnch_enqueue_styles() {\n// \twp_enqueue_style( 'parent-style', get_template_directory_uri() .'/style.css' );\t\t//we don't need this if it's empty\n\t\n\t// Enqueue the parent rtl stylesheet\n\tif ( is_rtl() ) {\n\t\twp_enqueue_style( 'mfn-rtl', get_template_directory_uri() . '/rtl.css' );\n\t}\n\t\n\t// Enqueue the child stylesheet\n\twp_dequeue_style( 'style' );\n\twp_enqueue_style( 'style', get_stylesheet_directory_uri() .'/style.css' );\n\twp_enqueue_style( 'app', get_stylesheet_directory_uri() .'/dist/css/main.css', null, microtime() );\n\t\n}", "public function load_styles() {\n\t wp_enqueue_style( 'core', get_stylesheet_uri() );\n\t\twp_enqueue_style( 'main', get_stylesheet_directory_uri() . '/assets/css/main-style.min.css' );\n\n\t\t// ADD MORE STYLE HERE ...\n\t\t\n\t}", "function enqueueFiles()\n{\n wp_enqueue_style('style', get_stylesheet_uri(), array(), '1.22');\n wp_enqueue_script('script', get_template_directory_uri() . '/assets/js/custom.js', array(), '1.22');\n}", "public function enqueue_styles() {\n\n if ( !isset( $this->plugin_screen_hook_suffix ) ) {\n return;\n }\n\n $screen = get_current_screen();\n\n if ( isset( $screen->id ) && $screen->id == $this->plugin_screen_hook_suffix ) {\n wp_enqueue_style( 'font-awesome', plugin_dir_url( __FILE__ ) . 'css/vendor/font-awesome.min.css', array(), '4.7.0', 'all' );\n wp_enqueue_style( 'wpp-datepicker-theme', plugin_dir_url( __FILE__ ) . 'css/datepicker.css', array(), $this->version, 'all' );\n wp_enqueue_style( 'wordpress-popular-posts-admin-styles', plugin_dir_url( __FILE__ ) . 'css/admin.css', array(), $this->version, 'all' );\n }\n\n }", "public function enqueue_styles() {\n\n\t\twp_register_style( 'wpaddons_io_sitestyle', plugins_url( 'wpaddons-io-sdk/css/wpaddons-io.css', __FILE__ ) );\n\n\t\twp_enqueue_style( 'wpaddons_io_sitestyle' );\n\n\t}", "function tac_css_enqueuer() {\n\twp_register_style( 'tac_main', get_stylesheet_directory_uri() . '/style.css' );\n\twp_enqueue_style( 'tac_main' );\n}", "public function enqueue_styles() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in SpaceAPI_WP_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The SpaceAPI_WP_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/spaceapi-wp-admin.css', array(), $this->version, 'all' );\n\n\t}", "public function enqueue_styles() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Fastnetmarketing_Admin_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Fastnetmarketing_Admin_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/fastnetmarketing-admin-admin.css', array(), $this->version, 'all' );\n\n\t}", "function realEDU_theme_enqueue_styles(){\n\t\twp_enqueue_style('bootstrap-base', get_template_directory_uri() . \"/node_modules/bootstrap/dist/css/bootstrap.css\");\n\t\twp_enqueue_style('font-awesome', get_template_directory_uri() . \"/node_modules/font-awesome/css/font-awesome.css\");\n\n\t\twp_enqueue_style('stylesheet-default', get_template_directory_uri() . \"/style.css\");\n\t\twp_enqueue_style('custom-styles', get_template_directory_uri() . \"/css/app.css\");\n\t}", "function load_stylesheets(){\n /**/ \n\t\twp_register_style('mobiriseicon', get_template_directory_uri(). '/assets/web/assets/mobirise-icons2/mobirise2.css', '',2.0,'all');\n\t\twp_register_style('tether', get_template_directory_uri(). '/assets/tether/tether.min.css', '',1.0,'all');\n\t\twp_register_style('bootstrap', get_template_directory_uri(). '/assets/bootstrap/css/bootstrap.min.css', '',4.0,'all');\n\t\twp_register_style('bootstrapgrid', get_template_directory_uri(). '/assets/bootstrap/css/bootstrap-grid.min.css', '',4.0,'all');\n\t\twp_register_style('bootstrapreboot', get_template_directory_uri(). '/assets/bootstrap/css/bootstrap-reboot.min.css', '',4.0,'all');\n\t\twp_register_style('dropdown', get_template_directory_uri(). '/assets/dropdown/css/style.css', '',5.1,'all');\n\t\twp_register_style('socicon', get_template_directory_uri(). '/assets/socicon/css/styles.css', '',3.0,'all');\n\t\twp_register_style('themestyle', get_template_directory_uri(). '/assets/theme/css/style.css', '',3.0,'all');\n\t\twp_register_style('addstyle', get_template_directory_uri(). '/assets/mobirise/css/mbr-additional.css', '',3.0,'all');\n\t\twp_register_style('appcss', get_template_directory_uri(). '/assets/css/app.css', '',0.1,'all');\n \n wp_enqueue_style('mobiriseicon');\n wp_enqueue_style('tether');\n wp_enqueue_style('bootstrap');\n wp_enqueue_style('bootstrapgrid');\n wp_enqueue_style('bootstrapreboot');\n wp_enqueue_style('dropdown');\n wp_enqueue_style('socicon');\n wp_enqueue_style('themestyle');\n wp_enqueue_style('addstyle');\n wp_enqueue_style('appcss');\n}", "public function enqueues() {\n\n\t\t// CSS.\n\t\twp_enqueue_style(\n\t\t\t'wpforms-builder-setup',\n\t\t\tWPFORMS_PLUGIN_URL . 'assets/css/admin-builder-setup.css',\n\t\t\tnull,\n\t\t\tWPFORMS_VERSION\n\t\t);\n\t}", "public static function enqueue_styles() {\n\t\tif ( ! static::$enqueued && wp_style_is( 'cmb2-styles', 'enqueued' ) ) {\n\t\t\twp_enqueue_style( 'wplibs-form' );\n\t\t\twp_enqueue_script( 'wplibs-form' );\n\n\t\t\tstatic::$enqueued = true;\n\t\t}\n\t}", "public function enqueue_stylesheet() {\n\t\twp_register_style( self::HANDLE, $this->asset_resolver->resolve( 'css/theme.css' ), [], false );\n\t\twp_enqueue_style( self::HANDLE );\n\t}", "function addcss()\n{\nwp_register_style('ahmed_css', plugin_dir_url(__file__).'/styles-ahmed.css');\nwp_enqueue_style('ahmed_css');\n}", "public function enqueue_styles() {\n\t\t// wp_enqueue_style( $this->plugin_slug . '-plugin-styles', plugins_url( 'css/public.css', __FILE__ ), array(), self::VERSION );\n\t}", "function taleronWP_resources(){\n\twp_enqueue_style('style', get_stylesheet_uri());\n}", "function wptrebs_styles_scripts() {\n wp_enqueue_style( 'wptrebs_feed', plugins_url('..\\assets\\css\\style.css', __FILE__) );\n}", "public function enqueue_styles() {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Points_Of_Sale_Admin_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Points_Of_Sale_Admin_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style($this->plugin_name, plugin_dir_url(__FILE__) . 'css/points-of-sale-admin.css', array(), $this->version, 'all');\n\n\t}", "public function enqueue_styles() {\r\n\r\n\t\t}", "public function enqueue_styles() {\n\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/deeppress-public.css', array(), $this->version, 'all' );\n\n\t}", "function add_style(){\n\twp_enqueue_style('style',get_template_directory_uri().\"/css/style.css\");\n\twp_enqueue_style('bootstrap',get_template_directory_uri().\"/css/bootstrap.min.css\");\n}", "function add_style(){\n\twp_enqueue_style('style',get_template_directory_uri().\"/css/style.css\");\n\twp_enqueue_style('bootstrap',get_template_directory_uri().\"/css/bootstrap.min.css\");\n}", "function enqueue_styles()\n\t{\n\t\twp_register_style('theme-styles', get_theme_file_uri() . '/assets/css/styles.css', array(), '0.011', 'all');\n\t\twp_enqueue_style('theme-styles');\n\n\t\t// google fonts\n\t\twp_register_style('google-fonts', 'https://fonts.googleapis.com/css?family=Poppins:200,300,600|Merriweather:400,700&display=swap', array());\n\t\twp_enqueue_style('google-fonts');\n\n\t\t// font awesome\n\t\twp_register_style('font-awesome', 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.11.2/css/all.css', array());\n\t\twp_enqueue_style('font-awesome');\n\t}", "function enqueue_stylesheet() {\n\t\t\t\n\t\t\tif($this->test_stylesheet()){\n\t\t\t\tadd_action('tf_load_styles',array($this,'load_css'));\n\t\t\t add_filter('themify_google_fonts', array($this, 'enqueue_fonts'));\n\t\t\t add_filter('themify_custom_fonts', array($this, 'enqueue_custom_fonts'));\n\t\t\t}\n\t\t}", "function prefix_add_my_stylesheet() {\n wp_register_style( 'prefix-style', plugins_url('style1.css', __FILE__) );\n wp_enqueue_style( 'prefix-style',plugins_url('style1.css', __FILE__) );\n wp_enqueue_script( 'prefix-style',plugins_url('close.js', __FILE__) );\n wp_enqueue_style( 'fa-style',plugins_url('font-awesome-4.2.0/css/font-awesome.min.css', __FILE__) );\n \n}", "function hejtiger_theme_styles() {\n\n\twp_enqueue_style('style.css', get_stylesheet_uri() );\n}", "public function enqueue_styles()\n {\n wp_enqueue_style($this->andmoraho_vendors, plugin_dir_url(__FILE__) . 'css/andmoraho-vendors-admin.css', array(), $this->version, 'all');\n }", "function add_style()\r\n{\r\n wp_enqueue_style(\r\n 'bootstrap'\r\n , get_template_directory_uri().'/css/bootstrap.min.css'\r\n );\r\n wp_enqueue_style(\r\n 'fontawesome'\r\n , get_template_directory_uri().'/css/font-awesome.min.css'\r\n );\r\n wp_enqueue_style(\r\n 'main'\r\n , get_template_directory_uri().'/css/main.css'\r\n ); \r\n\r\n}", "private function enqueueStyle() {\n wp_enqueue_style(\n 'shokka-forms',\n plugins_url( 'css/dist/style.css', 'shokka-forms/shokka-forms.php' ),\n array(),\n filemtime(\n sprintf(\n '%s%s%s',\n trailingslashit( WP_PLUGIN_DIR ),\n plugin_dir_path( 'shokka-forms/shokka-forms.php' ),\n wp_normalize_path( 'css/dist/style.css' )\n )\n )\n );\n }", "function add_theme_scripts() {\n wp_enqueue_style( 'main_style_file', get_stylesheet_uri());\n /********** Including all.min css file ***********/\n wp_enqueue_style( 'minified_file', get_template_directory_uri() .'/css/all.min.css', array(), '1.1', 'all');\n /********** Including style css file ***********/\n wp_enqueue_style( 'style', get_template_directory_uri() .'/css/style.css', array(), '1.1', 'all');\n /********* Including bootstrap file ************/ \n wp_enqueue_style( 'bootstrap_file', get_template_directory_uri() .'/css/bootstrap.min.css', array (),'1.1', 'all'); \n //********* Including script files ************/\n wp_enqueue_script( $handle, get_template_directory_uri().'/js/bootstrap.min.js', array(), '1.1' , true ); \n}", "function styles() {\n\n\twp_enqueue_style(\n\t\t'styles',\n\t\tPLAYGROUND_THEME_TEMPLATE_URL . \"/dist/css/style.min.css\",\n\t\tfalse\n\t);\n}", "public function enqueue_styles() {\n\n\t\t\t/**\n\t\t\t * This function is provided for demonstration purposes only.\n\t\t\t *\n\t\t\t * An instance of this class should be passed to the run() function\n\t\t\t * defined in Advanced_Reviews_Pro_Loader as all of the hooks are defined\n\t\t\t * in that particular class.\n\t\t\t *\n\t\t\t * The Advanced_Reviews_Pro_Loader will then create the relationship\n\t\t\t * between the defined hooks and the functions defined in this\n\t\t\t * class.\n\t\t\t */\n\n\t\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/advanced-reviews-pro-public.css', array(), $this->version, 'all' );\n\t\t}", "function load_css()\n{\n wp_register_style('bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.min.css', array(), false, 'all');\n wp_enqueue_style('bootstrap');\n\n wp_register_style('main', get_template_directory_uri() . '/assets/css/index.css', array(), false, 'all');\n wp_enqueue_style('main');\n\n wp_register_style('media-query', get_template_directory_uri() . '/assets/css/index.mediaquery.css', array(), false, 'all');\n wp_enqueue_style('media-query');\n\n wp_register_style('menu', get_template_directory_uri() . '/assets/css/menu.css', array(), false, 'all');\n wp_enqueue_style('menu');\n\n wp_register_style('archive', get_template_directory_uri() . '/assets/css/archive.css', array(), false, 'all');\n wp_enqueue_style('archive');\n\n wp_register_style('swiper', get_template_directory_uri() . '/assets/css/swiper-bundle.min.css', array(), false, 'all');\n wp_enqueue_style('swiper');\n\n wp_register_style('font-css', get_template_directory_uri() . '/assets/fonts/stylesheet.css', array(), false, 'all');\n wp_enqueue_style('font-css');\n}", "function enqueueStyles() {\r\n $version = '0.2';\r\n $mainJS = get_template_directory_uri() . '/js/dist/main.js';\r\n $mainCSS = get_template_directory_uri() . '/css/dist/main.min.css';\r\n\r\n wp_enqueue_style('style', $mainCSS, $version, true);\r\n wp_enqueue_script('script', $mainJS, $version, true);\r\n}", "function themeslug_enqueue_style() {\n\twp_enqueue_style( 'main_css', get_template_directory_uri() . '/style.css', false ); \n\twp_enqueue_style( 'foundation_css', get_template_directory_uri() . '/css/foundation.min.style.css', false ); \n}", "function my_styles_files() {\n\twp_enqueue_style( 'montserrat-css', 'https://fonts.googleapis.com/css?family=Montserrat:400,700', false );\n\twp_enqueue_style( 'roboto-css', 'https://fonts.googleapis.com/css?family=Roboto:400,300,500,700', false );\n\twp_enqueue_style( 'bootstrap-css', get_template_directory_uri() . '/assets/css/bootstrap.css', false );\n\twp_enqueue_style( 'animate-css', get_template_directory_uri() . '/assets/css/animate.css', false );\n\twp_enqueue_style( 'jquery-ui-css', get_template_directory_uri() . '/assets/css/jquery-ui.css', false );\n\twp_enqueue_style( 'simple-line-icons-css', get_template_directory_uri() . '/assets/css/simple-line-icons.css', false );\n\twp_enqueue_style( 'font-awesome-css', get_template_directory_uri() . '/assets/css/font-awesome.min.css', false );\n\twp_enqueue_style( 'icon-font-css', get_template_directory_uri() . '/assets/css/icon-font.css', false );\n\twp_enqueue_style( 'auction-css', get_template_directory_uri() . '/assets/css/auction.css', false );\n\twp_enqueue_style( 'rs-plugin-css', get_template_directory_uri() . '/assets/rs-plugin/css/settings.css', false );\n\twp_enqueue_style( 'fancybox-css', get_template_directory_uri() . '/assets/js/jquery/fancybox/jquery.fancybox.css', false );\n\tif ( is_child_theme() ) {\n\t\twp_enqueue_style( 'parent-css', trailingslashit( get_template_directory_uri() ) . 'style.css', false );\n\t}\n\twp_enqueue_style( 'theme-css', get_stylesheet_uri(), false );\n}", "public function enqueue_styles() {\n\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/content-otter-tweet.css', array(), $this->version, 'all' );\n\n\t}", "function ezbreezies_styles() {\n\n\twp_enqueue_style( 'ezbreezies-style', get_template_directory_uri() . '/style.css' );\n\twp_enqueue_style( 'ezbreezies-main-style', get_template_directory_uri() . '/library/css/main-min.css' );\n\n}", "public function action_wp_enqueue_scripts() {\n\n\t\twp_enqueue_style( 'bootstrap', get_stylesheet_directory_uri() . '/lib/bootstrap/dist/css/bootstrap.css' );\n\t\twp_enqueue_style( 'core-style', get_stylesheet_directory_uri() . '/assets/stylesheets/core.css' );\n\n\t}", "function styles() {\n\t/**\n\t * Flag whether to enable loading uncompressed/debugging assets. Default false.\n\t *\n\t * @param bool additive_style_debug\n\t */\n\t$debug = apply_filters( 'additive_style_debug', false );\n\t$min = ( $debug || defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';\n\n\twp_enqueue_style( 'additive-fonts',\n\t\t\"https://fonts.googleapis.com/css?family=Arvo:400,700|Lato:300,400,700\",\n\t\tarray(),\n\t\tnull\n\t);\n\n\twp_enqueue_style(\n\t\t'normalize',\n\t\tADDITIVE_URL . \"/assets/css/normalize{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n\n\twp_enqueue_style(\n\t\t'skeleton',\n\t\tADDITIVE_URL . \"/assets/css/skeleton{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n\n\twp_enqueue_style(\n\t\t'additive',\n\t\tADDITIVE_URL . \"/assets/css/additive{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n\n\twp_enqueue_style(\n\t\t'font-awesome',\n\t\tADDITIVE_URL . \"/assets/css/font-awesome{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n}", "public function enqueueScripts() {\n wp_register_style('rrze-faq-style', plugins_url('assets/css/rrze-faq.css', plugin_basename($this->pluginFile)));\n wp_enqueue_style('rrze-faq-style');\n }", "public function enqueue() {\n $this->register();\n\n // If stylesheet is in browser cache, load it the traditional way\n if ( isset( $_COOKIE['fullCSS'] ) && false !== $_COOKIE['fullCSS'] )\n {\n // Load Typekit\n wp_enqueue_style( 'typekit' );\n // Default style.css.\n wp_enqueue_style( 'style' );\n }\n // Otherwise, inline critical CSS and load full stylesheet asynchronously\n else\n {\n add_filter( 'style_loader_tag', array( $this, 'custom_link_tag_attributes' ), 5, 4 );\n add_action( 'wp_head', array( __CLASS__, 'loadCSS' ), 10 );\n }\n\n // jQuery.\n wp_enqueue_script( 'jquery' );\n\n // Fullpage.js\n wp_enqueue_script( 'parallax' );\n wp_enqueue_script( 'fullpage' );\n\n // MmenuLight\n wp_enqueue_script( 'mmenu-light-polyfills' );\n wp_enqueue_script( 'mmenu-light' );\n\n // Frontend.\n wp_enqueue_script( 'app-js' );\n\n // Post comments.\n if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {\n wp_enqueue_script( 'comment-reply' );\n }\n }", "function scripts_styles() {\n\n\t\t// No need to process if in admin.\n\t\tif ( is_admin() ) {\n\t\t\treturn;\n\t\t}\n\n\t\t$theme_url = get_template_directory_uri();\n\t\t$main_css_url = $theme_url . '/style.css';\n\t\t$main_css_path = get_template_directory() . '/style.css';\n\t\t$main_css_ver = file_exists( $main_css_path ) ? filemtime( $main_css_path ) : '';\n\n\t\twp_enqueue_style( 'superiocity-style', $main_css_url, null, $main_css_ver );\n\t\twp_deregister_script( 'wp-embed' );\n\t}", "public function registerStyles()\n {\n wp_register_style('swiper-css', THEME_DIR_URI .'/assets/css/swiper.min.css', [], false, 'all');\n wp_register_style('dist-css', THEME_DIR_URI .'/assets/css/dist.css', [], false, 'all');\n wp_register_style('regional-css', THEME_DIR_URI .'/regional.css', [], false, 'all');\n wp_register_style('regional-style', THEME_DIR_URI .'/style.css', [], false, 'all');\n\n // Default app style file\n //wp_enqueue_style('style-css');\n\n // App styles\n wp_enqueue_style('swiper-css');\n wp_enqueue_style('dist-css');\n wp_enqueue_style('regional-css');\n wp_enqueue_style('regional-style');\n }", "function wpi_theme_styles() {\n wp_enqueue_style('bootstrap_css', get_template_directory_uri() . '/css/bootstrap.min.css');\n wp_enqueue_style('main_css', get_template_directory_uri() . '/style.css');\n \n \n\n }", "public function enqueues()\n {\n\n // CSS\n wp_enqueue_style(\n 'wpforms-builder-settings',\n WPFORMS_PLUGIN_URL . 'assets/css/admin-builder-settings.css',\n null,\n WPFORMS_VERSION\n );\n }", "function enqueue_styles() {\n\t\twp_register_style( 'github-embed', plugins_url( basename( dirname( __FILE__ ) ) . '/css/github-embed.css' ) );\n\t\twp_enqueue_style( 'github-embed' );\n\t}", "function WPThemeDevPrac_resources(){\n\n\twp_enqueue_style('style', get_stylesheet_uri());\n\n}", "public function enqueue_style() {\n\t\twp_enqueue_style( 'aztec-style', get_stylesheet_directory_uri() . '/assets/css/styles.css' );\n\t}", "function zweidrei_eins_register_styles() {\n\n\t$theme_version = wp_get_theme()->get( 'Version' ); \n\twp_enqueue_style( 'style', get_stylesheet_uri(), array(), $theme_version );\n\n\t/** \t\n\t * Add custom css\n\t * Bulma: Free, open source, and modern CSS framework based on Flexbox\n\t * https://bulma.io/ \n\t * Version: 0.9.0\n\t * Child: custom.css\n\t */\n\twp_enqueue_style( 'style1', get_template_directory_uri() . '/assets/css/bulma.min.css', array(), $theme_version );\n\twp_enqueue_style( 'style2', get_template_directory_uri() . '/assets/css/custom.css', array(), $theme_version );\n\n\t\n\n}", "function dseven_enqueue_style() {\n\twp_enqueue_style( 'dizzyseven', get_stylesheet_uri() ); \n\twp_enqueue_style( 'dizzyseven-guttenberg', get_template_directory_uri() . '/dizzy-gutenberg.css' );\n\twp_enqueue_style( 'dizzyseven-animateit', get_template_directory_uri() . '/include/animate-it/css/animations.css' );\n\tif (get_theme_mod('diz-custom-typography-css')) {\n\t wp_enqueue_style( 'dizzyseven-guttenberg-custom-editor', get_template_directory_uri() . '/custom-styles.css.php', false, true );\n\t }\n\tif (get_theme_mod('google_font_setting')) {\n\t wp_enqueue_style( 'dizzyseven-google-font', get_theme_mod( 'google_font_setting', '' ), false, true );\n\t }\n\tif (get_theme_mod('custom_font_setting')) {\n\t wp_enqueue_style( 'dizzyseven-custom-font', get_theme_mod( 'custom_font_setting', '' ), false, true );\n\t }\n}", "function wmt_theme_style () {\n\twp_enqueue_style( 'normalize_css', get_template_directory_uri() . '/css/normalize.css' );\n\twp_enqueue_style( 'bootstrap_css', get_template_directory_uri() . '/css/bootstrap.css' );\n\twp_enqueue_style( 'flexslider_css', get_template_directory_uri() . '/css/flexslider.css' );\n\twp_enqueue_style( 'font_awesome_css', get_template_directory_uri() . '/css/font-awesome.css' );\n\twp_enqueue_style( 'style_css', get_template_directory_uri() . '/css/estilos.css' );\n}", "function script_n_styles_func() {\n\n wp_enqueue_style( 'custom-stylesheet', PLUGINS_URL( '/css/custom.css', __FILE__ ) );\n wp_enqueue_style( 'font-awesome-cdn', 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css' );\n\n }", "public function enqueue_styles()\n\t{\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Prosvit_Extension_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Prosvit_Extension_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style('style_select2', plugin_dir_url(__FILE__) . 'css/select2.min.css', array(), $this->version, 'all');\n\t\twp_enqueue_style($this->plugin_name, plugin_dir_url(__FILE__) . 'css/prosvit-extension-admin.css', array(), $this->version, 'all');\n\t}", "function load_css() {\n wp_register_style('main', get_template_directory_uri() . '/css/main.css', array(), false, 'all');\n wp_enqueue_style('main');\n }", "function hankart_enqueue_styles() {\n // wp_dequeue_style( 'font-awesome' );\n // wp_dequeue_style( 'storefront-fonts' );\n // wp_dequeue_style( 'source-sans-pro' );\n // wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css' );\n // wp_enqueue_style( 'child-style', get_stylesheet_directory_uri() );\n wp_enqueue_style( 'load-fa', 'https://cdn.jsdelivr.net/npm/@fortawesome/[email protected]/css/fontawesome.min.css' );\n}", "function enqueue_styles() { \n \n /** REGISTER css/screen.css **/ \n wp_register_style( 'screen-style', THEME_DIR . '/style.css', array(), '1', 'all' ); \n wp_enqueue_style( 'screen-style' );\n \n}", "public function theme_styles()\n\t{\n\n\t\twp_enqueue_style(\n\t\t\t'sourcesanspro',\n\t\t\t'https://fonts.googleapis.com/css?family=Source+Sans+Pro&display=swap',\n\t\t\t[],\n\t\t\t'auto'\n\t\t);\n\t\twp_enqueue_style(\n\t\t\t'fontawesome',\n\t\t\tTHEME_URL . '/assets/fontawesome/css/all.min.css',\n\t\t\t[],\n\t\t\t'auto'\n\t\t);\n\t\twp_enqueue_style(\n\t\t\t'style',\n\t\t\tTHEME_URL . '/assets/css/style.min.css',\n\t\t\t[],\n\t\t\t'auto'\n\t\t);\n\t}", "function bp_enqueue_style() {\n wp_enqueue_style('main-css', get_template_directory_uri() . '/assets/css/theme.css');\n wp_enqueue_style('main-style', get_template_directory_uri() . '/style.css');\n}", "function streamline_enqueue() {\n // Theme Stylesheet (currently points to stylesheet in the sass folder)\n wp_enqueue_style( 'streamline-style' , get_stylesheet_uri('stylesheets/style.css') );\n}", "function fzproject_register_styles()\n{\n // register \n //wp_register_style('zoneslider_styles', plugins_url('zoneslider/style.css', __FILE__)); \n wp_register_style('fzproject_styles_theme', plugins_url('css/style.css', __FILE__));\n // enqueue \n //wp_enqueue_style('fzproject_styles'); \n wp_enqueue_style('fzproject_styles_theme');\n}", "function register_css_styles() {\n\tif (!is_admin()) {\n\t\tglobal $wp_styles;\n\t\t\n\t\t\n\t\t$cmsms_option = cmsms_get_global_options();\n\t\t\n\t\t\n\t\twp_register_style('theme-style', get_stylesheet_uri(), array(), '1.0.0', 'screen');\n\t\twp_register_style('theme-fonts', get_template_directory_uri() . '/css/fonts.php', array(), '1.0.0', 'screen');\n\t\twp_register_style('theme-adapt', get_template_directory_uri() . '/css/adaptive.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('theme-retina', get_template_directory_uri() . '/css/retina.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('jackbox', get_template_directory_uri() . '/css/jackbox.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('fontello', get_template_directory_uri() . '/css/fonts/css/fontello.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('jPlayer', get_template_directory_uri() . '/css/jquery.jPlayer.css', array(), '2.1.0', 'screen');\n\t\twp_register_style('isotope', get_template_directory_uri() . '/css/jquery.isotope.css', array(), '1.5.19', 'screen');\n\t\twp_register_script('respond', get_template_directory_uri() . '/js/respond.min.js', array(), '1.1.0', false);\n\t\t\n\t\twp_enqueue_style('theme-style');\n\t\twp_enqueue_style('theme-fonts');\n\t\twp_enqueue_style('fontello');\n\t\t\n\t\tif ($cmsms_option[CMSMS_SHORTNAME . '_responsive']) {\n\t\t\twp_enqueue_style('theme-adapt');\n\t\t}\n\t\t\n\t\tif ($cmsms_option[CMSMS_SHORTNAME . '_retina']) {\n\t\t\twp_enqueue_style('theme-retina');\n\t\t}\n\t\n\t\t\n\t\twp_enqueue_style('jackbox');\n\t\twp_enqueue_style('jPlayer');\n\t\twp_enqueue_style('isotope');\n\t\t\n\t\twp_register_style('jackbox-ie8', get_template_directory_uri() . '/css/jackbox-ie8.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('jackbox-ie9', get_template_directory_uri() . '/css/jackbox-ie9.css', array(), '1.0.0', 'screen');\n\t\t\n\t\twp_enqueue_style('theme-ie', get_template_directory_uri() . '/css/ie.css', array(), '1.0.0', 'screen');\n\t\twp_enqueue_style('theme-ieCss3', get_template_directory_uri() . '/css/ieCss3.php', array(), '1.0.0', 'screen');\n\t\t\n\t\t$wp_styles->add_data('jackbox-ie8', 'conditional', 'lt IE 9');\n\t\t$wp_styles->add_data('jackbox-ie9', 'conditional', 'gt IE 8');\n\t\t\n\t\t$wp_styles->add_data('theme-ie', 'conditional', 'lt IE 9');\n\t\t$wp_styles->add_data('theme-ieCss3', 'conditional', 'lt IE 9');\n\t}\n}", "function loadStyles() {\n\t\twp_register_style('hashee_styles', $this->pluginPath . 'css/hashee_styles.css');\n\t\twp_enqueue_style('hashee_styles');\n\t}" ]
[ "0.8177778", "0.7899687", "0.7802683", "0.7736126", "0.7729479", "0.77268356", "0.76421726", "0.76193553", "0.76180154", "0.7614855", "0.75992835", "0.75713885", "0.7558785", "0.7542281", "0.7527996", "0.75166017", "0.7505825", "0.74990594", "0.7481038", "0.7479054", "0.7477661", "0.7462815", "0.74627054", "0.745899", "0.74561775", "0.7456069", "0.7447089", "0.7441932", "0.7440113", "0.74282175", "0.7423562", "0.742289", "0.7417779", "0.74172443", "0.7413288", "0.74130094", "0.7409371", "0.7400749", "0.7395548", "0.7393797", "0.7392254", "0.7390902", "0.73902094", "0.7382767", "0.7379686", "0.7379089", "0.7372163", "0.737117", "0.7365827", "0.7364753", "0.7359333", "0.73531246", "0.7351074", "0.73510027", "0.7347516", "0.7343063", "0.7338327", "0.73291993", "0.73264766", "0.73264766", "0.7326134", "0.7325777", "0.7322657", "0.73191667", "0.73188835", "0.73144156", "0.7308483", "0.7300469", "0.728848", "0.7280806", "0.7280403", "0.72802895", "0.72784114", "0.72754735", "0.72738785", "0.7271057", "0.7268995", "0.7266626", "0.7265679", "0.725925", "0.72579694", "0.72517323", "0.72476614", "0.72475535", "0.7241455", "0.7236807", "0.723576", "0.7235286", "0.72330606", "0.7231788", "0.72299373", "0.722681", "0.72263455", "0.7225981", "0.7220489", "0.7215723", "0.7198616", "0.7194808", "0.719357", "0.7191365", "0.7190733" ]
0.0
-1
Properly enqueues Javascript files into WP. 1) jquery 2) Bootstrap 3) Google Maps API 4) Bootstrap Validator
function load_scripts() { global $redux_options; wp_enqueue_script("jquery"); $bs = $redux_options['opt-bootstrap']; if ( $bs == 1 ) { //Load from CDN// wp_enqueue_script( 'bootstrap-script', '//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/js/bootstrap.min.js', array( 'jquery' ), '3.3.2', true ); } elseif ( $bs == 2 ) { //Load from plugin// wp_enqueue_script( 'bootstrap-script', dirname( __FILE__ ).'/assets/bootstrap/js/bootstrap.min.js', array( 'jquery' ), '3.3.2', true ); } elseif ( $bs == 3 ) { //load from nowhere... They have it loaded elsewhere... lets check to be sure though } else { //load from plugin. (fallback)// wp_enqueue_script( 'bootstrap-script', dirname( __FILE__ ).'/assets/bootstrap/js/bootstrap.min.js', array( 'jquery' ), '3.3.2', true ); } wp_enqueue_script( 'google-maps-api', 'http://maps.google.com/maps/api/js?sensor=false', array(), '3', false ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static function wp_enqueue_scripts() {\n global $slplus_plugin;\n \n if (isset($slplus_plugin) && $slplus_plugin->ok_to_show()) { \n $api_key=$slplus_plugin->driver_args['api_key'];\n $google_map_domain=(get_option('sl_google_map_domain')!=\"\")? \n get_option('sl_google_map_domain') : \n \"maps.google.com\"; \n $sl_map_character_encoding='&oe='.get_option('sl_map_character_encoding','utf8'); \n \n //------------------------\n // Register our scripts for later enqueue when needed\n //\n //wp_register_script('slplus_functions',SLPLUS_PLUGINURL.'/core/js/functions.js');\n\t\t\t\tif (isset($api_key))\n\t\t\t\t{\n\t\t\t\t\twp_register_script(\n\t\t\t\t\t\t\t'google_maps',\n\t\t\t\t\t\t\t\"http://$google_map_domain/maps/api/js?v=3.9&amp;key=$api_key&amp;sensor=false\" //todo:character encoding ???\n\t\t\t\t\t\t\t//\"http://$google_map_domain/maps?file=api&amp;v=2&amp;key=$api_key&amp;sensor=false{$sl_map_character_encoding}\" \n\t\t\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\twp_register_script(\n\t\t\t\t\t\t'google_maps',\n\t\t\t\t\t\t\"http://$google_map_domain/maps/api/js?v=3.9&amp;sensor=false\"\n\t\t\t\t\t);\n\t\t\t\t}\n //wp_register_script(\n // 'slplus_map',\n // SLPLUS_PLUGINURL.'/core/js/store-locator-map.js',\n // array('google_maps','jquery')\n // ); \n\t\t\t\t\t\t\n\t\t\t\twp_register_script('csl_script', SLPLUS_PLUGINURL.'/core/js/csl.js', array('jquery'));\n \n // Setup Email Form Script If Selected\n // \n //if (get_option(SLPLUS_PREFIX.'_email_form')==1) {\n // wp_register_script(\n // 'slplus_emailform',\n // SLPLUS_PLUGINURL.'/core/js/store-locator-emailform.js',\n // array('google_maps','slplus_map')\n // ); \n //} \n } \n }", "static function wp_enqueue_scripts() {\n global $slplus_plugin; \n $api_key= (isset($slplus_plugin) && $slplus_plugin->ok_to_show()) ?\n $slplus_plugin->driver_args['api_key'] :\n ''\n ;\n $force_load = (\n isset($slplus_plugin) ?\n $slplus_plugin->settings->get_item('force_load_js',true) :\n false\n );\n\n $sl_google_map_domain=(get_option('sl_google_map_domain','')!=\"\")?\n get_option('sl_google_map_domain') : \n \"maps.google.com\"; \n $sl_map_character_encoding='&oe='.get_option('sl_map_character_encoding','utf8'); \n\n //------------------------\n // Register our scripts for later enqueue when needed\n //\n //wp_register_script('slplus_functions',SLPLUS_PLUGINURL.'/core/js/functions.js');\n if (isset($api_key))\n {\n wp_enqueue_script(\n 'google_maps',\n \"http://$sl_google_map_domain/maps/api/js?v=3.9&amp;key=$api_key&amp;sensor=false\" //todo:character encoding ???\n //\"http://$sl_google_map_domain/maps?file=api&amp;v=2&amp;key=$api_key&amp;sensor=false{$sl_map_character_encoding}\"\n );\n }\n else {\n wp_enqueue_script(\n 'google_maps',\n \"http://$sl_google_map_domain/maps/api/js?v=3.9&amp;sensor=false\"\n );\n }\n\n wp_enqueue_script(\n 'csl_script',\n SLPLUS_PLUGINURL.'/core/js/csl.js',\n array('jquery'),\n false,\n !$force_load\n );\n\n //--------------------\n // Localize The Script\n //--------------------\n // Prepare some data for JavaScript injection...\n //\n $slplus_home_icon = get_option('sl_map_home_icon');\n $slplus_end_icon = get_option('sl_map_end_icon');\n $slplus_home_icon_file = str_replace(SLPLUS_ICONURL,SLPLUS_ICONDIR,$slplus_home_icon);\n $slplus_end_icon_file = str_replace(SLPLUS_ICONURL,SLPLUS_ICONDIR,$slplus_end_icon);\n $slplus_home_size=(function_exists('getimagesize') && file_exists($slplus_home_icon_file))?\n getimagesize($slplus_home_icon_file) :\n array(0 => 20, 1 => 34);\n $slplus_end_size =(function_exists('getimagesize') && file_exists($slplus_end_icon_file)) ?\n getimagesize($slplus_end_icon_file) :\n array(0 => 20, 1 => 34);\n // Lets get some variables into our script\n //\n $scriptData = array(\n 'debug_mode' => (get_option(SLPLUS_PREFIX.'-debugging') == 'on'),\n 'disable_scroll' => (get_option(SLPLUS_PREFIX.'_disable_scrollwheel')==1),\n 'disable_dir' => (get_option(SLPLUS_PREFIX.'_disable_initialdirectory' )==1),\n 'distance_unit' => esc_attr(get_option('sl_distance_unit'),'miles'),\n 'load_locations' => (get_option('sl_load_locations_default')==1),\n 'map_3dcontrol' => (get_option(SLPLUS_PREFIX.'_disable_largemapcontrol3d')==0),\n 'map_country' => SetMapCenter(),\n 'map_domain' => get_option('sl_google_map_domain','maps.google.com'),\n 'map_home_icon' => $slplus_home_icon,\n 'map_home_sizew' => $slplus_home_size[0],\n 'map_home_sizeh' => $slplus_home_size[1],\n 'map_end_icon' => $slplus_end_icon,\n 'map_end_sizew' => $slplus_end_size[0],\n 'map_end_sizeh' => $slplus_end_size[1],\n 'use_sensor' => (get_option(SLPLUS_PREFIX.\"_use_location_sensor\")==1),\n 'map_scalectrl' => (get_option(SLPLUS_PREFIX.'_disable_scalecontrol')==0),\n 'map_type' => get_option('sl_map_type','roadmap'),\n 'map_typectrl' => (get_option(SLPLUS_PREFIX.'_disable_maptypecontrol')==0),\n 'show_tags' => (get_option(SLPLUS_PREFIX.'_show_tags')==1),\n 'overview_ctrl' => get_option('sl_map_overview_control',0),\n 'use_email_form' => (get_option(SLPLUS_PREFIX.'_email_form')==1),\n 'use_pages_links' => ($slplus_plugin->settings->get_item('use_pages_links')=='on'),\n 'use_same_window' => ($slplus_plugin->settings->get_item('use_same_window')=='on'),\n 'website_label' => esc_attr(get_option('sl_website_label','Website')),\n 'zoom_level' => get_option('sl_zoom_level',4),\n 'zoom_tweak' => get_option('sl_zoom_tweak',1),\n );\n wp_localize_script('csl_script','slplus',$scriptData);\n wp_localize_script('csl_script','csl_ajax',array('ajaxurl' => admin_url('admin-ajax.php'), 'nonce' => wp_create_nonce('em')));\n }", "function aitAdminEnqueueScriptsAndStyles()\n{\n\t$mapLanguage = get_locale();\n\taitAddScripts(array(\n\t\t'ait-googlemaps-api' => array(\n\t\t\t\t\t\t\t\t\t //'file' => 'https://maps.google.com/maps/api/js?key=AIzaSyC62AaIu5cD1nwSCmyO4-33o3DjkFCH4KE&sensor=false&amp;language='.$mapLanguage,\n\t\t\t\t\t\t\t\t\t 'file' => 'https://maps.google.com/maps/api/js?key=AIzaSyBL0QWiORKMYd585E4qvcsHcAR1R7wmdiY&sensor=false&amp;language='.$mapLanguage,\n\t\t\t\t\t\t\t\t\t 'deps' => array('jquery')\n\t\t\t\t\t\t\t\t\t ),\n\t\t'ait-jquery-gmap3' => array('file' => THEME_JS_URL . '/libs/gmap3.min.js', 'deps' => array('jquery', 'ait-googlemaps-api')),\n\t));\n}", "function loadup_scripts() {\n $key = get_option('google_api_key');\n wp_enqueue_script( 'mapStyle-js', get_template_directory_uri().'/js/map-styles.js', array('jquery'), '1.0.0', true );\n if(is_front_page() || is_page_template('templates/template-property.php')){\n wp_enqueue_script( 'google-map-api', 'https://maps.googleapis.com/maps/api/js?key='.$key, array('jquery'), '1.0.0', true );\n //wp_enqueue_script( 'mapfull-js', get_template_directory_uri().'/js/home-map.js', array('jquery'), '1.0.0', true );\n \n }\n\n if(is_front_page()){\n wp_enqueue_script( 'mapfull-js', get_template_directory_uri().'/js/home-map.js', array('jquery'), '1.0.0', true );\n }\n\n if(is_page_template('templates/template-property.php')){\n wp_enqueue_script( 'singlemap-js', get_template_directory_uri().'/js/single-map.js', array('jquery'), '1.0.0', true );\n }\n //wp_enqueue_script( 'vue-js', '//cdnjs.cloudflare.com/ajax/libs/vue/2.4.4/vue.js', array('jquery'), '1.0.0', true );\n //wp_enqueue_script( 'smoothstate-js', '//cdnjs.cloudflare.com/ajax/libs/smoothState.js/0.7.2/jquery.smoothState.min.js', array('jquery'), '1.0.0', true );\n wp_enqueue_script( 'slick-js', get_template_directory_uri().'/js/slick.min.js', array('jquery'), '1.0.0', true );\n\twp_enqueue_script( 'theme-js', get_template_directory_uri().'/js/mesh.js', array('jquery'), '1.0.0', true );\n\n wp_enqueue_style( 'slick-css', get_template_directory_uri().'/css/slick.css', '1.0.0', true );\n wp_enqueue_style( 'slick-theme-css', get_template_directory_uri().'/css/slick-theme.css', '1.0.0', true ); \n}", "function scriptsCerrado() {\n\n wp_enqueue_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.css', array(), '1.0');\n wp_enqueue_style('cerrado-less', get_template_directory_uri() . '/css/cerrado.css', array(), '1.0');\n wp_enqueue_style('bootstrap-responsive', get_template_directory_uri() . '/css/responsive.css', array(), '1.0');\n\n\n wp_deregister_script('jquery');\n wp_register_script('jquery', '//ajax.googleapis.com/ajax/libs/jquery/1.9.1/jquery.min.js', array(), null, true);\n wp_register_script('jquery-ui', '//ajax.googleapis.com/ajax/libs/jqueryui/1.10.0/jquery-ui.min.js', array('jquery'), null, true);\n wp_register_script('google-jsapi', 'https://www.google.com/jsapi?key=AIzaSyDPBKirC56WlHkkHZyLMe10U8HT8TleA38', array(), null);\n wp_register_script('google-maps', '//maps.googleapis.com/maps/api/js?sensor=true&language=es&region=ES', array(), null, true);\n wp_register_script('google-maps-clusterer', get_template_directory_uri() . '/js/marker-clusterer-plus/markerclusterer_packed.js', array('google-maps'), '2.0.15', true);\n\n wp_enqueue_script('google-jsapi');\n wp_enqueue_script('google-maps');\n\n wp_enqueue_script('jquery');\n\n wp_enqueue_script('jquery-ui');\n\n wp_enqueue_script('google-maps-clusterer');\n\n wp_enqueue_script('hogan');\n\n wp_enqueue_script('bootstrap', get_template_directory_uri() . '/js/bootstrap.js', array('jquery'), '2.3.0', true);\n wp_enqueue_script('cerrado', get_template_directory_uri() . '/js/cerrado.js', array('jquery'), '1.24', true);\n\n //array para variables javascript\n $cprVars = array('is_single' => is_single() && get_post_type(), 'is_archive'=>is_archive(), 'siteUrl'=> site_url('/'));\n wp_localize_script('cerrado', 'cprVars', $cprVars);\n}", "function register_js_script() {\n wp_enqueue_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js'); \n \n wp_register_script('bootstrap-js', plugins_url(PLUGIN_FOLDER.'/assets/vendor/bootstrap-3.3.7-dist/js/bootstrap.min.js'));\n\n wp_register_script('jquery2-js', plugins_url(PLUGIN_FOLDER.'/assets/js/jquery2.js')); \n wp_register_script('prism-js', plugins_url(PLUGIN_FOLDER.'/assets/js/prism.js')); \n wp_register_script('underscore-js', plugins_url(PLUGIN_FOLDER.'/assets/js/underscore.js')); \n wp_register_script('moment-js', plugins_url(PLUGIN_FOLDER.'/assets/js/moment.js')); \n wp_register_script('clndr-js', plugins_url(PLUGIN_FOLDER.'/assets/js/clndr.js')); \n wp_register_script('site-js', plugins_url(PLUGIN_FOLDER.'/assets/js/site.js')); \n wp_register_script('main-js', plugins_url(PLUGIN_FOLDER.'/assets/js/main.js')); \n \n\n wp_enqueue_script('jquery-ui-autocomplete', '');\n wp_enqueue_script('main-js');\n wp_enqueue_script('bootstrap-js');\n wp_enqueue_script('jquery2-js');\n wp_enqueue_script('prism-js'); \n wp_enqueue_script('underscore-js'); \n wp_enqueue_script('moment-js'); \n wp_enqueue_script('clndr-js'); \n wp_enqueue_script('site-js'); \n \n}", "function cinerama_edge_admin_scripts_init() {\n\t\t\n\t\t//This part is required for field type address\n\t\t$enable_google_map_in_admin = apply_filters('cinerama_edge_filter_google_maps_in_backend', false);\n\t\tif($enable_google_map_in_admin) {\n\t\t\t//include google map api script\n\t\t\t$google_maps_api_key = cinerama_edge_options()->getOptionValue( 'google_maps_api_key' );\n\t\t\t$google_maps_extensions = '';\n\t\t\t$google_maps_extensions_array = apply_filters( 'cinerama_edge_filter_google_maps_extensions_array', array() );\n\t\t\tif ( ! empty( $google_maps_extensions_array ) ) {\n\t\t\t\t$google_maps_extensions .= '&libraries=';\n\t\t\t\t$google_maps_extensions .= implode( ',', $google_maps_extensions_array );\n\t\t\t}\n\t\t\tif ( ! empty( $google_maps_api_key ) ) {\n wp_enqueue_script( 'edgtf-admin-maps', '//maps.googleapis.com/maps/api/js?key=' . esc_attr( $google_maps_api_key ) . $google_maps_extensions, array(), false, true );\n wp_enqueue_script( 'geocomplete', get_template_directory_uri() . '/framework/admin/assets/js/jquery.geocomplete.min.js', array('edgtf-admin-maps'), false, true );\n\t\t\t}\n\t\t}\n\n\t\twp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/framework/admin/assets/js/bootstrap.min.js', array(), false, true );\n\t\twp_enqueue_script( 'bootstrap-select', get_template_directory_uri() . '/framework/admin/assets/js/bootstrap-select.min.js', array(), false, true );\n\t\twp_enqueue_script( 'select2', get_template_directory_uri() . '/framework/admin/assets/js/select2.min.js', array(), false, true );\n\t\twp_enqueue_script( 'edgtf-ui-admin', get_template_directory_uri() . '/framework/admin/assets/js/edgtf-ui/edgtf-ui.js', array(), false, true );\n\n\n\t\twp_enqueue_style( 'font-awesome', get_template_directory_uri() . '/framework/admin/assets/css/font-awesome/css/font-awesome.min.css' );\n\t\twp_enqueue_style( 'select2', get_template_directory_uri() . '/framework/admin/assets/css/select2.min.css' );\n\n\t\t/**\n\t\t * @see CineramaEdgeClassSkinAbstract::registerScripts - hooked with 10\n\t\t * @see CineramaEdgeClassSkinAbstract::registerStyles - hooked with 10\n\t\t */\n\t\tdo_action( 'cinerama_edge_action_admin_scripts_init' );\n\t}", "function onetyone_scripts() {\n wp_enqueue_script('wpestate_ajaxcalls', '/wp-content/themes/onetyone'.'/js/ajaxcalls.js',array('jquery'), '1.0', true);\n wp_enqueue_script('wpestate_property', '/wp-content/themes/onetyone'.'/js/property.js',array('jquery'), '1.0', true);\n if(is_page(2081) || is_page(254))\n {\n // wp_enqueue_script( 'map-script', 'https://maps.googleapis.com/maps/api/js?key=AIzaSyBN2tzJmAQ_r3QTeWKT23Mw3rB-v5Y5zBU', array(), null, true );\n wp_enqueue_script( 'map-js-script', '/wp-content/themes/onetyone' . '/js/map.js', array(), null, true );\n }\n}", "function ale_map_load_scripts() {\n wp_register_script( 'google-maps-api', 'http://maps.google.com/maps/api/js?sensor=false' );\n }", "function upcode_loadJS(){\n if (!is_admin()){\n\t\t// desregistrando o jquery nativo e registrando o do CDN do Google.\n\t\twp_deregister_script('jquery');\n\t\twp_register_script('jquery', '//cdnjs.cloudflare.com/ajax/libs/jquery/3.2.1/jquery.min.js', false, '3.2.1');\n\t\twp_enqueue_script('jquery');\n\n\t\t$js = get_template_directory_uri() . '/assets/js/';\n\t\twp_enqueue_script('propper',\t\t\t\t'//cdnjs.cloudflare.com/ajax/libs/popper.js/1.11.0/umd/popper.min.js', ['jquery']);\n\t\twp_enqueue_script('bootstrap-min',\t'//maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/js/bootstrap.min.js', ['jquery','propper']);\n\t\twp_enqueue_script('fancybox',\t\t\t\t'//cdn.rawgit.com/fancyapps/fancybox/master/dist/jquery.fancybox.min.js', ['jquery']);\n\t\twp_enqueue_script('slick',\t\t\t\t\t'//cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.7.1/slick.min.js', ['jquery']);\n\t\twp_enqueue_script('fontawesome',\t\t'//use.fontawesome.com/releases/v5.0.8/js/all.js', ['jquery']);\n\t\twp_enqueue_script('v4-shims',\t\t\t\t'//use.fontawesome.com/releases/v5.0.8/js/v4-shims.js', ['jquery']);\n\n\t\twp_enqueue_script('offcanvas',\t\t$js . 'bootstrap.offcanvas.min.js', ['jquery']);\n\t\twp_enqueue_script('acf-maps', \t\t$js . 'maps.js', ['jquery']);\n\t\twp_enqueue_script('mask', \t\t\t\t$js . 'jquery.mask.min.js', ['jquery']);\n\t\twp_enqueue_script('codigo', \t\t\t$js . 'codigo.js', ['jquery']);\n }\n}", "public function enqueue()\n {\n wp_enqueue_script('google-maps', '//maps.googleapis.com/maps/api/js?key=' . $this->apiKey, array(), '3', true);\n wp_enqueue_script('google-map-init');\n }", "function flexiauto_scripts_loader() {\n\t\t/* Load custom styles */\n\t\twp_enqueue_style('reset', TPL_DIR . '/assets/css/vendor/reset.css');\n\t\twp_enqueue_style('bootstrap-styles', TPL_DIR . '/assets/css/vendor/bootstrap.min.css');\n\t\twp_enqueue_style('flexi-styles', TPL_DIR . '/assets/css/flexi.min.css');\n\n\t\t/* Load custom scripts */\n\t\twp_deregister_script('jquery');\n\t\twp_register_script('jquery', TPL_DIR . '/assets/js/vendor/jquery.min.js', array(), false, true);\n\t\twp_enqueue_script('jquery');\n\n\t\twp_enqueue_script('bootstrap-scripts', TPL_DIR . '/assets/js/vendor/bootstrap.min.js', array(), false, true);\n\t\twp_enqueue_script('nicescroll', TPL_DIR . '/assets/js/vendor/jquery.nicescroll.min.js', array(), false, true);\n\t\twp_enqueue_script('jquery-validate', TPL_DIR . '/assets/js/vendor/jquery.validate.min.js', array(), false, true);\n\t\twp_enqueue_script('match-height', TPL_DIR . '/assets/js/vendor/jquery.matchHeight.min.js', array(), false, true);\n\t\twp_enqueue_script('flexi-scripts', TPL_DIR . '/assets/js/flexi.min.js', array(), false, true);\n\n\t}", "public static function enqueues() {\n\t\twp_enqueue_script( 'wc-country-select' ) ;\n\t\twp_enqueue_script( 'wc-address-i18n' ) ;\n\t}", "function wpg_enqueue() {\n\n //css\n wp_enqueue_style( 'wpg-style', get_stylesheet_uri() );\n wp_enqueue_style( 'ie8', get_stylesheet_directory_uri() . \"/css/ie8.css\");\n wp_style_add_data( 'ie8', 'conditional', 'lt IE 9' );\n\n //deregister\n wp_deregister_script( 'jquery' );\n\n //register\n wp_register_script( 'mapa-api', add_query_arg( 'key', get_theme_mod('wpg_map_apikey', ''), 'https://maps.googleapis.com/maps/api/js?'));\n wp_register_script('google-map', get_template_directory_uri() . '/js/mapa.min.js','', '1.0.1', true);\n\n //enqueue\n wp_enqueue_script('jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js');\n\n // lt IE 9\n wp_enqueue_script( 'html5', get_template_directory_uri() . '/js/assets/html5shiv.min.js', array('jquery'), '20120206', false );\n wp_script_add_data( 'html5', 'conditional', 'lt IE 9' );\n\n wp_enqueue_script( 'imgGallery', get_template_directory_uri() . '/js/assets/imgGallery.min.js', array('jquery'), '1.0.1', true );\n wp_enqueue_script( 'slick', get_template_directory_uri() . '/js/assets/slick.min.js', array('jquery'), '1.0.1', true );\n\n wp_enqueue_script( 'wpg-main-js', get_template_directory_uri() . '/js/main.min.js', array('jquery'), '1.0.1', true );\n\n wp_localize_script( 'wpg-main-js', 'datalanuge', array(\n 'next' => __('Previous Image (left arrow key)', 'wpg_theme'),\n 'prev' => __('Next Image (right arrow key)', 'wpg_theme'),\n 'of'=> __('of','wpg_theme'),\n 'close' => __('Close (Escape key)', 'wpg_theme'),\n 'load' => __('Loading ...', 'wpg_theme'),\n 'image' => __('Image', 'wpg_theme'),\n 'error_image' => __('it cannot be loaded.', 'wpg_theme'),\n )\n);\n\n// Google map\nif (get_theme_mod('wpg_contact_maps') == true){\n wp_enqueue_script('mapa-api');\n wp_enqueue_script('google-map');\n}\n\n// Comment\nif ( is_single() && comments_open() && get_option( 'thread_comments' ) ) {\n wp_enqueue_script( 'comment-reply' );\n}\n}", "function WBootStrap_load_js(){\n\t$JS_Files = array(\n\t\t'prettify' => 'google-code-prettify/prettify.js',\n\t\t'transition' => 'bootstrap-transition.js',\n\t\t'alert' => 'bootstrap-alert.js',\n\t\t'modal' => 'bootstrap-modal.js',\n\t\t'dropdown' => 'bootstrap-dropdown.js',\n\t\t'scrollspy' => 'bootstrap-scrollspy.js',\n\t\t'tab' => 'bootstrap-tab.js',\n\t\t'tooltip' => 'bootstrap-tooltip.js',\n\t\t'popover' => 'bootstrap-popover.js',\n\t\t'button' => 'bootstrap-button.js',\n\t\t'collapse' => 'bootstrap-collapse.js',\n\t\t'carousel' => 'bootstrap-carousel.js',\n\t\t'typeahead' => 'bootstrap-typeahead.js',\n\t);\n\t$JS_Files = apply_filters('WBootStrap_js_enqueue_filter',$JS_Files);\n\tforeach ($JS_Files as $key => $value) {\n\t\twp_enqueue_script($key, get_template_directory_uri().'/assets/js/'.$value, array('jquery'),theme_version, true );\n\t}\n\t\n\t/*\n\t\t//to load manually each script use:\n\twp_enqueue_script('prettify', get_template_directory_uri().'/assets/js/google-code-prettify/prettify.js', array('jquery'),theme_version, true );\n wp_enqueue_script('transition', get_template_directory_uri().'/assets/js/bootstrap-transition.js', array('jquery'),theme_version, true );\n wp_enqueue_script('alert', get_template_directory_uri().'/assets/js/bootstrap-alert.js', array('jquery'),theme_version, true );\n wp_enqueue_script('modal', get_template_directory_uri().'/assets/js/bootstrap-modal.js', array('jquery'),theme_version, true );\n wp_enqueue_script('dropdown', get_template_directory_uri().'/assets/js/bootstrap-dropdown.js', array('jquery'),theme_version, true );\n wp_enqueue_script('scrollspy', get_template_directory_uri().'/assets/js/bootstrap-scrollspy.js', array('jquery'),theme_version, true );\n wp_enqueue_script('tab', get_template_directory_uri().'/assets/js/bootstrap-tab.js', array('jquery'),theme_version, true );\n wp_enqueue_script('tooltip', get_template_directory_uri().'/assets/js/bootstrap-tooltip.js', array('jquery'),theme_version, true );\n wp_enqueue_script('popover', get_template_directory_uri().'/assets/js/bootstrap-popover.js', array('tooltip.js'),theme_version, true );\n wp_enqueue_script('button', get_template_directory_uri().'/assets/js/bootstrap-button.js', array('jquery'),theme_version, true );\n wp_enqueue_script('collapse', get_template_directory_uri().'/assets/js/bootstrap-collapse.js', array('jquery'),theme_version, true ); \n wp_enqueue_script('carousel', get_template_directory_uri().'/assets/js/bootstrap-carousel.js', array('jquery'),theme_version, true ); \n wp_enqueue_script('typeahead', get_template_directory_uri().'/assets/js/bootstrap-typeahead.js', array('jquery'),theme_version, true );\n */\n}", "function mpfy_enqueue_gmaps() {\n\twp_dequeue_script('google_map_api');\n\twp_dequeue_script('google-maps');\n\twp_dequeue_script('cspm_google_maps_api');\n\twp_dequeue_script('gmaps');\n\twp_deregister_script('gmaps');\n\n\t// load our own version of gmaps as we require the geometry library\n\t$api_key = carbon_get_theme_option('mpfy_google_api_key');\n\t$api_key_param = $api_key ? '&key=' . $api_key : '';\n\twp_enqueue_script('gmaps', '//maps.googleapis.com/maps/api/js?libraries=geometry' . $api_key_param, array(), false, true);\n}", "function load_js_css() {\n\n\t\t\twp_register_script( 'fontawesome-all', get_stylesheet_directory_uri() . '/js/fontawesome-all.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'owl', get_stylesheet_directory_uri() . '/js/owl.carousel.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'selectric', get_stylesheet_directory_uri() . '/js/jquery.selectric.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'select', get_stylesheet_directory_uri() . '/js/select.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'jquery-ui', get_stylesheet_directory_uri() . '/js/jquery-ui.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'tab_menu', get_stylesheet_directory_uri() . '/js/tab_menu.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'aos', get_stylesheet_directory_uri() . '/js/aos.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'rangeslider', get_stylesheet_directory_uri() . '/js/rangeslider.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'bootstrap', get_stylesheet_directory_uri() . '/js/bootstrap.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'easymap', get_stylesheet_directory_uri() . '/js/easymap.plugin.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'markerclusterer', get_stylesheet_directory_uri() . '/js/markerclusterer.min.js', array(), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'customscrollbar', get_stylesheet_directory_uri() . '/js/jquery.mCustomScrollbar.concat.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'ddslick', get_stylesheet_directory_uri() . '/js/jquery.ddslick.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\t\t\twp_register_script( 'project045-main', get_stylesheet_directory_uri() . '/js/main.min.js', array( 'jquery' ), Project045_Definitions::$scripts_version, true );\n\n\t\t\twp_enqueue_script( 'fontawesome-all' );\n\t\t\twp_enqueue_script( 'owl' );\n\t\t\twp_enqueue_script( 'selectric' );\n\t\t\twp_enqueue_script( 'select' );\n\t\t\twp_enqueue_script( 'jquery-ui' );\n\t\t\twp_enqueue_script( 'tab_menu' );\n\t\t\twp_enqueue_script( 'aos' );\n\t\t\twp_enqueue_script( 'rangeslider' );\n\t\t\twp_enqueue_script( 'bootstrap' );\n\t\t\twp_enqueue_script( 'easymap' );\n\t\t\twp_enqueue_script( 'markerclusterer' );\n\t\t\twp_enqueue_script( 'customscrollbar' );\n\t\t\twp_enqueue_script( 'ddslick' );\n\t\t\twp_enqueue_script( 'project045-main' );\n\n\t\t}", "function plugin_frontend_scripts_styles()\r\r\n{\r\r\n $options = get_option('oneclick');\r\r\n $gmap_iconizer_apikey = $options['gmap_iconizer_apikey'];\r\r\n if ($gmap_iconizer_apikey != \"\") {\r\r\n wp_enqueue_script('gmap_main_js', 'https://maps.googleapis.com/maps/api/js?v=3key=' . $gmap_iconizer_apikey, '', '', false);\r\r\n }\r\r\n else {\r\r\n wp_enqueue_script('sensor_js', 'http://maps.googleapis.com/maps/api/js?sensor=false', '', false);\r\r\n }\r\r\n}", "function wpeHeaderScripts()\n{\n wp_register_script('jquery', '//cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js', array(), '3.4.1');\n wp_enqueue_script('jquery');\n\n wp_register_script('popper', '//cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js', array(), '1.14.7', true);\n wp_enqueue_script('popper');\n\n wp_register_script('bootstrap', '//cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.min.js', array(), '4.3.1', true);\n wp_enqueue_script('bootstrap');\n\n wp_register_script('maps', 'https://maps.googleapis.com/maps/api/js?key=AIzaSyCZF31krTQH_5QnEpdIsEgmsBV-Iy884rE', array(), '7.7.7', true);\n wp_enqueue_script('maps');\n\n // wp_register_script('vue', '//cdnjs.cloudflare.com/ajax/libs/vue/2.6.10/vue.min.js', array(), '2.6.10');\n // wp_enqueue_script('vue');\n\n wp_register_script('selectric', get_template_directory_uri() . '/js/jquery.selectric.js', array(), '1.0.0', true);\n wp_enqueue_script('selectric');\n\n // wp_register_script('owl.carousel', get_template_directory_uri() . '/js/owl.carousel.js', array(), '2.3.4', true);\n wp_register_script('owl.carousel', '//cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/owl.carousel.min.js', array(), '2.3.4', true);\n wp_enqueue_script('owl.carousel');\n\n // Load footer scripts (footer.php)\n wp_register_script('wpeScripts', get_template_directory_uri() . '/js/scripts.js', array(), '1.7.0', true);\n wp_enqueue_script('wpeScripts');\n wp_localize_script('wpeScripts', 'adminAjax', array(\n 'ajaxurl' => admin_url('admin-ajax.php'),\n 'templatePath' => get_template_directory_uri(),\n 'posts_per_page' => get_option('posts_per_page'),\n 'loadingmessage' => __('Sending user info, please wait...')\n ));\n}", "function register_my_jscripts() {\n\n \t wp_register_script( 'googleapi', 'https://maps.googleapis.com/maps/api/js?libraries=geometry&key=AIzaSyA21ZwPY6xqz4gvkdil2wGGBRWSGEayq78', array( 'jquery' ), NULL, false );wp_enqueue_script( 'googleapi' );\n\n\n\t wp_register_script( 'niceScroll', THEME_DIR .'/js/jquery.nicescroll.min.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'niceScroll' );\n \t wp_register_script( 'fancyboxm', THEME_DIR .'/js/fancybox/jquery.mousewheel-3.0.6.pack.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'fancyboxm' );\n \t wp_register_script( 'fancybox', THEME_DIR .'/js/fancybox/jquery.fancybox.pack.js?v=2.1.5', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'fancybox' );\n \t wp_register_script( 'moment', THEME_DIR .'/js/moment.min.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'moment' );\n \t wp_register_script( 'calendar', THEME_DIR .'/js/fullcalendar.min.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'calendar' );\n \t if(is_rtl()){\n \t \t\twp_register_script( 'hecalendar', THEME_DIR .'/js/he.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'hecalendar' );\n \t }\n\t wp_register_script( 'swiper', THEME_DIR .'/js/swiper.min.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'swiper' );\n\n\t\twp_register_script(\"addthis\",\"//s7.addthis.com/js/300/addthis_widget.js#pubid=ra-57e21979bdebcfe3\",array('jquery'),NULL,true);\n\t\twp_enqueue_script( 'addthis' );\n\n\t wp_register_script( 'functions', THEME_DIR .'/js/functions.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'functions' );\n\t wp_register_script( 'accessibility', THEME_DIR .'/js/accessibility.js', array( 'jquery' ), NULL, true ); wp_enqueue_script( 'accessibility' );\n\n\t if( is_archive('event') )\n\t \t\twp_localize_script( 'functions', 'allPostsObject', get_all_events() );\n\n\t}", "function mocca_script_files() {\n\n wp_deregister_script('jquery'); // Remove Registeration Old JQuery\n wp_register_script('jquery', includes_url('/js/jquery/jquery.js'), false, '', true); // Register a New JQuery in Footer\n wp_enqueue_script('jquery'); // Enqueue New JQuery\n wp_enqueue_script('popper-js', get_template_directory_uri() . '/js/popper.min.js', array(), false, true);\n wp_enqueue_script('bootstrap-js', get_template_directory_uri() . '/js/bootstrap.min.js', array(), false, true);\n }", "function enqueue_javascript() {\n\n // TODO : only if needed for cities drop down\n //\n if ( file_exists( $this->addon->dir . 'include/widgets/slp_widgets.js' ) ) {\n $this->js_settings['ajaxurl'] = admin_url( 'admin-ajax.php' );\n wp_enqueue_script( $this->addon->slug . '_widgets' , $this->addon->url . '/include/widgets/slp_widgets.js' , array( 'jquery' ) );\n wp_localize_script( $this->addon->slug . '_widgets' , 'slp_experience' , $this->js_settings );\n }\n }", "function pegasus_child_bootstrap_js() {\r\n\t\t\r\n\t\twp_enqueue_script( 'pegasus_custom_js', get_stylesheet_directory_uri() . '/js/pegasus-custom.js', array(), '', true );\r\n\t\t\r\n\t\t//wp_enqueue_script( 'matchHeight_js', get_stylesheet_directory_uri() . '/js/jquery.matchHeight-min.js', array(), '', true );\r\n\t\t\r\n\t\t\r\n\t}", "function ajout_scripts() {\n wp_register_script('bootstrap_script', get_template_directory_uri() . '/assets/scripts/bootstrap.min.js', array('jquery'),'1.1', true);\n wp_enqueue_script('bootstrap_script');\n \n wp_register_script('main_js', get_template_directory_uri() . '/assets/scripts/main.js', array('jquery'),'1.1', true);\n wp_enqueue_script('main_js');\n \n // enregistrement des styles\n wp_register_style( 'google_font', 'https://fonts.googleapis.com/css?family=Anton|Oxygen' );\n wp_enqueue_style( 'google_font' );\n \n wp_register_style( 'bootstrap_style', get_template_directory_uri() . '/assets/styles/bootstrap.min.css' );\n wp_enqueue_style( 'bootstrap_style' );\n \n // enregistrement des styles\n wp_register_style( 'main_style', get_template_directory_uri() . '/assets/styles/main.css' );\n wp_enqueue_style( 'main_style' );\n}", "public function scripts() {\n // Make sure scripts are only added once via shortcode\n $this->add_scripts = true;\n\n wp_register_script('jquery-form-validation', SWPM_FORM_BUILDER_URL . '/js/jquery.validate.min.js', array('jquery'), '1.9.0', true);\n wp_register_script('swpm-form-builder-validation', SWPM_FORM_BUILDER_URL . \"/js/swpm-validation$this->load_dev_files.js\", array('jquery', 'jquery-form-validation'), '20140412', true);\n wp_register_script('swpm-form-builder-metadata', SWPM_FORM_BUILDER_URL . '/js/jquery.metadata.js', array('jquery', 'jquery-form-validation'), '2.0', true);\n wp_register_script('swpm-ckeditor', SWPM_FORM_BUILDER_URL . '/js/ckeditor/ckeditor.js', array('jquery'), '4.1', true);\n\n wp_enqueue_script('jquery-form-validation');\n wp_enqueue_script('swpm-form-builder-validation');\n wp_enqueue_script('swpm-form-builder-metadata');\n\n $locale = get_locale();\n $translations = array(\n 'cs_CS', // Czech\n 'de_DE', // German\n 'el_GR', // Greek\n 'en_US', // English (US)\n 'en_AU', // English (AU)\n 'en_GB', // English (GB)\n 'es_ES', // Spanish\n 'fr_FR', // French\n 'he_IL', // Hebrew\n 'hu_HU', // Hungarian\n 'id_ID', // Indonseian\n 'it_IT', // Italian\n 'ja_JP', // Japanese\n 'ko_KR', // Korean\n 'nl_NL', // Dutch\n 'pl_PL', // Polish\n 'pt_BR', // Portuguese (Brazilian)\n 'pt_PT', // Portuguese (European)\n 'ro_RO', // Romanian\n 'ru_RU', // Russian\n 'sv_SE', // Swedish\n 'tr_TR', // Turkish\n 'zh_CN', // Chinese\n 'zh_TW', // Chinese (Taiwan)\n );\n\n // Load localized vaidation and datepicker text, if translation files exist\n if (in_array($locale, $translations)) {\n wp_register_script('swpm-validation-i18n', SWPM_FORM_BUILDER_URL . \"/js/i18n/validate/messages-$locale.js\", array('jquery-form-validation'), '1.9.0', true);\n wp_register_script('swpm-datepicker-i18n', SWPM_FORM_BUILDER_URL . \"/js/i18n/datepicker/datepicker-$locale.js\", array('jquery-ui-datepicker'), '1.0', true);\n\n wp_enqueue_script('swpm-validation-i18n');\n }\n // Otherwise, load English translations\n else {\n wp_register_script('swpm-validation-i18n', SWPM_FORM_BUILDER_URL . \"/js/i18n/validate/messages-en_US.js\", array('jquery-form-validation'), '1.9.0', true);\n wp_register_script('swpm-datepicker-i18n', SWPM_FORM_BUILDER_URL . \"/js/i18n/datepicker/datepicker-en_US.js\", array('jquery-ui-datepicker'), '1.0', true);\n\n wp_enqueue_script('swpm-validation-i18n');\n }\n }", "function bootstrap_scripts() {\n\t\t\tif ( ! is_admin() ) {\n\n\t\t\t\t// Twitter Bootstrap CSS.\n\t\t\t\twp_register_style( 'bootstrap', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css', '', null, 'all' );\n\t\t\t\twp_enqueue_style( 'bootstrap' );\n\n\t\t\t\t// Load jQuery.\n\t\t\t\twp_enqueue_script( 'jquery' );\n\n\t\t\t\t// Twitter Bootstrap Javascript.\n\t\t\t\twp_register_script( 'bootstrap', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js', 'jquery', null, true );\n\t\t\t\twp_enqueue_script( 'bootstrap' );\n\n\t\t\t\t// Google Webfont.\n\t\t\t\twp_register_script( 'webfont', 'https://ajax.googleapis.com/ajax/libs/webfont/1.6.26/webfont.js', null, null, true );\n\t\t\t\twp_enqueue_script( 'webfont' );\n\n\t\t\t\t// Load Font Awesome via Google Webfont.\n\t\t\t\twp_add_inline_script( 'webfont', 'WebFont.load({custom:{families:[\"font-awesome\"],urls:[\"https://maxcdn.bootstrapcdn.com/font-awesome/4.6.3/css/font-awesome.min.css\"]}});' );\n\n\t\t\t}\n\t\t}", "function jk_scripts(){\n\twp_register_script('materialize-js',get_stylesheet_directory_uri().'/js/bootstrap.min.js',array('jquery'),true);\n\twp_enqueue_script('materialize-js');\n\twp_register_script('myjs',get_stylesheet_directory_uri().'/js/myjs.js',array('jquery'),true);\n\twp_enqueue_script('myjs');\n}", "public function enqueue_scripts($hook) {\n $screen = get_current_screen();\n switch(true){\n case ('wpcf7_contact_form' == $screen->post_type && 'post' == $screen->base):\n case ('toplevel_page_wpcf7' == $hook || 'contact_page_wpcf7-new' == $hook):\n\n $plugin_dir = plugin_dir_url( __DIR__ );\n $google_map_api_key = get_option('cf7_googleMap_api_key','');\n $airplane_mode = true;\n if(! class_exists( 'Airplane_Mode_Core' ) || !Airplane_Mode_Core::getInstance()->enabled()){\n $scheme = 'http';\n if(is_ssl()) $scheme = 'https';\n wp_enqueue_script( 'google-maps-api-admin', $scheme.'://maps.google.com/maps/api/js?key='. $google_map_api_key, array( 'jquery' ), null, true );\n $airplane_mode = false;\n }\n wp_enqueue_script( 'gmap3-admin', $plugin_dir . '/assets/gmap3/gmap3.min.js', array( 'jquery', 'google-maps-api-admin' ), $this->version, true );\n \twp_enqueue_script( 'arrive-js', $plugin_dir . '/assets/arrive/arrive.min.js', array( 'jquery' ), $this->version, true );\n \twp_enqueue_script( $this->plugin_name, $plugin_dir . '/admin/js/admin_settings_map.js', array( 'jquery' ), $this->version, true );\n wp_localize_script( $this->plugin_name, 'cf7_map_admin_settings', array(\n \t\t'theme_dir' \t\t\t=> plugin_dir_url( __DIR__ ),\n 'marker_lat' => '12.007089',\n 'marker_lng' => '79.810600',\n 'map_zoom' => '3',\n 'airplane'=>$airplane_mode\n \t) );\n break;\n }\n\t}", "function bootstrap_theme_enqueue_scripts() {\n $template_url = get_template_directory_uri();\n\n // jQuery.\n wp_enqueue_script('jquery');\n\n // JS \n wp_enqueue_script('jquery-script', $template_url . '/js/jquery-1.10.2.js', array('jquery'), null, true);\n wp_enqueue_script('bootstrap-script', $template_url . '/js/bootstrap.min.js', array('jquery'), null, true);\n wp_enqueue_script('wow-script', $template_url . '/js/wow.js', array('jquery'), null, true);\n wp_enqueue_script('jquery-ui', $template_url . '/js/jquery-ui.min.js', array('jquery'), null, true);\n wp_enqueue_script('waypoints', $template_url . '/js/waypoints.min.js', array('jquery'), null, true);\n wp_enqueue_script('magnific-popup', $template_url . '/js//jquery.magnific-popup.min.js', array('jquery'), null, true);\n wp_enqueue_script('isotope', $template_url . '/js/isotope.pkgd.min.js', array('jquery'), null, true);\n wp_enqueue_script('custom', $template_url . '/js/custom.js', array('jquery'), null, true);\n\n // CSS\n wp_enqueue_style('bootstrap-style', $template_url . '/css/bootstrap.min.css', array(), null, 'all');\n wp_enqueue_style('animate', $template_url . '/css/animate.css', array(), null, 'all');\n wp_enqueue_style('magnific-popup-css', $template_url . '/css/magnific-popup.css', array(), null, 'all');\n wp_enqueue_style('font-awesome', $template_url . '/font-awesome/css/font-awesome.min.css', array(), null, 'all');\n wp_enqueue_style('preloader', $template_url . '/css/preloader.css', array(), null, 'all');\n\n //Main Style\n wp_enqueue_style('main-style', get_stylesheet_uri());\n\n //Google Fonts\n wp_enqueue_style('google-fonts', '//fonts.googleapis.com/css?family=Arvo|Oswald:300|Open+Sans:300,400,700');\n\n // Load Thread comments WordPress script.\n if (is_singular() && get_option('thread_comments')) {\n wp_enqueue_script('comment-reply');\n }\n}", "function themesflat_shortcode_register_assets() {\t\t\n\t\twp_enqueue_style( 'vc_extend_shortcode', plugins_url('assets/css/shortcodes.css', __FILE__), array() );\t\n\t\twp_enqueue_style( 'vc_extend_style', plugins_url('assets/css/shortcodes-3rd.css', __FILE__),array() );\n\t\twp_register_script( 'themesflat-carousel', plugins_url('assets/3rd/owl.carousel.js', __FILE__), array(), '1.0', true );\n\t\twp_register_script( 'themesflat-flexslider', plugins_url('assets/3rd/jquery.flexslider-min.js', __FILE__), array(), '1.0', true );\t\t\n\t\twp_register_script( 'themesflat-manific-popup', plugins_url('assets/3rd/jquery.magnific-popup.min.js', __FILE__), array(), '1.0', true );\t\t\n\t\twp_register_script( 'themesflat-counter', plugins_url('assets/3rd/jquery-countTo.js', __FILE__), array(), '1.0', true );\n\t\twp_enqueue_script( 'flat-shortcode', plugins_url('assets/js/shortcodes.js', __FILE__), array(), '1.0', true );\n\t\twp_register_script( 'themesflat-google', 'https://maps.googleapis.com/maps/api/js?key=AIzaSyCIm1AxfRgiI_w36PonGqb_uNNMsVGndKo&v=3.7', array(), '1.0', true );\n\t\twp_register_script( 'themesflat-gmap3', plugins_url('assets/3rd/gmap3.min.js', __FILE__), array(), '1.0', true );\t\n\t}", "function pramble_script_enqueue() {\n\t\t\t\t// wp_enqueue_script( 'jquery', get_template_directory_uri() . '/bootstrap/js/jquery.min.js', array(), '1.0.0', true);\n\t\t\t\t// wp_enqueue_script( 'customjs1', get_template_directory_uri() . '/bootstrap/js/bootstrap.min.js/', array(), '1.0.0', true );\n\t\t\t\t// wp_enqueue_script( 'ieviewportbugworkaround', get_template_directory_uri() . '/assets/js/ie10-viewport-bug-workaround.js', array(), null, true);\n\t\t\t\t// wp_enqueue_style( 'customstyle', get_template_directory_uri() . '/css/pramble.css', array(), '1.0.0', 'all' ); \n\t\t\t\t// wp_enqueue_style( 'customstyle2', get_template_directory_uri() . '/bootstrap/css/bootstrap.css', array(), '1.0.0', 'all' );\n\t\t\t\t// //wp_enqueue_style( 'customstyle1', get_template_directory_uri() . '/css/foundation.css', array(), '6.0.0', 'all' );\n\t\t\t\t// //wp_enqueue_script( 'customjs', get_template_directory_uri() . '/js/pramble.js/', array(), '1.0.0', true );\n\n\t\t\t // enqueue the scripts for the site//\n\t\t\t\t\t\twp_deregister_script( 'jquery' );\n\t\t\t wp_enqueue_script( 'jquery', get_template_directory_uri() . '/assets/js/jquery.min.js', false, null, true);// the true arg tells wordpress to load the js in before the closing head tag\n\n\t\t\t wp_deregister_script( 'bootstrap' );\n\t\t\t wp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/bootstrap/js/bootstrap.min.js', false, null, true);\n\n\t\t\t wp_deregister_script( 'ieviewportbugworkaround' );\n\t\t\t wp_enqueue_script( 'ieviewportbugworkaround', get_template_directory_uri() . '/assets/js/ie10-viewport-bug-workaround.js', false, null, true);\n\n\t \n\n\t wp_deregister_style( 'bootstrap' );\n\t wp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/bootstrap/css/bootstrap.css', false, null, 'all');\n\t wp_enqueue_style( 'customstyle', get_template_directory_uri() . '/css/pramble.css', array(), '1.0.0', 'all' ); \n\t\t\t\t\n\t\t}", "function cnew_load_scripts() {\r\n wp_register_script( 'cnew-js-admin', CNEW_PLUGIN_URL . 'includes/js/cne-workshops-admin.js', array( 'jquery', 'jquery-ui-core', 'jquery-ui-datepicker', 'cnew-js-jquery-validate' ), '', true );\r\n wp_register_script( 'cnew-js-jquery-mask', CNEW_PLUGIN_URL . 'includes/js/jquery.maskedinput.min.js', array( 'jquery' ), '', true );\r\n wp_register_script( 'cnew-js-jquery-validate', CNEW_PLUGIN_URL . 'includes/js/jquery.validate.min.js', array( 'jquery' ), '', true );\r\n wp_register_style( 'cnew-css-admin', CNEW_PLUGIN_URL . 'includes/css/cne-workshops-admin.css' );\r\n wp_register_style( 'cnew-css-jquery', 'https://ajax.googleapis.com/ajax/libs/jqueryui/1.12.1/themes/smoothness/jquery-ui.css' );\r\n\r\n wp_enqueue_script( 'cnew-js-admin' );\r\n wp_enqueue_script( 'cnew-js-jquery-mask' );\r\n wp_enqueue_style( 'cnew-js-jquery-validate' );\r\n wp_enqueue_style( 'cnew-css-admin' );\r\n wp_enqueue_style( 'cnew-css-jquery' );\r\n }", "function enqueue_script() {\n wp_enqueue_script('jquery-fallback', includes_url() . '/js/jquery/jquery.js');\n wp_enqueue_script('resform-main', $this->assetsUrl . 'js/main.js', array('jquery-fallback'), true);\n }", "function custom_scripts_loading() {\n // Deregister the included library\n wp_deregister_script( 'jquery' );\n \n // Register the library again from Google's CDN\n wp_register_script( 'jquery', 'https://code.jquery.com/jquery-1.11.2.min.js', array(), null, false );\n\n // Register custom scripts\n wp_register_script( 'bootstrap', get_template_directory_uri() . '/js/vendor/bootstrap.min.js', array( 'jquery' ) );\n\twp_register_script( 'jquery-easing', get_template_directory_uri() . '/js/vendor/jquery.easing.js', array( 'jquery' ) );\n\twp_register_script( 'jquery-scroll-to', get_template_directory_uri() . '/js/vendor/jquery.scrollTo.min.js', array( 'jquery' ) );\n\twp_register_script( 'custom-script', get_template_directory_uri() . '/js/site-wide.js', array( 'jquery' ) );\n\t\n\t//Enqueue scripts\n\twp_enqueue_script( 'bootstrap' );\n\twp_enqueue_script( 'jquery-easing' );\n\twp_enqueue_script( 'jquery-scroll-to' );\n\twp_enqueue_script( 'custom-script' );\n\n\t/*\n\t * Custom Google Fonts. Simply follow the format below.\n\t * Use pipes \"|\" when adding multiple fonts\n\t */\n\t$query_args = array(\n\t\t'family' => 'Open+Sans:400,400i,700'//'Open+Sans:400,700|Oswald:700'\n\t);\n\twp_register_style('google_fonts', add_query_arg( $query_args, \"//fonts.googleapis.com/css\" ), array(), null );\n\twp_enqueue_style('google_fonts');\n}", "function glio_scripts_loader() {\n\n if (is_singular() && comments_open() && get_option('thread_comments')) {\n\n wp_enqueue_script('comment-reply');\n\n }\n wp_enqueue_script('modernizr-min-js', 'http://cdnjs.cloudflare.com/ajax/libs/modernizr/2.6.2/modernizr.min.js', array('jquery'), '2.6.2', true);\n wp_enqueue_script('html5-js', 'http://html5shim.googlecode.com/svn/trunk/html5.js', array('jquery'), '1.0', true);\n wp_enqueue_script('glio-js', get_template_directory_uri() . '/assets/js/glio.js', array('jquery'), '1.0', true);\n if (is_page( 'contact-us' )) {\n\n wp_enqueue_script('maps-google', 'https://maps.googleapis.com/maps/api/js?sensor=false', array('jquery'), '1.0', true);\n \n }\n}", "function theme_name_scripts() {\n\t\t// wp_enqueue_style( 'style-name', get_stylesheet_uri() );\n\t\twp_enqueue_script( 'jquery', get_template_directory_uri() . '/js/jquery.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'retina.min', get_template_directory_uri() . '/js/retina.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'isotope.pkgd.min', get_template_directory_uri() . '/js/isotope.pkgd.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.magnific-popup.min', get_template_directory_uri() . '/js/jquery.magnific-popup.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.mousewheel.min', get_template_directory_uri() . '/js/jquery.mousewheel.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.tinycarousel.min', get_template_directory_uri() . '/js/jquery.tinycarousel.min.js', array(), '1.0.0', true );\n\t\twp_enqueue_script( 'jquery.lazylinepainter.min.js', get_template_directory_uri() . '/js/jquery.lazylinepainter.min.js', array(), '1.0.0', true );\n\t\tif ( is_page( 'contact' ) ){ wp_enqueue_script( 'jquery.gmap.min', get_template_directory_uri() . '/js/jquery.gmap.min.js', array(), '1.0.0', true ); }\n\t\twp_enqueue_script( 'scripts', get_template_directory_uri() . '/js/scripts.js', array(), '1.0.0', true );\n\t}", "function scripts_load_bootstrap_and_custom_js()\n{\n\n wp_register_script( 'bootstrap-js-cdn',\n '//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js',\n array('jquery'), null, false );\n wp_enqueue_script( 'bootstrap-js-cdn' );\n\n wp_register_script( 'jquery-cookie-js',\n '//f3thefort.com/wp-content/themes/thefort/scripts/js.cookie.js',\n array('jquery'), null, false );\n wp_enqueue_script( 'jquery-cookie-js' );\n\n wp_register_script( 'theme-functions-js',\n '//f3thefort.com/wp-content/themes/thefort/scripts/theme-functions.js',\n array('jquery'), null, false );\n wp_localize_script( 'theme-functions-js', 'myAjax', array( 'ajaxurl' => admin_url( 'admin-ajax.php' )));\n\n wp_enqueue_script( 'theme-functions-js' );\n}", "function innelyz_scripts() {\n wp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/assets/js/bootstrap.js', array('jquery'), '3.3.7', false);\n wp_enqueue_style( 'bootstrap', get_template_directory_uri() .'/assets/css/bootstrap.css', array(), false, 'all' );\n wp_enqueue_style( 'google-fonts', '//fonts.googleapis.com/css?family=Lora|Pacifico|Roboto');\n wp_enqueue_style( 'innelyz-style', get_stylesheet_uri() );\n }", "function ineedmyjava() {\n\tif (!is_admin()) {\n \n\t\twp_deregister_script('jquery');\n\t\twp_register_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js', false, '1.11.0', true);\n\t\twp_enqueue_script('jquery');\n\t\t\n\t\t// other scripts...\n\t\twp_register_script(\n\t\t\t'custom',\n\t\t\tget_bloginfo('template_directory') . '/js/custom.js',\n\t\t\tarray('jquery') );\n\t\twp_enqueue_script('custom');\n\t\t\n\t\t\n\t\t// other scripts...\n\t\twp_register_script(\n\t\t\t'isotope',\n\t\t\tget_bloginfo('template_directory') . '/js/isotope.js',\n\t\t\tarray('jquery') );\n\t\twp_enqueue_script('isotope');\n\t\t\n\t\t\n\t\t// other scripts...\n\t\twp_register_script(\n\t\t\t'images',\n\t\t\tget_bloginfo('template_directory') . '/js/images-loaded.js',\n\t\t\tarray('jquery') );\n\t\twp_enqueue_script('images');\n\t\t\n\t\t\n\t\t// other scripts...\n\t\twp_register_script(\n\t\t\t'bootstrap',\n\t\t\tget_bloginfo('template_directory') . '/js/bootstrap.js',\n\t\t\tarray('jquery') );\n\t\twp_enqueue_script('bootstrap');\n\t\t\n\t\t\n\t\t// other scripts...\n\t\twp_register_script(\n\t\t\t'colorbox',\n\t\t\tget_bloginfo('template_directory') . '/js/colorbox.js',\n\t\t\tarray('jquery') );\n\t\twp_enqueue_script('colorbox');\n\t\t\n\t\t\n\t\t\n\t}\n}", "function meu_site_script_enqueue() {\n\n// Bootstrap\n\n wp_enqueue_style(\"bootstrap_css\", \"https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css\");\n\n wp_enqueue_script( 'boot1','https://code.jquery.com/jquery-3.3.1.min.js', array( 'jquery' ),'',true );\n\n wp_enqueue_script( 'boot2','https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js', array( 'jquery' ),'',true );\n\n wp_enqueue_script( 'boot3','https://stackpath.bootstrapcdn.com/bootstrap/4.1.1/js/bootstrap.min.js', array( 'jquery' ),'',true );\n\n// CSS\n\n wp_enqueue_style( 'customstyle', get_template_directory_uri() . '/assets/css/meu-site.css', array(), '1.0.0', 'all' );\n\n// JS & jQuery\n\n wp_enqueue_script('customjs', get_template_directory_uri() . '/assets/js/meu-site.js', array('jquery'), '1.0.0', true);\n\n}", "function load_custom_scripts() {\n\t//slidebars\n\twp_enqueue_script('slidebars', THEMEROOT . '/js/slidebars.min.js', array('jquery'), '0.13.3', true);\n\t//bootstrap\n\twp_enqueue_script('bootstrap', THEMEROOT . '/js/bootstrap.min.js', array('jquery'), '3.3.6', true);\n\t//fancybox\n\twp_enqueue_script('fancybox', THEMEROOT . '/js/jquery.fancybox.pack.js', array('jquery'), '2.1.5', true);\n\t//valitate\n\twp_enqueue_script('validate', THEMEROOT . '/js/jquery.validate.min.js', array('jquery'), '1.15', true);\n\t\n\t//script\n\twp_enqueue_script('custom_script', THEMEROOT . '/js/scripts.js', array('jquery'), false, true);\n}", "function google_map_load_scripts(){\n\twp_register_script( 'google-maps-api', 'http://maps.google.com/maps/api/js?sensor=false' );\n}", "function basel_enqueue_scripts() {\n\t\tif ( is_singular() && comments_open() && get_option( 'thread_comments' ) )\n\t\t\twp_enqueue_script( 'comment-reply' );\n\t\t\n\t\twp_register_script( 'maplace', get_template_directory_uri() . '/js/maplace-0.1.3.min.js', array('jquery', 'google.map.api'), '', true );\n\t\t\n\t\tif( ! basel_woocommerce_installed() )\n\t\t\twp_register_script( 'jquery-cookie', get_template_directory_uri() . '/js/jquery.cookie.js', array('jquery'), '1.4.1', true );\n\n\t\twp_enqueue_script( 'basel_html5shiv', get_template_directory_uri() . '/js/html5.js' );\n\t\twp_script_add_data( 'basel_html5shiv', 'conditional', 'lt IE 9' );\n\n\t\twp_dequeue_script( 'flexslider' );\n\t\twp_dequeue_script( 'photoswipe-ui-default' );\n\t\twp_dequeue_script( 'prettyPhoto-init' );\n\t\twp_dequeue_style( 'photoswipe-default-skin' );\n\n\t\tif( basel_get_opt( 'image_action' ) != 'zoom' ) {\n\t\t\twp_dequeue_script( 'zoom' );\n\t\t}\n\n\t\twp_enqueue_script( 'isotope', get_template_directory_uri() . '/js/isotope.pkgd.min.js', array( 'jquery' ), '', true );\n\t\twp_enqueue_script( 'waypoints' );\n\t\twp_enqueue_script( 'wpb_composer_front_js' );\n\n\t\tif( basel_get_opt( 'minified_js' ) ) {\n\t\t\twp_enqueue_script( 'basel-theme', get_template_directory_uri() . '/js/theme.min.js', array( 'jquery', 'jquery-cookie' ), '', true );\n\t\t} else {\n\t\t\twp_enqueue_script( 'basel-libraries', get_template_directory_uri() . '/js/libraries.js', array( 'jquery', 'jquery-cookie' ), '', true );\n\t\t\twp_enqueue_script( 'basel-functions', get_template_directory_uri() . '/js/functions.js', array( 'jquery', 'jquery-cookie' ), '', true );\n\t\t}\n\n\t\t// Add virations form scripts through the site to make it work on quick view\n\t\tif( basel_get_opt( 'quick_view_variable' ) ) {\n\t\t\twp_enqueue_script( 'wc-add-to-cart-variation' );\n\t\t}\n\n\n\t\t$translations = array(\n\t\t\t'adding_to_cart' => esc_html__('Processing', 'basel'),\n\t\t\t'added_to_cart' => esc_html__('Product was successfully added to your cart.', 'basel'),\n\t\t\t'continue_shopping' => esc_html__('Continue shopping', 'basel'),\n\t\t\t'view_cart' => esc_html__('View Cart', 'basel'),\n\t\t\t'go_to_checkout' => esc_html__('Checkout', 'basel'),\n\t\t\t'loading' => esc_html__('Loading...', 'basel'),\n\t\t\t'countdown_days' => esc_html__('days', 'basel'),\n\t\t\t'countdown_hours' => esc_html__('hr', 'basel'),\n\t\t\t'countdown_mins' => esc_html__('min', 'basel'),\n\t\t\t'countdown_sec' => esc_html__('sc', 'basel'),\n\t\t\t'loading' => esc_html__('Loading...', 'basel'),\n\t\t\t'wishlist' => ( class_exists( 'YITH_WCWL' ) ) ? 'yes' : 'no',\n\t\t\t'cart_url' => ( basel_woocommerce_installed() ) ? esc_url( WC()->cart->get_cart_url() ) : '',\n\t\t\t'ajaxurl' => admin_url('admin-ajax.php'),\n\t\t\t'add_to_cart_action' => ( basel_get_opt( 'add_to_cart_action' ) ) ? esc_js( basel_get_opt( 'add_to_cart_action' ) ) : 'widget',\n\t\t\t'categories_toggle' => ( basel_get_opt( 'categories_toggle' ) ) ? 'yes' : 'no',\n\t\t\t'enable_popup' => ( basel_get_opt( 'promo_popup' ) ) ? 'yes' : 'no',\n\t\t\t'popup_delay' => ( basel_get_opt( 'promo_timeout' ) ) ? (int) basel_get_opt( 'promo_timeout' ) : 1000,\n\t\t\t'popup_event' => basel_get_opt( 'popup_event' ),\n\t\t\t'popup_scroll' => ( basel_get_opt( 'popup_scroll' ) ) ? (int) basel_get_opt( 'popup_scroll' ) : 1000,\n\t\t\t'popup_pages' => ( basel_get_opt( 'popup_pages' ) ) ? (int) basel_get_opt( 'popup_pages' ) : 0,\n\t\t\t'promo_popup_hide_mobile' => ( basel_get_opt( 'promo_popup_hide_mobile' ) ) ? 'yes' : 'no',\n\t\t\t'product_images_captions' => ( basel_get_opt( 'product_images_captions' ) ) ? 'yes' : 'no',\n\t\t\t'all_results' => __('View all results', 'basel'),\n\t\t\t'product_gallery' => basel_get_product_gallery_settings(),\n\t\t\t'zoom_enable' => ( basel_get_opt( 'image_action' ) == 'zoom') ? 'yes' : 'no',\n\t\t\t'ajax_scroll' => ( basel_get_opt( 'ajax_scroll' ) ) ? 'yes' : 'no',\n\t\t\t'ajax_scroll_class' => apply_filters( 'basel_ajax_scroll_class' , '.main-page-wrapper' ),\n\t\t\t'ajax_scroll_offset' => apply_filters( 'basel_ajax_scroll_offset' , 100 ),\n\t\t\t'product_slider_auto_height' => ( apply_filters( 'basel_product_slider_auto_height' , false ) ) ? 'yes' : 'no',\n\t\t);\n\n\t\twp_localize_script( 'basel-functions', 'basel_settings', $translations );\n\t\twp_localize_script( 'basel-theme', 'basel_settings', $translations );\n\t\t\n\t\tif( ( is_home() || is_singular( 'post' ) || is_archive() ) && basel_get_opt('blog_design') == 'masonry' ) {\n\t\t\t// Load masonry script JS for blog\n\t\t\twp_enqueue_script( 'masonry' );\n\t\t}\n\n\t}", "function artistpress_scripts() {\n\t\twp_enqueue_style( 'reset', get_template_directory_uri() . '/css/reset.css', array(), '2.0' );\n\t\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css', array(), '3.3.7' );\n\t\twp_enqueue_style( 'main_style', get_template_directory_uri() . '/style.css' );\n\t\twp_enqueue_script( 'jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js', array(), '1.11.3', true );\n\t\twp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/js/bootstrap.min.js', array( 'jquery' ), '3.3.6', true );\n\t\twp_register_script( 'load', get_template_directory_uri() . '/js/load.js' );\n\n\t\t//localize params for use in load.js\n\t\t$theme_params = array(\n\t\t 'backround_image' => get_option('backround_image'),\n\t\t 'action_url' => get_option('action_url'),\n\t\t);\n\n\t\twp_localize_script( 'load', 'themeParams', $theme_params );\n\n\t\twp_enqueue_script( 'load', get_template_directory_uri() . '/js/load.js', array( 'jquery' ,'bootstrap'), '1', true );\n\t}", "function skShortIncludeJs() {\r\n\t\tglobal $ShortcodeKidPath;\r\n\t\tif(!is_admin()) {\r\n\t\t\t\r\n\t\t\t//shortcodes.js\r\n\t\t\twp_register_script('skshortcodes', DT_PLUGINS_URL.'/shortcodes/shortcodekid/js/shortcodes.js');\r\n\t\t\t\r\n\t\t\t//Enqueue our script\r\n\t\t\twp_enqueue_script('jquery');\r\n\t\t\twp_enqueue_script('skshortcodes');\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t}", "public function registerScriptsCommon() {\n $v = Wpjb_Project::VERSION;\n $p = plugins_url().'/wpjobboard/public/js/';\n $x = plugins_url().'/wpjobboard/application/vendor/';\n \n wp_register_script(\"wpjb-suggest\", $p.\"wpjb-suggest.js\", array(\"jquery\"), $v, true );\n \n wp_register_script(\"wpjb-vendor-selectlist\", $x.\"select-list/jquery.selectlist.pack.js\", array(\"jquery\"), null, true);\n wp_register_script(\"wpjb-plupload\", $p.\"wpjb-plupload.js\", array(\"plupload-all\"), $v, true);\n wp_register_script(\"wpjb-vendor-datepicker\", $x.\"date-picker/js/datepicker.js\", array(\"jquery\"));\n \n wp_register_script(\"wpjb-gmaps-infobox\", $p.\"gcode-infobox.js\", array());\n wp_register_script(\"wpjb-gmaps-markerclusterer\", $p.\"gcode-markerclusterer.js\", array());\n \n wp_register_script(\"wpjb-ace\", $x.\"ace/ace.js\", array(), \"1.2.6\");\n \n wp_register_script(\"wpjb-vendor-stripe\", \"https://js.stripe.com/v3/\");\n wp_register_script(\"wpjb-stripe\", $p.\"wpjb-stripe.js\", array(\"jquery\", \"wpjb-stripe-main\", \"wpjb-payment\"), $v);\n //wp_register_script(\"wpjb-stripe-elements\", $p.\"wpjb-stripe-elements.js\", array(\"jquery\", \"wpjb-stripe\", \"wpjb-stripe-main\"), $v);\n wp_register_script(\"wpjb-stripe-main\", \"https://js.stripe.com/v3/\", array(), $v);\n \n wp_register_script('wpjb-myresume', $p.'frontend-myresume.js', array(\"jquery\", \"wp-util\"), $v );\n \n wp_register_script('wpjb-admin-customize', $p.'admin-customize.js', array(\"jquery\"), $v, true );\n }", "public function public_enqueue_scripts() {\n\n\t\twp_register_script('custom-event-polyfill', get_template_directory_uri() . '/js/polyfill/custom-event.min.js', array(), $this->version, true);\n\t\twp_register_script('promise-polyfill', get_template_directory_uri() . '/js/polyfill/promise.min.js', array(), $this->version, true);\n\t\t// wp_register_script('scroll-polyfill', get_template_directory_uri() . '/js/polyfill/smoothscroll.min.js', array(), $this->version, true);\n\n\t\twp_register_script('tinyAnimate', get_template_directory_uri() . '/js/utils/TinyAnimate.js', array(), $this->version, true);\n\t\twp_register_script('swipe', get_template_directory_uri() . '/js/utils/swipe.js', array(), $this->version, true);\n\t\twp_register_script('collection', get_template_directory_uri() . '/js/utils/collection.js', array(), $this->version, true);\n\t\twp_register_script('media-player', get_template_directory_uri() . '/js/utils/media-player.js', array('tinyAnimate', 'collection'), $this->version, true);\n\t\twp_register_script('media-player-v2', get_template_directory_uri() . '/js/utils/media-player-v2.js', array('tinyAnimate', 'collection'), $this->version, true);\n\t\twp_register_script('build', get_template_directory_uri() . '/js/utils/build.js', array(), $this->version, true);\n\t\twp_register_script('ajax', get_template_directory_uri() . '/js/utils/ajax.js', array(), $this->version, true);\n\t\twp_register_script('marquee', get_template_directory_uri() . '/js/utils/marquee.js', array(), $this->version, true);\n\t\twp_register_script('popup', get_template_directory_uri() . '/js/utils/popup.js', array('tinyAnimate'), $this->version, true);\n\t\twp_register_script('calendar', get_template_directory_uri() . '/js/utils/calendar.js', array(), $this->version, true);\n\t\twp_register_script('translation', get_template_directory_uri() . '/js/utils/translation.js', array(), $this->version, true);\n\t\twp_register_script('grid-system', get_template_directory_uri() . '/js/utils/grid-system.js', array('tinyAnimate'), $this->version, true);\n\t\twp_register_script('sticky', get_template_directory_uri() . '/js/utils/sticky.js', array(), $this->version, true);\n\t\twp_register_script('custom-dispatcher', get_template_directory_uri() . '/js/utils/custom-dispatcher.js', array(), $this->version, true);\n// \t\twp_enqueue_script('grid', get_template_directory_uri() . '/js/grid.js', array('grid-system'), $this->version, true);\n// \t\twp_enqueue_script('projects-grid', get_template_directory_uri() . '/js/projects.js', array('grid'), $this->version, true);\n// \t\twp_enqueue_script('project', get_template_directory_uri() . '/js/project.js', array('grid'), $this->version, true);\n// \t\twp_enqueue_script('image', get_template_directory_uri() . '/js/image.js', array('tinyAnimate'), $this->version, true);\n\t\t// wp_register_script('grid-slideshow', get_template_directory_uri() . '/js/grid-slideshow.js', array('media-player', 'swipe', 'build'), $this->version, true);\n\n\t\t// wp_enqueue_script('home', get_template_directory_uri() . '/js/home.js', array('grid-slideshow'), $this->version, true);\n\t\t// wp_enqueue_script('header', get_template_directory_uri() . '/js/header.js', array('popup', 'sticky', 'marquee'), $this->version, true);\n\t\t// wp_enqueue_script('single', get_template_directory_uri() . '/js/single.js', array('grid-slideshow'), $this->version, true);\n\t\t// wp_enqueue_script('bios', get_template_directory_uri() . '/js/bios.js', array('popup'), $this->version, true);\n\t\t// wp_enqueue_script('agenda', get_template_directory_uri() . '/js/agenda.js', array('popup', 'ajax', 'build', 'calendar', 'grid-slideshow'), $this->version, true);\n\t\t// wp_enqueue_script('intro', get_template_directory_uri() . '/js/intro.js', array('media-player'), $this->version, true);\n\n\t\twp_register_script('cookies', get_template_directory_uri() . '/js/utils/cookies.js', array(), $this->version, false);\n\n\t\twp_register_script('gmap', get_template_directory_uri() . '/js/utils/gmap.js', array('gmap-api'), $this->version, true);\n\n\t}", "function pbg_scripts() {\n\n\tglobal $wp_scripts;\n\t\twp_enqueue_style ( 'mbc_bootstrap_css', get_template_directory_uri() . '/css/bootstrap.css' );\n\t\twp_enqueue_style ( 'mbc_main_css', get_template_directory_uri() . '/css/app.css' );\n\t\twp_register_script ( 'html5_shiv', 'https://oss.maxcdn.com/html5shiv/3.7.3/html5shiv.min.js', '', '', false );\n\t\twp_register_script ( 'respond_js', 'https://oss.maxcdn.com/respond/1.4.2/respond.min.js', '', '', false );\n\t\t$wp_scripts->add_data ( 'html5_shiv', 'conditional', 'lt IE 9' );\n\t\t$wp_scripts->add_data ( 'respond_js', 'conditional', 'lt IE 9' );\n\t\twp_enqueue_script ( 'bottstrap_js', get_template_directory_uri() . '/js/bootstrap.min.js', array('jquery'), '', true );\n\n}", "function loadScripts() {\n\t\twp_enqueue_script('jquery');\n\t\twp_enqueue_script('jquery.tmpl', $this->pluginPath . 'js/jquery.tmpl.js');\n\t\twp_enqueue_script('hashee_app', $this->pluginPath . 'js/hashee_app.js');\n?>\n \t\t<script type=\"text/javascript\" src=\"http://maps.googleapis.com/maps/api/js?sensor=false\"></script>\n\t\t<script id=\"hasheeBubbleTemplate\" type=\"text/x-jquery-tmpl\">\n\t\t\t<div class=\"tweet\"><div id=\"${from_user_id}\"><img src=\"${profile_image_url}\" style=\"float:left; margin-right: 5px;\" />${text} by ${from_user}<br><small>${pp_created_on}</small></div></div>\n\t\t</script>\n<?php\n\t}", "function load_custom_files(){\n\n wp_register_script(\n 'custom-script',\n get_stylesheet_directory_uri().'/js/custom.js',\n array('jquery')\n ); \n wp_enqueue_script('custom-script');\n\n wp_register_script(\n 'jquery-steps',\n get_stylesheet_directory_uri().'/js/jquery.steps.min.js',\n array('jquery')\n ); \n wp_enqueue_script('jquery-steps');\n\n wp_register_script(\n 'jquery-validate',\n get_stylesheet_directory_uri().'/js/jquery.validate.js',\n array('jquery')\n ); \n wp_enqueue_script('jquery-validate');\n\n wp_register_script(\n 'jquery-methods',\n get_stylesheet_directory_uri().'/js/additional-methods.min.js',\n array('jquery')\n ); \n wp_enqueue_script('jquery-methods');\n\n wp_register_style(\n 'jquery-steps-style',\n get_stylesheet_directory_uri().'/css/jquery.steps.css'); \n wp_enqueue_style('jquery-steps-style');\n\n }", "function include_css_js_files()\n{\n\twp_register_style('css_file1','https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css');\n\twp_enqueue_style('css_file1');\n\n\n\twp_register_script('js_file1','https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js');\n\twp_enqueue_script('js_file1');\n\twp_register_script('js_file2','https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.16.0/umd/popper.min.js');\n\twp_enqueue_script('js_file2');\n\twp_register_script('js_file3','https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js');\n\twp_enqueue_script('js_file3');\n\n}", "function theme_scripts() {\n\t\twp_enqueue_style('bootstrap-css', get_template_directory_uri().'/styles/bootstrap/css/bootstrap.min.css');\n\t\twp_enqueue_script('jquery', 'https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js');\n\t\twp_enqueue_script('bootstrap-js', get_template_directory_uri().'/styles/bootstrap/js/bootstrap.min.js');\n\t\twp_enqueue_script('custom-js', get_template_directory_uri().'/js/functions.js');\n\t}", "function register_location_js_css() {\n\twp_register_script( google_maps_register, google_maps_key );\n\n\twp_register_script(\n\t\tscript_register,\n\t\tplugins_url( 'js/google-map.js', __FILE__ ),\n\t\tarray( 'jquery' ),\n\t\tfilemtime( plugin_dir_path( __FILE__ ) . '/js/google-map.js' ),\n\t\ttrue\n\t);\n\twp_register_style(\n\t\tstyle_register_plugin,\n\t\tplugins_url( 'css/style.css', __FILE__ ),\n\t\tarray(),\n\t\tfilemtime( plugin_dir_path( __FILE__ ) . '/css/style.css' )\n\t);\n}", "function mini_bonds_scripts() {\n wp_enqueue_script( 'bootstrap_js', plugins_url( 'assets/bootstrap/js/bootstrap.min.js', __FILE__ ) , array(), '3.3.5', true );\n wp_enqueue_script( 'jqueryui_js', plugins_url( 'assets/jquery-ui-1.11.4/jquery-ui.min.js', __FILE__ ) , array(), '1.11.4', true );\n wp_enqueue_script( 'parsley_js', plugins_url( 'assets/js/Parsley.js-2.2.0/dist/parsley.min.js', __FILE__ ) , array(), '2.2.0', true );\n wp_enqueue_script( 'selectBoxit_js', plugins_url( 'assets/js/jquery.selectBoxIt/src/javascripts/jquery.selectBoxIt.min.js', __FILE__ ) , array(), '3.8.1', true );\n wp_enqueue_script( 'minibond_js', plugins_url( 'assets/js/main.js', __FILE__ ) , array(), '1.0.0', true );\n /* add css libraries */\n wp_register_style( 'bootstrap_css', plugins_url( 'assets/bootstrap/css/bootstrap.min.css', __FILE__ ), false, '3.3.5' );\n wp_enqueue_style( 'bootstrap_css' );\n wp_register_style( 'jqueryui_css', plugins_url( 'assets/jquery-ui-1.11.4/jquery-ui.min.css', __FILE__ ), false, '1.11.4' );\n wp_enqueue_style( 'jqueryui_css' );\n wp_register_style( 'selectBoxit_css', plugins_url( 'assets/js/jquery.selectBoxIt/src/stylesheets/jquery.selectBoxIt.css', __FILE__ ), false, '3.8.1' );\n wp_enqueue_style( 'selectBoxit_css' );\n wp_register_style( 'fontawesome_css', 'https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css', false, '4.4.0' );\n wp_enqueue_style( 'fontawesome_css' );\n wp_register_style( 'minibond_css', plugins_url( 'assets/css/main.css', __FILE__ ), false, '1.0.0' );\n wp_enqueue_style( 'minibond_css' );\n}", "public function admin_enqueue_scripts()\n\t\t{\n\t\t\tglobal $pagenow; \n\t\t\tif (is_admin() || $pagenow === 'wc_prd_vendor') { \n\t\t\t\twp_register_script( 'bootstrap-tooltip', $this->assets_url . 'js/bootstrap-tooltip.js', array( 'jquery' ), '1.0' );\n\t\t\t\twp_register_script( 'select2', $this->assets_url . 'js/select2/select2.min.js', array( 'jquery' ), '3.5.2' );\n\t\t\t\twp_register_script( 'topgroupshops-media', $this->assets_url . 'js/topgroupshops-media.js', array( 'jquery' ), '1.0' );\n\t\t\t\twp_register_script( 'sf-scripts', $this->assets_url . 'js/sf-jquery.js', array( 'jquery' ), '1.0' );\n\t\t\t\twp_register_style( 'select2', $this->assets_url . 'js/select2/select2.css' );\n\t\t\t\twp_register_style( 'sf-styles', $this->assets_url . 'css/sf-styles.css' );\n\t\t\t}\n\t\t}", "function enqueue_scripts() {\n wp_register_script( 'waypoints', THEME . '/js/waypoint.min.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'waypoints' );\n wp_register_script( 'slick', THEME . '/js/slick.min.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'slick' );\n wp_register_script( 'validate', THEME . '/js/validate.min.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'validate' );\n wp_register_script( 'client', THEME . '/js/client.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'client' );\n wp_register_script( 'scripts', THEME . '/js/scripts.js', array( 'jquery' ), '1', true ); wp_enqueue_script( 'scripts' );\n}", "function load_custom_scripts() {\n wp_enqueue_script('vendor_script', THEMEROOT . '/js/vendor.min.js', array('jquery'), false, true);\n wp_enqueue_script('main_script', THEMEROOT . '/js/main.js', array('jquery'), false, true);\n wp_localize_script('main_script', 'TCAjax', array('url' => admin_url('admin-ajax.php'), 'nonce' => wp_create_nonce('tcajax-nonce')));\n}", "static function enqueue_scripts(){\n\t\tself::include_css();\n\t\tself::include_js();\n\t}", "function load_all_scripts() {\n\n // jQuery is included with wordpress by default\n\n wp_enqueue_script(\n 'bootstrap',\n get_stylesheet_directory_uri() . '/js/bootstrap.min.js',\n array( 'jquery' )\n );\n\n wp_enqueue_script(\n 'custom',\n get_stylesheet_directory_uri() . '/js/custom.js',\n array( 'jquery', 'bootstrap' )\n );\n}", "function viaggio_scripts() {\n\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.min.css' );\n\twp_enqueue_style( 'bootstrap-theme', get_template_directory_uri() . '/assets/css/bootstrap-theme.min.css' );\n\twp_enqueue_style( 'animate', get_template_directory_uri() . '/assets/css/animate.min.css' );\n\twp_enqueue_style( 'slicknav', get_template_directory_uri() . '/assets/css/slicknav.min.css' );\n\twp_enqueue_style( 'fontawesome-theme', get_template_directory_uri() . '/assets/css/font-awesome/css/font-awesome.min.css' );\n\twp_enqueue_style( 'nivo', get_template_directory_uri() . '/assets/css/nivo-slider.css' );\n\twp_enqueue_style( 'viaggio-style', get_stylesheet_uri() );\n\twp_enqueue_style( 'viaggio-responsive', get_template_directory_uri() . '/assets/css/responsive.css' );\n\n\t\n\twp_enqueue_script( 'viaggio-plugin', get_template_directory_uri(). '/assets/js/plugin-bundle.js', array('jquery'), \"20124141\" , true );\n\twp_enqueue_script( 'viaggio-google-map', '//maps.googleapis.com/maps/api/js?key='. cs_get_option('contact-google-api'), array(), '1', true );\n\twp_enqueue_script( 'viaggio-custom', get_template_directory_uri(). '/assets/js/custom.js', array('jquery'), \"20124155\" , true );\n\twp_enqueue_script( 'viaggio-navigation', get_template_directory_uri() . '/js/navigation.js', array('jquery'), '20151215', true );\n\twp_enqueue_script( 'viaggio-skip-link-focus-fix', get_template_directory_uri() . '/js/skip-link-focus-fix.js', array('jquery'), '20151215', true );\n\n\n\n\tif ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {\n\t\twp_enqueue_script( 'comment-reply' );\n\t}\n}", "function assets() {\n /* Registro de estilos de depeendencias */\n wp_register_style('boostrap','https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css', '', '5.0.1', 'all');\n wp_register_style('font_primary', 'https://fonts.googleapis.com/css2?family=Montserrat&display=swap', '', '1.0', 'all');\n\n \n /* Cargar las depencias de css */\n wp_enqueue_style( 'stylesAll', get_stylesheet_uri(), array('boostrap', 'font_primary'), '1.0', 'all' );\n\n /* true: que se ejecute en el footer */\n\n wp_register_script( 'validate', plugins_url( '/validate.js', __FILE__ ), array( 'jquery' ) );\n wp_enqueue_script('validate'); \n\n wp_register_script('popper', 'https://cdn.jsdelivr.net/npm/@popperjs/[email protected]/dist/umd/popper.min.js', '', '1.16.0', true);\n \n wp_enqueue_script('b5','https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.min.js', array('popper'), '1.0', true );\n wp_enqueue_script('custom', get_template_directory_uri().'/assets/js/custom.js', '', '1.0', true );\n\n /* enviar informacion de js a una funcions, uso de apirest */\n wp_localize_script('custom', 'ajar', array( \n 'ajaxurl' => admin_url('admin-ajax.php'),\n 'apiurl' => home_url('wp-json/ajar/v1/'),\n ));\n\n}", "function fumseck_register_bootstrap_js() {\n\twp_enqueue_script(\n\t\t'bootstrap_js',\n\t\tget_stylesheet_directory_uri() . '/3rdparty/bootstrap-3.0.3/dist/js/bootstrap.min.js',\n\t\tarray( 'jquery' )\n\t);\n}", "function custom_js(){\n wp_register_script('adding_jquery', get_template_directory_uri().'/js/jquery.js','','',true );\n wp_register_script('adding_materialjs', get_template_directory_uri().'/js/materialize.min.js','','', true);\n wp_register_script('custom_scripts', get_template_directory_uri().'/js/custom.js','','',true );\n \n wp_enqueue_script('adding_jquery');\n wp_enqueue_script('adding_materialjs');\n wp_enqueue_script('custom_scripts');\n}", "public function enqueue_scripts() {\n\t\t\n\t\twp_register_script( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'js/sanoa-links-linter-public.js', '', $this->version, true ); // Put in footer\n\n // Grab all options\n\t\t$options = get_option($this->plugin_name);\n\t\t\n $urlparts = parse_url(site_url());\n $domain = $urlparts [host];\n\n\t\t$input_hostname = \n\t\t\t(empty($options['input-hostname'])) ? $domain : $options['input-hostname'];\t\n\n\t\t// Localize the script with new data\t\n\t\t$searchArgs = array(\n\t\t\t'input_hostname' => $input_hostname,\n\t\t\t$this->plugin_name\n\t\t);\n\t\twp_localize_script( $this->plugin_name, 'php_vars', $searchArgs );\n\n\t\twp_enqueue_script( $this->plugin_name );\n\n\t}", "public function loadScripts()\n\t\t\t{\n\t\t\t\t// Contest CSS\n\t\t\t\twp_register_style('wppc-shortcode-css', WPPC_URI.'css/wppc-shortcode.css', '', WPPC_VERSION);\n\t\t\t\twp_enqueue_style('wppc-shortcode-css');\n\t\t\t\twp_register_style('wppc-colorbox-css', WPPC_URI.'css/colorbox.css', '', '1.5.13');\n\t\t\t\twp_enqueue_style('wppc-colorbox-css');\n\n\t\t\t\t// jQuery\n\t\t\t\twp_enqueue_script('jquery', '', '', '', true);\n\n\t\t\t\t// jQuery UI core\n\t\t\t\twp_enqueue_script('jquery-ui-core', array('jquery'), '', '', true);\n\n\t\t\t\t// jQuery UI Tabs\n\t\t\t\twp_enqueue_script('jquery-ui-tabs', array('jquery-ui-core'), '', '', true);\n\n\t\t\t\t// Font Awesome\n\t\t\t\twp_register_style('font-awesome', 'https://maxcdn.bootstrapcdn.com/font-awesome/4.5.0/css/font-awesome.min.css', '', '', 'all');\n\t\t\t\twp_enqueue_style('font-awesome');\n\n\t\t\t\t// Contest JS\n\t\t\t\twp_register_script('wppc-shortcode', WPPC_URI.'js/wppc-shortcode.js', array('jquery'), WPPC_VERSION, true);\n\t\t\t\twp_enqueue_script('wppc-shortcode');\n\n\t\t\t\t// Colorbox JS\n\t\t\t\twp_register_script('wppc-colorbox', WPPC_URI.'js/jquery.colorbox-min.js', array('jquery'), '1.5.13', true);\n\t\t\t\twp_enqueue_script('wppc-colorbox');\n\n\t\t\t\t// Ajax calls\n\t\t\t\twp_register_script('wppc-ajax-frontend', plugins_url('js/wppc-ajax-frontend.min.js', WPPC_FILE), array('jquery'), WPPC_VERSION, true);\n\t\t\t\twp_enqueue_script('wppc-ajax-frontend');\n\n\t\t\t\t// Localize Ajax handler - TO BE DELETED LATER\n\t\t\t\twp_localize_script('wppc-ajax-frontend', 'wppcSubmitPhoto', array(\n\t\t\t\t\t'ajaxurl' => WPPC_URI.'ajax/ajax-handler.php',\n\t\t\t\t\t'action' => $this->submitFormAction,\n\t\t\t\t));\n\n\t\t\t\t// ImagesLoaded JS script\n\t\t\t\twp_enqueue_script('images-loaded', WPPC_URI.'js/imagesloaded.pkgd.min.js', array('jquery'), IMAGES_LOADED_VERSION, true);\n\t\t\t}", "function ajout_scripts() {\nwp_register_script('bootstrap_script', JS_URL. '/bootstrap.min.js', array('jquery'),'1.1', true);\nwp_enqueue_script('bootstrap_script');\n\n// enregistrement d'un nouveau script\nwp_register_script('main_script', JS_URL. '/main.js', array('jquery'),'1.1', true);\nwp_enqueue_script('main_script');\n\n\n\n\n// enregistrement d'un nouveau style\nwp_register_style( 'googlefont_style', 'https://fonts.googleapis.com/css?family=Montserrat|Roboto:300,400,500,700,900' );\nwp_enqueue_style( 'googlefont_style' );\n\n// enregistrement d'un nouveau style\nwp_register_style( 'bootstrap_style', CSS_URL. '/bootstrap.min.css' );\nwp_enqueue_style( 'bootstrap_style' );\n\n\n\n// enregistrement d'un nouveau style\nwp_register_style( 'main_style', CSS_URL. '/main.css' );\n\n// appel du style dans la page\nwp_enqueue_style( 'main_style' );\n\n}", "function protagonist_load_scripts(){\n // CSS\n wp_enqueue_style( 'bootstrapcss', get_template_directory_uri() . '/css/bootstrap.min.css', array(), '4.3.1', 'all' );\n wp_enqueue_style( 'protagonistcss', get_template_directory_uri() . '/css/protagonist.css', array(), '1.0.5', 'all' );\n wp_enqueue_style( 'googlefonts', 'https://fonts.googleapis.com/css?family=Coiny|Open+Sans' );\n // JS\n wp_deregister_script( 'jquery' );\n wp_register_script( 'jquery', get_template_directory_uri() . 'js/jquery.js', false, '3.3.1', true );\n wp_enqueue_script( 'jquery' );\n wp_enqueue_script( 'bootstrapjs', get_template_directory_uri() . '/js/bootstrap.min.js', array('jquery'), '4.3.1', true );\n // FONTAWESOME\n wp_enqueue_style( 'fontawesomecss', get_template_directory_uri() . '/inc/fontawesome/css/all.min.css' );\n wp_enqueue_script( 'fontawesomejs', get_template_directory_uri() . '/inc/fontawesome/js/all.min.js' );\n}", "function my_enqueue() {\n\n\twp_register_style( 'namespace', 'https://dev.raiseitfast.com/wp-content/plugins/change-password/css/change-pwd-style.css' );\n\twp_enqueue_style( 'namespace' );\n\n/*\t\twp_enqueue_script('jQuery-min', 'https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js', '1.0.1', '', true );\t\n\n\twp_enqueue_script('bootstrap-min', get_template_directory_uri().'/js/bootstrap.min.js', '1.0.0','', true );\n\n\twp_enqueue_script('jquery-ui-js', get_template_directory_uri().'/js/jquery-ui.js', '1.0.0', '', true );\n\n\twp_enqueue_script('loadingoverlay-min-js', get_template_directory_uri().'/js/loadingoverlay.min.js', '1.0.1', '', true );\t\n\n\twp_enqueue_script('fabric-js', get_template_directory_uri().'/js/fabric.js', '1.0.0', '', true );\n\n\twp_enqueue_script('darkroom-js', get_template_directory_uri().'/js/darkroom.js', '1.0.0', '', true );\n\n\twp_enqueue_script('bootstrap-select-js', get_template_directory_uri().'/js/bootstrap-select.min.js', '1.0.0', '', true );\n\n\n\n\twp_enqueue_script('site-js', get_template_directory_uri().'/js/site-js.js', '1.0', '', true );\n\n\twp_enqueue_script('form-fieldset-js', get_template_directory_uri().'/js/form-fieldset.js', '1.0', '', true );\n\n\twp_enqueue_script('easing-min-js', get_template_directory_uri().'/js/jquery.easing.min.js', '1.0.0', '', true );\n\n\twp_enqueue_script('bootstrap-datepicker-js', get_template_directory_uri().'/js/bootstrap-datepicker.js', '1.0.0', '', true );\n\n\twp_enqueue_script('timepicker-min-js', get_template_directory_uri().'/js/timepicker.min.js', '1.0.0', '', true );\n\n\twp_enqueue_script('easytabs-min-js', get_template_directory_uri().'/js/jquery.easytabs.min.js','', true );*/\n\n\twp_localize_script('site-js', 'ajax_var', array(\n\n\t\t'url' => admin_url('admin-ajax.php'),\n\n\t\t'nonce' => wp_create_nonce('ajaxnonce')\n\n\t));\n\n}", "function wpbootstrap_scripts_with_jquery()\n{\n\twp_register_script('jquery', get_template_directory_uri(). '/assetts/js/jquery-migrate-1.4.1.min.js');\n\twp_enqueue_script('jquery');\n\twp_register_script( 'bootstrap-js', get_template_directory_uri() . '/bootstrap/js/bootstrap.js', array( 'jquery' ) );\n\t// For either a plugin or a theme, you can then enqueue the script:\n\twp_enqueue_script( 'bootstrap-js' );\n}", "function bootstrap_files()\n{\n wp_enqueue_style(\"bootstrap\", \"//stackpath.bootstrapcdn.com/bootstrap/4.1.2/css/bootstrap.min.css\");\n wp_enqueue_script(\"bootstrapjs\", \"//stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.bundle.min.js\", array('jquery'));\n}", "static function wck_fep_register_script(){\n\t\t//datepicker\n\t\twp_enqueue_script('jquery-ui-datepicker');\n\t\twp_enqueue_style('jquery-style', plugins_url( '', dirname(__FILE__) ).'/assets/datepicker/datepicker.css');\n\n\t\t//colorpicker\n\t\twp_enqueue_style( 'wp-color-picker' );\n\t\twp_enqueue_style( 'wck-colorpicker-style', plugins_url( '', dirname(__FILE__) ).'/assets/colorpicker/colorpicker.css', false, '1.0' );\n\t\twp_enqueue_script( 'iris', admin_url( 'js/iris.min.js' ), array( 'jquery-ui-draggable', 'jquery-ui-slider', 'jquery-touch-punch' ), false, 1 );\n\t\twp_enqueue_script( 'wp-color-picker', admin_url( 'js/color-picker.min.js' ), array( 'iris' ), false, 1 );\n\n\t\t//phone\n\t\twp_enqueue_script( 'wck-jquery-inputmask', plugins_url( '', dirname(__FILE__) ).'/assets/phone/jquery.inputmask.bundle.min.js', array( 'jquery' ), false, 1 );\n\n // map\n $options = get_option( 'wck_extra_options' );\n\n if( !empty( $options[0]['google-maps-api'] ) ) {\n wp_enqueue_script( 'wck-google-maps-api-script', 'https://maps.googleapis.com/maps/api/js?key=' . $options[0]['google-maps-api'] . '&libraries=places', array('jquery') );\n wp_enqueue_script( 'wck-google-maps-script', plugin_dir_url( __FILE__ ) . '../assets/map/map.js', array('jquery') );\n wp_enqueue_style( 'wck-google-maps-style', plugin_dir_url( __FILE__ ) . '../assets/map/map.css' );\n }\n\n\t\t/* FEP script */\n\t\twp_register_script( 'wck-fep', plugins_url('wck-fep.js', __FILE__ ), array('jquery'), '1.0', true );\n\t\twp_register_style( 'wck-fep-css', plugins_url('wck-fep.css', __FILE__ ) );\n\t\t/* register WCK script for frontend */\n\t\twp_register_script( 'wck-js', plugins_url( '', dirname(__FILE__) ).'/wordpress-creation-kit.js', array('jquery', 'jquery-ui-datepicker'), '1.0', true );\n\n\t\t// wysiwyg\n\t\twp_register_script( 'wck-ckeditor', plugins_url( '', dirname(__FILE__) ).'/assets/js/ckeditor/ckeditor.js', array(), '1.0', true );\n\n\t\t/* media upload wck script */\n\t\twp_register_script('wck-upload-field', plugins_url('/../fields/upload.js', __FILE__), array('jquery') );\n\t}", "public function load_admin_scripts()\n {\n // Enqueue styles\n wp_enqueue_style('soccerpress', plugins_url('assets/css/soccerpress.css', __FILE__), array(), '1.0.0', false);\n wp_enqueue_style('bootstrap-css', plugins_url('assets/css/bootstrap.min.css', __FILE__), array(), '4.3.1', false);\n\n // Enqueue scripts\n wp_register_script('bootstrap-js', plugins_url('assets/js/bootstrap.min.js', __FILE__), array(), '4.3.1', false);\n }", "function _scripts() {\n\twp_enqueue_style( 'bootstrap-css', get_template_directory_uri() . '/assets/vendor/bootstrap/css/bootstrap.min.css', array(), null );\n\n\twp_enqueue_style( 'cleanblog-css', get_template_directory_uri() . '/assets/css/clean-blog.min.css', array(), null );\n\n\twp_enqueue_style( 'fontawesome', get_template_directory_uri() . '/assets/vendor/font-awesome/css/font-awesome.min.css', array(), null );\n\n\twp_enqueue_style( 'font-lora', 'https://fonts.googleapis.com/css?family=Lora:400,700,400italic,700italic', array(), null );\n\n\twp_enqueue_style( 'font-opensans', 'https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800', array(), null );\n\n\twp_enqueue_script( 'jquery-js', get_theme_file_uri( '/assets/vendor/jquery/jquery.min.js' ), array(), null );\n\t\n\twp_enqueue_script( 'bootstrap-js', get_theme_file_uri( '/assets/vendor/bootstrap/js/bootstrap.min.js' ), array(), null );\n\n\twp_enqueue_script( 'bootstrapvalidation', get_theme_file_uri( '/assets/js/jqBootstrapValidation.js' ), array(), null );\n\n\twp_enqueue_script( 'contact-me', get_theme_file_uri( '/assets/js/contact_me.js' ), array(), null );\n\n\twp_enqueue_script( 'cleanblog-js', get_theme_file_uri( '/assets/js/clean-blog.min.js' ), array(), null );\n\t\n}", "function linolakestheme_scripts_setup() {\n\t\twp_enqueue_style( 'linolakes-bootstrap-css', get_template_directory_uri() . '/lib/bootstrap/css/bootstrap.min.css', array( ), current_time( 'mysql' ), 'all' );\n\t\twp_enqueue_style( 'font-awesome-css', get_template_directory_uri() . '/lib/bootstrap/css/font-awesome.min.css', array( ), current_time( 'mysql' ), 'all' );\n\t\t \n\t\t// Loads our main stylesheet.\n\t\twp_enqueue_style( 'flat_responsive-style', get_stylesheet_uri(), array(), current_time( 'mysql' ) );\n\t\t\n\t\t// Loads our scripts.\t \n\t\twp_enqueue_script('linolakes-bootstrap-js', get_template_directory_uri() . '/lib/bootstrap/js/bootstrap.min.js', array('jquery'), current_time( 'mysql' ), true);\n\t\twp_enqueue_script('linolakes-jquery-js', get_template_directory_uri() . '/lib/bootstrap/js/jquery.min.js', array('jquery'), current_time( 'mysql' ), true);\n\t\t\t\t\n\t}", "function load_external_javascript($isDataTables = false, $isRecaptcha = false, $bootstrap4 = false) {\n?>\n<?php if ($bootstrap4) { ?>\n <script src=\"external/jquery3.5.1/jquery-3.5.1.min.js\"></script>\n <script src=\"external/bootstrap4.5.0/bootstrap.bundle.min.js\" type=\"text/javascript\"></script>\n<?php } else { ?>\n <script src=\"external/jquery1.7.2/jquery-1.7.2.min.js\"></script>\n <script src=\"external/jqueryui1.8.16/jquery-ui-1.8.16.custom.min.js\"></script>\n <script src=\"external/bootstrap2.3.2/bootstrap.js\" type=\"text/javascript\"></script>\n<?php } ?>\n <script src=\"external/choices9.0.0/choices.min.js\"></script>\n<?php if ($isDataTables) { ?>\n <script src=\"external/dataTables1.10.16/jquery.dataTables.js\"></script>\n<?php }\n if ($isRecaptcha) { ?>\n <script async defer id=\"recaptcha-script\" src=\"https://www.google.com/recaptcha/api.js\"></script>\n<?php }\n}", "function country_inn_scripts()\n{\n $enable_animation = esc_html(country_inn_get_option('country_inn_animation_option'));\n\n /*Bootstrap*/\n wp_enqueue_style('bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.css', array(), '4.5.1');\n \n /* Animation CSS Enqueue */\n $animation_options = ('country_inn_animation_option');\n if( $enable_animation == 0 ){\n wp_enqueue_style('animacountry_inn_get_optionte', get_template_directory_uri() . '/assets/css/animate.css', array(), '4.5.0');\n }\n\n wp_enqueue_style('fontawesome', get_template_directory_uri() . '/assets/css/fontawesome.css', array(), '4.5.0');\n\n wp_enqueue_style('slick', get_template_directory_uri() . '/assets/css/slick.css', array(), '4.5.0');\n\n wp_enqueue_style('slick-theme', get_template_directory_uri() . '/assets/css/slick-theme.css', array(), '4.5.0');\n\n \n /*google font */\n wp_enqueue_style('country-inn-googleapis', 'https://fonts.googleapis.com/css?family=Cutive+Mono%7CFira+Sans:300,300i,400,400i,500,500i,600,600i,700,800%7CRoboto+Condensed:400,700%7CRock+Salt%7CDawning+of+a+New+Day', array(), null);\n \n wp_enqueue_style('country-inn-style', get_stylesheet_uri());\n \n wp_enqueue_style('country-inn-skin', get_template_directory_uri() . '/assets/css/skin.css', array(), '4.5.0');\n\n wp_enqueue_style('country-inn-responsive', get_template_directory_uri() . '/assets/css/responsive.css', array(), '4.5.0');\n\n \n wp_enqueue_script('bootstrap', get_template_directory_uri() . '/assets/js/bootstrap.js', array('jquery'), '20151215', true);\n \n\n wp_enqueue_script('slick', get_template_directory_uri() . '/assets/js/slick.js', array('jquery'), '20151215', true); \n\n wp_enqueue_script('jarallax', get_template_directory_uri() . '/assets/js/jarallax.js', array('jquery'), '20151215', true);\n\n wp_enqueue_script('jquery-sticky', get_template_directory_uri() . '/assets/js/jquery.sticky.js', array('jquery'), '20151216', true);\n\n wp_enqueue_script('jquery-waypoints', get_template_directory_uri() . '/assets/js/jquery.waypoints.js', array('jquery'), '20151215', true);\n\n if( $enable_animation !=1 )\n {\n \n wp_enqueue_script('wow', get_template_directory_uri() . '/assets/js/wow.js', array('jquery'), '20151215', true);\n\n wp_enqueue_script('country-inn-custom-wow', get_template_directory_uri() . '/assets/js/custom-owl.js', array('jquery'), '20151215', true);\n \n }\n\n wp_enqueue_script('country-inn-main', get_template_directory_uri() . '/assets/js/main.js', array('jquery'), '201512169', true);\n\n if (is_singular() && comments_open() && get_option('thread_comments')) {\n wp_enqueue_script('comment-reply');\n }\n}", "function monalisa_scripts() {\n\t\n\t//google font\n\twp_enqueue_style( 'monalisa-google-fonts', monalisa_google_fonts_url(), array(), null );\t\n\twp_enqueue_style('bootstrap' , get_template_directory_uri(). '/assets/bootstrap/css/bootstrap.min.css');\t\n\twp_enqueue_style('font-awesome.min' , get_template_directory_uri(). '/assets/fonts/font-awesome.min.css');\t\n\twp_enqueue_style('owl.carousel' , get_template_directory_uri(). '/assets/owlcarousel/css/owl.carousel.css');\t\n\twp_enqueue_style('owl.theme' , get_template_directory_uri(). '/assets/owlcarousel/css/owl.theme.css');\t\n\twp_enqueue_style('prettyPhoto' , get_template_directory_uri(). '/assets/css/prettyPhoto.css');\t\n\twp_enqueue_style('flexslider' , get_template_directory_uri(). '/assets/css/flexslider.css');\t\n\twp_enqueue_style('animate' , get_template_directory_uri(). '/assets/css/animate.css');\t\n\twp_enqueue_style('monalisa-main-style' , get_template_directory_uri(). '/assets/css/style.css');\t\n\twp_enqueue_style( 'monalisa-style', get_stylesheet_uri() );\n\n\t// Load JS Files\n\twp_enqueue_script( 'html5shiv', get_template_directory_uri() . '/js/html5shiv.min.js', array(), '3.7.2' );\t\n\twp_script_add_data( 'html5shiv', 'conditional', 'lt IE 9' ); \t\n\twp_enqueue_script( 'respond', get_template_directory_uri() . '/js/respond.min.js', array(), '1.4.2' );\n\twp_script_add_data( 'respond', 'conditional', 'lt IE 9' ); \n\t\n\twp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/assets/bootstrap/js/bootstrap.min.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'modernizr', get_template_directory_uri() . '/assets/js/modernizr-2.8.3.min.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'jquery.inview.min', get_template_directory_uri() . '/assets/js/jquery.inview.min.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'jquery.flexslider-min', get_template_directory_uri() . '/assets/js/jquery.flexslider-min.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'jquery.prettyPhoto', get_template_directory_uri() . '/assets/js/jquery.prettyPhoto.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'owl.carousel.min', get_template_directory_uri() . '/assets/owlcarousel/js/owl.carousel.min.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'scrolltopcontrol', get_template_directory_uri() . '/assets/js/scrolltopcontrol.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'wow.min', get_template_directory_uri() . '/assets/js/wow.min.js', array('jquery'), '659812', true );\n\twp_enqueue_script( 'scripts', get_template_directory_uri() . '/assets/js/scripts.js', array('jquery'), '659812', true );\n\n\tif ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {\n\t\twp_enqueue_script( 'comment-reply' );\n\t}\n}", "function coc_scripts() {\r\n\t\t\r\n\t\twp_enqueue_script( 'script1', get_template_directory_uri() . '../bootstrap/js/bootstrap.js', array ( 'jquery' ), 1, true);\t\t\r\n\t\t\r\n\t\twp_enqueue_script( 'script2', get_template_directory_uri() . '../bootstrap/js/bootstrap.min.js', array ( 'jquery' ), 1, true);\t\r\n\t}", "function wpi_theme_js() {\n\n global $wp_scripts;\n\n wp_register_script('html5_shiv', 'https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js', '', '', false);\n wp_register_script('respond_js', 'https://oss.maxcdn.com/respond/1.4.2/respond.min.js', '', '', false);\n\n $wp_scripts->add_data('html5_shiv', 'conditional', 'lt IE 9');\n $wp_scripts->add_data('respond_js', 'conditional', 'lt IE 9');\n/**\n * Load javascripts used by the theme\n */\n\n\n\n \n wp_enqueue_script('main_js', get_template_directory_uri(). '/js/main.js', array('jquery'), '', true);\n wp_enqueue_script('bootstrap_js', get_template_directory_uri(). '/js/bootstrap.min.js', array('jquery'), '', true);\n \n \n \n \n\n }", "function prepare_scripts() {\n\twp_register_script('ajax_autofill', plugin_dir_url(__FILE__) . \"js/autofill_ajax.js\", array('jquery'));\n\twp_enqueue_script('ajax_autofill');\n}", "function my_scripts_files() {\n\twp_enqueue_script( 'jquery-js', get_template_directory_uri() . '/assets/js/jquery-1.11.1.min.js', false );\n\twp_enqueue_script( 'bootstrap-js', get_template_directory_uri() . '/assets/js/bootstrap.min.js', false );\n\twp_enqueue_script( 'rs-plugin-1-js', get_template_directory_uri() . '/assets/rs-plugin/js/jquery.themepunch.tools.min.js', false );\n\twp_enqueue_script( 'rs-plugin-2-js', get_template_directory_uri() . '/assets/rs-plugin/js/jquery.themepunch.revolution.min.js', false );\n\twp_enqueue_script( 'plugin-js', get_template_directory_uri() . '/assets/js/plugins.js', false );\n\twp_enqueue_script( 'fancybox-js', get_template_directory_uri() . '/assets/js/jquery/fancybox/jquery.fancybox.pack.js', false );\n\twp_enqueue_script( 'custom-js', get_template_directory_uri() . '/assets/js/custom.js', false );\n}", "function cam_enqueue_related_pages_scripts_and_styles(){\n // wp_enqueue_style('related-styles', plugins_url('/css/bootstrap.min.css', __FILE__));\n wp_enqueue_script('releated-script', plugins_url( '/js/custom.js' , __FILE__ ), array('jquery','jquery-ui-droppable','jquery-ui-draggable', 'jquery-ui-sortable'));\n }", "function legisletsdothis_load_resources() {\n \n global $post;\n\n if(has_shortcode($post->post_content, 'legisletsdothis')){\n wp_enqueue_script(\"legisletsdothis-googlemaps\", \"https://maps.googleapis.com/maps/api/js?key=AIzaSyCyXnRHRgaJSOpF-QuEpecokWC-rR4ynnQ\", array(), false, true);\n wp_enqueue_script(\"legisletsdothis-core-js\", plugins_url('legisletsdothis/legisletsdothis.js'), array(), '1.0.5', true);\n wp_enqueue_style(\"legisletsdothis-core-css\", plugins_url('legisletsdothis/legisletsdothis.css'), array(), '1.0.5');\n }\n }", "public function scripts() {\n\t\t// Make sure scripts are only added once via shortcode\n\t\t$this->add_scripts = true;\n\n\t\twp_register_script( 'jquery-form-validation', plugins_url( '/js/jquery.validate.min.js', __FILE__ ), array( 'jquery' ), '1.9.0', true );\n\t\twp_register_script( 'visual-form-builder-validation', plugins_url( \"/js/vfb-validation$this->load_dev_files.js\", __FILE__ ) , array( 'jquery', 'jquery-form-validation' ), '20140221', true );\n\t\twp_register_script( 'visual-form-builder-metadata', plugins_url( \"/js/jquery.metadata$this->load_dev_files.js\", __FILE__ ) , array( 'jquery', 'jquery-form-validation' ), '2.0', true );\n\t\twp_register_script( 'farbtastic-js', plugins_url( \"/js/farbtastic$this->load_dev_files.js\", __FILE__ ), array( 'jquery' ), '1.3', true );\n\t\twp_register_script( 'vfb-ckeditor', plugins_url( '/js/ckeditor/ckeditor.js', __FILE__ ), array( 'jquery' ), '4.1', true );\n\n\t\twp_enqueue_script( 'jquery-form-validation' );\n\t\twp_enqueue_script( 'visual-form-builder-validation' );\n\t\twp_enqueue_script( 'visual-form-builder-metadata' );\n\n\t\twp_localize_script( 'visual-form-builder-validation', 'VfbAjax', array( 'ajaxurl' => admin_url( 'admin-ajax.php' ) ) );\n\n\t\t$locale = get_locale();\n $translations = array(\n \t'cs_CS',\t// Czech\n \t'de_DE',\t// German\n \t'el_GR',\t// Greek\n \t'en_US',\t// English (US)\n \t'en_AU',\t// English (AU)\n \t'en_GB',\t// English (GB)\n \t'es_ES',\t// Spanish\n \t'fr_FR',\t// French\n \t'he_IL', \t// Hebrew\n \t'hu_HU',\t// Hungarian\n \t'id_ID',\t// Indonseian\n \t'it_IT',\t// Italian\n \t'ja_JP',\t// Japanese\n \t'ko_KR',\t// Korean\n \t'nl_NL',\t// Dutch\n \t'pl_PL',\t// Polish\n \t'pt_BR',\t// Portuguese (Brazilian)\n \t'pt_PT',\t// Portuguese (European)\n \t'ro_RO',\t// Romanian\n \t'ru_RU',\t// Russian\n \t'sv_SE',\t// Swedish\n \t'tr_TR', \t// Turkish\n \t'zh_CN',\t// Chinese\n \t'zh_TW',\t// Chinese (Taiwan)\n );\n\n\t\t// Load localized vaidation and datepicker text, if translation files exist\n if ( in_array( $locale, $translations ) ) {\n wp_register_script( 'vfb-validation-i18n', plugins_url( \"/js/i18n/validate/messages-$locale.js\", __FILE__ ), array( 'jquery-form-validation' ), '1.9.0', true );\n wp_register_script( 'vfb-datepicker-i18n', plugins_url( \"/js/i18n/datepicker/datepicker-$locale.js\", __FILE__ ), array( 'jquery-ui-datepicker' ), '1.0', true );\n\n wp_enqueue_script( 'vfb-validation-i18n' );\n }\n // Otherwise, load English translations\n else {\n\t wp_register_script( 'vfb-validation-i18n', plugins_url( \"/js/i18n/validate/messages-en_US.js\", __FILE__ ), array( 'jquery-form-validation' ), '1.9.0', true );\n wp_register_script( 'vfb-datepicker-i18n', plugins_url( \"/js/i18n/datepicker/datepicker-en_US.js\", __FILE__ ), array( 'jquery-ui-datepicker' ), '1.0', true );\n\n wp_enqueue_script( 'vfb-validation-i18n' );\n }\n\t}", "function custom_scripts() {\n\twp_enqueue_style( 'bootstrap_css', get_template_directory_uri() . '/css/bootstrap.css', array(), null);\n\t// wp_enqueue_style( 'b_css', get_template_directory_uri() . '/css/b.css', array(), null );\n\twp_enqueue_style( 'animate_css', get_template_directory_uri() . '/css/animate.min.css', array(), null );\n\twp_enqueue_style( 'font_awesome_css', get_template_directory_uri() . '/css/font-awesome.min.css', array(), null );\n\twp_enqueue_style( 'custom_css', get_stylesheet_uri(), array(), null );\n\twp_enqueue_style( 'carousel_css', get_template_directory_uri() . '/carousel.css', array(), null );\n\twp_enqueue_style( 'owl_carousel_css', get_template_directory_uri() . '/css/owl.carousel.css', array(), null );\n\twp_enqueue_style( 'owl_theme_css', get_template_directory_uri() . '/css/owl.theme.css', array(), null );\n\n\twp_enqueue_script( 'modernizr_js', get_template_directory_uri() . '/js/modernizr.custom.02.03.15.js', array('jquery'), false, true );\n\twp_enqueue_script( 'bootstrap_js', get_template_directory_uri() . '/js/bootstrap.js', array('modernizr_js'), false, true );\n\twp_enqueue_script( 'waypoints_js', get_template_directory_uri() . '/js/waypoints.min.js', array('bootstrap_js'), false, true );\n\twp_enqueue_script( 'owl_js', get_template_directory_uri() . '/js/owl.carousel.min.js', array('waypoints_js'), false, true );\n\t// wp_enqueue_script( 'masonry_js', get_template_directory_uri() . '/js/masonry.pkgd.min.js', array('owl_js'), false, true );\n}", "function tm_mbr_add_jquery(){\r\n\t//wp_enqueue_style('team-member-style', plugin_dir_url( __FILE__ ).'css/team-member-style.css', array(), 1.0 );\r\n\r\n\twp_enqueue_script( 'jquery' );\r\n\r\n\tif(is_admin()){\r\n\t\twp_enqueue_script( 'lp_admin_js', plugin_dir_url( __FILE__ ).'js/admin.js', array(), 1.0, true );\r\n\t\twp_localize_script( 'lp_admin_js', 'lp_admin_ajax', array(\r\n\t\t\t'ajaxurl'=>admin_url( 'admin-ajax.php' ),\r\n\t\t));\r\n\t}else{\r\n\t\twp_enqueue_script( 'lp_front_js', plugin_dir_url( __FILE__ ).'js/front-end.js', array(), 1.0, true );\r\n\t\twp_localize_script( 'lp_front_js', 'lp_front_ajax', array(\r\n\t\t\t'ajaxurl'=>admin_url( 'admin-ajax.php' ),\r\n\t\t));\r\n\t}\r\n}", "public function enqueue_scripts() {\n\n\t\t$min = \\wpforms_get_min_suffix();\n\n\t\tif ( \\wpforms_has_field_type( 'date-time', $this->form_data ) ) {\n\t\t\t\\wp_enqueue_script(\n\t\t\t\t'wpforms-maskedinput',\n\t\t\t\tWPFORMS_PLUGIN_URL . 'assets/js/jquery.inputmask.bundle.min.js',\n\t\t\t\tarray( 'jquery' ),\n\t\t\t\t'4.0.6',\n\t\t\t\ttrue\n\t\t\t);\n\t\t}\n\n\t\t\\wp_enqueue_script(\n\t\t\t'wpforms-conversational-forms-mobile-detect',\n\t\t\t\\wpforms_conversational_forms()->url . \"assets/js/vendor/mobile-detect{$min}.js\",\n\t\t\tarray(),\n\t\t\t'1.4.3',\n\t\t\ttrue\n\t\t);\n\n\t\t\\wp_enqueue_script(\n\t\t\t'wpforms-conversational-forms',\n\t\t\t\\wpforms_conversational_forms()->url . \"assets/js/conversational-forms{$min}.js\",\n\t\t\tarray( 'jquery', 'wpforms-conversational-forms-mobile-detect' ),\n\t\t\t\\WPFORMS_CONVERSATIONAL_FORMS_VERSION,\n\t\t\ttrue\n\t\t);\n\n\t\t\\wp_enqueue_style(\n\t\t\t'wpforms-conversational-forms',\n\t\t\t\\wpforms_conversational_forms()->url . \"assets/css/conversational-forms{$min}.css\",\n\t\t\tarray( 'wpforms-font-awesome' ),\n\t\t\t\\WPFORMS_CONVERSATIONAL_FORMS_VERSION\n\t\t);\n\n\t\t\\wp_localize_script(\n\t\t\t'wpforms-conversational-forms',\n\t\t\t'wpforms_conversational_forms',\n\t\t\tarray(\n\t\t\t\t'html' => $this->get_field_additional_html(),\n\t\t\t\t'i18n' => array(\n\t\t\t\t\t'select_placeholder' => \\esc_html__( 'Type or select an option', 'wpforms-conversational-forms' ),\n\t\t\t\t\t'select_list_empty' => \\esc_html__( 'No suggestions found', 'wpforms-conversational-forms' ),\n\t\t\t\t\t'select_option_helper' => \\wp_kses( __( '<strong>Enter</strong> to select option', 'wpforms-conversational-forms' ), array( 'strong' => array() ) ),\n\t\t\t\t),\n\t\t\t)\n\t\t);\n\n\t\t\\wp_enqueue_style(\n\t\t\t'wpforms-font-awesome',\n\t\t\tWPFORMS_PLUGIN_URL . 'assets/css/font-awesome.min.css',\n\t\t\tarray(),\n\t\t\t'4.7.0'\n\t\t);\n\t}", "function inject_scripts() {\n\n\tglobal $wp_styles, $wp_scripts;\n\n\t//Default way of loading styles. Version number added to ensure\n\t//the correct version is sent to the client regardless of caching.\n\twp_register_style( 'style', get_stylesheet_uri(), false, '1.0.0' );\n\twp_enqueue_style( 'style' );\n\n\t// Adds an ie8 and below stylesheet:\t\n\twp_enqueue_style( 'ie8_style', get_stylesheet_directory_uri() . '/css/ie8.css', array( 'style' ) );\n\twp_style_add_data( 'ie8_style', 'conditional', 'lte IE 8' );\n\n\n\t$js_dir = get_template_directory_uri() . '/js';\n\t$js_libs = $js_dir . '/bower_components';\n\n\t//Loads requirejs, all scripts are set true to push them into the footer:\n\twp_enqueue_script( 'requrejs', $js_libs . '/requirejs/require.js', array(), '', true );\n\n\n\t//config file that depends on requirejs.\n\twp_register_script( 'optimize', $js_dir . '/optimize.min.js', '', '', true );\n\n\n\t//Creates a json object so the configjs knows its directory. \n\twp_localize_script( 'optimize', 'dir', array(\n\t\t'path'\t\t=> $js_dir,\n\t\t'ajax_url'\t=> admin_url( 'admin-ajax.php' )\n\t));\n\n\n\twp_enqueue_script( 'optimize', '', '', '', true );\n\n\t// Styles for the lightbox plugin.\n\twp_register_style('lightbox-style', $js_libs . '/lightbox2/dist/css/lightbox.min.css' );\n\twp_enqueue_style( 'lightbox-style' );\n\n}", "function dvk_dequeue_scripts() {\n\t\t$load_scripts = false;\n\t\tif( is_singular() ) {\n\t\t\t$post = get_post();\n\t\t\tif( has_shortcode($post->post_content, 'contact-form-7') ) {\n\t\t\t\t$load_scripts = true;\n\t\t\t\t//Additional scripts that may be used with CF7\n\t\t\t\twp_enqueue_style( 'select2-style', '//cdnjs.cloudflare.com/ajax/libs/select2/4.0.0/css/select2.min.css' );\n\t\t\t\twp_enqueue_script( 'select2-js', '//cdnjs.cloudflare.com/ajax/libs/select2/4.0.0/js/select2.min.js');\n\t\t\t}\n\t\t}\n\t\tif( ! $load_scripts ) {\n\t\t\twp_dequeue_script( 'contact-form-7' );\n\t\t\twp_dequeue_style( 'contact-form-7' );\n\t\t}\n\t}", "public function enqueue_scripts($hook) {\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Points_Of_Sale_Admin_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Points_Of_Sale_Admin_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\tif ($hook != 'post.php' && $hook != 'post-new.php') {\n\t\t\treturn;\n\t\t}\n\n\t\t//DEFINE LANGUAGE OF GOOGLE MAPS\n\t\t$google_map_language = 'pt';\n\n\t\t$languageString = '';\n\t\tif ($google_map_language != '' && $google_map_language != 'pt') {\n\t\t\t$languageString = '&language=' . $google_map_language;\n\t\t}\n\n\t\t// INCLUDE THE .JS\n\t\tif (is_ssl()) {\n\t\t\twp_enqueue_script('pos_google_maps', 'https://maps.googleapis.com/maps/api/js?sensor=true&libraries=places' . $languageString);\n\t\t} else {\n\t\t\twp_enqueue_script('pos_google_maps', 'http://maps.googleapis.com/maps/api/js?sensor=true&libraries=places' . $languageString);\n\t\t}\n\n\t\twp_enqueue_script('pos_locationpicker', plugin_dir_url(__FILE__) . 'js/locationpicker.jquery.min.js', array('jquery'), $this->version, false);\n\t\twp_enqueue_script($this->plugin_name, plugin_dir_url(__FILE__) . 'js/points-of-sale-admin.js', array('pos_google_maps', 'jquery'), $this->version, false);\n\n\t\twp_localize_script($this->plugin_name, 'pos_locationpicker_data', $this->pos_localize_script());\n\n\t}", "function appglobe_jquery_enqueue() { \n\n /* \n Probably not necessary if called with the 'wp_enqueue_scripts' action.\n */\n if (is_admin()) return; \n\n global $wp_scripts; \n\n /*\n Change this flag to have the CDN script \n triggered by wp_footer instead of wp_head.\n If Google CDN is unavailable for some reason the flag \n will be ignored and the local WordPress \n jQuery gets enqueued and included in the head\n by the wp_head function.\n */\n $cdn_script_in_footer = false; \n /*\n Register jQuery from Google CDN.\n */\n if (is_a($wp_scripts, 'WP_Scripts') && isset($wp_scripts->registered['jquery'])) {\n /* \n The WordPress jQuery version. \n */\n $registered_jquery_version = $wp_scripts -> registered[jquery] -> ver; \n\n if($registered_jquery_version) {\n /* \n The jQuery Google CDN URL. \n Makes a check for HTTP on top of SSL/TLS (HTTPS) \n to make sure the URL is correct.\n */\n $google_jquery_url = ($_SERVER['SERVER_PORT'] == 443 ? \"https\" : \"http\") . \n \"://ajax.googleapis.com/ajax/libs/jquery/$registered_jquery_version/jquery.min.js\";\n\n /* \n Get the HTTP header response for the this URL, and check that its ok. \n If ok, include jQuery from Google CDN. \n */\n if(200 === wp_remote_retrieve_response_code(wp_remote_head($google_jquery_url))) {\n wp_deregister_script('jquery');\n wp_register_script('jquery', $google_jquery_url , false, null, $cdn_script_in_footer);\n }\n }\n }\n /* \n Enqueue jQuery from Google if available. \n Fall back to the local WordPress default.\n If the local WordPress jQuery is called, it will get \n included in the header no matter what the \n $cdn_script_in_footer flag above is set to.\n */\n wp_enqueue_script('jquery'); \n}", "function load_scripts() {\n wp_enqueue_script('bootstrap-js', 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js', array('jquery'), '4.0.0', true );\n wp_enqueue_style('bootstrap-css', 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css', array(), '4.0.0', 'all');\n wp_enqueue_style('base', get_template_directory_uri() . '/css/base.css', array(), '1.0', 'all');\n}", "function wpbootstrap_scripts_with_jquery() {\n wp_register_script('custom-script', get_template_directory_uri() . '/js/bootstrap.js', array('jquery'));\n wp_enqueue_script('custom-script');\n}", "function uptownwhere_scripts() {\r\n\t//Stylesheets\r\n\twp_register_style( 'normalize', get_template_directory_uri() . '/css/normalize.css' );\r\n\twp_enqueue_style( 'normalize' );\r\n\twp_register_style( 'style', get_template_directory_uri() . '/style.css' );\r\n\twp_enqueue_style( 'style' );\r\n\twp_register_style( 'theme', get_template_directory_uri() . '/css/theme.css' );\r\n\twp_enqueue_style( 'theme' );\r\n\twp_register_style( 'responsive', get_template_directory_uri() . '/css/responsive.css' );\r\n\twp_enqueue_style( 'responsive' );\r\n\twp_register_style( 'slick', get_template_directory_uri() . '/js/slick/slick.css' );\r\n\twp_enqueue_style( 'slick' );\r\n wp_register_style( 'swipebox', get_template_directory_uri() . '/js/swipebox/swipebox.css' );\r\n wp_enqueue_style( 'swipebox' );\r\n wp_register_style( 'lightbox', get_template_directory_uri() . '/js/lightbox/lightbox.css' );\r\n wp_enqueue_style( 'lightbox' );\r\n wp_register_style( 'fontawesome', '//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css');\r\n wp_enqueue_style( 'fontawesome' );\r\n\r\n\t//Scripts\r\n wp_enqueue_script( 'slick', get_template_directory_uri() . '/js/slick/slick.min.js', array('jquery'), '1.0.0', true );\r\n wp_enqueue_script( 'mapgenerator', get_template_directory_uri() . '/js/map-gen.js', array( 'jquery' ) );\r\n wp_enqueue_script( 'sticky', get_template_directory_uri() . '/js/sticky.js', array( 'jquery' ) );\r\n wp_enqueue_script( 'linkpreview', get_template_directory_uri() . '/js/linkpreview.js', array( 'jquery' ) );\r\n wp_enqueue_script( 'proxyajax', get_template_directory_uri() . '/js/proxy-ajax.js', array( 'jquery' ) );\r\n wp_enqueue_script( 'lightbox', get_template_directory_uri() . '/js/lightbox/lightbox.js', array( 'jquery' ) );\r\n wp_enqueue_script( 'swipebox', get_template_directory_uri() . '/js/swipebox/jquery.swipebox.min.js', array('jquery'), '1.0.0', true );\r\n wp_enqueue_script( 'function', get_template_directory_uri() . '/js/function.js', array('jquery', 'slick'), '1.0.0', true );\r\n\r\n}", "function mgc_enqueue_init() {\n if (!is_admin()) {\n wp_deregister_script('jquery');\n\n wp_enqueue_script('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js', null, null, true);\n wp_enqueue_script('jquery.validate', 'http://ajax.microsoft.com/ajax/jquery.validate/1.7/jquery.validate.min.js', array('jquery'), null, true);\n wp_enqueue_script('jquery.scrollto', get_bloginfo('template_url').'/scripts/jquery.scrollTo-1.4.2-min.js', array('jquery'), null, true);\n wp_enqueue_script('jquery.localscroll', get_bloginfo('template_url').'/scripts/jquery.localscroll-1.2.7-min.js', array('jquery', 'jquery.scrollto'), null, true);\n\n wp_enqueue_script('cufon', get_bloginfo('template_url').'/scripts/cufon-yui.js', null, null, true);\n wp_enqueue_script('chunk', get_bloginfo('template_url').'/style/fonts/ChunkFive_400.font.js', array('cufon'), null, true);\n\n wp_enqueue_script('mgc.main', get_bloginfo('template_url').'/scripts/MGC.main.js', array('jquery', 'jquery.validate', 'jquery.scrollto', 'jquery.localscroll'), null, true);\n wp_enqueue_script('mgc', get_bloginfo('template_url').'/scripts/MGC.js', array('jquery', 'cufon', 'mgc.main'), null, true);\n }\n}", "function wptest_scripts() {\n\t/* Loading Stylesheet! */\n\twp_enqueue_style( 'stylesheet ', get_stylesheet_uri(), array(), true );\n\twp_enqueue_style( 'dashicon-style', get_stylesheet_uri(), array( 'dashicons' ), true );\n\twp_register_style( 'bootstrap_reboot', get_template_directory_uri() . '/assets/css/bootstrap-reboot.min.css', array(), true );\n\twp_enqueue_style( 'bootstrap_reboot' );\n\twp_register_style( 'bootstrap_css', get_template_directory_uri() . '/assets/css/bootstrap.min.css', array(), true );\n\twp_enqueue_style( 'bootstrap_css' );\n\twp_register_style( 'layout_css', get_template_directory_uri() . '/assets/css/layout-main.min.css', array(), true );\n\twP_enqueue_style( 'layout_css' );\n\t/* Loading Scripts! */\n\twp_register_script( 'bootstrap_js', get_template_directory_uri() . '/assets/js/bootstrap.min.js', array( 'jquery' ), true );\n\twp_enqueue_script( 'bootstrap_js' );\n}", "function myweather_scripts(){\n\n wp_enqueue_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.css');\n wp_enqueue_script('jquery');\n\n wp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/js/bootstrap.js');\n wp_enqueue_script( 'script', get_template_directory_uri() . '/js/script.js', array('jquery'));\n\n}", "function wpbootstrap_scripts_with_jquery()\n{\n\twp_register_script( 'custom-script', get_template_directory_uri() . '/bootstrap/js/bootstrap.js', array( 'jquery' ) );\n\t// For either a plugin or a theme, you can then enqueue the script:\n\twp_enqueue_script( 'custom-script' );\n\n\t// \t// Register the script like this for a theme:\n\t// wp_register_script( 'parallax-script', get_template_directory_uri() . '/bootstrap/js/parallax.js', array( 'jquery' ) );\n\t// // For either a plugin or a theme, you can then enqueue the script:\n\t// wp_enqueue_script( 'parallax-script' );\n\n}", "public function public_enqueue_scripts() {\n wp_enqueue_script( 'jquery_focuspoint', plugin_dir_url( __FILE__ ) . 'js/jquery.focuspoint.min.js', array('jquery'), $this->version, true );\n wp_enqueue_script( 'wp_focuslock', plugin_dir_url( __FILE__ ) . 'js/wp-focuslock.js', array('jquery', 'jquery_focuspoint'), $this->version, true );\n }", "function wa_wcc_load_scripts($jquery_true) {\n\n\t\twp_register_style('wa_wcc_mtree_css_file', get_template_directory_uri().'/plugin/collapse/assets/css/mtree.css');\n\t\twp_enqueue_style('wa_wcc_mtree_css_file');\n\n\n\t\tif($this->options['configuration']['load_velocity'] === TRUE) {\n\n\t wp_register_script('wa_wcc_velocity',get_template_directory_uri().'/plugin/collapse/assets/js/jquery.velocity.min.js',array('jquery'),'',($this->options['configuration']['loading_place'] === 'header' ? false : true));\n\t wp_enqueue_script('wa_wcc_velocity'); \n\n\t\t}\n\n\t}" ]
[ "0.7688724", "0.7506284", "0.7400612", "0.7400038", "0.73943806", "0.7343996", "0.7318699", "0.7288863", "0.72575504", "0.72565913", "0.71974033", "0.71854246", "0.7171689", "0.71642244", "0.71556664", "0.7153486", "0.71473545", "0.7145843", "0.7135006", "0.7132085", "0.71201026", "0.711158", "0.7107954", "0.7084126", "0.7081276", "0.70797485", "0.70784694", "0.70635325", "0.70192504", "0.7018553", "0.7011479", "0.7007062", "0.70058835", "0.70002484", "0.6999152", "0.69553244", "0.6950594", "0.6947535", "0.69359404", "0.69356984", "0.69316024", "0.6930426", "0.6924344", "0.6924183", "0.692224", "0.6921437", "0.6915516", "0.6912791", "0.6902628", "0.6901882", "0.6891093", "0.68906355", "0.68830746", "0.68800807", "0.6874909", "0.6872948", "0.6871393", "0.68680996", "0.6865044", "0.6861085", "0.68607956", "0.68542737", "0.6853652", "0.6853318", "0.68523765", "0.68471736", "0.6843803", "0.68388957", "0.6838712", "0.6834943", "0.68345946", "0.6830842", "0.68192565", "0.68180984", "0.6817004", "0.6816824", "0.68129694", "0.68117106", "0.68065643", "0.6803138", "0.68015665", "0.67981076", "0.6794795", "0.6791834", "0.6791238", "0.67889804", "0.67888796", "0.67857164", "0.67850864", "0.67806166", "0.6778454", "0.6778311", "0.67668194", "0.67667943", "0.6765125", "0.67643636", "0.6758493", "0.67537665", "0.6751766", "0.6751467" ]
0.7588458
1
Properly enqueues stylesheets files into WP. 1) Bootsctap 2) WP Property Manger Styles 3) Font Awesome 4) Bootstrap Validator
function load_styles() { global $redux_options; $bs = $redux_options['opt-bootstrap']; if ( $bs == 1 ) { //Load from CDN// wp_enqueue_style( 'bootstrap-script', '//maxcdn.bootstrapcdn.com/bootstrap/3.3.2/css/bootstrap.min.css', array(), '3.3.2' ); } elseif ( $bs == 2 ) { //Load from plugin// wp_enqueue_style( 'bootstrap-script', dirname( __FILE__ ).'/assets/bootstrap/css/bootstrap.min.css', array(), '3.3.2' ); } elseif ( $bs == 3 ) { //load from nowhere... They have it loaded elsewhere... lets check to be sure though } else { //load from plugin. (fallback)// wp_enqueue_style( 'bootstrap-script', dirname( __FILE__ ).'/assets/bootstrap/css/bootstrap.min.css', array(), '3.3.2' ); } wp_enqueue_style( 'wppm-styes', plugin_dir_url( __FILE__ ).'assets/css/wppm.css', array(), '1'); wp_enqueue_style( 'fa-styes', plugin_dir_url( __FILE__ ).'assets/font-awesome/css/font-awesome.min.css', array(), '1'); wp_enqueue_style( 'bs-validate-css', plugin_dir_url( __FILE__ ).'assets/css/min/bootstrapValidator.min.css', array(), '.52'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function mocca_styles_files() {\n \n wp_enqueue_style('bootstrap-css', get_template_directory_uri() . '/css/bootstrap.min.css');\n wp_enqueue_style('fontawesome-css', get_template_directory_uri() . '/css/fontawesome-all.min.css');\n wp_enqueue_style('normalize-css', get_template_directory_uri() . '/css/normalize.css');\n wp_enqueue_style('main-css', get_template_directory_uri() . '/css/main.css');\n }", "function fincollect_styles() {\n wp_enqueue_style( 'fancybox', get_template_directory_uri() . '/assets/css/jquery.fancybox.css' );\n wp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.css' );\n wp_enqueue_style( 'main-style', get_stylesheet_uri() );\n }", "function cm_load_styles() {\n wp_enqueue_style( 'style', get_stylesheet_uri() );\n wp_enqueue_style( 'font-awesome', get_stylesheet_directory_uri() . '/css/font-awesome.min.css' );\n wp_enqueue_style( 'bootstrap', get_stylesheet_directory_uri() . '/css/bootstrap.min.css' );\n wp_enqueue_style( 'main', get_stylesheet_directory_uri() . '/css/main.css' );\n}", "function load_stylesheets(){\n /**/ \n\t\twp_register_style('mobiriseicon', get_template_directory_uri(). '/assets/web/assets/mobirise-icons2/mobirise2.css', '',2.0,'all');\n\t\twp_register_style('tether', get_template_directory_uri(). '/assets/tether/tether.min.css', '',1.0,'all');\n\t\twp_register_style('bootstrap', get_template_directory_uri(). '/assets/bootstrap/css/bootstrap.min.css', '',4.0,'all');\n\t\twp_register_style('bootstrapgrid', get_template_directory_uri(). '/assets/bootstrap/css/bootstrap-grid.min.css', '',4.0,'all');\n\t\twp_register_style('bootstrapreboot', get_template_directory_uri(). '/assets/bootstrap/css/bootstrap-reboot.min.css', '',4.0,'all');\n\t\twp_register_style('dropdown', get_template_directory_uri(). '/assets/dropdown/css/style.css', '',5.1,'all');\n\t\twp_register_style('socicon', get_template_directory_uri(). '/assets/socicon/css/styles.css', '',3.0,'all');\n\t\twp_register_style('themestyle', get_template_directory_uri(). '/assets/theme/css/style.css', '',3.0,'all');\n\t\twp_register_style('addstyle', get_template_directory_uri(). '/assets/mobirise/css/mbr-additional.css', '',3.0,'all');\n\t\twp_register_style('appcss', get_template_directory_uri(). '/assets/css/app.css', '',0.1,'all');\n \n wp_enqueue_style('mobiriseicon');\n wp_enqueue_style('tether');\n wp_enqueue_style('bootstrap');\n wp_enqueue_style('bootstrapgrid');\n wp_enqueue_style('bootstrapreboot');\n wp_enqueue_style('dropdown');\n wp_enqueue_style('socicon');\n wp_enqueue_style('themestyle');\n wp_enqueue_style('addstyle');\n wp_enqueue_style('appcss');\n}", "function styles_load_custom()\n{\n wp_register_style( 'google-fonts-roboto-style',\n '//fonts.googleapis.com/css?family=Roboto',\n array(), '', 'all' );\n wp_enqueue_style( 'google-fonts-roboto-style' );\n\n wp_register_style( 'font-awesome-style-cdn',\n '//maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css',\n array(), '4.7.0', 'all' );\n wp_enqueue_style( 'font-awesome-style-cdn' );\n\n wp_register_style( 'bootstrap-style-cdn',\n '//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css',\n array(), '3.3.7', 'all' );\n wp_enqueue_style( 'bootstrap-style-cdn' );\n\n wp_register_style( 'bootstrap-theme-style-cdn',\n '//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap-theme.min.css',\n array('bootstrap-style-cdn'), '3.3.7', 'all' );\n wp_enqueue_style( 'bootstrap-theme-style-cdn' );\n\n wp_enqueue_style( 'theme-styles', get_stylesheet_directory_uri() . '/style.css', array(), filemtime( get_stylesheet_directory() . '/style.css' ) );\n\n\n}", "function enqueue_our_required_stylesheets(){\n\twp_enqueue_style('font-awesome', '//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css');\n\twp_enqueue_style('custom', get_stylesheet_directory_uri() . '/custom.css');\n}", "function load_stylesheets()\n{\n // 1. Download bootstrap css from serwer (katalog otoedu)\n wp_register_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css', array(), false, 'all');\n wp_enqueue_style('bootstrap');\n\n // 2. Download style css from serwer (katalog otoedu)\n // It is my style (not bootstrap). That must be second position\n wp_register_style('style', get_template_directory_uri() . '/style.css', array(), false, 'all');\n wp_enqueue_style('style');\n}", "function realEDU_theme_enqueue_styles(){\n\t\twp_enqueue_style('bootstrap-base', get_template_directory_uri() . \"/node_modules/bootstrap/dist/css/bootstrap.css\");\n\t\twp_enqueue_style('font-awesome', get_template_directory_uri() . \"/node_modules/font-awesome/css/font-awesome.css\");\n\n\t\twp_enqueue_style('stylesheet-default', get_template_directory_uri() . \"/style.css\");\n\t\twp_enqueue_style('custom-styles', get_template_directory_uri() . \"/css/app.css\");\n\t}", "function wpi_theme_styles() {\n wp_enqueue_style('bootstrap_css', get_template_directory_uri() . '/css/bootstrap.min.css');\n wp_enqueue_style('main_css', get_template_directory_uri() . '/style.css');\n \n \n\n }", "function hsbc_theme_stylesheets() {\r\n wp_enqueue_style( 'hsbc-theme-materialize-style', get_template_directory_uri() .'/assets/css/materialize.min.css', array(), null, 'all' );\r\n wp_enqueue_style( 'hsbc-theme-hsbc-style', get_template_directory_uri() .'/assets/css/hsbc.css', array('hsbc-theme-materialize-style'), null, 'all' );\r\n wp_enqueue_style( 'hsbc-theme-required-style', get_stylesheet_uri(), '', null, 'all' );\r\n}", "function purpleBlog_resources() {\n\n\t/*-- stylesheets ---*/\n\twp_enqueue_style( 'style', get_stylesheet_uri() );\n\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/css/bootstrap.css' );\n\twp_enqueue_style( 'bootstrap_theme', get_template_directory_uri() . '/css/bootstrap-theme.css' );\n}", "function blueauthentic_load_styles() {\n\t$theme_version = wp_get_theme()->get( 'Version' );\n\twp_enqueue_style( 'blueauthentic-css', get_template_directory_uri() . '/style.css', array( 'blueauthentic-bootstrap', 'blueauthentic-fontawesome' ), $theme_version, 'all' );\n\twp_enqueue_style( 'blueauthentic-bootstrap', 'https://maxcdn.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css', array(), '4.5.2', 'all' );\n\twp_enqueue_style( 'blueauthentic-fontawesome', 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/all.min.css', array(), '5.15.1', 'all' );\n}", "function jk_styles(){\n\twp_enqueue_style('bootstrap_css',get_stylesheet_directory_uri().'/css/bootstrap.min.css');\n\twp_enqueue_style('social media fonts','https://use.fontawesome.com/releases/v5.0.10/css/all.css\" integrity=\"sha384-+d0P83n9kaQMCwj8F4RJB66tzIwOKmrdb46+porD/OvrJ+37WqIM7UoBtwHO6Nlg\" crossorigin=\"anonymous\"');\n\twp_enqueue_style('fonts', \"http://fonts.googleapis.com/icon?family=Material+Icons\");\n\n\n}", "function womendevs_enqueue_style() {\n \n // Bootstrap CSS\n wp_enqueue_style( 'bootstrap', '//stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css' , false ); \n\n // Google Font\n wp_enqueue_style( 'googlefont', '//fonts.googleapis.com/css?family=Roboto' , false ); \n \n // Font Awesome\n wp_enqueue_style( 'fontawesome', '//use.fontawesome.com/releases/v5.8.1/css/all.css' , false );\n\n // Ma feuille CSS\n wp_enqueue_style( 'core', get_stylesheet_uri() , false ); \n}", "function add_style()\r\n{\r\n wp_enqueue_style(\r\n 'bootstrap'\r\n , get_template_directory_uri().'/css/bootstrap.min.css'\r\n );\r\n wp_enqueue_style(\r\n 'fontawesome'\r\n , get_template_directory_uri().'/css/font-awesome.min.css'\r\n );\r\n wp_enqueue_style(\r\n 'main'\r\n , get_template_directory_uri().'/css/main.css'\r\n ); \r\n\r\n}", "function cbusds_styles()\n{\n\n wp_register_style('w3css', get_template_directory_uri() . '/css/w3.css', array(), '', 'all');\n wp_enqueue_style('w3css'); // Enqueue it!\n\n wp_register_style('normalize', get_template_directory_uri() . '/normalize.css', array(), '1.0', 'all');\n wp_enqueue_style('normalize'); // Enqueue it!\n\n wp_register_style('cbusdscss', get_template_directory_uri() . '/style.css', array(), '1.0', 'all');\n wp_enqueue_style('cbusdscss'); // Enqueue it!\n}", "function coc_styles() {\r\n\t\t\r\n\t\twp_enqueue_style( 'style1', get_template_directory_uri() . '../css/bootstrap.css',false,'1','all');\r\n\t\t\r\n\t\twp_enqueue_style( 'style2', get_stylesheet_uri() );\r\n\t\t\r\n\t\twp_enqueue_style( 'style3', get_template_directory_uri() . '../bootstrap/css/bootstrap.css',false,'1','all');\r\n\t\t\r\n\t\twp_enqueue_style( 'style4', get_template_directory_uri() . '../bootstrap/css/bootstrap.min.css',false,'1','all');\r\n\t\t\t\t\r\n\t}", "function ROMP_enquiry_form_admin_assets(){\n\t\twp_enqueue_style('CSS-bootstrap-min', 'https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/css/bootstrap.min.css');\n\t\twp_enqueue_script('JS-bootstrap-min', 'https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.3.1/js/bootstrap.min.js');\n\t\twp_enqueue_style( 'ROMP-enquiry-form-css', plugins_url( 'romp-enquiry-plugin/assets/css/style.css'), 20, 1 );\n\t}", "function re_add_my_stylesheet() {\n // Respects SSL, Style.css is relative to the current file\n wp_enqueue_style( 'variations', get_stylesheet_directory_uri() . '/assets/css/variations.css' );\n wp_enqueue_style( 'base', get_stylesheet_directory_uri() . '/assets/css/base.css' );\n wp_enqueue_style( 'flexslider', get_stylesheet_directory_uri() . '/assets/css/flexslider.css' );\n \n /* Themes */\n\n // wp_enqueue_style( 'westwaters', get_stylesheet_directory_uri() . '/westwaters/custom.css' ); \n wp_enqueue_style( 'jumplife', get_stylesheet_directory_uri() . '/jumplife/custom.css' );\n\n /* END Themes */\n\n wp_enqueue_style('font-awesome', '//netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.css');\n //wp_enqueue_script('smooth-scrolling', get_stylesheet_directory_uri() . '/assets/js/smooth-scrolling.js');\n wp_enqueue_script('flex-slider', get_stylesheet_directory_uri() . '/assets/js/jquery.flexslider-min.js');\n\n}", "function my_assets() {\n\n\twp_enqueue_style( 'bootstrap.css', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css');\n\n\twp_enqueue_style( 'fontawesome.css', \"https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css\");\n\n\twp_enqueue_style('customstyle', get_template_directory_uri() . '/style.css');\n}", "function get_css_files() {\n\n wp_enqueue_style( 'cookieconsent', get_template_directory_uri() . '/vendor/cookieconsent/cookieconsent.min.css' );\n\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/vendor/bootstrap/bootstrap.min.css' );\n\twp_enqueue_style( 'styles', get_template_directory_uri() . '/css/styles.css' );\n\n}", "function styles() {\n\t/**\n\t * Flag whether to enable loading uncompressed/debugging assets. Default false.\n\t *\n\t * @param bool additive_style_debug\n\t */\n\t$debug = apply_filters( 'additive_style_debug', false );\n\t$min = ( $debug || defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';\n\n\twp_enqueue_style( 'additive-fonts',\n\t\t\"https://fonts.googleapis.com/css?family=Arvo:400,700|Lato:300,400,700\",\n\t\tarray(),\n\t\tnull\n\t);\n\n\twp_enqueue_style(\n\t\t'normalize',\n\t\tADDITIVE_URL . \"/assets/css/normalize{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n\n\twp_enqueue_style(\n\t\t'skeleton',\n\t\tADDITIVE_URL . \"/assets/css/skeleton{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n\n\twp_enqueue_style(\n\t\t'additive',\n\t\tADDITIVE_URL . \"/assets/css/additive{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n\n\twp_enqueue_style(\n\t\t'font-awesome',\n\t\tADDITIVE_URL . \"/assets/css/font-awesome{$min}.css\",\n\t\tarray(),\n\t\tADDITIVE_VERSION\n\t);\n}", "function elzero_style() {\n wp_enqueue_style('font-awesome-style' , get_template_directory_uri() . '/assets/css/font-awesome.min.css', array(),'4.7.0');\n wp_enqueue_style('bootstrap-style' , get_template_directory_uri() . '/assets/css/bootstrap.min.css', array(),'4.0.0-alpha.6');\n wp_enqueue_style('my-style' , get_template_directory_uri() . '/assets/css/style.min.css', array(),'1.0.0');\n}", "function load_css()\n{\n wp_register_style('bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.min.css', array(), false, 'all');\n wp_enqueue_style('bootstrap');\n\n wp_register_style('main', get_template_directory_uri() . '/assets/css/index.css', array(), false, 'all');\n wp_enqueue_style('main');\n\n wp_register_style('media-query', get_template_directory_uri() . '/assets/css/index.mediaquery.css', array(), false, 'all');\n wp_enqueue_style('media-query');\n\n wp_register_style('menu', get_template_directory_uri() . '/assets/css/menu.css', array(), false, 'all');\n wp_enqueue_style('menu');\n\n wp_register_style('archive', get_template_directory_uri() . '/assets/css/archive.css', array(), false, 'all');\n wp_enqueue_style('archive');\n\n wp_register_style('swiper', get_template_directory_uri() . '/assets/css/swiper-bundle.min.css', array(), false, 'all');\n wp_enqueue_style('swiper');\n\n wp_register_style('font-css', get_template_directory_uri() . '/assets/fonts/stylesheet.css', array(), false, 'all');\n wp_enqueue_style('font-css');\n}", "function plugin_admin_styles() {\r\n\t\t\t// used by media upload\r\n\t\t\twp_enqueue_style('thickbox');\r\n\t\t\t// Register & enqueue our admin.css file \r\n\t\t\twp_register_style('framework', $this->framework_url .'framework.css');\r\n\t\t\twp_enqueue_style('framework');\r\n\t\t\t// color picker\r\n\t\t\twp_enqueue_style( 'farbtastic' );\r\n\t\t\r\n\t\t}", "function basics_enqueue_styles() {\n wp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/assets/css/bootstrap.min.css' );\n wp_enqueue_style( 'basics-style', get_template_directory_uri() . '/style.css');\n}", "function load_tiul_stylesheets(){\n// wp_enqueue_style('bootstrap');\n\n// wp_register_style('animate', get_template_directory_uri(). '/css/animate.css', array(), 1, 'all');\n// wp_enqueue_style('animate');\n\n// wp_register_style('font', get_template_directory_uri(). '/css/font-awesome.min.css', array(), 1, 'all');\n// wp_enqueue_style('font');\n\n// wp_register_style('theme', get_template_directory_uri(). '/css/owl.theme.css', array(), 1, 'all');\n// wp_enqueue_style('theme');\n\n// wp_register_style('carousel', get_template_directory_uri(). '/css/owl.carousel.css', array(), 1, 'all');\n// wp_enqueue_style('carousel');\n\n wp_register_style('style', get_template_directory_uri(). '/style.css', array(), 1, 'all');\n wp_enqueue_style('style');\n\n}", "function enqueue_styles_and_scripts() {\n\n\twp_enqueue_style('bootstrap', '//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css');\n\twp_enqueue_style('animate', get_theme_file_uri('/css/animate.css'));\n\twp_enqueue_style('et-line', get_theme_file_uri('/css/et-line.min.css'));\n\twp_enqueue_style('font-awesome', get_theme_file_uri('/css/font-awesome.min.css'));\n\n // Theme's default font from google fonts\n wp_enqueue_style('font-montserrat', '//fonts.googleapis.com/css?family=Montserrat');\n\n\t// Theme main stylesheet.\n\t// Update version automatically after each file modification\n \t$mainCssSrc = get_stylesheet_uri();\n\t$mainCssVer = filemtime( get_stylesheet_directory() . '/style.css');\n\n\twp_enqueue_style('main_style', $mainCssSrc, array(), $mainCssVer);\n\n // JS includes\n\twp_enqueue_script('bootstrap_js', '//maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js');\n\twp_enqueue_script('blocs', get_theme_file_uri('/js/blocs.js'), array('jquery'), '0.2', true);\n}", "function cg_framework_admin_styles($hook)\n{\n // LOADING BOOTSTRAP 4 ON THE WP ADMIN SIDE\n // wp_register_style(\n // 'wpplugin-admin-bootstrap',\n // 'https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css',\n // [],\n // time()\n // );\n\n // wp_enqueue_style('wpplugin-admin-bootstrap');\n\n // LOADING MAIN PLUGIN ADMIN SIDE STYLES\n wp_register_style(\n 'cg-framework-admin',\n CG_FRAMEWORK_URL . 'admin/assets/dist/css/admin.min.css',\n [],\n time()\n );\n\n wp_enqueue_style('cg-framework-admin');\n}", "function parques_styles()\n{ \n\t// add general style\n\twp_enqueue_style( 'style', get_template_directory_uri().'/style.css',array(),'3.0.2' );\n\n\t// add css bootstrap\n\twp_enqueue_style( 'bootstrap-css', get_template_directory_uri().'/bootstrap-3.2.0/css/bootstrap.min.css',array(),'3.0.2' );\n\twp_enqueue_style( 'bootstrap-theme', get_template_directory_uri().'/bootstrap-3.2.0/css/bootstrap-theme.min.css',array(),'3.0.2' );\n\twp_enqueue_style( 'bootstrap-map', get_template_directory_uri().'/bootstrap-3.2.0/css/bootstrap.css.map',array(),'3.0.2' );\n\twp_enqueue_style( 'bootstrap-theme-map', get_template_directory_uri().'/bootstrap-3.2.0/css/bootstrap-theme.css.map',array(),'3.0.2' );\n}", "public function enqueue_styles() {\n\n\t\tif ($this->css) {\n\t\t\tforeach ($this->css as $css) {\n\t\t\t\t$fileTitle = basename($css['link']);\n\t\t\t\t$fileTitle = str_replace('.css', '', $fileTitle);\n\t\t\t\t$fileTitle = preg_replace(\n\t\t\t\t\t'/[^0-9a-zA-Z]/',\n\t\t\t\t\t\"-\",\n\t\t\t\t\tstr_replace('@', '', $css['package']) . '-' . $fileTitle\n\t\t\t\t);\n\t\t\t\twp_enqueue_style($fileTitle, $css['link'], array(), $css['version'], 'all');\n\t\t\t}\n\t\t}\n\n\t}", "public function enqueue_styles() {\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/deeppress-admin.css', array(), $this->version, 'all' );\n\t\twp_enqueue_style( \n\t\t\t$this->plugin_name.'-imageview', plugin_dir_url( __FILE__ ) . 'css/jquery.imageview.css', \n\t\t\tarray(), \n\t\t\t$this->version, 'all' \n\t\t);\n\t\twp_enqueue_style( \n\t\t\t$this->plugin_name.'-annotorious', plugin_dir_url( __FILE__ ) . 'css/jquery.selectareas.css', \n\t\t\tarray(), \n\t\t\t$this->version, 'all' \n\t\t);\n\t\twp_enqueue_style(\n\t\t\t$this->plugin_name.'-lightgallery', plugin_dir_url( __FILE__ ) . 'css/lightgallery.min.css',\n\t\t\tarray(),\n\t\t\t$this->version, 'all'\n\t\t);\n\n\t}", "function add_css() \n {\n if( $this->options['use-css-file'] ) {\n wp_register_style( 'bbquotations-style' , $this->plugin_url . 'bbquotations-style.css');\n wp_enqueue_style( 'bbquotations-style' );\n } \n }", "function theme_styles() {\r\n\twp_enqueue_style( 'bootstrap_css', get_template_directory_uri() . '/css/bootstrap.min.css');\r\n\twp_enqueue_style( 'main_css', get_template_directory_uri() . '/style.css');\r\n}", "function capstone_frontend_styles() {\n\t\tif ( !is_admin() ) {\n\n\t\t\t// Libraries Styles\n\t\t\twp_enqueue_style('fontawesome', CAPSTONE_CSS_URI . '/lib/font-aswesome.css');\n\t\t\twp_enqueue_style('icheck', CAPSTONE_JS_URI . '/lib/icheck/square/blue.css');\n\t\t\twp_enqueue_style('material-icons', 'https://fonts.googleapis.com/icon?family=Material+Icons');\n\t\t\twp_enqueue_style('flickity', CAPSTONE_CSS_URI . '/lib/flickity.min.css');\n\t\t\twp_enqueue_style('mapbox', 'https://api.mapbox.com/mapbox-gl-js/v0.52.0/mapbox-gl.css');\n\t\t\twp_enqueue_style('mapbox-geocoder', 'https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-geocoder/v2.3.0/mapbox-gl-geocoder.css');\n\t\t\t\n\t\t\t// Theme Styles\n\t\t\twp_enqueue_style('capstone-main', CAPSTONE_CSS_URI . '/main.min.css', array('wp-mediaelement'));\n\t\t\t\n\t\t\t// Google Fonts\n\t\t\twp_enqueue_style('capstone-fonts', capstone_fonts_url(), array(), '1.0.0');\n\t\t\t\n\t\t\t// Add Inline Styles (dynamic)\n\t\t\tob_start();\n\t\t\trequire( get_template_directory() .'/styles/dynamic.php' );\n\t\t\t$dynamic_css = ob_get_clean();\n\t wp_add_inline_style('capstone-main', $dynamic_css);\n\t\t}\n\t}", "public function action_wp_enqueue_scripts() {\n\n\t\twp_enqueue_style( 'bootstrap', get_stylesheet_directory_uri() . '/lib/bootstrap/dist/css/bootstrap.css' );\n\t\twp_enqueue_style( 'core-style', get_stylesheet_directory_uri() . '/assets/stylesheets/core.css' );\n\n\t}", "function zweidrei_eins_register_styles() {\n\n\t$theme_version = wp_get_theme()->get( 'Version' ); \n\twp_enqueue_style( 'style', get_stylesheet_uri(), array(), $theme_version );\n\n\t/** \t\n\t * Add custom css\n\t * Bulma: Free, open source, and modern CSS framework based on Flexbox\n\t * https://bulma.io/ \n\t * Version: 0.9.0\n\t * Child: custom.css\n\t */\n\twp_enqueue_style( 'style1', get_template_directory_uri() . '/assets/css/bulma.min.css', array(), $theme_version );\n\twp_enqueue_style( 'style2', get_template_directory_uri() . '/assets/css/custom.css', array(), $theme_version );\n\n\t\n\n}", "function lb_styles() {\n\n \n wp_enqueue_style( 'bootstrap_css', 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css' );\n\n wp_enqueue_style( 'font_awesome', 'https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css' );\n\n wp_enqueue_style( 'slick_css', '//cdn.jsdelivr.net/gh/kenwheeler/[email protected]/slick/slick.min.css' );\n\n wp_enqueue_style( 'main_css', get_template_directory_uri() . '/style.css' );\n\n}", "function css_files() {\n\t\twp_enqueue_style('escalate_network-admin-global', $this->plugin_url .'/css/styles-admin-global.css');\n\t}", "public function enqueue_styles_and_stuffs() {\n\t\t // libraries\n\t\t wp_enqueue_style( 'woocommerce_prettyPhoto_css' );\n\t\t\twp_enqueue_style( 'jquery-selectBox' );\n\t\t\twp_enqueue_style( 'yith-wcwl-font-awesome' );\n\n\t\t\t// main plugin style\n\t\t\tif ( ! wp_style_is( 'yith-wcwl-user-main', 'registered' ) ) {\n\t\t\t\twp_enqueue_style( 'yith-wcwl-main' );\n\t\t\t}\n\t\t\telse {\n\t\t\t\twp_enqueue_style( 'yith-wcwl-user-main' );\n\t\t\t}\n\n\t\t\t// theme specific style\n\t\t\tif( wp_style_is( 'yith-wcwl-theme', 'registered' ) ){\n\t\t\t wp_enqueue_style( 'yith-wcwl-theme' );;\n }\n\n\t\t\t// custom style\n\t\t\t$this->enqueue_custom_style();\n\t\t}", "function front_end_styles()\n{\n\twp_register_style( 'front-end-normalize', get_template_directory_uri() . '/css/reset.css', array(), null, 'all' );\n wp_register_style( 'front-end-styles', get_template_directory_uri() . '/css/styles.css', array(), null, 'all' );\n wp_register_style( 'front-end-plugins', get_template_directory_uri() . '/css/plugins.css', array(), null, 'all' );\n wp_register_style( 'front-end-media-queries', get_template_directory_uri() . '/css/media-queries.css', array(), null, 'all' );\n \n \n wp_enqueue_style( 'front-end-normalize' );\n wp_enqueue_style( 'front-end-styles' );\n wp_enqueue_style( 'front-end-plugins' );\n wp_enqueue_style( 'front-end-media-queries' );\n}", "function load_bootstrap()\n{\n wp_enqueue_style( 'bootstrap.min', get_template_directory_uri() . '/css/bootstrap.min.css');\n wp_enqueue_style( 'style.css', get_template_directory_uri() . '/style.css');\n}", "function theme_styles() {\n wp_enqueue_style('bootstrap-css', get_template_directory_uri . '/css/bootstrap.min.css', array(), '', 'all');\n // wp_enqueue_style('bootstrap-theme', get_template_directory_uri . '/css/bootstrap-theme.min.css', array('bootstrap-css'), '', 'all');\n}", "function my_styles_files() {\n\twp_enqueue_style( 'montserrat-css', 'https://fonts.googleapis.com/css?family=Montserrat:400,700', false );\n\twp_enqueue_style( 'roboto-css', 'https://fonts.googleapis.com/css?family=Roboto:400,300,500,700', false );\n\twp_enqueue_style( 'bootstrap-css', get_template_directory_uri() . '/assets/css/bootstrap.css', false );\n\twp_enqueue_style( 'animate-css', get_template_directory_uri() . '/assets/css/animate.css', false );\n\twp_enqueue_style( 'jquery-ui-css', get_template_directory_uri() . '/assets/css/jquery-ui.css', false );\n\twp_enqueue_style( 'simple-line-icons-css', get_template_directory_uri() . '/assets/css/simple-line-icons.css', false );\n\twp_enqueue_style( 'font-awesome-css', get_template_directory_uri() . '/assets/css/font-awesome.min.css', false );\n\twp_enqueue_style( 'icon-font-css', get_template_directory_uri() . '/assets/css/icon-font.css', false );\n\twp_enqueue_style( 'auction-css', get_template_directory_uri() . '/assets/css/auction.css', false );\n\twp_enqueue_style( 'rs-plugin-css', get_template_directory_uri() . '/assets/rs-plugin/css/settings.css', false );\n\twp_enqueue_style( 'fancybox-css', get_template_directory_uri() . '/assets/js/jquery/fancybox/jquery.fancybox.css', false );\n\tif ( is_child_theme() ) {\n\t\twp_enqueue_style( 'parent-css', trailingslashit( get_template_directory_uri() ) . 'style.css', false );\n\t}\n\twp_enqueue_style( 'theme-css', get_stylesheet_uri(), false );\n}", "function hankart_enqueue_styles() {\n // wp_dequeue_style( 'font-awesome' );\n // wp_dequeue_style( 'storefront-fonts' );\n // wp_dequeue_style( 'source-sans-pro' );\n // wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css' );\n // wp_enqueue_style( 'child-style', get_stylesheet_directory_uri() );\n wp_enqueue_style( 'load-fa', 'https://cdn.jsdelivr.net/npm/@fortawesome/[email protected]/css/fontawesome.min.css' );\n}", "function script_n_styles_func() {\n\n wp_enqueue_style( 'custom-stylesheet', PLUGINS_URL( '/css/custom.css', __FILE__ ) );\n wp_enqueue_style( 'font-awesome-cdn', 'https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css' );\n\n }", "function clea_base_enqueue_styles() {\n\t\n\t/*\n\t* enqueue font awesome 4.0 from CDN\n\t* @since 1.1.0\n\t*/\n\twp_enqueue_style( 'font-awesome', 'https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css' );\n\t\n\n\t/*\n\t* @since 1.1.0\n\t* specific style added to the unique style.css file\n\t*/\n\twp_enqueue_style( 'clea-specific', trailingslashit( THEME_URI ) . 'css/clea-specific.css' );\t\n}", "function theme_scripts()\r\n{\r\n // Load Bootstrap\r\n\twp_enqueue_style( 'theme-bootstrap', get_theme_file_uri( '/assets/vendor/bootstrap/css/bootstrap.min.css' ));\r\n\t// Load Font-Awesome\r\n\twp_enqueue_style( 'theme-fontawesome', get_theme_file_uri( '/assets/vendor/font-awesome/css/all.min.css' ));\r\n // Theme stylesheet.\r\n\twp_enqueue_style( 'theme-style', get_stylesheet_uri() );\r\n}", "function weeklypowerup_enqueue_styles()\n{\n\n\t wp_enqueue_style(\"add_normalize\", \t\tget_template_directory_uri() \t. \"/assets/css/normalize.css\");\n\n\t wp_enqueue_style(\"add_webflow_css\", \tget_template_directory_uri() \t. \"/assets/css/webflow.css\");\n\n\t wp_enqueue_style(\"add_weekly_css\", \tget_template_directory_uri() \t. \"/assets/css/weeklypowerup.webflow.css\");\n\n\t wp_enqueue_style(\"add_nunito_font\", \t\t\t\t\t\t\t\t'https://fonts.googleapis.com/css?family=Nunito', false); \n\n\t wp_enqueue_script('add_prism_js', \t\tget_template_directory_uri() \t. '/assets/js/prism.js');\n\t\n\t wp_enqueue_style(\"add_prism_css\", \tget_template_directory_uri() \t. \"/assets/css/prism.css\");\n\n wp_enqueue_style(\"frontpage-custom\", \tget_template_directory_uri() . \"/assets/css/frontpage.css\");\n\n\t wp_enqueue_script('add_webflow_js', \tget_template_directory_uri() \t. '/assets/js/webflow.js', array( 'jquery' ));\n \n wp_enqueue_style(\"weeklypowerup-style\", get_stylesheet_uri());\n \n \n}", "function mvc_bootstrap_enqueue_styles() {\n wp_enqueue_style( 'bootstrap_css', \"https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css\");\n }", "function bwcr_enqueue(){\n wp_enqueue_style( 'bwcr-style', plugin_dir_url( __FILE__ ) . 'style.css', array(), filemtime(plugin_dir_path( __FILE__ ) . 'style.css'), false );\n wp_enqueue_script( 'bwcr-script', plugin_dir_url( __FILE__ ) . 'script.js', array(), filemtime(plugin_dir_path( __FILE__ ) . 'script.js'), false );\n wp_enqueue_style( 'font-awe', 'https://use.fontawesome.com/releases/v5.6.3/css/all.css', array(), '5.6.3', false );\n}", "function monza_mod_enqueue_styles() {\n\n $parent_style = 'monza-style';\n $parent_dir = get_template_directory_uri();\n\n wp_enqueue_style('bootstrap', get_template_directory_uri() . '/libs/bootstrap/css/bootstrap.min.css');\n wp_enqueue_style('font-awesome', get_template_directory_uri() . '/libs/font-awesome/css/font-awesome.min.css');\n wp_enqueue_style('owl-carousel', get_template_directory_uri() . '/libs/owl/owl.carousel.css');\n wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );\n\n if ( function_exists('monza_custom_style')) {\n wp_add_inline_style( 'monza-style', monza_custom_style() );\n }\n\n // enqueue the modification last\n wp_enqueue_style( 'monza-mod-vyh-style',\n get_stylesheet_directory_uri() . '/style.css',\n array( $parent_style ),\n wp_get_theme()->get('Version')\n );\n// wp_enqueue_style( 'monza-mod-vyh-style',\n// get_stylesheet_directory_uri() . '/style.css',\n// array( $parent_style )\n// );\n}", "function enqueue_my_styles_scripts() \n{\n\n\twp_enqueue_style( 'genericons', get_template_directory_uri() . '/genericons/genericons.css', array(), '3.2', false );\n\n\twp_enqueue_style( 'bootstrap-min', get_template_directory_uri() . '/css/bootstrap.min.css', array(), '3.2.2', false );\n\n\twp_enqueue_style( 'style-2-css', get_template_directory_uri() . '/css/style-2.css', array(), '3.2.2', false );\n\n\n\t/*\twp_enqueue_style( 'style-3-css', get_template_directory_uri() . '/style3.css', array(), '3.2.2', false );*/\n\n\n\t/*\twp_enqueue_style( 'jquery-ui.min', get_template_directory_uri() . '/css/jquery-ui.min.css', array(), '3.2.2', false );*/\n\n\twp_enqueue_style( 'raiseit-style', get_stylesheet_uri(), false );\n\n\twp_enqueue_style( 'darkroom-css', get_template_directory_uri() . '/css/darkroom.css', array(), '3.2.2', false );\n\n\twp_enqueue_style( 'bootstrap-select-css', get_template_directory_uri() . '/css/bootstrap-select.min.css\n\t\t', array(), '3.2.2', false );\n\n\twp_enqueue_style( 'bootstrap-datepicker-css', get_template_directory_uri() . '/css/bootstrap-datepicker.css\n\t\t', array(), '3.2.2', false );\n\n\twp_enqueue_style( 'timepicker-min-css', get_template_directory_uri() . '/css/timepicker.min.css\n\t\t', array(), '3.2.2', false );\n\t\n\t/*wp_enqueue_style( 'page-css', get_template_directory_uri() . '/css/page.css', array(), '3.2.2', false );*/\n\n\twp_enqueue_style( 'intlTelInput-css', get_template_directory_uri() . '/css/intlTelInput.css', array(), '3.2.2', false );\n\n\t/*\twp_enqueue_style( 'fontawesome', get_template_directory_uri() . '/css/fontawesome-all.min.css', array(), '3.2', false );*/\n\n}", "function krypton_scripts() {\n\twp_enqueue_style( 'bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css');\n\twp_enqueue_style( 'style', get_template_directory_uri() . '/css/style.css' );\n\t//wp_enqueue_script( 'modernizr', get_template_directory_uri() . '/js/modernizr.js');\n}", "function enqueue_admin_styles() {\n\t\twp_enqueue_style( 'lcarsframework', plugin_dir_url( dirname(__FILE__) ) . 'css/lcarsframework.css', array(), lcars_Framework::VERSION );\n\t\twp_enqueue_style( 'wp-color-picker' );\n\t}", "function load_stylesheets() {\n\n\twp_register_style('myCSS' , get_template_directory_uri() . '/style.css', array(), false, 'all');\n\twp_enqueue_style('myCSS');\n}", "function enqueues() {\n\t\twp_register_style( 'ks-thematic-actions', plugin_dir_url( __FILE__ ) . 'style.css' );\n\t wp_enqueue_style( 'ks-thematic-actions' );\n\t}", "function wordpressboilerplate_scripts (){\n wp_enqueue_style( 'wordpressboilerplate-style', get_stylesheet_uri() );\n wp_enqueue_script( 'wordpressboilerplate-script', get_template_directory_uri() . 'js/main.js', array( 'jquery' ) );\n\n wp_register_style('animate.css', get_stylesheet_uri() . 'assets/vendor/font-awesome/css/font-awesome.min.css');\n}", "function upcode_loadCSS(){\n\t$css = get_template_directory_uri() . '/assets/css/';\n\twp_enqueue_style( 'offcanvas', \t\t\t$css . '_bootstrap.offcanvas.css' );\n\twp_enqueue_style( 'fancybox', \t\t\t'//cdn.rawgit.com/fancyapps/fancybox/60c37246/dist/jquery.fancybox.min.css' );\n\twp_enqueue_style( 'slick', \t\t\t\t\t'//cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.7.1/slick.min.css' );\n\twp_enqueue_style( 'slick-theme', \t\t'//cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.7.1/slick-theme.min.css' );\n\twp_enqueue_style( 'slick-loader', \t'//cdnjs.cloudflare.com/ajax/libs/slick-carousel/1.7.1/ajax-loader.gif' );\n\twp_enqueue_style( 'awesome', \t\t\t\t'//use.fontawesome.com/releases/v5.0.6/css/all.css' );\n}", "function load_styles_and_scripts(){\r\n\r\n\t//register styles\r\n\twp_register_style('bootstrap-styles',get_template_directory_uri().'/css/bootstrap.min.css');\r\n\twp_register_style('main-styles',get_template_directory_uri().'/style.css');\r\n\r\n\t\r\n\t//register scripts\r\n\twp_register_script('bootstrap-scripts',get_template_directory_uri().'/js/bootstrap.min.js');\r\n\r\n\t//load styles\r\n\twp_enqueue_style('bootstrap-styles',get_template_directory_uri().'/css/bootstrap.min.css');\r\n\twp_enqueue_style('main-styles',get_template_directory_uri().'/style.css');\r\n\r\n\t\r\n\t//load scripts\r\n\twp_enqueue_script('jquery');\r\n\twp_enqueue_script('bootstrap-scripts',get_template_directory_uri().'/js/bootstrap.min.js');\r\n\r\n}", "function add_theme_scripts() {\n wp_enqueue_style( 'main_style_file', get_stylesheet_uri());\n /********** Including all.min css file ***********/\n wp_enqueue_style( 'minified_file', get_template_directory_uri() .'/css/all.min.css', array(), '1.1', 'all');\n /********** Including style css file ***********/\n wp_enqueue_style( 'style', get_template_directory_uri() .'/css/style.css', array(), '1.1', 'all');\n /********* Including bootstrap file ************/ \n wp_enqueue_style( 'bootstrap_file', get_template_directory_uri() .'/css/bootstrap.min.css', array (),'1.1', 'all'); \n //********* Including script files ************/\n wp_enqueue_script( $handle, get_template_directory_uri().'/js/bootstrap.min.js', array(), '1.1' , true ); \n}", "public function styles() {\n\t\t\n\t\twp_register_style( 'tinymassmailer-admin', _tinymassmailer_PATH . '/css/page-options.css' );\n\t\twp_enqueue_style( 'tinymassmailer-admin' );\n\t\t\n\t}", "function add_style(){\n\twp_enqueue_style('style',get_template_directory_uri().\"/css/style.css\");\n\twp_enqueue_style('bootstrap',get_template_directory_uri().\"/css/bootstrap.min.css\");\n}", "function add_style(){\n\twp_enqueue_style('style',get_template_directory_uri().\"/css/style.css\");\n\twp_enqueue_style('bootstrap',get_template_directory_uri().\"/css/bootstrap.min.css\");\n}", "public function enqueues() {\n\n\t\t// CSS.\n\t\twp_enqueue_style(\n\t\t\t'wpforms-builder-setup',\n\t\t\tWPFORMS_PLUGIN_URL . 'assets/css/admin-builder-setup.css',\n\t\t\tnull,\n\t\t\tWPFORMS_VERSION\n\t\t);\n\t}", "function wpdocs_theme_name_scripts() {\n wp_enqueue_style('pva-style', get_stylesheet_uri());\n wp_enqueue_style('pva-bootstrap', get_stylesheet_directory_uri() . '/css/bootstrap.min.css', array(), '1.0.0', 'all');\n wp_enqueue_script('pva-script', get_template_directory_uri() . '/js/sitescript.js', array(), '1.0.0', true);\n}", "function cs_style_and_scripts() {\n \n\t\twp_enqueue_style( 'bootstrap-css', get_stylesheet_directory_uri() .'/public/css/vendor.css' );\n\t\twp_enqueue_style( 'bootstrap-css', get_stylesheet_directory_uri() .'/public/css/app.css' );\n wp_enqueue_style( 'main-css', get_stylesheet_uri() );\n\n /*wp_enqueue_script( 'myscripts', get_stylesheet_directory_uri() . '/assets/js/app.js', '', '1.0.0', true );\n wp_localize_script('myscripts', 'cs_obj', array(\n 'ajax_url' => admin_url('admin-ajax.php'),\n ));*/\n\n }", "public function styles(){\n //Enqueue styles\n /**\n * wp_enqueue_style('sample-style',$this->directory_uri . '/sample.css');\n * ...\n * ....\n */\n }", "public function form_css(){\n\t\twp_register_style( 'lead_gen_plugin', plugin_dir_url( __FILE__ ) . 'css/style.css', false );\n\t\twp_enqueue_style( 'lead_gen_plugin' );\n\t}", "function wmt_theme_style () {\n\twp_enqueue_style( 'normalize_css', get_template_directory_uri() . '/css/normalize.css' );\n\twp_enqueue_style( 'bootstrap_css', get_template_directory_uri() . '/css/bootstrap.css' );\n\twp_enqueue_style( 'flexslider_css', get_template_directory_uri() . '/css/flexslider.css' );\n\twp_enqueue_style( 'font_awesome_css', get_template_directory_uri() . '/css/font-awesome.css' );\n\twp_enqueue_style( 'style_css', get_template_directory_uri() . '/css/estilos.css' );\n}", "function yks_admin_styles() {\n\twp_enqueue_style( 'yikes-bootstrap-style', get_template_directory_uri() . '/inc/css/style-admin.css', array(), 'all' );\n}", "function rt_theme_styles(){\n\t/**\n\t priemrio o nome\n\t segundo o diretorio\n\t*/\n\twp_enqueue_style('bootstrap-css', get_template_directory_uri() . '/vendor/bootstrap/css/bootstrap.min.css?ver=1');\n\twp_enqueue_style('clean-blog', get_template_directory_uri() . '/css/clean-blog.css?ver=1');\n\twp_enqueue_style('font-awesome', get_template_directory_uri() . '/vendor/font-awesome/css/font-awesome.min.css');\n\n\t// FONTES\n\twp_enqueue_style('google-font-lora', 'https://fonts.googleapis.com/css?family=Lora:400,700,400italic,700italic');\n\twp_enqueue_style('google-font-open-sans', 'https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800');\n\n\t// SCRIPTS\n\n\twp_enqueue_script('theme-jquery', get_template_directory_uri() . '/vendor/jquery/jquery.min.js');\n\twp_enqueue_script('theme-js', get_template_directory_uri() . '/vendor/jquery/jquery.js', array('jquery'), '', true);\n\t\n\twp_enqueue_script('bootstrap-js', get_template_directory_uri() . '/vendor/bootstrap/js/bootstrap.bundle.min.js');\n\twp_enqueue_script('clean-blog-js', get_template_directory_uri() . '/js/clean-blog.min.js');\n\t\n}", "public function frontEndStyleScripts(): void\n {\n wp_enqueue_style('users-data-bootstrap', plugin_dir_url(dirname(__FILE__)) . 'assets/css/bootstrap.min.css', [], UsersListing::getVersion());\n wp_enqueue_style('users-data-fontawsome', plugin_dir_url(dirname(__FILE__)) . 'assets/css/font-awesome.min.css', [], UsersListing::getVersion());\n wp_enqueue_style('users-data-styles', plugin_dir_url(dirname(__FILE__)) . 'assets/css/users-data.css', [], UsersListing::getVersion());\n //\n wp_enqueue_script('jquery-min', plugin_dir_url(dirname(__FILE__)) . 'assets/js/jquery.min.js', ['jquery'], UsersListing::getVersion(), false);\n wp_enqueue_script('jquery-popper', plugin_dir_url(dirname(__FILE__)) . 'assets/js/popper.min.js', ['jquery'], UsersListing::getVersion(), false);\n wp_enqueue_script('bootstrap-min', plugin_dir_url(dirname(__FILE__)) . 'assets/js/bootstrap.min.js', ['jquery'], UsersListing::getVersion(), false);\n }", "public function registerStyles()\n {\n wp_register_style('swiper-css', THEME_DIR_URI .'/assets/css/swiper.min.css', [], false, 'all');\n wp_register_style('dist-css', THEME_DIR_URI .'/assets/css/dist.css', [], false, 'all');\n wp_register_style('regional-css', THEME_DIR_URI .'/regional.css', [], false, 'all');\n wp_register_style('regional-style', THEME_DIR_URI .'/style.css', [], false, 'all');\n\n // Default app style file\n //wp_enqueue_style('style-css');\n\n // App styles\n wp_enqueue_style('swiper-css');\n wp_enqueue_style('dist-css');\n wp_enqueue_style('regional-css');\n wp_enqueue_style('regional-style');\n }", "function styles() {\n\n\twp_enqueue_style(\n\t\t'styles',\n\t\tERI_SCAFFOLD_TEMPLATE_URL . '/dist/css/style.css',\n\t\t[],\n\t\tERI_SCAFFOLD_VERSION\n\t);\n\n\tif ( is_page_template( 'templates/page-styleguide.php' ) ) {\n\t\twp_enqueue_style(\n\t\t\t'styleguide',\n\t\t\tERI_SCAFFOLD_TEMPLATE_URL . '/dist/css/styleguide-style.css',\n\t\t\t[],\n\t\t\tERI_SCAFFOLD_VERSION\n\t\t);\n\t}\n}", "function theme_styles() {\r\n wp_enqueue_style('bootstrap-css', 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css', array(), '', 'all');\r\n}", "function WDA_admin_css_all_page() { \n wp_register_style($handle = 'WDA_admin-css-all', $src = plugins_url('css/WDA_style.css', __FILE__), $deps = array(), $ver = '1.0.0', $media = 'all');\n wp_enqueue_style('WDA_admin-css-all');\n}", "function register_assets()\n{\n\n if (is_single()) {\n wp_enqueue_style( //fonctions pour charger un feuille de style css personalisé sur une page en particulier avec la fonction if(is_front_page)\n 'jpg-custom-single-css',\n get_template_directory_uri() . '/assets/styles/projets.css',\n array(),\n '1.0'\n );\n }\n if (is_page()) {\n wp_enqueue_style( //fonctions pour charger un feuille de style css personalisé sur une page en particulier avec la fonction if(is_front_page)\n 'jpg-custom-page-css',\n get_template_directory_uri() . '/assets/styles/page.css',\n array(),\n '1.0'\n );\n }\n\n\n wp_enqueue_style(\n 'jpg',\n get_stylesheet_uri(),\n array(),\n '1.0'\n\n );\n wp_enqueue_style(\n 'wordpress-css',\n \"https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css\"\n\n );\n wp_enqueue_style(\n 'jpg-custom-css',\n get_template_directory_uri() . '/assets/styles/main.css',\n array(),\n '1.0'\n\n );\n\n\n\n\nwp_enqueue_script(\n 'wordpress',\n 'https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js'\n\n);\n\nwp_enqueue_script(\n 'jpg',\n get_template_directory_uri() . '/assets/scripts/main.js',\n array('wordpress'),\n '1.0',\n true\n);\n}", "function enqueue_stylesheet() {\n\t\t\t\n\t\t\tif($this->test_stylesheet()){\n\t\t\t\tadd_action('tf_load_styles',array($this,'load_css'));\n\t\t\t add_filter('themify_google_fonts', array($this, 'enqueue_fonts'));\n\t\t\t add_filter('themify_custom_fonts', array($this, 'enqueue_custom_fonts'));\n\t\t\t}\n\t\t}", "public function vpup_load_styles() \n {\n // Enqueue our styles.\n wp_enqueue_style( 'vpup-main-styles', VPUP_URL . 'wp-vue/src/assets/css/main.css' );\n wp_enqueue_style( 'vpup-font-awesome', 'https://stackpath.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css' );\n }", "function addcss()\n{\nwp_register_style('ahmed_css', plugin_dir_url(__file__).'/styles-ahmed.css');\nwp_enqueue_style('ahmed_css');\n}", "function maker_4ym_admin_styles() {\n wp_register_style( 'maker_4ym_admin_stylesheet', plugins_url( '/css/style.css',__FILE__ ) );\n wp_enqueue_style( 'maker_4ym_admin_stylesheet' );\n}", "public function enqueueAssets()\n {\n wp_enqueue_style( WPADW_DOMAIN . '-admin-style', WPADW_URL . '/assets/style.css' );\n }", "function cwd_wp_bootstrap_scripts_styles() {\n wp_enqueue_script('bootstrapjs', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js', array('jquery'),'3.3.5', true );\n // Loads Bootstrap minified CSS file.\n wp_enqueue_style('bootstrapwp', 'https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css', false ,'3.3.5');\n // Loads our main stylesheet.\n wp_enqueue_style('style', get_stylesheet_directory_uri() . '/style.css', array('bootstrapwp') );\n}", "public function enqueue_styles() {\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/sanoa-links-linter-public.css', array(), $this->version, 'all' );\n\t}", "function enqueue_our_required_stylesheets(){\n wp_enqueue_style('font-awesome', get_stylesheet_directory_uri() . '/css/font-awesome/css/font-awesome.css'); \n}", "function montheme_register_assets()\n{\n\t//enregistre le style et le script\n\twp_register_style('bootstrap', 'https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css');\n\twp_register_style('style-css', get_stylesheet_uri());\n\twp_register_script('bootstrap', 'https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js', [], false, true); //[] =pas de dependance, false = pas de numero de version et true = script chargé dans le footer\n\t//permet d'utiliser le style et le script\n\twp_enqueue_style('bootstrap');\n\twp_enqueue_style('style-css');\n\twp_enqueue_script('bootstrap');\n}", "function aurum_wp_enqueue_scripts() {\n\t// Styles\n\t$rtl_include = '';\n\n\twp_enqueue_style( 'icons-entypo' );\n\twp_enqueue_style( 'icons-fontawesome' );\n\twp_enqueue_style( 'bootstrap' );\n\twp_enqueue_style( 'aurum-main' );\n\t\n\tif ( ! is_child_theme() ) {\n\t\twp_enqueue_style( 'style' );\n\t}\n\n\t// Right to left bootstrap\n\tif ( is_rtl() ) {\n\t\twp_enqueue_style( array( 'bootstrap-rtl' ) );\n\t}\t\n\n\t// Custom Skin\n\tif ( get_data( 'use_custom_skin' ) ) {\n\t\tif ( false == apply_filters( 'aurum_use_filebased_custom_skin', aurum_use_filebased_custom_skin() ) ) {\n\t\t\twp_enqueue_style( 'custom-skin', site_url( '?custom-skin=1' ), null, null );\n\t\t}\n\t}\n\n\t// Scripts\n\twp_enqueue_script( array( 'jquery', 'bootstrap', 'tweenmax' ) );\n}", "function safed_styles() {\n\n wp_enqueue_style( 'safed-fonts', plugin_dir_url( __FILE__ ) . 'fonts/fonts.min.css', array(), get_the_time('U'));\n wp_enqueue_style( 'safed-icons', plugin_dir_url( __FILE__ ) . 'assets/css/all.min.css', array(), get_the_time('U'));\n\n}", "function awesome_script_enqueue() {\r\n\t//css\r\n\twp_enqueue_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css', array(), '3.3.4', 'all');\r\n\twp_enqueue_style('customstyle', get_template_directory_uri() . '/css/katayam.css', array(), '1.0.0', 'all');\r\n\t//js\r\n\twp_enqueue_script('jquery');\r\n\twp_enqueue_script('bootstrapjs', get_template_directory_uri() . '/js/bootstrap.min.js', array(), '3.3.4', true);\r\n\twp_enqueue_script('customjs', get_template_directory_uri() . '/js/katayam.js', array(), '1.0.0', true);\r\n\t\r\n}", "function propanel_of_style_only() {\n\twp_enqueue_style('admin-style', get_stylesheet_directory_uri().'/admin/admin-style.css');\n\twp_enqueue_style('color-picker', get_stylesheet_directory_uri().'/admin/colorpicker.css');\n}", "public function enqueue_styles()\n\t{\n\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Prosvit_Extension_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Prosvit_Extension_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\n\t\twp_enqueue_style('style_select2', plugin_dir_url(__FILE__) . 'css/select2.min.css', array(), $this->version, 'all');\n\t\twp_enqueue_style($this->plugin_name, plugin_dir_url(__FILE__) . 'css/prosvit-extension-admin.css', array(), $this->version, 'all');\n\t}", "public function enqueue_styles() {\n\t\t/**\n\t\t * This function is provided for demonstration purposes only.\n\t\t *\n\t\t * An instance of this class should be passed to the run() function\n\t\t * defined in Nerd_Wp_Loader as all of the hooks are defined\n\t\t * in that particular class.\n\t\t *\n\t\t * The Nerd_Wp_Loader will then create the relationship\n\t\t * between the defined hooks and the functions defined in this\n\t\t * class.\n\t\t */\n\t\twp_enqueue_style( $this->plugin_name, plugin_dir_url( __FILE__ ) . 'css/contact-helpdesk-admin.css', array(),\n\t\t\t$this->version, 'all' );\n\t}", "function wptrebs_styles_scripts() {\n wp_enqueue_style( 'wptrebs_feed', plugins_url('..\\assets\\css\\style.css', __FILE__) );\n}", "function ajout_scripts() {\n wp_enqueue_style('bootstrap', get_template_directory_uri() . '/assets/bootstrap/css/bootstrap.min.css');\n wp_enqueue_style('font-awesome', get_template_directory_uri() . '/assets/fonts/font-awesome.min.css');\n wp_enqueue_style('font-awesome', get_template_directory_uri() . '/assets/css/styles.min.css');\n wp_enqueue_style('font-1', 'https://fonts.googleapis.com/css?family=Open+Sans');\n wp_enqueue_style('font-2', 'https://fonts.googleapis.com/css?family=Roboto');\n\n wp_enqueue_script('messcripts', get_template_directory_uri() . '/assets/js/jquery.min.js');\n wp_enqueue_script('messcripts2', get_template_directory_uri() . '/assets/js/script.js');\n wp_enqueue_style('crdStyles', get_stylesheet_uri());\n\n\n}", "public static function orgafresh_child_enqueue_styles() {\n wp_enqueue_style( 'orgafresh-style', get_template_directory_uri() . '/style.css', array('font-awesome') );\n\n wp_enqueue_style( 'child-style', get_stylesheet_directory_uri() . '/style.css', array('font-awesome') );\n\n wp_enqueue_style( 'velesh-theme-style', THEME_URL . '/assets/css/main.min.css', array());\n\n wp_enqueue_style( 'owl-carousel-style', THEME_URL . '/assets/owlcarousel/css/owl.carousel.min.css', array());\n\n }", "function register_css_styles() {\n\tif (!is_admin()) {\n\t\tglobal $wp_styles;\n\t\t\n\t\t\n\t\t$cmsms_option = cmsms_get_global_options();\n\t\t\n\t\t\n\t\twp_register_style('theme-style', get_stylesheet_uri(), array(), '1.0.0', 'screen');\n\t\twp_register_style('theme-fonts', get_template_directory_uri() . '/css/fonts.php', array(), '1.0.0', 'screen');\n\t\twp_register_style('theme-adapt', get_template_directory_uri() . '/css/adaptive.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('theme-retina', get_template_directory_uri() . '/css/retina.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('jackbox', get_template_directory_uri() . '/css/jackbox.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('fontello', get_template_directory_uri() . '/css/fonts/css/fontello.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('jPlayer', get_template_directory_uri() . '/css/jquery.jPlayer.css', array(), '2.1.0', 'screen');\n\t\twp_register_style('isotope', get_template_directory_uri() . '/css/jquery.isotope.css', array(), '1.5.19', 'screen');\n\t\twp_register_script('respond', get_template_directory_uri() . '/js/respond.min.js', array(), '1.1.0', false);\n\t\t\n\t\twp_enqueue_style('theme-style');\n\t\twp_enqueue_style('theme-fonts');\n\t\twp_enqueue_style('fontello');\n\t\t\n\t\tif ($cmsms_option[CMSMS_SHORTNAME . '_responsive']) {\n\t\t\twp_enqueue_style('theme-adapt');\n\t\t}\n\t\t\n\t\tif ($cmsms_option[CMSMS_SHORTNAME . '_retina']) {\n\t\t\twp_enqueue_style('theme-retina');\n\t\t}\n\t\n\t\t\n\t\twp_enqueue_style('jackbox');\n\t\twp_enqueue_style('jPlayer');\n\t\twp_enqueue_style('isotope');\n\t\t\n\t\twp_register_style('jackbox-ie8', get_template_directory_uri() . '/css/jackbox-ie8.css', array(), '1.0.0', 'screen');\n\t\twp_register_style('jackbox-ie9', get_template_directory_uri() . '/css/jackbox-ie9.css', array(), '1.0.0', 'screen');\n\t\t\n\t\twp_enqueue_style('theme-ie', get_template_directory_uri() . '/css/ie.css', array(), '1.0.0', 'screen');\n\t\twp_enqueue_style('theme-ieCss3', get_template_directory_uri() . '/css/ieCss3.php', array(), '1.0.0', 'screen');\n\t\t\n\t\t$wp_styles->add_data('jackbox-ie8', 'conditional', 'lt IE 9');\n\t\t$wp_styles->add_data('jackbox-ie9', 'conditional', 'gt IE 8');\n\t\t\n\t\t$wp_styles->add_data('theme-ie', 'conditional', 'lt IE 9');\n\t\t$wp_styles->add_data('theme-ieCss3', 'conditional', 'lt IE 9');\n\t}\n}", "public function adminThemeStylesAndScripts()\n {\n wp_enqueue_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.admin.min.css', array());\n wp_enqueue_style('my-admin-theme', get_template_directory_uri() . '/includes/snv/Theme/admin/style.css');\n wp_enqueue_script('my-admin-script', get_template_directory_uri() . '/includes/snv/Theme/admin/script.js', array('jquery'), '1.0', true);\n\n // for the contactonfo page\n wp_enqueue_script('media-upload');\n wp_enqueue_script('thickbox');\n wp_enqueue_style('thickbox');\n }", "function rhd_enqueue_styles(){\n\tglobal $theme_opts;\n\n\twp_register_style( 'rhd-sitewide', content_url() . '/global/sitewide.css', array(), '1', 'all' );\n\twp_register_style( 'rhd-main', RHD_THEME_DIR . '/css/main.css', array(), '1', 'all' );\n\twp_register_style( 'rhd-enhanced', RHD_THEME_DIR . '/css/enhanced.css', array(), '1', 'all' );\n\twp_register_style( 'Slidebars', RHD_THEME_DIR . '/js/vendor/Slidebars/dist/slidebars.min.css', array(), null, 'all' );\n\n\t$normalize_deps = array();\n\t$normalize_deps[] = 'Slidebars';\n\n\tif ( !rhd_is_mobile() ) {\n\t\twp_enqueue_style( 'rhd-enhanced' );\n\t}\n\n\twp_register_style( 'normalize', RHD_THEME_DIR . '/css/normalize.css', $normalize_deps, null, 'all' );\n\n\twp_enqueue_style( 'rhd-main' );\n\twp_enqueue_style( 'rhd-sitewide' );\n\twp_enqueue_style( 'normalize' );\n\twp_enqueue_style( 'google-fonts' );\n}", "function add_css() {\n // È possibile aggiungere un file css presente nella cartella del tema\n wp_register_style('normalize', get_template_directory_uri() . '/vendor/normalize/normalize.css', array(), null, 'all');\n wp_enqueue_style('normalize');\n wp_register_style('main', get_template_directory_uri() . '/css/main.css', array('normalize'), null, 'all');\n wp_enqueue_style('main');\n\n // È possibile anche aggiungere un url remoto (es. Google Fonts)\n // wp_register_style('webfont', 'https://fonts.googleapis.com/css?family=Source+Sans+Pro:200,300,400,500,600,700,800,900', array(), null, 'all');\n // wp_enqueue_style('webfont');\n\n // Inoltre è possibile aggiungere un css solo se una determinata condizione è vera\n // In questo esempio aggiungiamo il file home.css solo se ci troviamo sulla pagina di home\n // if(is_home()) {\n // wp_register_style('home', get_template_directory_uri() . '/css/home.css', array(), null, 'all');\n // wp_enqueue_style('home');\n // }\n}" ]
[ "0.77529055", "0.7746947", "0.76875204", "0.7680872", "0.76689994", "0.765971", "0.76147896", "0.7591085", "0.75883204", "0.7573206", "0.75511104", "0.75253123", "0.7525203", "0.74831843", "0.74619573", "0.7454659", "0.74416053", "0.74372935", "0.7431867", "0.742428", "0.738918", "0.7380793", "0.7378714", "0.7365869", "0.73453486", "0.7343128", "0.7330211", "0.7313211", "0.7307292", "0.7305136", "0.7302385", "0.72740024", "0.7258541", "0.7258364", "0.72522825", "0.7249978", "0.724668", "0.7241376", "0.72377366", "0.72353953", "0.7234037", "0.72332907", "0.72263217", "0.7210418", "0.72054034", "0.7203809", "0.72014225", "0.71996146", "0.7198378", "0.719388", "0.7191861", "0.71910906", "0.71868014", "0.7185227", "0.7183363", "0.71764904", "0.7166577", "0.71645516", "0.7163346", "0.7160011", "0.7157097", "0.7156947", "0.7156849", "0.7156849", "0.7156151", "0.71554327", "0.7154608", "0.7153696", "0.71510106", "0.7150831", "0.7149922", "0.71341777", "0.7129656", "0.71287894", "0.71259964", "0.71250904", "0.712039", "0.7104332", "0.71000445", "0.70975024", "0.70954674", "0.7093878", "0.70933205", "0.7088168", "0.7079199", "0.70729005", "0.7070188", "0.70684916", "0.70680887", "0.7063247", "0.7057041", "0.70568585", "0.70560914", "0.70534647", "0.7053252", "0.7053132", "0.7051547", "0.7048138", "0.7042994", "0.70399356" ]
0.76370484
6
Format the start date.
public function getStartDateAttribute($value) { return Carbon::parse($value)->format('m/d/Y'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getFormattedStartDate() {\n\t\t$format_1 = 'Y-m-d';\n\t\t$format_2 = 'Y-m-d H:i';//format coming from web page\n\t\t$format_3 = 'Y-m-d H:i:s';//format coming from mysql\n\t\t$date = null;\n\t\t$formatted_date = \"\";\n\t\t\n\t\tif (!isset($this -> start_time) ) \n\t\t\treturn \"\";\n\t\t$date = DateTime::createFromFormat($format_2, $this -> start_time);\n\t\tif ( $date == false )\n\t\t\t$date = DateTime::createFromFormat($format_3, $this -> start_time);\n\t\t// var_dump($date);\n\t\treturn $date == false ? \"\" : $date->format($format_1) ;\n\t\t\n\t}", "public function dateStartFriendly(): string\n {\n return Carbon::parse($this->date_start)->format('d-m-Y');\n }", "public function setStart($format, $start) { //input should be dd-mm-yyyy format\n $date = DateTime::createFromFormat($format, $start);\n $this->_start = $date;\n }", "public function get_start_date()\n\t{\n\t\treturn $this->start_date;\n\t}", "public function getFormattedBeginAt(): string\n {\n\n return $this->beginAt->format('d-m-Y');\n\n }", "private function formatStartDate($startdate) {\n\t\t// Check if $startdate is safe\n\t\treturn $startdate . ' 00:00:00';\n\t}", "public function getStart_date() {\n\t\treturn $this->_start_date;\n\t}", "public function getStartDate()\n {\n return $this->stringToDate((string) $this->json()->start_date);\n }", "public function getDateStart()\n {\n return $this->dateStart;\n }", "public function getDateStart()\n {\n return $this->dateStart;\n }", "public function getDateStart()\n {\n return $this->dateStart;\n }", "public function getStartDate() {\n\n return $this->start_date;\n }", "public function getBeginDate() {\n return $this->beginDate;\n }", "public function getBeginDateAttribute()\n {\n return date('Y-m-d',strtotime($this->attributes['created_at']));\n }", "function getStartDate() \n\t{\n\t\treturn (strlen($this->start_date)) ? $this->start_date : NULL;\n\t}", "public function formatDate() {\n\t\t\tif(!empty($this->review_date)) {\n\t\t\t\t$date = new dateTime($this->review_date);\n\t\t\t\treturn $date->format('M jS, Y - H:i');\n\t\t\t}\n\t\t}", "private function getStartDate( $start_date )\n {\n return $this->matchDateFormat( $start_date )\n ? $start_date\n : Carbon::now()->subDays(7)->format('Y-m-d');\n }", "private function getStartDate( $start_date )\n {\n return $this->matchDateFormat( $start_date )\n ? $start_date\n : Carbon::now()->subDays(7)->format('Y-m-d');\n }", "public function getStartDate(){\n\t\treturn $this->startDate;\n\t}", "public function getStartDate();", "public function getStartDate();", "public function getStartDate() {\n return $this->startDate;\n }", "public function setDateStart($var)\n {\n GPBUtil::checkString($var, True);\n $this->dateStart = $var;\n\n return $this;\n }", "function setStartDate($start_date = \"\") \n\t{\n\t\t$this->start_date = $start_date;\n\t}", "function eo_get_the_start($format='d-m-Y',$id='',$occurrence=0){\n\tglobal $post;\n\t$event = $post;\n\n\tif(isset($id)&&$id!='') $event = eo_get_by_postid($id,$occurrence);\n\t\n\tif(empty($event)) return false;\n\n\t$date = esc_html($event->StartDate).' '.esc_html($event->StartTime);\n\n\tif(empty($date)||$date==\" \")\n\t\treturn false;\n\n\treturn eo_format_date($date,$format);\n}", "public function getStart()\n {\n return Carbon::createFromFormat('d/m/Y', $this->data_entrada);\n }", "public function get_start_time()\r\n {\r\n return strtotime(date('Y-m-d 00:00:00', $this->get_display_time()));\r\n }", "public function getStartDate()\n {\n return $this->StartDate;\n }", "public function getStartDate()\n {\n return $this->startDate;\n }", "public function getStartDate()\n {\n return $this->startDate;\n }", "public function getStartDate()\n {\n return $this->startDate;\n }", "public function getStartDate()\n {\n return $this->startDate;\n }", "public function getStartDate()\n {\n return $this->startDate;\n }", "public function getStartDate() {\n return $this->startDate;\n }", "public function getStartDateTime();", "public function setStartDate(string $date);", "public function getStartDate()\n {\n if ($this->startDate == null) {\n return null;\n }\n return $this->startDate->format(\"Ymd\");\n }", "public function date() {\n return $this->begin;\n }", "public function getStartDate() \n {\n return $this->_fields['StartDate']['FieldValue'];\n }", "function eo_get_schedule_start($format='d-m-Y',$id=''){\n\tglobal $post;\n\t$event = $post;\n\n\tif(isset($id)&&$id!='') $event = eo_get_by_postid($id);\n\n\t$date = esc_html($event->reoccurrence_start.' '.$event->StartTime);\n\n\tif(empty($date)||$date==\" \")\n\t\treturn false;\n\n\treturn eo_format_date($date,$format);\n}", "protected function getStart()\n {\n return new Zend_Date(\n Mage::getStoreConfig(self::CONFIG_PREFIX . 'start', $this->getStore()),\n $this->getDateTimeFormat(),\n $this->getLocale()->getLocaleCode()\n );\n }", "public function getStartdate() : string\r\n\t{\r\n\t\treturn $this->startdate;\r\n\t}", "public function getStartDate($format)\n {\n return gmdate($format, gmmktime(0, 0, 0, $this->getStartMonth(), 1, $this->getStartYear()));\n }", "public function get_date()\n {\n $start_date = $this->start_date;\n if (0 >= (int) $start_date) {\n return false;\n }\n\n return date('Y-m-d H:i', $start_date / 1000);\n }", "public function toString($start): string {\n $month = $start;\n $months =['Janvier','Fevrier','Mars','Avril','Mai','Juin','Juillet','Aout','Septembre','Octobre','Novembre','Decembre'];\n return $months[$month - 1] .' '.$this->year;\n\n }", "public function getManualDateStart() {}", "public function setStartDate($value)\n {\n $this->startDate = $value;\n }", "public function getStartAttribute($value){\n return Carbon::parse($value)->format('Y-m-d');\n }", "public function setStartDate($date)\n\t{\n\t\treturn $this->setDate('Start', $date);\n\n\t}", "public function setStartDate(DrupalDateTime $start_date);", "public function getDateBegin()\n {\n return $this->dateBegin;\n }", "public function getDateBegin()\n {\n return $this->dateBegin;\n }", "public function setStartDate($date)\n\t\t{\n\t\t\t$this->start_date = $date;\n\t\t}", "public function setStartDateAttribute($value)\n\t{\n\t\treturn $this->attributes['start_date'] = Carbon::parse($value)->format('Y-m-d H:i:s');\n\t}", "function eo_the_start($format='d-m-Y',$id='',$occurrence=0){\n\techo eo_get_the_start($format,$id,$occurrence);\n}", "public function formatDate($date = null);", "public function set_start_date($start_date)\n\t{\n\t\tif (is_null($start_date)) {\n\t\t\tthrow new InvalidArgumentException(\"Project Start Date Invalid!\");\n\t\t}\n\t\t$this->start_date = $start_date;\n\t}", "public function setStartDate($val)\n {\n $this->_propDict[\"startDate\"] = $val;\n return $this;\n }", "public function away_mode_start_date() {\n\n\t\t$current = current_time( 'timestamp' ); //The current time\n\n\t\t//if saved date is in the past update it to something in the future\n\t\tif ( isset( $this->settings['start'] ) && isset( $this->settings['enabled'] ) && $current < $this->settings['end'] ) {\n\t\t\t$start = $this->settings['start'];\n\t\t} else {\n\t\t\t$start = strtotime( date( 'n/j/y 12:00 \\a\\m', ( current_time( 'timestamp' ) + ( 86400 ) ) ) );\n\t\t}\n\n\t\t//Date Field\n\t\t$content = '<input class=\"start_date_field\" type=\"text\" id=\"itsec_away_mode_start_date\" name=\"itsec_away_mode[away_start][date]\" value=\"' . date( 'm/d/y', $start ) . '\"/><br>';\n\t\t$content .= '<label class=\"start_date_field\" for=\"itsec_away_mode_start_date\"> ' . __( 'Set the date at which the admin dashboard should become unavailable', 'it-l10n-ithemes-security-pro' ) . '</label>';\n\n\t\techo $content;\n\n\t}", "public function setStartDate($value) \n {\n $this->_fields['StartDate']['FieldValue'] = $value;\n return $this;\n }", "public function getFormattedCreateDate();", "private function setTitle()\n {\n $this->title = $this->start_date;\n\n if ($this->start_date != $this->end_date) {\n $this->title .= ' - '.$this->end_date;\n }\n }", "public function setStartDate($startDate='')\r\n\t\t{\r\n\t\t\tif ($startDate != '')\r\n\t\t\t{\r\n\t\t\t\t$this->start_date = $startDate;\r\n\t\t\t}\r\n\t\t}", "function erp_financial_start_date() {\n $financial_year_dates = erp_get_financial_year_dates();\n\n return $financial_year_dates['start'];\n}", "public function get_startDate()\n {\n return $this->_startDate;\n }", "public function setStartDate($start_date)\n {\n $this->json()->start_date = $this->dateToString($start_date);\n }", "function FormatDateRange ($start, $end) {\n\t\n\t\t$full_format='F jS, Y';\n\t\t$no_year_format='F jS';\n\t\t$month_format='F';\n\t\t$day_format='jS';\n\t\t$year_format='Y';\n\t\t\n\t\t//\tThey're both null/missing/improper\n\t\tif (!is_date($start) && !is_date($end)) return '';\n\t\t\n\t\t//\tThe first is missing/null/improper\n\t\tif (!is_date($start)) $start=$end;\n\t\telse if (!is_date($end)) $end=$start;\n\t\t\n\t\t//\tThey're both the same\n\t\t/*if ($start->format(DateTime::ISO8601)===$end->format(DateTime::ISO8601)) {\n\t\t\n\t\t\t//\tJust output one of them\n\t\t\treturn $start->format($full_format);\n\t\t\n\t\t}*/\n\t\t\n\t\t//\tThey're in the same year\n\t\tif ($start->format('Y')===$end->format('Y')) {\n\t\t\n\t\t\t//\tThey're in the same month\n\t\t\tif ($start->format('n')===$end->format('n')) {\n\t\t\t\n\t\t\t\t//\tThey're on the same day\n\t\t\t\tif ($start->format('j')===$end->format('j')) {\n\t\t\t\t\n\t\t\t\t\treturn $start->format($full_format);\n\t\t\t\t\n\t\t\t\t} else {\n\t\t\t\t\n\t\t\t\t\treturn sprintf(\n\t\t\t\t\t\t'%1$s %2$s - %3$s, %4$s',\n\t\t\t\t\t\t$start->format($month_format),\n\t\t\t\t\t\t$start->format($day_format),\n\t\t\t\t\t\t$end->format($day_format),\n\t\t\t\t\t\t$start->format($year_format)\n\t\t\t\t\t);\n\t\t\t\t\n\t\t\t\t}\n\t\t\t\n\t\t\t} else {\n\t\t\t\n\t\t\t\treturn sprintf(\n\t\t\t\t\t'%1$s - %2$s, %3$s',\n\t\t\t\t\t$start->format($no_year_format),\n\t\t\t\t\t$end->format($no_year_format),\n\t\t\t\t\t$start->format($year_format)\n\t\t\t\t);\n\t\t\t\n\t\t\t}\n\t\t\n\t\t} else {\n\t\t\n\t\t\treturn sprintf(\n\t\t\t\t'%1$s - %1$s',\n\t\t\t\t$start->format($full_format),\n\t\t\t\t$end->format($full_format)\n\t\t\t);\n\t\t\n\t\t}\n\t\n\t}", "public function getStartOfDayDate()\n {\n return $this->_date->date(null, '0:0:0');\n }", "public function setStartDateAttribute($date)\n {\n // Use with Carbon instance:\n // -------\n // Carbon::createFromFormat('H:i', $date)->format('H:i');\n return $this->attributes['start_date'] = strtotime(str_replace('/', '-', $date));\n }", "public function getStartDateTime()\n {\n return $this->startDateTime;\n }", "function getStartDate()\n {\n $oDaySpan = $this->_value;\n $value = is_null($oDaySpan) ? null : $oDaySpan->getStartDate();\n return $value;\n }", "public function formStartDateAttribute($value)\n {\n return Carbon::parse($value)->format('Y-m-d');\n }", "function formatDate($date){\r\n\t\t\t\t$dateObject = date_create($date);\r\n\t\t\t\treturn date_format($dateObject, \"j F Y\");\r\n\t\t\t}", "public function setStartDate($value)\n {\n return $this->set('StartDate', $value);\n }", "public function setStartDate($value)\n {\n return $this->set('StartDate', $value);\n }", "public function test_start_date_format_type()\n {\n // show actiual errors without handling\n //$this->withoutExceptionHandling();\n \n $this->json('POST', '/', array_merge($this->data(),['start_date'=>'abc']))\n ->seeJson([\n 'start_date' => [\"The start date does not match the format Y-m-d.\",\"The start date is not a valid date.\",\"The start date must be a date after today -30 days.\",\"The start date must be a date before end date.\",\"The start date must be a date before today.\"]\n ]);\n \n }", "function eo_schedule_start($format='d-m-Y',$id=''){\n\techo eo_get_schedule_start($format,$id);\n}", "public function setStart($start)\n {\n //Argument 1 must be a string\n Argument::i()->test(1, 'string', 'int');\n\n if (is_string($start)) {\n $start = strtotime($start);\n }\n\n $start = date('Y-m-d H:i:s', $start);\n\n $this->query['start_date'] = $start;\n\n return $this;\n }", "public function getStartAt()\n {\n return $this->start_at;\n }", "public function getStartDateFieldName(string $objectType = ''): string\n {\n if ('rating' === $objectType) {\n return 'createdDate';\n }\n \n return '';\n }", "public function getStartDateAttribute($value) {\n $value = Carbon::parse($value);\n return $value->format(\"Y-m-d H:i\");\n }", "private function getEventStartDate()\n {\n $startDate = $this->TicketPage()->getEventStartDate();\n $this->extend('updateEventStartDate', $startDate);\n return $startDate;\n }", "function setStartDateAndTime($start_date = \"\", $start_time) \n\t{\n\t\t$y = ''; $m = ''; $d = ''; $h = ''; $i = ''; $s = '';\n\t\tif (preg_match(\"/(\\d{4})-(\\d{2})-(\\d{2})/\", $start_date, $matches))\n\t\t{\n\t\t\t$y = $matches[1];\n\t\t\t$m = $matches[2];\n\t\t\t$d = $matches[3];\n\t\t}\n\t\tif (preg_match(\"/(\\d{2}):(\\d{2}):(\\d{2})/\", $start_time, $matches))\n\t\t{\n\t\t\t$h = $matches[1];\n\t\t\t$i = $matches[2];\n\t\t\t$s = $matches[3];\n\t\t}\n\t\t$this->start_date = sprintf('%04d%02d%02d%02d%02d%02d', $y, $m, $d, $h, $i, $s);\n\t}", "public function setStartDateAttribute($value)\n {\n $this->attributes['start_date'] = Carbon::parse($value);\n }", "public function getStartDate() {\r\n $startDate = new \\DateTime('@' . $this->getTimestamp());\r\n\r\n switch($this->getMode()) {\r\n case self::$modeYear:\r\n $startDate->modify('first day of January');\r\n break;\r\n case self::$modeMonth:\r\n $startDate->modify('first day of this month');\r\n break;\r\n case self::$modeWeek:\r\n $date = date('w', $startDate->getTimestamp());\r\n if($date != 1) {\r\n $startDate->modify('last Monday');\r\n }\r\n break;\r\n case self::$modeDay:\r\n break;\r\n default:\r\n throw new \\Exception(\"ViewMode is not known in ViewCalendar.\");\r\n break;\r\n }\r\n\r\n $startDate->setTime(0, 0, 0);\r\n return $startDate;\r\n }", "protected function makeDateHeaderString() {\n\t\t$timeZone = date(\"Z\");\n\t\t$op = ($timeZone[0] == '-') ? '-' : '+';\n\t\t$timeZone = abs($timeZone);\n\t\t$timeZone = floor($timeZone / 3600) * 100 + ($timeZone % 3600) / 60;\n\t\t$dateString = sprintf(\"%s %s%04d\", date(\"D, j M Y H:i:s\"), $op, $timeZone);\n\t\treturn \"Date: \" . $dateString . $this->_endString;\n\t}", "public function getMembershipStartAttribute($value)\n {\n return \\DateTime::createFromFormat($this->getDateFormat(), $value)->format('j/n/Y g:i A');\n }", "public function setBeginDate($beginDate) {\n $this->beginDate = $beginDate;\n }", "public function setStartDateTime($val)\n {\n $this->_propDict[\"startDateTime\"] = $val;\n return $this;\n }", "public function format()\n {\n if (!empty($this->start) && !is_a($this->start, DateTime::class)) {\n throw new Exception(\"VCalendar 'start' property must be a DateTime object.\");\n }\n \n return $this->beginVCal() . join('', $this->events) . $this->endVCal();\n }", "public function getStartTimestamp() {}", "public function setStartDate($startDate) {\n $this->startDate = $startDate;\n }", "protected function getDatePrefix()\r\n\t{\r\n\t\treturn date('YmdHis');\r\n\t}", "public function setCollectionDateStart($val){\n\t\tif(trim($val) != \"\"){\n\t\t\t$this->collectionDateStart = trim($val);\n\t\t}\t\t\n\t\treturn $this;\n\t}", "public function setStart(DateTime $start) {\n\t\t$this->start = $start;\n\t}", "function formatDate()\n\t{\n\t\techo date(\"m/d/y\");\n\t}", "public function setStartDate(\\DateTime $value)\n {\n $this->setItemValue('start_date', (string)$value->getTimestamp());\n }", "public function setStart(ilDateTime $a_date = null)\n\t{\n\t\t$this->start = $a_date;\n\t}", "public function formatDate($date){\n return date('F j, Y, g: i a', strtotime($date));\n }", "public function getStartDateAttribute($value){\n\t\tif( $value == \"0000-00-00\" || $value == NULL ){\n\t\t\treturn \"\";\n\t\t}else{\n\t\t\treturn date(\"d/m/Y\", strtotime($value));\n\t\t}\n\t}" ]
[ "0.7492452", "0.7234154", "0.6983034", "0.69220424", "0.6802845", "0.6753398", "0.6724922", "0.6559034", "0.6529451", "0.6529451", "0.6529451", "0.6517675", "0.64793724", "0.6457548", "0.64107466", "0.6406207", "0.63937455", "0.63888526", "0.6371989", "0.6326973", "0.6326973", "0.6314986", "0.6302645", "0.6300838", "0.6297648", "0.62829155", "0.6261757", "0.62415844", "0.6237726", "0.6237726", "0.6237726", "0.6237726", "0.6237726", "0.623148", "0.61960894", "0.61791074", "0.6170307", "0.61570746", "0.6130001", "0.6116179", "0.61000717", "0.6095064", "0.608392", "0.6061182", "0.60599333", "0.6042386", "0.6028529", "0.60280824", "0.6026951", "0.60256314", "0.6021443", "0.6021443", "0.60198003", "0.6016719", "0.59981525", "0.59734386", "0.59542555", "0.5942857", "0.5922959", "0.5906263", "0.5896397", "0.5881655", "0.5866791", "0.5850943", "0.58345205", "0.58126545", "0.5811675", "0.5804369", "0.5781685", "0.57739806", "0.5756213", "0.57225823", "0.57035774", "0.57002604", "0.56998086", "0.5689675", "0.568415", "0.5678023", "0.5674033", "0.5670685", "0.56600314", "0.5654879", "0.5654582", "0.5646356", "0.5613417", "0.5603287", "0.56028867", "0.55983233", "0.5594587", "0.5589459", "0.55841994", "0.5583788", "0.55822176", "0.55762106", "0.55490065", "0.5545911", "0.55385995", "0.5534472", "0.5534403", "0.5531559" ]
0.5746318
71
Format the end date.
public function getEndDateAttribute($value) { return Carbon::parse($value)->format('m/d/Y'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function formatEndDate($enddate) {\n\t\treturn $enddate . ' 23:59:59';\n\t}", "public function getFormattedEndDate() {\n\t\t$format_1 = 'Y-m-d';\n\t\t$format_2 = 'Y-m-d H:i';//format coming from web page\n\t\t$format_3 = 'Y-m-d H:i:s';//format coming from mysql\n\t\t$date = null;\n\t\t$formatted_date = \"\";\n\t\t\n\t\tif (!isset($this -> end_time) ) \n\t\t\treturn \"\";\n\t\t$date = DateTime::createFromFormat($format_2, $this -> end_time);\n\t\tif ( $date == false )\n\t\t\t$date = DateTime::createFromFormat($format_3, $this -> end_time);\n\t\t// var_dump($date);\n\t\treturn $date == false ? \"\" : $date->format($format_1) ;\n\t\t\n\t}", "public function getFormattedEndAt(): string\n {\n\n return $this->endAt->format('d-m-Y');\n\n }", "public function set_end_date()\n {\n if ($this->end_date === NULL && $this->start_date === NULL) {\n $this->formated_end_date = \"the game has not started yet\";\n } elseif($this->end_date === NULL && $this->start_date !== NULL) {\n $this->formated_end_date = \"the game is not finished yet\";\n } else {\n $end_date = Carbon::createFromTimestamp($this->end_date / 1000);\n $this->formated_end_date = $end_date->toDayDateTimeString();\n }\n return $this->formated_end_date; \n }", "public function getEndDate()\n {\n if ( ! $this->getData('end_date'))\n {\n return \"-\";\n }\n\n return $this->getData('end_date');\n }", "public function get_end_date()\n\t{\n\t\treturn $this->end_date;\n\t}", "public function get_end_date($date_format = '') {\r\n\t\tif ( $this->is_endless() ) {\r\n\t\t\treturn false;\r\n\t\t}\r\n\r\n\t\tif ( ! strlen( $date_format ) ) {\r\n\t\t\t$date_format = get_option('date_format', 'd/m/Y');\r\n\t\t}\r\n\r\n\t\t/**\r\n\t\t * Filter the end date format using the charitable_campaign_end_date_format hook.\r\n\t\t */\r\n\t\t$date_format = apply_filters( 'charitable_campaign_end_date_format', $date_format, $this );\r\n\r\n\t\t/**\r\n\t\t * This is how the end date is stored in the database, so just return that directly.\r\n\t\t */\r\n\t\tif ( 'Y-m-d H:i:s' == $date_format ) {\r\n\t\t\treturn $this->end_date;\r\n\t\t}\r\n\t\t\r\n\t\treturn date( $date_format, $this->get_end_time() );\r\n\t}", "function eo_get_the_end($format='d-m-Y',$id='',$occurrence=0){\n\tglobal $post;\n\t$event = $post;\n\n\tif(isset($id)&&$id!='') $event = eo_get_by_postid($id);\n\n\tif(empty($event)) return false;\n\n\t$date = esc_html($event->EndDate).' '.esc_html($event->FinishTime);\n\n\tif(empty($date)||$date==\" \")\n\t\treturn false;\n\n\treturn eo_format_date($date,$format);\n}", "public function getEnd_date() {\n\t\treturn $this->_end_date;\n\t}", "private function _retrieveEndDate()\n {\n global $preferences;\n\n $bdate = new \\DateTime($this->_begin_date);\n if ( $preferences->pref_beg_membership != '' ) {\n //case beginning of membership\n list($j, $m) = explode('/', $preferences->pref_beg_membership);\n $edate = new \\DateTime($bdate->format('Y') . '-' . $m . '-' . $j);\n while ( $edate <= $bdate ) {\n $edate->modify('+1 year');\n }\n $this->_end_date = $edate->format('Y-m-d');\n } else if ( $preferences->pref_membership_ext != '' ) {\n //case membership extension\n $dext = new \\DateInterval('P' . $this->_extension . 'M');\n $edate = $bdate->add($dext);\n $this->_end_date = $edate->format('Y-m-d');\n }\n }", "public function getDate_planning_end()\n {\n return strftime('%d-%m-%Y', strtotime($this->_date_planning_end));\n }", "public function getEndDate()\r\n\t\t{\r\n\t\t\treturn $this->end_date;\r\n\t\t}", "function eo_get_schedule_end($format='d-m-Y',$id=''){\n\tglobal $post;\n\t$event = $post;\n\n\tif(isset($id)&&$id!='') $event = eo_get_by_postid($id);\n\n\t$date = esc_html($event->reoccurrence_end.' '.$event->StartTime);\n\n\tif(empty($date)||$date==\" \")\n\t\treturn false;\n\n\treturn eo_format_date($date,$format);\n}", "function FormatDateRange ($start, $end) {\n\t\n\t\t$full_format='F jS, Y';\n\t\t$no_year_format='F jS';\n\t\t$month_format='F';\n\t\t$day_format='jS';\n\t\t$year_format='Y';\n\t\t\n\t\t//\tThey're both null/missing/improper\n\t\tif (!is_date($start) && !is_date($end)) return '';\n\t\t\n\t\t//\tThe first is missing/null/improper\n\t\tif (!is_date($start)) $start=$end;\n\t\telse if (!is_date($end)) $end=$start;\n\t\t\n\t\t//\tThey're both the same\n\t\t/*if ($start->format(DateTime::ISO8601)===$end->format(DateTime::ISO8601)) {\n\t\t\n\t\t\t//\tJust output one of them\n\t\t\treturn $start->format($full_format);\n\t\t\n\t\t}*/\n\t\t\n\t\t//\tThey're in the same year\n\t\tif ($start->format('Y')===$end->format('Y')) {\n\t\t\n\t\t\t//\tThey're in the same month\n\t\t\tif ($start->format('n')===$end->format('n')) {\n\t\t\t\n\t\t\t\t//\tThey're on the same day\n\t\t\t\tif ($start->format('j')===$end->format('j')) {\n\t\t\t\t\n\t\t\t\t\treturn $start->format($full_format);\n\t\t\t\t\n\t\t\t\t} else {\n\t\t\t\t\n\t\t\t\t\treturn sprintf(\n\t\t\t\t\t\t'%1$s %2$s - %3$s, %4$s',\n\t\t\t\t\t\t$start->format($month_format),\n\t\t\t\t\t\t$start->format($day_format),\n\t\t\t\t\t\t$end->format($day_format),\n\t\t\t\t\t\t$start->format($year_format)\n\t\t\t\t\t);\n\t\t\t\t\n\t\t\t\t}\n\t\t\t\n\t\t\t} else {\n\t\t\t\n\t\t\t\treturn sprintf(\n\t\t\t\t\t'%1$s - %2$s, %3$s',\n\t\t\t\t\t$start->format($no_year_format),\n\t\t\t\t\t$end->format($no_year_format),\n\t\t\t\t\t$start->format($year_format)\n\t\t\t\t);\n\t\t\t\n\t\t\t}\n\t\t\n\t\t} else {\n\t\t\n\t\t\treturn sprintf(\n\t\t\t\t'%1$s - %1$s',\n\t\t\t\t$start->format($full_format),\n\t\t\t\t$end->format($full_format)\n\t\t\t);\n\t\t\n\t\t}\n\t\n\t}", "public function getDateEnd()\n {\n return $this->dateEnd;\n }", "public function getDateEnd()\n {\n return $this->dateEnd;\n }", "public function getDateEnd()\n {\n return $this->dateEnd;\n }", "public function getDateEnd()\n {\n return $this->dateEnd;\n }", "public function getDateEnd()\n {\n return $this->dateEnd;\n }", "function getEndDate() \n\t{\n\t\treturn (strlen($this->end_date)) ? $this->end_date : NULL;\n\t}", "public function getEndDate() {\n\n return $this->end_date;\n }", "private function getEndDate( $end_date )\n {\n return $this->matchDateFormat( $end_date )\n ? $end_date\n : Carbon::now()->format('Y-m-d');\n }", "private function getEndDate( $end_date )\n {\n return $this->matchDateFormat( $end_date )\n ? $end_date\n : Carbon::now()->format('Y-m-d');\n }", "function eo_the_end($format='d-m-Y',$id=''){\n\techo eo_get_the_end($format,$id);\n}", "public function away_mode_end_date() {\n\n\t\t$current = current_time( 'timestamp' ); //The current time\n\n\t\t//if saved date is in the past update it to something in the future\n\t\tif ( isset( $this->settings['end'] ) && isset( $this->settings['enabled'] ) && $current < $this->settings['end'] ) {\n\t\t\t$end = $this->settings['end'];\n\t\t} else {\n\t\t\t$end = strtotime( date( 'n/j/y 12:00 \\a\\m', ( current_time( 'timestamp' ) + ( 86400 * 2 ) ) ) );\n\t\t}\n\n\t\t//Date Field\n\t\t$content = '<input class=\"end_date_field\" type=\"text\" id=\"itsec_away_mode_end_date\" name=\"itsec_away_mode[away_end][date]\" value=\"' . date( 'm/d/y', $end ) . '\"/><br>';\n\t\t$content .= '<label class=\"end_date_field\" for=\"itsec_away_mode_end_date\"> ' . __( 'Set the date at which the admin dashboard should become available', 'it-l10n-ithemes-security-pro' ) . '</label>';\n\n\t\techo $content;\n\n\t}", "public function getEndDate();", "public function getEndDate();", "function erp_financial_end_date() {\n $financial_year_dates = erp_get_financial_year_dates();\n\n return $financial_year_dates['end'];\n}", "public function getEndDate()\n {\n return $this->stringToDate((string) $this->json()->end_date);\n }", "public function getEnd()\n {\n return Carbon::createFromFormat('d/m/Y', $this->data_saida);\n }", "public function setDateEnd($var)\n {\n GPBUtil::checkString($var, True);\n $this->dateEnd = $var;\n\n return $this;\n }", "public function getEndDateTime();", "public function getEndDate() {\n return $this->endDate;\n }", "function eo_schedule_end($format='d-m-Y',$id=''){\n\techo eo_get_schedule_end($format,$id);\n}", "public function getEndDate(): Date\n {\n return $this->endDate;\n }", "public function getEndDate(){\n\t\treturn $this->endDate;\n\t}", "public function endDate()\n {\n $specialEndDate = $this->getSpecialEndDate();\n if ($specialEndDate !== false) {\n return $specialEndDate;\n }\n\n $this->date->setTimestamp($this->begin);\n\n $position = array_search($this->ruleInfo['baseWeekday'], $this->ruleInfo['weekdays']);\n\n if ($position !== 0) {\n $this->date->gotoDayOfWeek($this->ruleInfo['weekdays'][0]);\n }\n\n $repeatedWeek = ceil(($this->ruleInfo['times'] + $position) / count($this->ruleInfo['weekdays'])) - 1;\n $mod = ($this->ruleInfo['times'] + $position) % count($this->ruleInfo['weekdays']);\n $endDayPosition = $mod === 0 ? count($this->ruleInfo['weekdays']) - 1 : $mod - 1;\n $this->date->addWeek($repeatedWeek * $this->ruleInfo['freq']);\n\n if ($endDayPosition === 0) {\n $this->ruleInfo['end'] = $this->date->getDateWithExtendedYear();\n\n return $this->ruleInfo['end'];\n }\n\n $this->date->gotoDayOfWeek($this->ruleInfo['weekdays'][$endDayPosition]);\n $this->ruleInfo['end'] = $this->date->getDateWithExtendedYear();\n\n return $this->ruleInfo['end'];\n }", "protected function getEnd()\n {\n return new Zend_Date(\n Mage::getStoreConfig(self::CONFIG_PREFIX . 'end', $this->getStore()),\n $this->getDateTimeFormat(),\n $this->getLocale()->getLocaleCode()\n );\n }", "public function setEndDate(string $date);", "public function test_end_date_format_type()\n {\n // show actiual errors without handling\n ////$this->withoutExceptionHandling();\n \n $this->json('POST', '/', array_merge($this->data(),['end_date'=>'abc']))\n ->seeJson([\n 'end_date' => [\"The end date does not match the format Y-m-d.\",\"The end date is not a valid date.\",\"The end date must be a date after or equal to start date.\",\"The end date must be a date before or equal to today.\"]\n ]);\n }", "public function getEndDate()\n {\n return $this->EndDate;\n }", "function setEndDate($end_date = \"\") \n\t{\n\t\t$this->end_date = $end_date;\n\t}", "public function getEndDate()\n {\n return $this->endDate;\n }", "public function getEndDate()\n {\n return $this->endDate;\n }", "public function getEndDate()\n {\n return $this->endDate;\n }", "public function getEndDate()\n {\n return $this->endDate;\n }", "public function getEndDate()\n {\n return $this->endDate;\n }", "public function getEndDate()\n {\n return $this->endDate;\n }", "public function getEndDate() \n {\n return $this->_fields['EndDate']['FieldValue'];\n }", "function tripal_jobs_get_end_time($job){\n if($job->end_time > 0){\n $end = format_date($job->end_time);\n } else {\n $end = '';\n }\n return $end;\n}", "public function getEndDate() {\n return $this->endDate;\n }", "public function getEndDate() {\n return $this->endDate;\n }", "function FormatDateTimeRange ($start, $end) {\n\t\n\t\t$full_format='F jS, Y g:i A';\n\t\t$no_year_format='F jS';\n\t\t$month_format='F';\n\t\t$day_format='jS';\n\t\t$year_format='Y';\n\t\t$time_format='g:i A';\n\t\t$date_format='F jS, Y';\n\t\t$time_format_no_ampm='g:i';\n\t\n\t\t//\tIf both are missing/improper, fail\n\t\t//\tby returning the empty string\n\t\tif (!is_date($start) && !is_date($end)) return '';\n\t\t\n\t\t//\tOne is missing/improper, treat it as\n\t\t//\ta \"range\" between start and start or\n\t\t//\tend and end\n\t\tif (!is_date($start)) $start=$end;\n\t\telse if (!is_date($end)) $end=$start;\n\t\t\n\t\t//\tThey're in the same year\n\t\tif ($start->format('Y')===$end->format('Y')) {\n\t\t\n\t\t\t//\tThey're in the same month\n\t\t\tif ($start->format('n')===$end->format('n')) {\n\t\t\t\n\t\t\t\t//\tThey're on the same day\n\t\t\t\tif ($start->format('j')===$end->format('j')) {\n\t\t\t\t\n\t\t\t\t\t//\tThey're both in the afternoon/morning\n\t\t\t\t\tif ($start->format('A')===$end->format('A')) {\n\t\t\t\t\t\n\t\t\t\t\t\t//\tThey're at the same time\n\t\t\t\t\t\tif ($start->format('g:i')===$end->format('g:i')) {\n\t\t\t\t\t\t\n\t\t\t\t\t\t\treturn $start->format($full_format);\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\treturn sprintf(\n\t\t\t\t\t\t\t'%s %s - %s',\n\t\t\t\t\t\t\t$start->format($date_format),\n\t\t\t\t\t\t\t$start->format($time_format_no_ampm),\n\t\t\t\t\t\t\t$end->format($time_format)\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\n\t\t\t\t\treturn sprintf(\n\t\t\t\t\t\t'%s - %s',\n\t\t\t\t\t\t$start->format($full_format),\n\t\t\t\t\t\t$end->format($time_format)\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\t\treturn sprintf(\n\t\t\t\t\t'%s %s %s - %s %s %s',\n\t\t\t\t\t$start->format($month_format),\n\t\t\t\t\t$start->format($day_format),\n\t\t\t\t\t$start->format($time_format),\n\t\t\t\t\t$end->format($day_format),\n\t\t\t\t\t$end->format($time_format),\n\t\t\t\t\t$end->format($year_format)\n\t\t\t\t);\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\treturn sprintf(\n\t\t\t\t'%s %s - %s %s %s',\n\t\t\t\t$start->format($no_year_format),\n\t\t\t\t$start->format($time_format),\n\t\t\t\t$end->format($no_year_format),\n\t\t\t\t$end->format($time_format),\n\t\t\t\t$end->format($year_format)\n\t\t\t);\n\t\t\t\n\t\t}\n\t\t\n\t\treturn sprintf(\n\t\t\t'%s - %s',\n\t\t\t$start->format($full_format),\n\t\t\t$end->format($full_format)\n\t\t);\n\t\n\t}", "public function setEndDate(DrupalDateTime $end_date = NULL);", "public function setEndDate($date)\n\t\t{\n\t\t\t$this->end_date = $date;\n\t\t}", "public function setEndDate($end_date)\n {\n $this->json()->end_date = $this->dateToString($end_date);\n }", "public function setEndDate( KCommandContext $context )\n {\n $data = $context->data;\n \n if( $data->day || $data->month || $data->year )\n { \n $date = new KDate();\n \n $date->day( (int) $data->day );\n \n $date->month( (int) $data->month );\n \n $date->year( (int) $data->year );\n \n $data->endDate = $date;\n }\n }", "function _isValidEndDate()\r\n {\r\n if (strtotime($this->data[$this->name]['end_date']) > strtotime(date('Y-m-d H:i:s'))) {\r\n return true;\r\n }\r\n return false;\r\n }", "public function getEndDateAndTime() {}", "function getEndDate()\n {\n $oDaySpan = $this->_value;\n $value = is_null($oDaySpan) ? null : $oDaySpan->getEndDate();\n return $value;\n }", "public function setEndDate($date)\n\t{\n\t\treturn $this->setDate('End', $date);\n\t}", "public function getEndDate() {\r\n $endDate = new \\DateTime('@' . $this->getTimestamp());\r\n\r\n switch($this->getMode()) {\r\n case self::$modeYear:\r\n $endDate->modify('last day of December');\r\n break;\r\n case self::$modeMonth:\r\n $endDate->modify('last day of this month');\r\n break;\r\n case self::$modeWeek:\r\n $date = date('w', $endDate->getTimestamp());\r\n if($date != 0) {\r\n $endDate->modify('next Sunday');\r\n }\r\n break;\r\n case self::$modeDay:\r\n break;\r\n default:\r\n throw new \\Exception(\"ViewMode is not known in ViewCalendar.\");\r\n break;\r\n }\r\n\r\n $endDate->setTime(23, 59, 59);\r\n return $endDate;\r\n }", "public function set_end_date($end_date)\n\t{\n\t\tif (is_null($end_date)) {\n\t\t\tthrow new InvalidArgumentException(\"Project End Date Invalid!\");\n\t\t}\n\t\t$this->end_date = $end_date;\n\t}", "private function end() {\n return $this->formats['end'];\n }", "public function setEndDateAttribute($value)\n\t{\n\t\treturn $this->attributes['end_date'] = Carbon::parse($value)->format('Y-m-d H:i:s');\n\t}", "public function get_endDate()\n {\n return $this->_endDate;\n }", "public function getEndDateTime()\n {\n return $this->endDateTime;\n }", "public function setDateEnd($dateEnd)\n {\n $this->dateEnd = $dateEnd;\n \n return $this;\n }", "public function setEndDate($value)\n {\n $this->endDate = $value;\n }", "function format_daterange($start_date, $end_date, $format = 'd', $full_text, $start_text, $end_text, $culture = null, $charset = null)\n{\n if ($start_date != '' && $end_date != '')\n {\n return sprintf($full_text, format_date($start_date, $format, $culture, $charset), format_date($end_date, $format, $culture, $charset));\n }\n else if ($start_date != '')\n {\n return sprintf($start_text, format_date($start_date, $format, $culture, $charset));\n }\n else if ($end_date != '')\n {\n return sprintf($end_text, format_date($end_date, $format, $culture, $charset));\n }\n}", "public function setDateEnd($dateEnd = null)\n {\n $this->dateEnd = $dateEnd;\n\n return $this;\n }", "public function formatDate() {\n\t\t\tif(!empty($this->review_date)) {\n\t\t\t\t$date = new dateTime($this->review_date);\n\t\t\t\treturn $date->format('M jS, Y - H:i');\n\t\t\t}\n\t\t}", "public function setEndDate($endDate='')\r\n\t\t{\r\n\t\t\tif ($endDate != '')\r\n\t\t\t{\r\n\t\t\t\t$this->end_date = $endDate;\r\n\t\t\t}\r\n\t\t}", "public function setCollectionDateEnd($val){\n\t\tif(trim($val) != \"\"){\n\t\t\t$this->collectionDateEnd = trim($val);\n\t\t}\t\t\n\t\treturn $this;\n\t}", "public function getDateTimeObjectEnd();", "public function get_end_time() {\r\n\t\tif ( ! isset( $this->end_time ) ) {\r\n\r\n\t\t\tif ( $this->is_endless() ) {\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\r\n\t\t\t/**\r\n\t\t\t * The date is stored in the format of Y-m-d H:i:s.\r\n\t\t\t */\r\n\t\t\t$date_time \t= explode( ' ', $this->end_date );\r\n\t\t\t$date \t\t= explode( '-', $date_time[0] );\r\n\t\t\t$time \t\t= explode( ':', $date_time[1] );\r\n\t\t\t$this->end_time = mktime( $time[0], $time[1], $time[2], $date[1], $date[2], $date[0] );\r\n\t\t}\r\n\t\treturn $this->end_time;\r\n\t}", "function setEndDateAndTime($end_date = \"\", $end_time) \n\t{\n\t\t$y = ''; $m = ''; $d = ''; $h = ''; $i = ''; $s = '';\n\t\tif (preg_match(\"/(\\d{4})-(\\d{2})-(\\d{2})/\", $end_date, $matches))\n\t\t{\n\t\t\t$y = $matches[1];\n\t\t\t$m = $matches[2];\n\t\t\t$d = $matches[3];\n\t\t}\n\t\tif (preg_match(\"/(\\d{2}):(\\d{2}):(\\d{2})/\", $end_time, $matches))\n\t\t{\n\t\t\t$h = $matches[1];\n\t\t\t$i = $matches[2];\n\t\t\t$s = $matches[3];\n\t\t}\n\t\t$this->end_date = sprintf('%04d%02d%02d%02d%02d%02d', $y, $m, $d, $h, $i, $s);\n\t}", "public function getEndOfDayDate()\n {\n return $this->_date->date(null, '23:59:59');\n }", "function get_end_date($values)\n {\n if(!empty($values['edate']))\n {\n $edate = explode(\"-\",$values['edate']);\n $end_timestamp = mktime(0,0,0,$edate[1],$edate[2],$edate[0]);\n }\n else\n $end_timestamp = time();\n \n return $end_timestamp;\n }", "public function end($value = '')\n {\n if (!empty($value)) {\n\n return $this->builder->where(\"rc_date\", '<=', date('Y-m-d', strtotime($value)));\n }\n }", "public function setEndDate($value) \n {\n $this->_fields['EndDate']['FieldValue'] = $value;\n return $this;\n }", "public function get_endtime()\n {\n }", "public function getEndAttribute($input)\n {\n $zeroDate = str_replace(['Y', 'm', 'd'], ['0000', '00', '00'], config('app.date_format'));\n\n if ($input != $zeroDate && $input != null) {\n return Carbon::createFromFormat('Y-m-d', $input)->format(config('app.date_format'));\n } else {\n return '';\n }\n }", "public function getFreeSupportEndDate() {\n\t\tif (!$this->startfgp) {\n\t\t\treturn '';\n\t\t}\n\t\t$time = strtotime($this->startfgp.\" + \".$this->durationfgp.\" days\");\n\t\treturn $time;\n\t}", "public function setEndDateTime($val)\n {\n $this->_propDict[\"endDateTime\"] = $val;\n return $this;\n }", "function roomify_conversations_add_end_date_field() {\n field_info_cache_clear();\n\n // \"conversation_book_end_date\" field.\n if (field_read_field('conversation_book_end_date') === FALSE) {\n $field = array(\n 'field_name' => 'conversation_book_end_date',\n 'type' => 'datetime',\n 'cardinality' => 1,\n 'locked' => 1,\n 'settings' => array(\n 'cache_count' => 4,\n 'cache_enabled' => 0,\n 'granularity' => array(\n 'day' => 'day',\n 'hour' => 0,\n 'minute' => 0,\n 'month' => 'month',\n 'second' => 0,\n 'year' => 'year',\n ),\n 'profile2_private' => FALSE,\n 'timezone_db' => '',\n 'todate' => '',\n 'tz_handling' => 'none',\n ),\n );\n field_create_field($field);\n }\n\n field_cache_clear();\n\n // \"conversation_book_end_date\" field instance.\n if (field_read_instance('roomify_conversation', 'conversation_book_end_date', 'standard') === FALSE) {\n $instance = array(\n 'field_name' => 'conversation_book_end_date',\n 'entity_type' => 'roomify_conversation',\n 'label' => 'End Date',\n 'bundle' => 'standard',\n 'required' => FALSE,\n 'widget' => array(\n 'type' => 'date_popup',\n ),\n 'settings' => array(\n 'default_value' => 'now',\n 'default_value2' => 'same',\n 'default_value_code' => '',\n 'default_value_code2' => '',\n 'user_register_form' => FALSE,\n ),\n );\n field_create_instance($instance);\n }\n}", "function getDateofMonthEnd($date){\n return date(\"Y-m-t\", strtotime($date));\n }", "public function getFormattedExpirationDate();", "private function getEndDate($root) {\n\t\t$block = $this->getDatePriceBlock($root);\n\t\t// start and end dates\n\t\tif (count($block) === 3) {\n\t\t\t$date = trim($block[1]->text());\n\t\t\t$retVal = $this->formatDate($date);\n\t\t\treturn $retVal;\n\t\t}\n\t\t\n\t\treturn null;\n\t}", "public function removeEndDate()\n\t{\n\t\t$this->dateEnd = null;\n\t\t\n\t\treturn $this;\n\t}", "public function setDateEnd($dateEnd)\n {\n $this->dateEnd = VT::toDateTimeImmutable($dateEnd);\n }", "public function getEndTime()\r\n {\r\n $date = new Zend_Date($this->start_time);\r\n $date->addDay($this->duration);\r\n \r\n return $date->toString(Time_Format::getFullDateTimeFormat());\r\n }", "public function setEndDate($value)\n {\n return $this->set('EndDate', $value);\n }", "public function setEndDate($value)\n {\n return $this->set('EndDate', $value);\n }", "public function setEndAttribute($input)\n {\n if ($input != null && $input != '') {\n $this->attributes['end'] = Carbon::createFromFormat(config('app.date_format'), $input)->format('Y-m-d');\n } else {\n $this->attributes['end'] = null;\n }\n }", "function NiceFromToDate() {\r\n\t\tif (!$this->ToDate && $this->FromDate) return '';\r\n\t\t\r\n\t\t$from_date = new Date();\r\n\t\t$to_date = new Date();\r\n\t\t$from_date->setValue($this->FromDate);\r\n\t\t$to_date->setValue($this->ToDate);\r\n\t\t\t\t\r\n\t\tif (!$this->ToDate && $this->FromDate) return $from_date->FormatI18N('%e. %B %Y');\r\n\r\n\t\t$from_month = $from_date->FormatI18N('%B');\r\n\t\t$to_month = $to_date->FormatI18N('%B');\r\n\t\t\r\n\t\t$from_year = $from_date->Format('Y');\r\n\t\t$to_year = $from_date->Format('Y');\r\n\t\t\r\n\t\tif($from_month == $to_month) {\r\n\t\t\t$long_from_to_date = $from_date->Format('j. - ').$to_date->Format('j. ').$to_month.' '.$to_year;\r\n\t\t}\r\n\t\telseif($from_year == $to_year) {\r\n\t\t\t$long_from_to_date = $from_date->Format('j. ').$from_month.' - '.$to_date->Format('j. ').$to_month.' '.$to_year;\r\n\t\t}\r\n\t\telse {\r\n\t\t\t$long_from_to_date = $from_date->FormatI18N('%e. %B %Y') . ' - ' . $to_date->FormatI18N('%e. %B %Y');\r\n\t\t}\r\n\t\treturn $long_from_to_date;\r\n\t\t//$this->FromDate->setConfig('dateformat','dd/MM/y');//.FormatI18N('%e. %B %Y');\r\n\t}", "private function setEndDate(string $endYear = null) {\n\t\tif(is_null($endYear)){\n\t\t\t$endYear = $this->startDate->format('Y');\n\t\t} else {\n\t\t\t$endYear = (int) $endYear;\n\t\t\tif($endYear>2000 && $endYear<2100)\n\t\t\t{\n\t\t\t\t$endYear = (int) $endYear;\n\t\t\t} else {\n\t\t\t\t$endYear = $this->startDate->format('Y');\n\t\t\t}\n\t\t}\n\t\t$this->endDate = DateTime::createFromFormat('d-m-Y','31-12-'.$endYear);\n\t}", "public function setEndDateAttribute($date)\n {\n // Use with Carbon instance:\n // -------\n // Carbon::createFromFormat('H:i', $date)->format('H:i');\n return $this->attributes['end_date'] = strtotime(str_replace('/', '-', $date));\n }", "private function endTime($year, $month, $date) {\n return $year . '-' . $month . '-' . $date . ' 23:59:59';\n }", "function updateSubscriptionEndDate($subscription_start_date, $timePeriodForService) {\n $subscriptionEndDate = '';\n if ($timePeriodForService == \"1 Month\") {\n $timePeriod = \"1 month\";\n $subscriptionEndDate = date('Y-m-d',strtotime($subscription_start_date . \" + \". $timePeriod));\n } elseif ($timePeriodForService == \"3 months\" || $timePeriodForService == \"3 Months\"){ // Added as per discussion with Faizan CCP-5379\n $timePeriod = \"3 months\";\n $subscriptionEndDate = date('Y-m-d',strtotime($subscription_start_date . \" + \". $timePeriod));\n } elseif ($timePeriodForService == \"1 Year\" || ($timePeriodForService == '' || $timePeriodForService == null)) {\n $timePeriod = \"365 day\";\n $subscriptionEndDate = date('Y-m-d',strtotime($subscription_start_date . \" + \". $timePeriod));\n } elseif ($timePeriodForService == \"2 Years\") {\n $timePeriod = \"730 day\";\n $subscriptionEndDate = date('Y-m-d',strtotime($subscription_start_date . \" + \". $timePeriod));\n } elseif ($timePeriodForService == \"3 Years\") {\n $timePeriod = \"1095 day\";\n $subscriptionEndDate = date('Y-m-d',strtotime($subscription_start_date . \" + \". $timePeriod));\n }\n\n return $subscriptionEndDate;\n }" ]
[ "0.7788637", "0.7714097", "0.7450253", "0.74389845", "0.7060781", "0.7006745", "0.6926648", "0.68608665", "0.6849643", "0.6844956", "0.6756861", "0.6724656", "0.6714335", "0.66852075", "0.666537", "0.666537", "0.666537", "0.666537", "0.666537", "0.6652039", "0.6637865", "0.66264457", "0.6619224", "0.6593398", "0.65438646", "0.6536867", "0.6536867", "0.65138227", "0.65118176", "0.6442322", "0.6381279", "0.63729846", "0.63029873", "0.62930435", "0.6274832", "0.6268213", "0.6252732", "0.6251329", "0.622686", "0.62208533", "0.6195098", "0.6193363", "0.6164373", "0.6164373", "0.6164373", "0.6164373", "0.6164373", "0.6164373", "0.61375034", "0.6136996", "0.6126922", "0.6126922", "0.6041998", "0.6013626", "0.5962632", "0.59447145", "0.5941135", "0.5908164", "0.58866847", "0.58679193", "0.58519864", "0.5843661", "0.5835896", "0.5818834", "0.5817044", "0.5812143", "0.5786115", "0.5735164", "0.57165927", "0.57130575", "0.571086", "0.5696361", "0.56442636", "0.5626334", "0.5626068", "0.56159246", "0.56061053", "0.5603541", "0.559701", "0.55826175", "0.5565802", "0.5548192", "0.5543175", "0.5538795", "0.55373305", "0.55365515", "0.5532556", "0.5510172", "0.55077595", "0.55062056", "0.5500007", "0.5482464", "0.5482081", "0.5481642", "0.5475264", "0.5468212", "0.5460934", "0.5459351", "0.5458932", "0.5456843" ]
0.54952693
91
We only let the user see its own socialprofile if they are also allowed to edit it
public function viewSocialProfile(User $actor, User $user): string { if (($actor->id === $user->id && $actor->hasPermission('fof-socialprofile.editOwn')) || $actor->hasPermission('fof-socialprofile.view') ) { return $this->allow(); } return $this->deny(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function canViewProfile() {\n\t\treturn (!$this->protectedProfile || WCF::getUser()->userID == $this->userID || UserProfile::isBuddy($this->userID) || WCF::getUser()->getPermission('admin.general.canViewPrivateUserOptions'));\n\t}", "public function only_logged_in_customer_can_see_profile_edit_form()\n {\n $response = $this->get('/profile/edit')\n ->assertRedirect('/login');\n\n }", "function yz_hide_profile_settings_page_for_other_users() {\n\n if ( apply_filters( 'yz_hide_profile_settings_page_for_other_users', true ) ) {\n if ( bp_is_user() && ! is_super_admin() && ! bp_is_my_profile() ) {\n bp_core_remove_nav_item( bp_get_profile_slug() );\n }\n }\n\n}", "private function _check_socials_access() {\n\n return Access_token::inst()->check_socials_access($this->c_user->id);\n\n }", "function user_can_edit_user($user_id, $other_user)\n {\n }", "public function editprofile()\n\t\t{\n\t\t\tif(Auth::check()) {\n\t\t\t\t$userinfo = Auth::user();\n\t\t\t\treturn View::make('editprofile')->with('userinfo', $userinfo);\n\t\t\t} else {\n\t\t\t\tApp::abort(403);\n\t\t\t}\n\t\t}", "abstract protected function isSocialUser($type);", "public function canEdit()\n {\n if(!Auth::check())\n {\n return false;\n }\n //If the user is active/logged in, return true so that we can display user's specific objects\n if(Auth::user()->id===$this->user_id)\n {\n return true;\n }\n //By default\n return false;\n }", "public function editprofile_action()\n {\n Auth::checkAuthentication();\n \n \n $postname = Request::post('user_name');\n $postemail = Request::post('user_email');\n $postbio = Request::post('user_bio');\n\n\n if(Session::get('user_name') != $postname && $postname != null)\n {\n UserModel::editUserName($postname);\n }\n \n if(Session::get('user_email') != $postemail && $postemail != null)\n {\n UserModel::editUserEmail($postemail);\n }\n \n //null is checked in this method\n AvatarModel::createAvatar();\n \n if(Session::get('user_bio') != $postbio && $postbio != null)\n {\n UserModel::editBio($postbio);\n }\n\n return true;\n }", "public function editOwnProfile()\n {\n $user = User::find(Auth::user()->id);\n\n return view('profile.edit', compact('user'));\n }", "public function myprofileAction()\n {\n \tZend_Registry::set('Category', Category::ACCOUNT);\n \tZend_Registry::set('SubCategory', SubCategory::NONE);\n\n $album = $this->_user->getProfileAlbum();\n if(!$album->isReadableBy($this->_user, $this->_acl)){\n $album = null;\n \t}\n\n $blog = $this->_user->getBlog();\n if(!$blog->isReadableBy($this->_user, $this->_acl)){\n $blog = null;\n \t}\n\n $this->view->profilee = $this->_user;\n $this->view->album = $album;\n $this->view->blog = $blog;\n $this->view->medias = $album->getItemSet();\n\n $this->renderScript('user/profile.phtml');\n }", "function isOwner($facebookID){\n\t\tif($facebookID == $this->fk_member_id){\n\t\t\treturn true;\n\t\t}else{\n\t\t\treturn false;\n\t\t}\t\t\n\t}", "private function is_hidden_profile() {\n\t\treturn ! bp_profile_visibility_is_visible_profile( bp_displayed_user_id(), bp_loggedin_user_id() );\n\t}", "function canEdit() {\r\n\t\tif($this->owner->ID == Member::currentUserID())\r\n\t\t\treturn true;\r\n\r\n\t\t$member = Member::currentUser();\r\n\t\tif($member)\r\n\t\t\treturn $member->isAdmin();\r\n\r\n\t\treturn false;\r\n\t}", "public function canEdit()\n {\n if (!$this->site) {\n return false;\n }\n\n if (!$this->current_user) {\n return false;\n }\n\n if ($this->site->userIsVerified($this->current_user)) {\n return true;\n }\n\n return false;\n }", "function editProfile($staff){\n return false;\n }", "public function Edit_My_Profile()\n\t{\n\t\t$this->_CheckLogged();\n\t\t\n\t\t$this->_processInsert($this->instructors_model->getMyPostId());\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 profile_view(User $user)\n {\n return $user->hasPermission('profile-view');\n }", "function set_editor_profile() {\n\tif (!current_user_can('manage_options')) { ?>\n \t<style type=\"text/css\">\n \t\t.user-rich-editing-wrap, .user-comment-shortcuts-wrap, .show-admin-bar, .user-admin-bar-front-wrap,\n \t\t.user-nickname-wrap, .user-display-name-wrap, .user-url-wrap, .user-description-wrap, #profile-page h2 {\n\t\t\t\tdisplay:none !important;\n\t\t\t}\n\t\t</style>\n\t\t<?php\n\t}\n}", "public function edit_self(ProfileUser $editted_profile) {\r\n\t\tif ($this->user_id) {\r\n\t\t\t$sql = \"UPDATE `users` SET program = '$editted_profile->program' AND level = '$editted_profile->level' AND commuter = '$editted_profile->commuter' AND bio = '$editted_profile->bio' WHERE user_id = '$this->user_id' LIMIT 1\";\r\n\t\t\t$result = $this->dbc->query($sql)\r\n\t\t\tor die ($this->dbc->error);\r\n\t\t}\r\n\t}", "public function profile() {\n $this->restrictToRoleId(2);\n \n // Exécute la view\n $this->show('user/profile');\n }", "function action_profile_show() {\n // Process request with using of models\n $user = get_authorized_user();\n // Make Response Data\n if ($user !== NULL) {\n $data = [\n 'profile' => $user,\n ];\n return ['view' => 'user/show', 'data' => $data];\n } else {\n return error403();\n }\n}", "public function edit(Social $social)\n {\n //\n }", "function have_profile(){\n\treturn ( get_profile('enabled') === true && get_profile() !== -1 );\n}", "protected function handlePrivacy() : void // public visibility\n {\n if (!User::$id || empty($this->_get['id'][0]))\n {\n trigger_error('AjaxProfile::handlePrivacy - profileId empty or user not logged in', E_USER_ERROR);\n return;\n }\n\n $uid = User::$id;\n if ($this->_get['user'] && User::isInGroup(U_GROUP_ADMIN | U_GROUP_BUREAU))\n {\n if (!($uid = DB::Aowow()->selectCell('SELECT id FROM ?_account WHERE user = ?', $this->_get['user'])))\n {\n trigger_error('AjaxProfile::handlePrivacy - user \"'.$this->_get['user'].'\" does not exist', E_USER_ERROR);\n return;\n }\n }\n\n if ($this->undo)\n {\n DB::Aowow()->query('UPDATE ?_account_profiles SET extraFlags = extraFlags & ?d WHERE profileId IN (?a) AND accountId = ?d', ~PROFILER_CU_PUBLISHED, $this->_get['id'], $uid);\n DB::Aowow()->query('UPDATE ?_profiler_profiles SET cuFlags = cuFlags & ?d WHERE id IN (?a) AND user = ?d', ~PROFILER_CU_PUBLISHED, $this->_get['id'], $uid);\n }\n else\n {\n DB::Aowow()->query('UPDATE ?_account_profiles SET extraFlags = extraFlags | ?d WHERE profileId IN (?a) AND accountId = ?d', PROFILER_CU_PUBLISHED, $this->_get['id'], $uid);\n DB::Aowow()->query('UPDATE ?_profiler_profiles SET cuFlags = cuFlags | ?d WHERE id IN (?a) AND user = ?d', PROFILER_CU_PUBLISHED, $this->_get['id'], $uid);\n }\n }", "function userCanEditPage()\n\t{\n\t\t// use Yawp::authUsername() instead of $this->username because\n\t\t// we need to know if the user is authenticated or not.\n\t\treturn $this->acl->pageEdit(Yawp::authUsername(), $this->area, \n\t\t\t$this->page);\n\t}", "function ds_get_social_profiles() {\n\n // Return a filterable social profile.\n return apply_filters(\n 'ds_social_profiles',\n array()\n );\n \n}", "public function is_profile_page() {\r\n\t\tglobal $pagenow;\r\n\r\n\t\treturn $pagenow === 'profile.php' || $pagenow === 'user-new.php' || $pagenow === 'user-edit.php';\r\n\t}", "public function profile()\n {\n $user_id = auth()->user()->id;\n $user = User::find($user_id);\n if (auth()->user()->id !== $user->id){\n return back ('user.edit')->with('error', 'Unauthorized Access');\n }\n return view ('user.edit')->with('user', $user);\n }", "public function profileEdit()\n {\n\t$oUser = Auth::user();\n return view('profile_edit', ['oUser' => $oUser, 'active' => 'profile_link']);\n }", "public function canMemberLikes() {\n $viewer = Engine_Api::_()->user()->getViewer();\n if (!$viewer || !$viewer->getIdentity()) {\n return false;\n }\n\t\t$like_profile_show = Engine_Api::_()->getApi( 'settings' , 'core' )->getSetting( 'like.profile.show' ) ;\n\t\tif ( empty( $like_profile_show ) ) {\n\t\t\treturn false;\n\t\t}\n\t\treturn true;\n }", "function edit() {\n\t\t\t\n\t\t// Require a validated association \n\t\tProfileAssociationValidRequired::check();\r\n\t\n\t\t// Get annonce\r\n\t\t$this->fetchAnnonce();\n\t\t\n\t\t// We should have write access to this annonce\n\t\t$this->checkWriteAccess();\r\n\t\r\n\t\t// Redirect to the annonce\r\n\t\t$this->renderView(\"editAnnonce\");\r\n\t\r\n\t}", "function auth_can_edit_user($user, $target)\n{\n global $min_user_editing_level;\n \n // Always allowed to modify your own stuff\n if(strcasecmp($user, $target) == 0)\n {\n return 1;\n }\n\n if(authGetUserLevel($user) >= $min_user_editing_level)\n {\n return 1;\n }\n\n // Unathorised access\n return 0;\n}", "function canEdit($user) {\n if($user->getId() == $this->getId()) {\n return true; // user can change his own account\n } // if\n\n return $user->isCompanyManager($this->getCompany());\n }", "public function profile() {\n if ($this->input->post() && $this->session->has_userdata('curr_user_id_edit')) {\n $this->_edit_profile();\n return;\n }\n\n // else, continue here\n\n $user_id = $this->session->userdata('user')['id'];\n // if third segment is not specified\n if (!$this->uri->segment(3)) {\n $this->_redirect('dashboard/profile/' . $user_id);\n return;\n }\n\n $id_segment = $this->uri->segment(3);\n // user should be active!\n $user = $this->_fetch_user($id_segment);\n\n // if user does not exist\n // or user status is 0\n if (!$user || $user['status'] == 0) {\n $this->session->set_flashdata('msg', 'An error occurred. User does not exist.');\n $this->_redirect('dashboard');\n return;\n }\n\n // allow edit if curr id == segment\n $allow_edit = $id_segment === $user_id;\n\n if ($allow_edit && $this->uri->segment(4) === 'edit') {\n $edit = true;\n }\n // if not edit, redirect to no /edit\n else if ($this->uri->segment(4) === 'edit') {\n $this->_redirect('dashboard/profile/' . $id_segment);\n return;\n }\n // else if any segment\n // go back to profile\n else if ($this->uri->segment(4)) {\n $this->_redirect('dashboard/profile/' . $id_segment);\n return;\n }\n\n // if just view\n if (!(isset($edit) && $edit)) {\n // unset user id edit here\n $this->session->unset_userdata('curr_user_id_edit');\n // display profile view\n $data = array(\n 'title' => 'My Profile',\n 'msg' => $this->session->flashdata('msg'),\n 'user' => $user,\n 'allow_edit' => $allow_edit\n );\n $this->_view(\n array('templates/nav', 'pages/dashboard/profile', 'alerts/msg'),\n array_merge($this->_nav_items, $data)\n );\n return;\n }\n\n // proceed here if edit\n $this->load->library('form_validation');\n\n // set session of currently editing\n // unset if not editing above\n $this->session->set_userdata('curr_user_id_edit', $user['id']);\n // display edit profile view\n $this->_show_edit_profile($user);\n }", "public function checkForProfile()\n\t\t{\n\t\t\treturn (!Auth::user()->profiles) ? false : true;\n\t\t}", "public function canModifyVisibilityOfUsers();", "public function profile($userid = null){\r\n if (!$this->user)\r\n url::redirect(\"/user/register\");\r\n \r\n if(!$userid)\r\n $userid = $this->user->id;\r\n\t\t\r\n // filter sql control symbols\r\n $userid = str_replace( array('?', '#', '%', \"'\"),'',$userid );\r\n\t\t\r\n $user = null;\r\n $allow_edit = false;\r\n\r\n // відкриває вікно редагування персональних даних після активації\r\n $editPersonal = false;\r\n\t\t\r\n if( ($this->logged_in && $this->user->id == $userid ) ){\r\n $user = $this->user;\r\n if($user->last_login == 0){\r\n $editPersonal = true;\r\n $user->last_login = time();\r\n $user->save();\r\n }\r\n $allow_edit = true;\r\n\r\n // провірка на синхронізацію мікроблогінгу з твітером\r\n /*\r\n if(isset($_SESSION['oauth_token']) && isset($_SESSION['oauth_token_secret']) && isset($_REQUEST['oauth_verifier'])){\r\n $consumer_key = Kohana::config('user.TWITTER_KEY');\r\n $consumer_secret = Kohana::config('user.TWITTER_SECRET');\r\n \r\n include Kohana::find_file('vendor','TwitterOAuth');\r\n $connection = new TwitterOAuth($consumer_key, $consumer_secret, $_SESSION['oauth_token'], $_SESSION['oauth_token_secret']);\r\n $token_credentials = $connection->getAccessToken($_REQUEST['oauth_verifier']);\r\n $user->twitter_token = $token_credentials['oauth_token'];\r\n $user->twitter_secret = $token_credentials['oauth_token_secret'];\r\n $user->twitter_last_sync = $user->twitter_last_sync != 0 ? $user->twitter_last_sync : 0;\r\n $user->save();\r\n }\r\n */\r\n \r\n } else {\r\n $user = ORM::factory('user', $userid);\r\n }\r\n\t\t\r\n // user not found, show 404\r\n if(empty($user->id)){\r\n Kohana::show_404();\r\n exit;\r\n }\r\n \r\n javascript::add(array('comments','jquery.jcarousel.pack','friendship', 'swfobject', 'jquery.uploadify.v2.1.4'));\r\n stylesheet::add(array('jcarousel/jquery.jcarousel','jcarousel/skin', 'uploadify'));\r\n\t\t\r\n\r\n //javascript::add('messages');\r\n \r\n //$messagesCount = ORM::factory('message')->where('user_id', $user->id)->count_all();\r\n //$lastMessage = ORM::factory('message')->where('user_id', $user->id)->orderby('date', 'DESC')->limit(1)->find();\r\n \t$statistic=Statistic_Controller::getInstance();\r\n \t$view = new View('userpage');\r\n $view->standart=$statistic->getStats('standart');\r\n $view->site=$statistic->getStats('site');\r\n $view->filter=$statistic->getStats('filter');\r\n $view->user_profile = $user;\r\n $view->lang = Kohana::lang('user');\r\n $view->allowedit = $allow_edit;\r\n $view->editPersonal = $editPersonal;\r\n \r\n $view->logged_in_user = $this->user;\r\n //$view->ads_count = ORM::factory('ads')->where('user_id', $user->id)->count_all();\r\n\r\n //$view->user_stat = MOJOUser::user_statistic($user->id);\r\n //$view->friends = MOJOUser::get_friends($user->id);\r\n\r\n /*\r\n $view->was_events_count = ORM::factory('event')\r\n\t\t\t\t\t\t\t->join('events_users','events_users.event_id','events.id')\r\n\t\t\t\t\t\t\t->where(array('events_users.user_id'=>$user->id,\r\n\t\t\t\t\t\t\t\t\t\t 'events.start_date <' => time(),\r\n\t\t\t\t\t\t\t\t\t\t 'events.status'=>1 ))\r\n\t\t\t\t\t\t\t->orderby(array('events.start_date'=>'desc'))\r\n\t\t\t\t\t\t\t->count_all();\r\n\t\t\t\t\t\t\t\r\n $view->will_events_count = ORM::factory('event')\r\n\t\t\t\t\t\t\t->join('events_users','events_users.event_id','events.id')\r\n\t\t\t\t\t\t\t->where(array('events_users.user_id'=>$user->id,\r\n\t\t\t\t\t\t\t\t\t\t 'events.start_date >' => time(),\r\n\t\t\t\t\t\t\t\t\t\t 'events.status'=>1))\r\n\t\t\t\t\t\t\t->orderby(array('events.start_date'=>'asc'))\r\n\t\t\t\t\t\t\t->count_all();\r\n\t\t\r\n $view->was_events = ORM::factory('event')\r\n\t\t\t\t\t\t\t->join('events_users','events_users.event_id','events.id')\r\n\t\t\t\t\t\t\t->where(array('events_users.user_id'=>$user->id,\r\n\t\t\t\t\t\t\t\t\t\t 'events.start_date <' => time(),\r\n\t\t\t\t\t\t\t\t\t\t 'events.status'=>1 ))\r\n\t\t\t\t\t\t\t->orderby(array('events.start_date'=>'desc'))\r\n\t\t\t\t\t\t\t->find_all(4); \r\n\t\t\t\t\t\t\t\r\n $view->will_events = ORM::factory('event')\r\n\t\t\t\t\t\t\t->join('events_users','events_users.event_id','events.id')\r\n\t\t\t\t\t\t\t->where(array('events_users.user_id'=>$user->id,\r\n\t\t\t\t\t\t\t\t\t\t 'events.start_date >' => time(),\r\n\t\t\t\t\t\t\t\t\t\t 'events.status'=>1))\r\n\t\t\t\t\t\t\t->orderby(array('events.start_date'=>'asc'))\r\n\t\t\t\t\t\t\t->find_all(4);\r\n $view->random_pictures = ORM::factory('picture')\r\n\t\t\t\t\t\t\t\t\t->select('pictures.*, events.name as event_name, events.city_custom, events.location_custom, locations.city as loc_city, locations.name as loc_name')\r\n\t\t\t\t\t\t\t\t\t->join('events', 'events.id', 'pictures.event_id','INNER')\r\n\t\t\t\t\t\t\t\t\t->join('locations', 'events.location_id', 'locations.id','LEFT')\r\n\t\t\t\t\t\t\t\t\t->join('presences', 'presences.picture_id', 'pictures.id','INNER')\r\n\t\t\t\t\t\t\t\t\t->where(array('pictures.deleted'=>0, 'presences.user_id'=>$user->id))\r\n\t\t\t\t\t\t\t\t\t->find_all(40);\r\n\t\t\t\t\t\t\t\t\t\r\n */\r\n $view->set_global('hide_flow', true);\r\n $view->allow_edit = $allow_edit;\r\n $view->active = 1;\r\n $view->render(true);\r\n\t}", "public function authorize()\n {\n if($this->path() == 'profile/create')\n {\n return true;\n } else {\n return false;\n }\n }", "public function edit(Profile $profile)\n {\n $user = $profile->user()->first();\n if (Gate::allows('users.update',$user)) {\n return view('user-profile::edit' , compact('profile'));\n }\n }", "public function forceProfilePage() {\n\t\t$user = wp_get_current_user();\n\t\tif ( ! is_object( $user ) ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t$settings = Auth_Settings::instance();\n\t\tif ( $settings->force_auth != true ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//not enable for this role oass\n\t\tif ( ! Auth_API::isEnableForCurrentRole( $user ) ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//check if this role is forced\n\t\tif ( ! Auth_API::isForcedRole( $user ) ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//user already enable OTP\n\t\tif ( Auth_API::isUserEnableOTP( $user->ID ) ) {\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t$screen = get_current_screen();\n\t\tif ( $screen->id != 'profile' ) {\n\t\t\twp_safe_redirect( admin_url( 'profile.php' ) . '#show2AuthActivator' );\n\t\t\texit;\n\t\t}\n\t}", "function EditOwnSettings()\n\t{\n\t\tif ($this->Admin()) {\n\t\t\treturn true;\n\t\t}\n\n\t\treturn $this->editownsettings;\n\t}", "function b2c_has_social_login() {\n\treturn ! empty( b2c_get_current_user_auth_provider() );\n}", "function hasWriteAccess() {\r\n\t\treturn (\r\n\t\t\t\t$this->annonce->associationID == $this->extendedProfile->userID ||\r\n\t\t\t\t$this->extendedProfile instanceof ProfileNiceBenevolat);\r\n\t}", "function save_extra_user_profile_fields( $user_id ) {\n if ( !current_user_can( 'edit_user', $user_id ) ) { \n return false; \n }\n\n\n $socialLinks=array(\"twitter\" => $_POST['twitter'] , \"facebook\" => $_POST['facebook'],\"instagram\" => $_POST['instagram']);\n\n \n update_user_meta(\n $user_id,\n 'social_links',\n $socialLinks\n );\n}", "public function isUserProfile(Model $model): bool\n {\n return isset($model->{$this->user_id_field}) && !is_null($model->{$this->user_id_field});\n }", "public function p_editProfile() {\n\t$_POST['modified'] = Time::now();\n \n $w = \"WHERE user_id = \".$this->user->user_id;\n\t\t\n\t# Insert\n\tDB::instance(DB_NAME)->update(\"users\", $_POST, $w);\n \n Router::redirect(\"/users/profile\");\n\n }", "abstract protected function getUserProfile();", "public function myProfile()\n\t{\n\t\t//echo \"<pre>\";print_r($this->session->userdata());die;\n\t\tif($this->session->userdata('VB_USER_ID') == ''):\n\t\t\tredirect(base_url());\n\t\tendif;\n\t\t$this->layouts->set_title(stripcslashes('Profile | VBloggers'));\n\t\t$this->layouts->set_keyword(stripcslashes('Profile | VBloggers'));\n\t\t$this->layouts->set_description(stripcslashes('Profile | VBloggers'));\n\t\t\n\t\t$this->layouts->login_view('user/profile',array(),$data);\n\t}", "protected function isAuthor() {\n return $this->getSocialUser() &&\n $this->getSocialUser()->ID === (int)$this->connectObj->CreatedBySocialUser->ID;\n }", "protected function CurrentUserHasEditPermissionToThisUser()\n {\n if (true === $this->IsOwner()) {\n return true;\n }\n /** @var SecurityHelperAccess $securityHelper */\n $securityHelper = ServiceLocator::get(SecurityHelperAccess::class);\n\n if (false === $securityHelper->isGranted(\n CmsPermissionAttributeConstants::TABLE_EDITOR_EDIT,\n $this->oTableConf\n )) {\n return false;\n }\n $user = $securityHelper->getUser();\n\n if (null === $user) {\n return false;\n }\n\n if (false === $securityHelper->isGranted(CmsUserRoleConstants::CMS_ADMIN)) {\n // Continue only if we have an ID. If we do not, this is a new record, so the check is not needed.\n if (null !== $this->sId && !empty($this->sId)) {\n $oTargetUser = TdbCmsUser::GetNewInstance();\n $oTargetUser->Load($this->sId);\n // If the target user is an admin, and the current user is not, then we do not grant edit permission.\n if ($oTargetUser->IsAdmin()) {\n return false;\n }\n\n // Also, the user may only edit users that have at least one portal in common.\n $allowedPortals = array_keys($user->getPortals());\n $portalsOfTargetUser = $oTargetUser->GetFieldCmsPortalIdList();\n if (count($portalsOfTargetUser) > 0\n && 0 === count(array_intersect($allowedPortals, $portalsOfTargetUser))) {\n return false;\n }\n }\n }\n\n return true;\n }", "public function checkCurrentUser(UserProfile $profile) : bool\n {\n if($this->getProfile()->getId() == $profile->getId()) {\n return true;\n }\n\n return false;\n }", "public function getUserCanEditAttribute()\n {\n return AccessControl::check($this, 'edit_post', false);\n }", "public function edit()\n {\n $my = auth()->user();\n\n return view('public.account.profile.edit', compact('my'));\n }", "public function actionProfile()\r\n\t{\r\n\t\t//disable jquery autoload\r\n\t\tYii::app()->clientScript->scriptMap=array(\r\n\t\t\t'jquery.js'=>false,\r\n\t\t);\r\n\t\t$model = $this->loadUser();\r\n\t $this->render('profile',array(\r\n\t \t'model'=>$model,\r\n\t\t\t'profile'=>$model->profile,\r\n\t ));\r\n\t}", "function at_follow_is_pro_user() {\n $isPro = false;\n $options = get_option('addthis_settings');\n $profile = $options['profile'];\n if ($profile) {\n $request = wp_remote_get( \"http://q.addthis.com/feeds/1.0/config.json?pubid=\" . $profile );\n $server_output = wp_remote_retrieve_body( $request );\n $array = json_decode($server_output);\n // check for pro user\n if (array_key_exists('_default',$array)) {\n $isPro = true;\n } else {\n $isPro = false;\n }\n }\n return $isPro;\n}", "public function usingSocialAccount()\n {\n return ( ! is_null($this->provider) && ! is_null($this->provider_id) ) ? true : false;\n }", "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 check_user_social(){\n\t\t\treturn $this->dao->check_user_social($this->db, $_POST['iduser']);\n\t\t}", "public function editProfile($editProfile, $profile_id) {\n\n if (isset($editProfile)) {\n $this->db->where('profile_id', $profile_id);\n $this->db->update('profile', $editProfile);\n return TRUE;\n } else {\n return False;\n }\n }", "public function canLikesettings() {\n $viewer = Engine_Api::_()->user()->getViewer();\n if (!$viewer || !$viewer->getIdentity()) {\n return false;\n }\n\t\t$like_profile_show = Engine_Api::_()->getApi( 'settings' , 'core' )->getSetting( 'like.profile.show' ) ;\n $like_setting_show = Engine_Api::_()->getApi( 'settings' , 'core' )->getSetting( 'like.setting.show' ) ;\n\t\tif ( empty( $like_profile_show ) || empty( $like_setting_show ) ) {\n\t\t\t\treturn false;\n\t\t}\n\t\treturn true;\n }", "private function checkingApiCanFetchAProfile($profile_id)\n {\n $api_profile=$this->api_request->get(\"profile\",\"single_profile\",$params=array('profile_id'=>$profile_id));\n return ($api_profile['user_id']==$profile_id);\n }", "static function allowShowingProfile($agentoptin)\n\t{\n global $configClass;\n if($configClass['show_agent_details'] == 1)\n\t\t{\n if($configClass['use_privacy_policy'] == 1) \n\t\t\t{\n if ($configClass['allow_user_profile_optin'] && $agentoptin == 0) \n\t\t\t\t{\n return true;\n }\n\t\t\t\telse\n\t\t\t\t{\n return false;\n }\n }\n\t\t\telse\n\t\t\t{\n return true;\n }\n }\n return false;\n }", "public function showOwnProfile()\n {\n //Se obtiene el id del usuario con la sesion activa\n $user = DB::table('users')->where('id', '=', Auth::user()->id)->first();\n\n return view('profile.show', compact('user'));\n }", "public function canEdit($member = null) {\n if (!$member)\n $member = Member::currentUser();\n\n if ($member->ID == $this->OwnerID || Permission::check('CMS_ACCESS_CMSMain', 'any', $member)) {\n return true;\n }\n\n return false;\n }", "public static function edit_profile() {\n\t\twp_enqueue_media();\n\t\twp_enqueue_script( 'ur-my-account' );\n\n\t\t$user_id = get_current_user_id();\n\t\t$form_id = ur_get_form_id_by_userid( $user_id );\n\n\t\t$profile = user_registration_form_data( $user_id, $form_id );\n\n\t\t$user_data = get_userdata( $user_id );\n\t\t$user_data = $user_data->data;\n\n\t\t$form_data_array = ( $form_id ) ? UR()->form->get_form( $form_id, array( 'content_only' => true ) ) : array();\n\n\t\tif ( ! empty( $form_data_array ) ) {\n\n\t\t\tif ( count( $profile ) < 1 ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// Prepare values.\n\t\t\tforeach ( $profile as $key => $field ) {\n\t\t\t\t$value = get_user_meta( get_current_user_id(), $key, true );\n\t\t\t\t$profile[ $key ]['value'] = apply_filters( 'user_registration_my_account_edit_profile_field_value', $value, $key );\n\t\t\t\t$new_key = str_replace( 'user_registration_', '', $key );\n\n\t\t\t\tif ( in_array( $new_key, ur_get_registered_user_meta_fields() ) ) {\n\t\t\t\t\t$value = get_user_meta( get_current_user_id(), ( str_replace( 'user_', '', $new_key ) ), true );\n\t\t\t\t\t$profile[ $key ]['value'] = apply_filters( 'user_registration_my_account_edit_profile_field_value', $value, $key );\n\t\t\t\t} elseif ( isset( $user_data->$new_key ) && in_array( $new_key, ur_get_user_table_fields() ) ) {\n\t\t\t\t\t$profile[ $key ]['value'] = apply_filters( 'user_registration_my_account_edit_profile_field_value', $user_data->$new_key, $key );\n\n\t\t\t\t} elseif ( isset( $user_data->display_name ) && 'user_registration_display_name' === $key ) {\n\t\t\t\t\t$profile[ $key ]['value'] = apply_filters( 'user_registration_my_account_edit_profile_field_value', $user_data->display_name, $key );\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tur_get_template(\n\t\t\t\t'myaccount/form-edit-profile.php',\n\t\t\t\tarray(\n\t\t\t\t\t'profile' => apply_filters( 'user_registration_profile_to_edit', $profile ),\n\t\t\t\t\t'form_data_array' => $form_data_array,\n\t\t\t\t)\n\t\t\t);\n\t\t} else {\n\t\t\techo '<h1>' . esc_html__( 'No profile details found.', 'user-registration' ) . '</h1>';\n\t\t}\n\t}", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "public function edit(Profile $profile)\n {\n //\n }", "function display_user_profile_fields() {\r\n global $wpdb, $user_id, $wpi_settings;\r\n $profileuser = get_user_to_edit($user_id);\r\n\r\n include($wpi_settings['admin']['ui_path'] . '/profile_page_content.php');\r\n }", "public function authorize()\n {\n $person = $this->findFromUrl('person');\n\n return $this->user()->can('update', $person);\n }", "public function isSocial_always_returnCorrectly()\n {\n $this->assertFalse($this->entity->isSocial());\n }", "public function profileAction()\n {\n \tZend_Registry::set('Category', Category::COMMUNITY);\n Zend_Registry::set('SubCategory', SubCategory::USERS);\n\n $userId = $this->_request->getParam(2, null);\n if(empty($userId)){\n throw new Lib_Exception_NotFound(\"No user id found for profile page\");\n }\n\n if($userId == $this->_user->{User::COLUMN_USERID}){\n \tZend_Registry::set('Category', Category::ACCOUNT);\n\t\t\tZend_Registry::set('SubCategory', SubCategory::NONE);\n }\n\n $table = new User();\n $user = $table->find($userId)->current();\n if(empty($user)){\n throw new Lib_Exception_NotFound(\"User '$userId' could not be found for profile page\");\n }\n\n $blog = $user->getBlog();\n if(!$blog->isReadableBy($this->_user, $this->_acl)){\n $blog = null;\n \t}\n\n $album = $user->getProfileAlbum();\n if(!$album->isReadableBy($this->_user, $this->_acl)){\n $album = null;\n \t}\n\n $this->view->profilee = $user;\n $this->view->album = $album;\n $this->view->blog = $blog;\n $this->view->medias = $album->getItemSet();\n }", "public function edit()\n {\n $user = auth()->user();\n if ($user->hasRole('contractor')) {\n $contractor = $user->contractor;\n $profilePicMedia = $user->profile_pic_media;\n return view('profile.edit', ['user' => $user, 'profilePicMedia' => $profilePicMedia, 'contractor' => $contractor]);\n } else {\n $profilePicMedia = $user->profile_pic_media;\n return view('profile.edit', ['user' => $user, 'profilePicMedia' => $profilePicMedia]);\n }\n }", "public function show(User $user)\n {\n /*\n Condition is failing due the relationship returns STRING instead of INTEGER\n if ($user->profile->created_by !== auth()->id() )\n\n Options to solve the problem,\n - Cast the returned value when required\n - Cast the auth()->id() as STRING or $user->profile->created_by as INTEGER\n - Modify the Model using $casts[] array and cast the field to INTEGER\n */\n // dd($theProfile->id); // returns integer\n // dd($user->profile->created_by); // returns string\n // $theProfile = $user->profile;\n\n // dd($user->id); // automatic conversion \n // dd(auth()->id()); // automatic conversion\n\n /*\n * Authorization\n */\n // dd($user->id);\n // dd($user->profile->user_id);\n // dd($user->profile->created_by);\n /*\n * Using Policies\\ProfilePolicy.php\n * These calls are not standard, In this case calling an authorization using other Model class.\n * \n */\n // $this->authorize('viewAny',Profile::class); // Call to the ProfilePolicy.php even if it is not registered in Providers\\AuthServiceProvider.php\n // $this->authorize('view',[Profile::class,$user->profile]); // Call to the ProfilePolicy.php even if it is not registered in Providers\\AuthServiceProvider.php\n\n /*\n * Gate Test\n * Note: Any Authorizable model can be used in the Gate call\n */\n/*\n //\n // Test sending the User RECORD as the main object\n //\n // if( Gate::forUser(auth()->user())->allows('test-gate', $user->id)) {\n if( Gate::forUser($user->profile)->allows('test-gate', $user->id)) {\n if( Gate::forUser($user->profile)->allows('test-gate', $user->profile->id)) {\n dd('ok');\n } else {\n dd('fail');\n } \n } else {\n abort(403,'fail - not logged in OR No Profile defined');\n }\n\n //\n // Test sending the Auth user as the main object\n //\n if( auth()->check() && (! is_Null(auth()->user()->profile) )) {\n if( Gate::forUser(auth()->user()->profile)->allows('test-gate', $user->profile->id)) {\n dd('ok');\n } else {\n dd('fail');\n } \n } else {\n abort(403,'fail - not logged in OR No Profile defined');\n }\n\n*/\n /*\n * Using Policies\\UserPolicy.php\n * Basic Validation: if ($user->profile->created_by !== auth()->id() )\n * \n */\n // dd($user->can('browse')); // Returns false\n // dd($user->profile->can('browse')); // Returns true\n\n // $this->authorize('view',$user); // Uses UserPolicy\n $this->authorize('view',$user->profile); // Uses ProfilePolicy\n\n /*\n Same validation in the controller.\n - Profile record existance validation required\n */\n if (is_null($user->profile)){\n if ( auth()->id() !== $user->id ) {\n abort(403,__('Record not owned'));\n } \n } else {\n if ($user->profile->created_by !== strval(auth()->id()) ) {\n abort(403,__('Record not owned'));\n } \n }\n // laravel helper\n // abort_if($user->profile->created_by !== auth()->id(), 403);\n // Via Policy control, creating the logic in the Policies/UserPolicy.php with the command:\n // php artisan make:policy ProfilePolicy –model=Profile\n // It requires to update the Providers/AuthServiceProvider.php\n // $this->authorize('view',$user->profile);\n // dd($user->profile);\n\n dd('return the User View');\n }", "public function editSocialAccounts()\n {\n $data = [\n 'facebook_url' => inputPost('facebook_url'),\n 'twitter_url' => inputPost('twitter_url'),\n 'instagram_url' => inputPost('instagram_url'),\n 'pinterest_url' => inputPost('pinterest_url'),\n 'linkedin_url' => inputPost('linkedin_url'),\n 'vk_url' => inputPost('vk_url'),\n 'telegram_url' => inputPost('telegram_url'),\n 'youtube_url' => inputPost('youtube_url')\n ];\n return $this->builder->where('id', cleanNumber(user()->id))->update($data);\n }", "abstract public function canEdit($user_guid = 0);", "public function canMyLikes() {\n $viewer = Engine_Api::_()->user()->getViewer();\n if (!$viewer || !$viewer->getIdentity()) {\n return false;\n }\n\t\treturn true;\n }", "public function isAuthorized($user) {\n if ($this->action === 'add') {\n return true;\n }\n\n // The owner of a post can edit and delete it\n if (in_array($this->action, array('edit', 'delete'))) {\n $presupuestoId = $this->request->params['pass'][0];\n if ($this->Post->isOwnedBy($presupuestoId, $user['id'])) {\n return true;\n }\n }\n\n return parent::isAuthorized($user);\n}", "private function allowModify()\n { \n if($this->viewVar['loggedUserRole'] <= 40 )\n {\n return TRUE;\n }\n else\n {\n return FALSE;\n }\n }", "function yz_redirect_author_page_to_bp_profile() {\n\n if ( is_author() && ! is_feed() ) {\n\n // Get Author ID.\n $author_id = get_queried_object_id();\n\n // Redirect.\n bp_core_redirect( bp_core_get_user_domain( $author_id ) );\n\n }\n\n}", "protected function canEdit() {}", "public function View_My_Profile()\n\t{\n\t\t$this->_CheckLogged();\n\t\t\n\t\t$this->_processInsert($this->instructors_model->getMyPostId(),'view');\n\t}", "public function editprofile()\n {\n //make sure user is logged in\n Auth::checkAuthentication();\n $data = array('ajaxform'=>'load');\n \n //loads user data from session, gives save button(post)\n $this->View->render('user/editProfile',$data);\n }", "function canEdit(User $user) {\n return $user->isFinancialManager();\n }", "public function authorize(): bool\n {\n return parent::authorize() && (int)$this->playList->user_id === auth()->user()->id;\n }", "public function actionPersonal() {\n if (Yii::app()->user->isGuest)\n throw new CHttpException(403, Yii::t(\"UserAdminModule.front\", \"You are not authorized to perform this action.\"));\n\n $user = User::model()->active()->findByPk((int) Yii::app()->user->id);\n\n if (!$user)\n throw new CHttpException(403, Yii::t(\"UserAdminModule.front\", \"You are not authorized to perform this action.\"));\n\n\n //=========== Here you can implement some logic (like changing password) ===========\n //----------------------------------------------------------------------------------\n\n if (isset($_POST['User'])) {\n $user->attributes = $_POST['User'];\n\n // Additional check. Only superadmin can create superadmins\n if (User::isSuperAdmin()) {\n // Superadmin can't decrease his own access level\n if (Yii::app()->user->id == $id)\n $user->is_superadmin = 1;\n else\n $user->is_superadmin = $_POST['User']['is_superadmin'];\n }\n else {\n $user->is_superadmin = 0;\n }\n\n if ($user->save()) {\n Yii::app()->user->setFlash('profileSaved', Yii::t('ui', 'Profile updated!!'));\n $this->refresh();\n }\n }\n $this->render('personal', compact('user'));\n }", "public function editinformation() \n {\n UserModel::authentication();\n \n //get the session user\n $user = UserModel::user();\n\n UserModel::update_profile();\n }", "public function profile()\n {\n if ($this->Session && $this->Permissions) {\n if($this->Session['admin'] == 1 || $this->Permissions['profielen'] == 'Y') {\n $data['Title'] = 'Gebruikers profiel';\n $data['Active'] = 4;\n $data['user'] = $this->user->getProfile();\n $data['logs'] = $this->Log->getUserLogs();\n $data['permissions'] = $this->rights->getUserRights();\n\n $this->load->view('components/admin_header', $data);\n $this->load->view('components/navbar_admin', $data);\n $this->load->view('admin/profile', $data);\n $this->load->view('components/footer');\n }\n } else {\n redirect('Admin', 'refresh');\n }\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 profile() {\n\t\tif($this->checkLoggedIn()) {\n\t\t\treturn $this->view->render('profile_view');\n\t\t}\n\t}", "public function edit()\n {\n $user = User::where('id',auth()->id())->first();\n return view('super.profile.edit', [\n 'edit' => $user,\n ]);\n }", "protected function restrict_to_author() {\n if ($this->post->author_id != $this->current_user->id) {\n forbidden();\n }\n }" ]
[ "0.6907887", "0.6484537", "0.64616543", "0.6323843", "0.62924355", "0.6231446", "0.6231039", "0.6231013", "0.62273675", "0.6223864", "0.6198434", "0.6146449", "0.6139429", "0.61246413", "0.61238503", "0.61084825", "0.6069421", "0.60664755", "0.6060511", "0.6060331", "0.60484356", "0.60482305", "0.6042151", "0.6011574", "0.5996891", "0.59929925", "0.5990832", "0.59890854", "0.596989", "0.5962642", "0.59561414", "0.594987", "0.59486014", "0.59458756", "0.59118646", "0.59039277", "0.5875531", "0.5872676", "0.5862632", "0.58616257", "0.58586115", "0.58560455", "0.5852728", "0.58396876", "0.58317715", "0.5823166", "0.5820746", "0.5818971", "0.5810523", "0.5797884", "0.57978374", "0.5795034", "0.5786476", "0.5774784", "0.5767118", "0.5759152", "0.57482904", "0.5745635", "0.57420236", "0.57403195", "0.57380736", "0.5737619", "0.57226586", "0.5712894", "0.57121736", "0.57071996", "0.57054067", "0.57006633", "0.57006633", "0.57006633", "0.57006633", "0.57006633", "0.57006633", "0.57006633", "0.57006633", "0.57006633", "0.5694077", "0.56919485", "0.56907094", "0.56905234", "0.5679399", "0.567771", "0.56765455", "0.56730527", "0.5664591", "0.56566155", "0.56522226", "0.5650013", "0.5647459", "0.56346893", "0.5622893", "0.5622186", "0.5617306", "0.561262", "0.5608041", "0.5607887", "0.559512", "0.55912364", "0.558861", "0.55874085" ]
0.61241156
14
Tells the dispatcher that you want to listen on the form.pre_set_data
public static function getSubscribedEvents() { // event and that the preSetData method should be called. return array(FormEvents::PRE_SUBMIT => 'preSubmitData'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function hooked()\n {\n $this->setData();\n }", "static function getSubscribedEvents()\n {\n return array(\n FormEvents::PRE_SET_DATA => 'preSetData',\n );\n }", "public function hook()\n {\n $this->setData();\n }", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SET_DATA => 'preSetData');\n }", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SET_DATA => 'preSetData');\n }", "public static function getSubscribedEvents()\n {\n // event and that the preSetData method should be called.\n return array(FormEvents::PRE_SET_DATA => 'preSetData');\n }", "public function postDispatch()\n {\n parent::postDispatch();\n\n $this->getRequestData();\n }", "public function hookForm() {\n }", "public function preSetData(FormEvent $event)\n {\n $data = $event->getData();\n $form = $event->getForm();\n\n if (null === $data) {\n return;\n }\n $this->addFields($form, $data);\n }", "public function hook_before(&$postdata) {\n\n\t\t }", "public function hookConfigForm() {\n }", "public static function getSubscribedEvents()\n\t{\n\t\treturn [\n\t\t\tFormEvents::PRE_SET_DATA => 'preSetData',\n\t\t];\n\t}", "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 }", "public function preSubmitData(FormEvent $event)\n {\n $data = $event->getData();\n\n $data = $this->sanitizeFormData($data);\n $event->setData($data);\n }", "protected function _setForm()\n\t{\t\n\t\t$controller = $this->getActionController();\n\t\t\n\t\t$this->_setViewFormData($controller)\n\t\t\t ->_setViewErrors($controller)\n\t\t\t ->_setViewWarnings($controller);\n\t\t\t\n\t}", "public function preDispatch(Zend_Controller_Request_Abstract $request)\n {\n\n }", "public function preDispatch( Zend_Controller_Request_Abstract $request )\n {\n\n }", "public function setFormData($data)\n {}", "public static function getSubscribedEvents()\n {\n return [\n FormEvents::PRE_SET_DATA => 'onPreSetData',\n ];\n }", "public static function getSubscribedEvents()\n {\n return [\n FormEvents::PRE_SET_DATA => 'onPreSetData',\n ];\n }", "public function _get_form_callback()\n {\n }", "public function __construct()\n {\n parent::__construct();\n $this->addPostRequestHandler([$this, \"onPostRequest\"]);\n }", "public function preSaveCallback()\n {\n $this->performPreSaveCallback();\n }", "public function preSaveCallback()\n {\n $this->performPreSaveCallback();\n }", "public function preDispatch() {\n\t\t\n\t\t}", "public function preDispatch()\n\t{\n\t\t$this->_actionController->initView();\n\t\t\n\t\t// We have to store the values here, because forwarding overwrites\n\t\t// the request settings.\n\t\t$request = $this->getRequest();\n\t\t$this->_lastAction = $request->getActionName();\n\t\t$this->_lastController = $request->getControllerName();\n\t}", "public function hookForm() {\n if ($this->isCompanyForm()) {\n $this->setDefaultExpDate();\n $this->makeBillingAreaRequired();\n }\n elseif ($this->isCompanyViewsMultiSearchForm()) {\n $this->form['company_name']['#type'] = 'textarea';\n $this->duplicateField('sort_by');\n }\n }", "protected function beforeSave($data=array())\n\t{\n\t\n\t}", "public function preDispatch()\n {\n //...\n }", "public function setDataFromRequest($dataFromRequest)\n {\n $this->dataFromRequest = $dataFromRequest;\n }", "function ValidateBeforeAdd(){\n $this->validator->ValidateForm($this->_data, true);\n }", "public function beforeDispatch(Event $event, Dispatcher $dispatcher)\n {\n \t//\n \t$validator = new ValidateInterceptor(new Memory());\n\t\t\n \t\n }", "protected function onRequest( array &$request )\n\t\t{\n\t\t\tif( !$this->disabled )\n\t\t\t{\n\t\t\t\tif( $this->readonly )\n\t\t\t\t{\n\t\t\t\t\t$this->submitted = true;\n\t\t\t\t}\n\n\t\t\t\tif( isset( $request[$this->getHTMLControlId()] ))\n\t\t\t\t{\n\t\t\t\t\t$this->submitted = true;\n\n\t\t\t\t\tif( $this->value != $request[$this->getHTMLControlId()] )\n\t\t\t\t\t{\n\t\t\t\t\t\t$this->changed = true;\n\t\t\t\t\t}\n\n\t\t\t\t\t$this->value = $request[$this->getHTMLControlId()];\n\t\t\t\t\tunset( $request[$this->getHTMLControlId()] );\n\t\t\t\t}\n\n\t\t\t\tif( !$this->value && $this->multiple )\n\t\t\t\t{\n\t\t\t\t\t$this->value = array();\n\t\t\t\t}\n\t\t\t\telseif( $this->value === '' )\n\t\t\t\t{\n\t\t\t\t\t$this->value = null;\n\t\t\t\t}\n\t\t\t}\n\n//\t\t\tif(( $this->ajaxPostBack || $this->ajaxValidation ) && $this->submitted)\n//\t\t\t{\n//\t\t\t\tif($this->validate($errMsg))\n//\t\t\t\t{\n//\t\t\t\t\t$this->getParentByType('\\System\\Web\\WebControls\\Page')->loadAjaxJScriptBuffer(\"Rum.clear('{$this->getHTMLControlId()}');\");\n//\t\t\t\t}\n//\t\t\t\telse\n//\t\t\t\t{\n//\t\t\t\t\t$this->getParentByType('\\System\\Web\\WebControls\\Page')->loadAjaxJScriptBuffer(\"Rum.assert('{$this->getHTMLControlId()}', '\".\\addslashes($errMsg).\"');\");\n//\t\t\t\t}\n//\t\t\t}\n\t\t}", "public function form()\n {\n $this->setData();\n }", "public function onStartDispatch()\n {\n /** @var Enlight_Event_EventManager $eventManager */\n $eventManager = $this->get('events');\n $container = $this->get('service_container');\n\n $resourceSubscriber = new Resource($this->get('models'), $this->get('config'));\n $eventManager->addSubscriber($resourceSubscriber);\n\n /** @var Sorting $sortingComponent */\n $sortingComponent = $container->get('swagcustomsort.sorting_component');\n /** @var Listing $listingComponent */\n $listingComponent = $this->get('swagcustomsort.listing_component');\n\n $subscribers = [\n new Resource($this->get('models'), $this->get('config')),\n new ControllerPath($this->Path(), $this->get('template')),\n new Frontend($this),\n new Backend($this, $this->get('models')),\n new Sort($this->get('models'), $sortingComponent, $listingComponent),\n new StoreFrontBundle($container, $sortingComponent)\n ];\n\n foreach ($subscribers as $subscriber) {\n $eventManager->addSubscriber($subscriber);\n }\n }", "public function preDispatch() {\n\t\t$registry = Shineisp_Registry::getInstance ();\n\t\t$this->translator = $registry->Zend_Translate;\n\t}", "protected function setPostData()\n\t{\n\t\t$this->request->addPostFields($this->query->getParams());\n\t}", "public function preDispatch() { }", "public function setDispatcherEvents()\n\t{\n\t\t$this->dispatcher = (new Dispatcher())->register($this->routes);\n\t}", "function __construct()\r\n\t{\r\n\t\t$this->events[\"BeforeAdd\"]=true;\r\n\r\n\r\n\t}", "public function preDispatch()\n {\n\n }", "public function postDispatch()\n {\n parent::postDispatch();\n if ($this->getFlag('', self::FLAG_NO_POST_DISPATCH)) {\n return;\n }\n Mage::dispatchEvent('controller_action_postdispatch_adminhtml', array('controller_action' => $this));\n }", "public function controller_processReceivedData() {\n // validate received form data\n // update data model\n }", "public function preDispatch();", "protected function beforeAjax()\n {\n if ($this->initialized) {\n return;\n }\n\n $this->controller->pageAction();\n $this->validateField();\n $this->prepareVars();\n $this->initialized = true;\n }", "public function init()\r\n {\r\n $this->setAttributes(array(\r\n 'name' => 'add-staff',\r\n 'method' => 'POST',\r\n 'action' => '/broker-tool/add-staff',\r\n 'class' => 'form-horizontal form-label-left',\r\n 'id' => 'add-staff',\r\n \"data-ajax-loader\"=>\"myLoader\"\r\n ));\r\n $this->addFields();\r\n $this->addCommon();\r\n }", "protected function preValidate() {}", "public function preDispatch()\r\n {\r\n $this->View()->setScope(Enlight_Template_Manager::SCOPE_PARENT);\r\n\r\n $this->View()->sUserLoggedIn = $this->admin->sCheckUser();\r\n $this->View()->sUserData = $this->getUserData();\r\n }", "function _init(&$event)\r\n\t\t{\r\n\t\t\tparent::_init($event);\r\n\t\t\t\r\n\t\t\t$this->inp\t\t\t\t=\t&$event->object('input_validation', array(&$event));\r\n\t\t\t$this->data_validation\t=\t&$event->object('data_validation', array(&$event));\r\n\t\t}", "public function preDispatch()\n\t{\n\n\t\t\n\t\t\n\t}", "protected function onRequest( array &$request )\n\t\t{\n\t\t\tif($this->controlToValidate->submitted) {\n\t\t\t\tif(!$this->controlToValidate->validate($err)) {\n\t\t\t\t\t$this->errMsg = $err;\n\t\t\t\t}\n\t\t\t\t$this->needsUpdating = true;\n\t\t\t}\n\t\t}", "public function beforeStore($data){ }", "public function __construct() {\n\t\t$form_event = ( isset( \\REALTY_BLOC_LOG::$option['form_event'] ) ? \\REALTY_BLOC_LOG::$option['form_event'] : array() );\n\n\t\t// List Active Form\n\t\t$active_forms = ( ( isset( $form_event['form'] ) and is_array( $form_event['form'] ) ) ? array_keys( $form_event['form'] ) : array() );\n\n\t\t// Add Hook For Save Form\n\t\tforeach ( $active_forms as $form_id ) {\n\t\t\tadd_action( \"wpforms_process_complete_{$form_id}\", array( $this, 'save_form_event' ), 10, 4 );\n\t\t}\n\t}", "function receive() {\n // Input type 1.\n if ($this->method == 'POST' && isset($_POST[$this->id . '-form_id']) && $_POST[$this->id . '-form_id'] == $this->id) {\n $this->request['raw_input'] = $_POST;\n }\n // Input types 2 and 3.\n else {\n $this->request['raw_input'] = $_GET;\n }\n }", "public function preSubmit(FormEvent $event)\n {\n $form = $event->getForm();\n $data = $event->getData();\n\n $accessor = PropertyAccess::createPropertyAccessor();\n foreach ($form->all() as $name => $child) {\n if (!isset($data[$name])) {\n $form->remove($name);\n continue;\n }\n\n if(!is_null($form->getData()) && is_bool($accessor->getValue($form->getData(), $name)) && isset($data[$name])) {\n $val = $data[$name];\n $data[$name] = ($val==\"true\")||($val==\"1\")||($val==\"on\");\n }\n }\n $event->setData($data);\n }", "public function prePersistCallback()\n {\n $this->performPrePersistCallback();\n }", "public function prePersistCallback()\n {\n $this->performPrePersistCallback();\n }", "public function setAsAjaxForm() {\n\t}", "public function onKernelRequest()\n {\n $this->checked = false;\n $this->initialize();\n }", "public function setRequestOnHandler($request)\n {\n }", "public function onBeforeSave($event);", "public function onPreSetData(FormEvent $event)\n {\n $form = $event->getForm();\n if ($this->authorizationChecker->isGranted('ROLE_SUPER_ADMIN')) {\n $roles = [\n 'User' => 'ROLE_USER',\n 'Admin' => 'ROLE_ADMIN',\n 'Super admin' => 'ROLE_SUPER_ADMIN',\n ];\n $form\n ->add(\n 'roles',\n ChoiceType::class,\n [\n 'label' => 'Roles',\n 'required' => true,\n 'expanded' => true,\n 'multiple' => true,\n 'choices' => $roles,\n ]\n );\n }\n }", "abstract function setupform();", "protected function hook_beforeSave(){}", "public function onControllerActionPredispatch($observer)\n {\n /** @var Mage_Core_Controller_Request_Http $request */\n $request = $observer->getControllerAction()->getRequest();\n\n $action = $request->getActionName();\n $controller = $request->getControllerName();\n\n if (($action == 'buildWidget' && $controller == 'widget') || ($action == 'save' && $controller == 'widget_instance')) {\n $rule = $request->getPost('rule', array());\n\n if (!empty($rule)) {\n $params = $request->getPost('parameters', array());\n\n // Serialize, encode and inject rule to post parameters\n $params['rule'] = base64_encode(serialize($rule));\n\n $request->setPost('parameters', $params);\n }\n }\n }", "public function hook_before_add(&$postdata) { \n\t //Your code here\n\n\t }", "public function hook_before_add(&$postdata) { \n\t //Your code here\n\n\t }", "public function processData() {\r\r\n if ( is_array($this->data) && isset($this->data['args']) )\r\r\n $this->args = array_merge($this->args, $this->data['args']);\r\r\n\r\r\n if ( is_array($this->data) && isset($this->data['value']) ) {\r\r\n // If called from back-end non-post context\r\r\n $this->data = $this->data['value'];\r\r\n }\r\r\n }", "public function init() {\n\t\tparent::init();\n\t\tadd_action( 'gform_after_submission', array( $this, 'after_submission' ), 10, 2 );\n\t\tadd_filter( 'gform_pre_render', [ $this, 'populate_posts' ] );\n\t\tadd_filter( 'gform_pre_validation', [ $this, 'populate_posts' ] );\n\t\tadd_filter( 'gform_pre_submission_filter', [ $this, 'populate_posts' ] );\n\t\tadd_filter( 'gform_admin_pre_render', [ $this, 'populate_posts' ] );\n\t\tadd_action( 'save_post_tribe_events', [ $this, 'maybe_create_venue' ], 10, 2 );\n\t}", "public function preUpdateCallback()\n {\n $this->performPreUpdateCallback();\n }", "public function preUpdateCallback()\n {\n $this->performPreUpdateCallback();\n }", "public function handleDataSubmission() {}", "public function hook()\n {\n // Add the settings tab\n// $this->on('!wprss_options_tabs', array($this, 'addTab'), null, 100);\n // Register the settings option, sections and fields\n// $this->on('!wprss_admin_init', array($this, 'register'));\n\n parent::hook();\n }", "public function _before_information_set_save($options = NULL) {\n $this->before_information_set_save($options);\n App::Module('Hook')->getHandler('Callback', 'before_information_set_save', $options);\n }", "protected function onBeforeSave()\n {\n }", "protected function loadFormData()\n\t{\n\t}", "public function onBeforeSave();", "public function hooks() {\n\t\tadd_action( 'wp_ajax_wp_sc_form_process_'. $this->button_slug, array( $this, 'process_form' ) );\n\n\t\t// If we have a conditional callback and the return of the callback is false\n\t\tif ( $this->args['conditional_callback'] && is_callable( $this->args['conditional_callback'] ) && ! call_user_func( $this->args['conditional_callback'], $this ) ) {\n\t\t\t// Then that means we should bail\n\t\t\treturn;\n\t\t}\n\n\t\tadd_action( 'admin_init', array( $this, 'button_init' ) );\n\t\tadd_action( 'admin_enqueue_scripts', array( $this, 'register_quicktag_button_script' ) );\n\t\tadd_action( 'admin_footer', array( $this, 'add_quicktag_button_script' ) );\n\t\tadd_action( 'admin_footer', array( $this, 'add_modal_form' ) );\n\t}", "public function definition_after_data() {\n parent::definition_after_data();\n $this->_form->freeze(['type']);\n $this->tool->form_definition_after_data($this->_form);\n }", "public function hookConfigForm() {\n\t\trequire IIIF_API_BRIDGE_DIRECTORY . '/config_form.php';\n\t}", "public function preSave() { }", "public function bootingCallback()\n {\n BaseField::$configKeys[] = 'validations';\n OptionManager::$configKeys[] = 'validations';\n\n $this->setMacros();\n\n Validation::extendValidatorOptions();\n }", "private function _preInit()\n {\n // Load the request before anything else, so everything else can safely check Craft::$app->has('request', true)\n // to avoid possible recursive fatal errors in the request initialization\n $this->getRequest();\n $this->getLog();\n\n // Set the timezone\n $this->_setTimeZone();\n\n // Set the language\n $this->updateTargetLanguage();\n }", "protected function _initPostParameters()\n {\n $this->set('_post', new DataHolder($_POST));\n }", "public function preSave() {}", "public function pre_action()\n\t{\n\t\tparent::pre_action();\n\t}", "public function onPreSubmit(FormEvent $event)\n {\n $data = $event->getForm()->getData();\n if (!$this->isApplicable($data)) {\n return;\n }\n\n $event->getForm()->remove('synchronizationSettings');\n }", "public function testPreSetDataWithExistingNode()\n {\n Phake::when($this->node)->getId()->thenReturn('nodeId');\n Phake::when($this->event)->getData()->thenReturn($this->node);\n\n $this->subscriber->preSetData($this->event);\n\n Phake::verify($this->form, Phake::never())->add(Phake::anyParameters());\n }", "function before_validation_on_update() {}", "function preDispatch()\n {\n\n }", "public function preDispatch()\n {\n // Get the instance of the front controller\n $this->_front = Zend_Controller_Front::getInstance();\n \n // Get the container from the front controller\n $this->_container = $this->_front->getParam('bootstrap')->getContainer();\n \n // Get the Zend_Config from the front container\n $this->_config = $this->_container->getConfig(); \n }", "function after_validation() {}", "public function __before() {\n\t\t// runs after this->data is set up, but before the class methods are run\n\t}", "public function preSetData(FormEvent $event)\n {\n $data = $event->getData();\n $form = $event->getForm();\n\n if (null === $data) {\n return;\n }\n\n // check if the object is \"new\"\n if (!$data->getId()) {\n if (!$data->getId()) {\n $form->add('file', 'file', array(\n 'required' => true,\n 'data_class' => 'Manhattan\\Bundle\\PostsBundle\\Entity\\Attachment'\n ));\n }\n }\n }", "public function init()\n {\n // set class to identify as p4cms-ui component\n $this->setAttrib('class', 'p4cms-ui')\n ->setAttrib('dojoType', 'p4cms.ui.grid.Form');\n\n // turn off CSRF protection - its not useful here (form data are\n // used for filtering the data grid and may be exposed in the URL)\n $this->setCsrfProtection(false);\n\n // call parent to publish the form.\n parent::init();\n }", "public function __construct()\n {\n //нельзя передавать никакие парпметры в конструктор, даже если в событие передаются!!!\n }", "public function beforeRender()\n {\n $controller = $this->_registry->getController();\n\n $this->addToController($controller);\n }", "public function postInit()\n {\n }", "public function postInit()\n {\n }", "public function postInit()\n {\n }" ]
[ "0.63769925", "0.630763", "0.62276375", "0.6217596", "0.6217596", "0.6217596", "0.6163092", "0.6101255", "0.59690595", "0.58957994", "0.5894433", "0.5854644", "0.58480656", "0.58137935", "0.57906675", "0.57619756", "0.5761212", "0.57596767", "0.5692357", "0.5692357", "0.5681159", "0.5670553", "0.5651164", "0.5651164", "0.5649653", "0.5588082", "0.5586786", "0.5581398", "0.5568907", "0.55652934", "0.5552563", "0.5550934", "0.5539351", "0.55307454", "0.55262893", "0.55226964", "0.5521751", "0.5519324", "0.55133486", "0.5508622", "0.5491516", "0.5487682", "0.54833674", "0.5478616", "0.5466746", "0.54567724", "0.5456644", "0.54500717", "0.5447733", "0.5446946", "0.5436292", "0.54340553", "0.5418646", "0.54057705", "0.5404266", "0.53919965", "0.53919965", "0.5389783", "0.53863215", "0.5379907", "0.53779924", "0.537705", "0.53746957", "0.53529805", "0.53519017", "0.53469086", "0.53469086", "0.5340363", "0.5332961", "0.53270924", "0.53270924", "0.53215015", "0.53200877", "0.53121024", "0.5309689", "0.5305147", "0.5302948", "0.5301783", "0.5299048", "0.5294714", "0.528528", "0.52830553", "0.52661973", "0.5246329", "0.5243046", "0.52286595", "0.52283865", "0.5227812", "0.52248305", "0.52171874", "0.5214436", "0.521086", "0.519974", "0.5196501", "0.5195951", "0.51910925", "0.5190674", "0.51865435", "0.51865435", "0.51865435" ]
0.5962247
9
Sanitize data to avoid XSS attacks
public function preSubmitData(FormEvent $event) { $data = $event->getData(); $data = $this->sanitizeFormData($data); $event->setData($data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function sanitize($data){\r\n\t\t\t$data=stripslashes($data); // Remove all slashses\r\n\t\t\t$data=strip_tags($data); //Remove all tags\r\n\t\t\treturn $data;\r\n\t\t}", "public function ex_sanitize($data){\n\n\t\treturn mysql_real_escape_string(htmlentities(trim($data)));\n\n\t}", "function sanitise_input($data) {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "function sanitize($data) {\n return htmlentities(strip_tags(mysql_real_escape_string($data)));\n }", "protected function sanitize() {}", "function sanitizeData($data) {\n\t\t$data = trim($data);\n\t\t$data = stripslashes($data);\n\t\t$data = htmlspecialchars($data);\n\n\t\treturn $data;\n\t}", "function sanitize_string_xss(string $data): string\n{\n return filter_var($data, FILTER_SANITIZE_STRING);\n}", "function anti_injection($data){\n\t$filter = stripslashes(strip_tags(htmlspecialchars($data, ENT_QUOTES)));\n\treturn $filter;\n}", "abstract public function sanitize();", "function sanitise_input($data)\n {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "function sanitise_input($data)\n {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "public function sanitize($data){\n\n\t\treturn mysql_real_escape_string(htmlentities($data));\n\n\t}", "function sanitize_input($data)\n {\n $data = trim($data); //remove whitespaces \n $data = stripslashes($data); //such as '\n $data = htmlspecialchars($data); //such as >,<&\n return $data;\n }", "function sanitize($data) {\n\t$data = trim($data);\n\t$data = stripslashes($data);\n\t$data = htmlspecialchars($data);\n\treturn $data;\n}", "function sanitizeInput($data) {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n $data = strip_tags($data);\n return $data;\n}", "public function sanitize()\n {\n parent::sanitize();\n\n foreach ($this->_cleanData as $key => $value) {\n $this->_cleanData[$key] = strip_tags($value);\n }\n }", "function sanitize($data) {\n $data = htmlentities(get_magic_quotes_gpc() ? stripslashes($data) : $data, ENT_QUOTES, 'UTF-8');\n return $data;\n }", "function sanitize($data) \n{\n\treturn htmlentities(strip_tags(mysql_real_escape_string($data)));\n}", "function filter($data) {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n}", "function filter_any_data($data){\n\t\t\t$data = trim($data);\n\t\t\t$data = stripslashes($data);\n\t\t\t$data = htmlspecialchars($data);\n\t\t\treturn $data;\n\t\t}", "function filter_mydata($data)\n{\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n}", "function cleanInput($data) { \r\n return htmlspecialchars(stripslashes(trim($data)));\r\n }", "function cleanseTheData($data) \n\t\t{\n \t\t\t$data = trim($data);\n\t\t\t$data = stripslashes($data);\n\t\t\t$data = htmlspecialchars($data);\n\t\t\treturn $data;\n\t\t}", "private static function clean_input($data) {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "function clean($data){\n\t\t$this->data = $data;\n\t\t$data = trim($data);\n\t\t$data = stripcslashes($data);\n\t\t$data = htmlspecialchars($data);\n\t\treturn $data;\n\t}", "function sanitize_input($data) { \r\n $data = trim($data); \r\n $data = stripslashes($data); \r\n $data = htmlspecialchars($data); \r\n return $data; \r\n }", "function cleanInput($data){ //sanitize data \n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "public function CleanData($data){\n\t\t\t$data = trim($data);\n\t\t\t$data=htmlentities($data,ENT_QUOTES, 'UTF-8');\n\t\t\t$data = filter_var($data,FILTER_SANITIZE_SPECIAL_CHARS);\n\t\t\treturn $data;\n\t\t\t}", "public function CleanData($data){\n\t\t\t$data = trim($data);\n\t\t\t$data=htmlentities($data,ENT_QUOTES, 'UTF-8');\n\t\t\t$data = filter_var($data,FILTER_SANITIZE_SPECIAL_CHARS);\n\t\t\treturn $data;\n\t\t\t}", "public function CleanData($data){\n\t\t\t$data = trim($data);\n\t\t\t$data=htmlentities($data,ENT_QUOTES, 'UTF-8');\n\t\t\t$data = filter_var($data,FILTER_SANITIZE_SPECIAL_CHARS);\n\t\t\treturn $data;\n\t\t\t}", "function clean_input($data) {\n $data = trim($data); // strips whitespace from beginning/end\n $data = stripslashes($data); // remove backslashes\n $data = htmlspecialchars($data); // replace special characters with HTML entities\n return $data;\n}", "function cleanData($data){\n\t\t$data = trim($data);\n\t\t$data = stripslashes($data);\n\t\t$data = htmlspecialchars($data);\n\t\treturn $data;\n\t}", "function cleanInput($data) {\n\t\n\treturn htmlspecialchars(stripslashes(trim($data)));\n}", "function cleanInput($data) {\n\t\t$data = trim($data);\n\t\t$data = stripslashes($data);\n\t\t$data = htmlspecialchars($data);\n\t\treturn $data;\n\t}", "public static function xss_clean(array $data)\n\t{\n\t\tforeach($data as $k => $v)\n\t\t{\n\t\t\t$data[$k] = filter_var($v, FILTER_SANITIZE_STRING);\t\t\n\t\t}\n\t\t\n\t\treturn $data;\n\t}", "function sanitize_validate_input($data){\n\t\t \t \t$data = filter_var($data, FILTER_SANITIZE_STRING);\n\t\t \t \t//$data = filter_var($data, FILTER_VALIDATE_EMAIL);\n\t\t \t \t$data = stripcslashes($data);\n\t\t \t \t$data = trim($data);\n\t\t \t \t$data = htmlspecialchars($data);\n\t\t \t \t\n\t\t \t \treturn $data; }", "function cleanInput($data) {\r\n\t\t\t$data = trim($data);\r\n\t\t\t$data = stripslashes($data);\r\n\t\t\t$data = htmlspecialchars($data);\r\n\t\t\treturn $data;\r\n\t\t}", "function StringInputCleaner($data) {\n\t//remove space bfore and after\n\t$data = trim($data);\n\t//remove slashes\n\t$data = stripslashes($data);\n\t$data = (filter_var($data, FILTER_SANITIZE_STRING));\n\t$data = utf8_encode($data);\n\treturn $data;\n}", "function StringInputCleaner($data) {\n\t//remove space bfore and after\n\t$data = trim($data);\n\t//remove slashes\n\t$data = stripslashes($data);\n\t$data = (filter_var($data, FILTER_SANITIZE_STRING));\n\t$data = utf8_encode($data);\n\treturn $data;\n}", "function antiinjection($data){\n\t$filter_sql = stripslashes(strip_tags(htmlspecialchars($data,ENT_QUOTES)));\n \treturn $filter_sql;\n}", "function cleanInput($data)\n\t{\n\t\t$data = trim($data);\n\t\t$data = stripslashes($data);\n\t\t$data = htmlspecialchars($data);\n\t\treturn $data;\n\t}", "function filterSpecials($data){\n\n if(!$this->isUTF8($data))\n $data = utf8_encode($data);\n $data = htmlspecialchars($data, ENT_QUOTES);\n\n return $data;\n }", "function sanitizeDBData($input) {\n $halfSan = filter_var($input, FILTER_SANITIZE_EMAIL);\n\n //sets slashes infront of \" ' and \\\n $output = filter_var($halfSan, FILTER_SANITIZE_MAGIC_QUOTES);\n\n return $output;\n}", "function clean_input($data){\r\n\t\t\t\t\t$data = trim($data);\r\n\t\t\t\t\t$data = stripslashes($data);\r\n\t\t\t\t\t$data = htmlspecialchars($data);\r\n\t\t\t\t\treturn $data;\r\n\t\t\t\t}", "function clean($data) {\n\t$data = trim($data);\n\t$data = stripslashes($data);\n\t$data = htmlspecialchars($data);\n\treturn $data;\n}", "function SafeConvert($data){\n\t$data=trim($data);\n\t//convert special characters to html entities\n\t//most hacking inputs in XSS are HTML in nature, so converting them to special characters so that they are not harmful\n\t$data=htmlspecialchars($data);\n\t//sanitize before using any MySQL database queries\n\t//this will escape quotes in the input.\n\t$data = mysql_real_escape_string($data);\n\treturn $data;\n}", "function scrubInput($data) {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n}", "function clean_input($data) {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n}", "function sanitize_input($data) {\r\n $data = trim($data);\r\n $data = stripslashes($data);\r\n $data = htmlspecialchars($data);\r\n return $data;\r\n}", "function sanitize($data)\n {\n $data=trim($data);\n $data=mysql_real_escape_string($data);\n return $data;\n }", "public function getSanitizeData($data){\n\t $santiziedData = $this->sanitizeString($data);\n\t return $santiziedData;\n }", "function cleanInput($data) { \n return htmlspecialchars(stripslashes(trim($data)));\n}", "public function sanitize()\n {\n $purifier = $this->_purifier;\n $this->_sanitized_data = array_map(\n function ($field) use ($purifier) {\n return $purifier->purify($field);\n },\n $this->_data\n );\n }", "function sanitize ($data) {\n\t\treturn htmlentities (mysqli_real_escape_string ($GLOBALS['con'], $data),ENT_NOQUOTES,\"utf-8\");\n\t}", "function sanitize($data){\n$data=trim($data);\n$data=htmlspecialchars($data);\n$data=mysql_real_escape_string($data);\nreturn $data;\n}", "public function sanitize($value);", "public function clean($data)\n {\n if (is_array($data)) {\n foreach ($data as $key => $value) {\n unset($data[$key]);\n\n $data[$this->clean($key)] = $this->clean($value);\n }\n } else {\n // Second param : ENT_COMPAT - convert double-quotes and leave single-quotes alone,\n // Third param : 'UTF-8' - set encoding.\n $data = htmlspecialchars($data, ENT_COMPAT, 'UTF-8');\n }\n\n return $data;\n }", "function filterUserInput($data) {\n\n // trim() function will remove whitespace from the beginning and end of string.\n $data = trim($data);\n\n // Strip HTML and PHP tags from a string\n $data = strip_tags($data);\n\n /* The stripslashes() function removes backslashes added by the addslashes() function.\n Tip: This function can be used to clean up data retrieved from a database or from an HTML form.*/\n $data = stripslashes($data);\n\n // htmlspecialchars() function converts special characters to HTML entities. Say '&' (ampersand) becomes '&amp;'\n $data = htmlspecialchars($data);\n return $data;\n\n}", "function sanitize($input) {\n return htmlspecialchars(strip_tags(trim($input)));\n }", "public function sanitize(&$data)\n\t{\n\t\treturn $data;\n\t}", "function cleanInput($data) { \n return htmlspecialchars(stripslashes(trim($data)));\n}", "function santitise_input($data) {\n $data = trim($data);\n //Removing backslashes.\n $data = stripslashes($data);\n //Removing HTML special/control characters.\n $data = htmlspecialchars($data);\n return $data; \n }", "function clean_input($data) \n{\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n}", "public function sanitize() {\n }", "public function xssClean($data)\r\n {\r\n return Bootstrap::xssClean($data);\r\n }", "function sanitize($dirty){\n return htmlentities($dirty,ENT_QUOTES,\"UTF-8\");\n}", "function sanitizeData_hard($var)\n\t{\n\t\t$var = trim($var); // gets rid of white space\n\t\t$var = stripslashes($var); // no slashes protecting stuff\n\t\t$var = htmlentities($var); // no html :-(\n\t\t$var = strip_tags($var); // no tags\n\t\treturn $var; //returns clean data\n\t}", "function sanitize_arr_string_xss(array $data): array\n{\n foreach ($data as $k => $v) {\n $data[$k] = filter_var($v, FILTER_SANITIZE_STRING);\n }\n return $data;\n}", "public function clean($data){\n if(!empty($data)){\n $data = trim(strip_tags(stripcslashes($data)));\n return $data;\n }\n }", "function test_input($data) {\n $data = trim($data);\n $data = strip_tags($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "function sanitize($string) {\n $data = htmlspecialchars(stripslashes(strip_tags(trim($string))));\n return $data;\n}", "function secure_input($data) {\n $data = trim($data);\n // remove backslashes (\\)\n $data = stripslashes($data);\n // save as HTML escaped code --> any scripts in input data will not run\n $data = htmlspecialchars($data);\n return $data;\n }", "function sanitizeString($str_input) {\r\n $str_input = strip_tags($str_input);\r\n $str_input = htmlentities($str_input);\r\n $str_input = stripslashes($str_input);\r\n return $str_input;\r\n}", "public function sanitize( $input ) {\n }", "function xss_clean_data($string)\n{\n $CI = & get_instance();\n $return = $CI->security->xss_clean($string);\n return $return;\n}", "function html_xss_clean($text) {\n return htmlspecialchars($text);\n}", "protected function sanitize($input){ \n\t\tif ( get_magic_quotes_gpc() )\n\t\t{\n\t\t\t$input = stripslashes($input);\n\t\t}\n\n\t $search = array(\n\t\t '@<script[^>]*?>.*?</script>@si', // Strip out javascript\n\t\t '@<[\\/\\!]*?[^<>]*?>@si', // Strip out HTML tags\n\t\t '@<style[^>]*?>.*?</style>@siU', // Strip style tags properly\n\t\t '@<![\\s\\S]*?--[ \\t\\n\\r]*>@' // Strip multi-line comments\n\t \t);\n\n\t\t$output = preg_replace($search, '', $input);\n\t\treturn $output;\n }", "public static function sanitize($data){\n\t\t\t$db = new Database;\n\t\t\tif (gettype($data) === 'array') {\n\t\t\t\treturn $data;\n\t\t\t}else{\n\t\t\t\t$data = trim($data);\t\t\t\t\n\t\t\t\t$data = stripcslashes($data);\n\t\t\t\t$data = mysqli_real_escape_string($db->link, $data);\n\t\t\t\treturn $data;\n\t\t\t}\n\t\t}", "function cleanInputs($data) {\n\t$data = trim($data);\n\t$data = stripslashes($data);\n\t$data = htmlspecialchars($data);\n\treturn $data;\n}", "function cleanInputs($data) {\n\t$data = trim($data);\n\t$data = stripslashes($data);\n\t$data = htmlspecialchars($data);\n\treturn $data;\n}", "function sanitize($val){\n return htmlentities(stripslashes(trim($val)), ENT_QUOTES);\n}", "function sanitize($data)\n{\n$data = trim($data);\n \n// apply stripslashes if magic_quotes_gpc is enabled\nif(get_magic_quotes_gpc())\n{\n$data = stripslashes($data);\n}\n \n// a mySQL connection is required before using this function\n$data = mysql_real_escape_string($data);\n \nreturn $data;\n}", "function clean_input($data){\r\n\t$data = trim($data);\r\n\t$data = stripslashes($data);\r\n\t$data = htmlspecialchars($data);\r\n\treturn $data;\t\r\n}", "public abstract function sanitize($string);", "function sanitize($input){\n $input = strip_tags($input);\n $input = htmlspecialchars($input);\n $input = trim($input);\n return $input;\n}", "function sanitize($input) {\n\t\n\t\t$input = stripslashes($input);\n\t\t$input = htmlspecialchars($input);\n\t\n\t\treturn $input;\n\t}", "function sanitize_string($str)\r\n{\r\n\t$str = strip_tags($str);\r\n $str = htmlentities($str, ENT_QUOTES);\r\n return $str;\r\n}", "function validate($data)\n {\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "function _xssClean($str) {\n\t\tif (is_array($str)) {\n\n\t\t\twhile (list($key) = each($str)) {\n\n\t\t\t\t$str[$key] = $this->_xssClean($str[$key]);\n\t\t\t}\n\n\t\t\treturn $str;\n\t\t}\n\n\n\t\t$str = _removeInvisibleCharacters($str);\n\t\t$str = _htmlEncode($str);\n\t\t$str = filter_var($str, FILTER_SANITIZE_STRING);\n\n\t\treturn $str;\n\t}", "function sanitize_input($str) {\n\treturn preg_replace(\"/[?'&<>\\\"]/\", \"\", $str);\n}", "function secure_input($data) {\r\n $data = trim($data);\r\n $data = stripslashes($data);\r\n $data = htmlspecialchars($data);\r\n // tbd mysql_real_escape_string\r\n return $data;\r\n}", "public function sanitize() {\n\n\t\t// load the tool that we want to use in the xss filtering process\n\t\t$this->loadTool();\n\n\t\tif (is_array($_GET) AND count($_GET) > 0) {\n\n\t\t\t$_GET = $this->clean_input_data($_GET);\n\t\t}\n\t\tif (is_array($_POST) AND count($_POST) > 0) {\n\n\t\t\t$_POST = $this->clean_input_data($_POST);\n\t\t}\n\t\tif (is_array($_COOKIE) AND count($_COOKIE) > 0) {\n\n\t\t\t$_COOKIE = $this->clean_input_data($_COOKIE);\n\t\t}\n\t\tif (is_array($_FILES) AND count($_FILES) > 0) {\n\n\t\t\t//$_FILES = $this->clean_input_data($_FILES, true);\n\t\t}\n\n\t}", "public function check_input($data)\n\t\t{\n\t\t\t$data = trim($data);\n\t\t\t$data = stripcslashes($data);\n\t\t\t$data = htmlspecialchars($data);\n\t\t\treturn $data;\n\t\t}", "function validation($data)\n{\n\t$data = htmlspecialchars($data);\n\t$data = trim($data);\n\t$data = stripcslashes($data);\n\treturn $data;\n}", "function test_input($data){\r\n $data = trim($data); //remove white spaces\r\n $data = stripcslashes($data); //remove backslashes\r\n $data = htmlspecialchars($data);\r\n return $data;\r\n }", "public function secure($data)\n {\n if (is_string($data)) {\n $data = htmlentities($data);\n $data = addslashes($data);\n $data = strip_tags($data, '');\n $data = str_replace(\"%20\", \" \", $data);\n }\n return $data;\n }", "public static function sanitize($data, $type)\n {\n\t\t## Use the HTML Purifier, as it help remove malicious scripts and code. ##\n\t\t## HTML Purifier 4.4.0 - Standards Compliant HTML Filtering ##\n\t\trequire_once(CORE_PATH . '/libs/htmlpurifier-4.4.0/HTMLPurifier.standalone.php');\n\n\t\t$purifier = new HTMLPurifier();\n\t\t$config = HTMLPurifier_Config::createDefault();\n\t\t$config->set('Core.Encoding', 'UTF-8');\n\n\t\tswitch($type){\n\n\t\t\tcase 'purestring':\n\t\t\t\t$data = filter_var( strip_tags($data), FILTER_SANITIZE_STRING, FILTER_FLAG_ENCODE_HIGH );\n\t\t\t\tbreak;\n\n\t\t\tcase 'username':\n\t\t\t\t$data = preg_replace( '/[^0-9a-zA-Z\\-\\_]+/', '', strip_tags($data) );\n\t\t\t\tbreak;\n\t\t}\n\t\t\n /* HTML purifier to help prevent XSS, just in case. */\n $data = $purifier->purify( $data );\n\n\t\treturn $data;\n\t}", "private function sanitize($form_data) {\n $sanitized_data = filter_var_array($form_data, FILTER_SANITIZE_STRING);\n \n // Return the sanitized datas\n return $sanitized_data;\n }", "function sanitize_string($a_string)\n{\n $a_string = htmlspecialchars($a_string, ENT_QUOTES);\n $a_string = strip_tags($a_string);\n return trim($a_string); \n}", "function validate($data){\n $data = trim($data);\n $data = stripslashes($data);\n $data = htmlspecialchars($data);\n return $data;\n }", "protected function sanitizeData(): array {\n $sanitizedData = [];\n foreach ($this->rawData as $data) {\n $sanitizedData[] = htmlentities($data);\n }\n return $sanitizedData;\n }" ]
[ "0.81130785", "0.7982253", "0.7944413", "0.79260486", "0.79190713", "0.79142207", "0.7910113", "0.78971577", "0.78630877", "0.78617656", "0.78617656", "0.78455967", "0.7843945", "0.7842018", "0.7820967", "0.78208345", "0.78197247", "0.7744831", "0.77422553", "0.7705791", "0.76963055", "0.76669866", "0.7661441", "0.7659585", "0.7648283", "0.76479745", "0.75887597", "0.7587953", "0.7587953", "0.7587953", "0.75626063", "0.75603956", "0.754797", "0.75363266", "0.7519549", "0.7519167", "0.7512875", "0.74818623", "0.74818623", "0.7467267", "0.7461771", "0.7440168", "0.7422311", "0.74218035", "0.7413543", "0.73907167", "0.73844695", "0.7365964", "0.7364017", "0.73627925", "0.73583883", "0.73563194", "0.7347875", "0.73260814", "0.73259723", "0.7325239", "0.7308345", "0.7307651", "0.72861224", "0.72600573", "0.7255288", "0.72383666", "0.72382736", "0.7231281", "0.7227908", "0.7226401", "0.72173375", "0.71943766", "0.7183516", "0.7180668", "0.7167065", "0.71628314", "0.7162703", "0.7153882", "0.71484196", "0.7144906", "0.71357197", "0.7132497", "0.7128017", "0.7128017", "0.7118595", "0.7115083", "0.71142936", "0.7104267", "0.70704633", "0.70363265", "0.70226735", "0.70121163", "0.7010093", "0.70091724", "0.7003092", "0.6999809", "0.69825804", "0.6980691", "0.6980309", "0.6979499", "0.6976935", "0.6975694", "0.69715047", "0.69699264", "0.6965524" ]
0.0
-1
Seed the application's database.
public function run() { Role::create(['name' => 'admin']); Role::create(['name' => 'user']); User::create([ 'name' => 'admin', 'email' => "[email protected]", 'password' => Hash::make('password'), ])->assignRole(['admin', 'user']); User::create([ 'name' => 'user', 'email' => "[email protected]", 'password' => Hash::make('password'), ])->assignRole('user'); User::factory()->count(50)->create()->each(function(User $user) { $user->assignRole('user'); $user->posts()->saveMany(Post::factory()->count(1000)->make()); }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function dbSeed(){\n\t\tif (App::runningUnitTests()) {\n\t\t\t//Turn foreign key checks off\n\t\t\tDB::statement('SET FOREIGN_KEY_CHECKS=0;');// <- USE WITH CAUTION!\n\t\t\t//Seed tables\n\t\t\tArtisan::call('db:seed');\n\t\t\t//Turn foreign key checks on\n\t\t\tDB::statement('SET FOREIGN_KEY_CHECKS=1;');// <- SHOULD RESET ANYWAY BUT JUST TO MAKE SURE!\n\t\t}\n\t}", "protected function seedDB()\n {\n $ans = $this->ask('Seed your database?: ', 'y');\n\n // Check if the answer is true\n if (preg_match('/^y/', $ans))\n {\n $this->call('db:seed');\n $this->comment('');\n $this->comment('Database successfully seeded.');\n $this->comment('=====================================');\n echo \"Your app is now ready!\";\n }\n }", "protected function seedDatabase(): void\n {\n $this->seedProductCategories();\n $this->seedProducts();\n }", "public function setupDatabase()\n {\n Artisan::call('migrate:refresh');\n Artisan::call('db:seed');\n\n self::$setupDatabase = false;\n }", "public function run()\n {\n $this->seed('FormsMenuItemsTableSeeder');\n $this->seed('FormsDataTypesTableSeeder');\n $this->seed('FormsDataRowsTableSeeder');\n $this->seed('FormsPermissionsTableSeeder');\n $this->seed('FormsSettingsTableSeeder');\n $this->seed('FormsTableSeeder');\n }", "public function run()\n {\n if (defined('STDERR')) fwrite(STDERR, print_r(\"\\n--- Seeding ---\\n\", TRUE));\n\n if (App::environment('production')) {\n if (defined('STDERR')) fwrite(STDERR, print_r(\"--- ERROR: Seeding in Production is prohibited ---\\n\", TRUE));\n return;\n }\n\n $this->call(RolesTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(ProvincesTableSeeder::class);\n $this->call(CitiesTableSeeder::class);\n $this->call(DistrictsTableSeeder::class);\n $this->call(ConfigsTableSeeder::class);\n $this->call(ConfigContentsTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n if (defined('STDERR')) fwrite(STDERR, print_r(\"Set FOREIGN_KEY_CHECKS=1 --- DONE\\n\", TRUE));\n\n // \\Artisan::call('command:regenerate-user-feeds');\n\n \\Cache::flush();\n\n if (defined('STDERR')) fwrite(STDERR, print_r(\"--- End Seeding ---\\n\\n\", TRUE));\n }", "protected function setupDatabase()\n {\n $this->call('migrate');\n $this->call('db:seed');\n\n $this->info('Database migrated and seeded.');\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(PermissionsSeeder::class);\n $this->call(RolesSeeder::class);\n $this->call(ThemeSeeder::class);\n\n //\n\n DB::table('paypal_info')->insert([\n 'client_id' => '',\n 'client_secret' => '',\n 'currency' => '',\n ]);\n DB::table('contact_us')->insert([\n 'content' => '',\n ]);\n DB::table('setting')->insert([\n 'site_name' => ' ',\n ]);\n DB::table('terms_and_conditions')->insert(['terms_and_condition' => 'text']);\n }", "public function seedDatabase(): void\n {\n echo \"Running seeds\";\n\n // Folder where all the seeds are.\n $folder = __DIR__ . '/../seeds/';\n\n // Scan all files/folders inside database.\n $files = \\scandir($folder);\n\n $seeders = [];\n foreach ($files as $key => $file) {\n\n // All files that don't start with a dot.\n if ($file[0] !== '.') {\n\n // Load the file.\n require_once $folder . $file;\n\n // We have to call the migrations after because\n // some seeds are dependant from other seeds.\n $seeders[] = explode('.', $file)[0];\n }\n }\n\n // Run all seeds.\n foreach ($seeders as $seeder) {\n (new $seeder)->run();\n }\n }", "protected function seedDatabase()\n {\n //$this->app->make('db')->table(static::TABLE_NAME)->delete();\n\n TestExtendedModel::create([\n 'unique_field' => '999',\n 'second_field' => null,\n 'name' => 'unchanged',\n 'active' => true,\n 'hidden' => 'invisible',\n ]);\n\n TestExtendedModel::create([\n 'unique_field' => '1234567',\n 'second_field' => '434',\n 'name' => 'random name',\n 'active' => false,\n 'hidden' => 'cannot see me',\n ]);\n\n TestExtendedModel::create([\n 'unique_field' => '1337',\n 'second_field' => '12345',\n 'name' => 'special name',\n 'active' => true,\n 'hidden' => 'where has it gone?',\n ]);\n }", "public function initDatabase()\n {\n $this->call('migrate');\n\n $userModel = config('admin.database.users_model');\n\n if ($userModel::count() == 0) {\n $this->call('db:seed', ['--class' => AdminSeeder::class]);\n }\n }", "public function run ()\n {\n if (App::environment() === 'production') {\n exit('Seed should be run only in development/debug environment.');\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('role_user')->truncate();\n\n // Root user\n $user = User::find(1);\n $user->assignRole('owner');\n\n $user = User::find(2);\n $user->assignRole('admin');\n\n $user = User::find(3);\n $user->assignRole('admin');\n\n $user = User::find(4);\n $user->assignRole('moderator');\n\n $user = User::find(5);\n $user->assignRole('moderator');\n \n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n }", "public function run()\n {\n Model::unguard();\n\n if (env('DB_CONNECTION') == 'mysql') {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n }\n\n $this->call(RolesTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(EntrustTableSeeder::class);\n\n $this->call(AccounttypeSeeder::class);\n $this->call(AppUserTableSeeder::class);\n $this->call(AppEmailUserTableSeeder::class);\n\n\n $this->call(CountryTableSeeder::class);\n $this->call(CityTableSeeder::class);\n\n\n $this->call(PostTypeTableSeeder::class);\n $this->call(PostSubTypeTableSeeder::class);\n // $this->call(PostTableSeeder::class);\n // $this->call(AppPostSolvedTableSeeder::class);\n\n\n $this->call(AppCommentTypeTableSeeder::class);\n // $this->call(AppCommentTableSeeder::class);\n // $this->call(AppSubCommentTableSeeder::class);\n\n\n if (env('DB_CONNECTION') == 'mysql') {\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }\n\n Model::reguard();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n DB::table('users')->truncate();\n DB::table('password_resets')->truncate();\n DB::table('domains')->truncate();\n DB::table('folders')->truncate();\n DB::table('bookmarks')->truncate();\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\n $this->seedUserAccount('[email protected]');\n $this->seedUserAccount('[email protected]');\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n // $this->call(UsersTableSeeder::class);\n /* Schema::dropIfExists('employees');\n Schema::dropIfExists('users');\n Schema::dropIfExists('requests');\n Schema::dropIfExists('requeststatus');*/\n User::truncate();\n InstallRequest::truncate();\n RequestStatus::truncate();\n\n $cantidadEmployyes = 20;\n $cantidadUsers = 20;\n $cantidadRequestStatus = 3;\n $cantidadRequests = 200;\n\n factory(User::class, $cantidadUsers)->create();\n factory(RequestStatus::class, $cantidadRequestStatus)->create();\n factory(InstallRequest::class, $cantidadRequests)->create();\n }", "public function run()\n {\n Model::unguard();\n foreach (glob(__DIR__ . '/seeds/*.php') as $filename) {\n require_once($filename);\n }\n // $this->call(UserTableSeeder::class);\n //DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n// $this->call('CustomerTableSeeder');\n $this->call('PhotoTableSeeder');\n// $this->call('ProductTableSeeder');\n// $this->call('StaffTableSeeder');\n// $this->call('PasswordResetsTableSeeder');\n// $this->call('UsersTableSeeder');\n $this->call('CustomersTableSeeder');\n $this->call('EmployeesTableSeeder');\n $this->call('InventoryTransactionTypesTableSeeder');\n $this->call('OrderDetailsTableSeeder');\n $this->call('OrderDetailsStatusTableSeeder');\n $this->call('OrdersTableSeeder');\n $this->call('InvoicesTableSeeder');\n $this->call('OrdersTableSeeder');\n $this->call('OrderDetailsTableSeeder');\n $this->call('OrdersStatusTableSeeder');\n $this->call('OrderDetailsTableSeeder');\n\n $this->call('OrdersTaxStatusTableSeeder');\n $this->call('PrivilegesTableSeeder');\n $this->call('EmployeePrivilegesTableSeeder');\n $this->call('ProductsTableSeeder');\n $this->call('InventoryTransactionsTableSeeder');\n $this->call('PurchaseOrderDetailsTableSeeder');\n\n $this->call('PurchaseOrderStatusTableSeeder');\n $this->call('PurchaseOrdersTableSeeder');\n $this->call('SalesReportsTableSeeder');\n $this->call('ShippersTableSeeder');\n $this->call('StringsTableSeeder');\n $this->call('SuppliersTableSeeder');\n //DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\n Model::reguard();\n }", "public function run()\n\t{\n $this->cleanDatabase();\n\n Eloquent::unguard();\n\n\t\t$this->call('UsersTableSeeder');\n\t\t$this->call('ProductsTableSeeder');\n\t\t$this->call('CartsTableSeeder');\n $this->call('StoreTableSeeder');\n $this->call('AdvertisementsTableSeeder');\n \n\t}", "public function run()\n {\n \tDB::table('seeds')->truncate();\n\n $seeds = array(\n array(\n 'name' => 'PreferencesTableSeeder_Update_11_18_2013',\n ),\n array(\n 'name' => 'PreferencesTableSeeder_Update_11_20_2013',\n ),\n );\n\n // Uncomment the below to run the seeder\n DB::table('seeds')->insert($seeds);\n }", "public function run()\n {\n $this->createDefaultPermissionSeeder(env('DB_CONNECTION', 'mysql'));\n }", "public function run()\n {\n $this->createDefaultPermissionSeeder(env('DB_CONNECTION', 'mysql'));\n }", "protected function setUp(): void\n {\n $db = new DB;\n\n $db->addConnection([\n 'driver' => 'sqlite',\n 'database' => ':memory:',\n ]);\n\n $db->bootEloquent();\n $db->setAsGlobal();\n\n $this->createSchema();\n }", "public function run()\n {\n //$this->call('UserTableSeeder');\n //$this->call('ProjectTableSeeder');\n //$this->call('TaskTableSeeder');\n\n /**\n * Prepare seeding\n */\n $faker = Faker::create();\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n Model::unguard();\n\n /**\n * Seeding user table\n */\n App\\User::truncate();\n factory(App\\User::class)->create([\n 'name' => 'KCK',\n 'email' => '[email protected]',\n 'password' => bcrypt('password')\n ]);\n\n /*factory(App\\User::class, 9)->create();\n $this->command->info('users table seeded');*/\n\n /**\n * Seeding roles table\n */\n Spatie\\Permission\\Models\\Role::truncate();\n DB::table('model_has_roles')->truncate();\n $superAdminRole = Spatie\\Permission\\Models\\Role::create([\n 'name' => '최고 관리자'\n ]);\n $adminRole = Spatie\\Permission\\Models\\Role::create([\n 'name' => '관리자'\n ]);\n $regularRole = Spatie\\Permission\\Models\\Role::create([\n 'name' => '정회원'\n ]);\n $associateRole = Spatie\\Permission\\Models\\Role::create([\n 'name' => '준회원'\n ]);\n\n App\\User::where('email', '!=', '[email protected]')->get()->map(function ($user) use ($regularRole) {\n $user->assignRole($regularRole);\n });\n\n App\\User::whereEmail('[email protected]')->get()->map(function ($user) use ($superAdminRole) {\n $user->assignRole($superAdminRole);\n });\n $this->command->info('roles table seeded');\n\n /**\n * Seeding articles table\n */\n App\\Article::truncate();\n $users = App\\User::all();\n\n $users->each(function ($user) use ($faker) {\n $user->articles()->save(\n factory(App\\Article::class)->make()\n );\n });\n $this->command->info('articles table seeded');\n\n /**\n * Seeding comments table\n */\n App\\Comment::truncate();\n $articles = App\\Article::all();\n\n $articles->each(function ($article) use ($faker, $users) {\n for ($i = 0; $i < 10; $i++) {\n $article->comments()->save(\n factory(App\\Comment::class)->make([\n 'author_id' => $faker->randomElement($users->pluck('id')->toArray()),\n //'parent_id' => $article->id\n ])\n );\n };\n });\n $this->command->info('comments table seeded');\n\n /**\n * Seeding tags table\n */\n App\\Tag::truncate();\n DB::table('article_tag')->truncate();\n $articles->each(function ($article) use ($faker) {\n $article->tags()->save(\n factory(App\\Tag::class)->make()\n );\n });\n $this->command->info('tags table seeded');\n\n /**\n * Seeding attachments table\n */\n App\\Attachment::truncate();\n if (!File::isDirectory(attachment_path())) {\n File::deleteDirectory(attachment_path(), true);\n }\n\n $articles->each(function ($article) use ($faker) {\n $article->attachments()->save(\n factory(App\\Attachment::class)->make()\n );\n });\n\n //$files = App\\Attachment::pluck('name');\n\n if (!File::isDirectory(attachment_path())) {\n File::makeDirectory(attachment_path(), 777, true);\n }\n\n /*\n foreach ($files as $file) {\n File::put(attachment_path($file), '');\n }\n */\n\n $this->command->info('attachments table seeded');\n\n /**\n * Close seeding\n */\n Model::reguard();\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n echo 'seeding permission...', PHP_EOL;\n $permissions = [\n 'role-list',\n 'role-create',\n 'role-edit',\n 'role-delete',\n 'formation-list',\n 'formation-create',\n 'formation-edit',\n 'formation-delete',\n 'user-list',\n 'user-create',\n 'user-edit',\n 'user-delete'\n ];\n foreach ($permissions as $permission) {\n Permission::create(['name' => $permission]);\n }\n echo 'seeding users...', PHP_EOL;\n\n $user= User::create(\n [\n 'name' => 'Mr. admin',\n 'email' => '[email protected]',\n 'password' => bcrypt('admin'),\n 'remember_token' => null,\n ]\n );\n echo 'Create Roles...', PHP_EOL;\n Role::create(['name' => 'former']);\n Role::create(['name' => 'learner']);\n Role::create(['name' => 'admin']);\n Role::create(['name' => 'manager']);\n Role::create(['name' => 'user']);\n\n echo 'seeding Role User...', PHP_EOL;\n $user->assignRole('admin');\n $role = $user->assignRole('admin');\n $role->givepermissionTo(Permission::all());\n\n \\DB::table('languages')->insert(['name' => 'English', 'code' => 'en']);\n \\DB::table('languages')->insert(['name' => 'Français', 'code' => 'fr']);\n }", "public function run()\n {\n $this->call(CountriesTableSeeder::class);\n $this->call(StatesTableSeeder::class);\n $this->call(CitiesTableSeeder::class);\n\n factory(Group::class)->create();\n factory(Contact::class, 5000)->create();\n }", "public function run()\n\t{\n\t\tEloquent::unguard();\n\n\t\t// $this->call('AdminTableSeeder');\n\t\t// $this->call('UserTableSeeder');\n\t\t// $this->call('MenuTableSeeder');\n\t\t// $this->call('ProductTableSeeder');\n\t\t// $this->call('CategoryTableSeeder');\n\t\t// $this->call('OptionTableSeeder');\n\t\t// $this->call('OptionGroupTableSeeder');\n\t\t// $this->call('TypeTableSeeder');\n\t\t// $this->call('LayoutTableSeeder');\n\t\t// $this->call('LayoutDetailTableSeeder');\n\t\t// $this->call('BannerTableSeeder');\n\t\t// $this->call('ConfigureTableSeeder');\n\t\t// $this->call('PageTableSeeder');\n\t\t// $this->call('ImageTableSeeder');\n\t\t// $this->call('ImageableTableSeeder');\n\t\t// ======== new Seed =======\n\t\t$this->call('AdminsTableSeeder');\n\t\t$this->call('BannersTableSeeder');\n\t\t$this->call('CategoriesTableSeeder');\n\t\t$this->call('ConfiguresTableSeeder');\n\t\t$this->call('ImageablesTableSeeder');\n\t\t$this->call('ImagesTableSeeder');\n\t\t$this->call('LayoutsTableSeeder');\n\t\t$this->call('LayoutDetailsTableSeeder');\n\t\t$this->call('MenusTableSeeder');\n\t\t$this->call('OptionablesTableSeeder');\n\t\t$this->call('OptionsTableSeeder');\n\t\t$this->call('OptionGroupsTableSeeder');\n\t\t$this->call('PagesTableSeeder');\n\t\t$this->call('PriceBreaksTableSeeder');\n\t\t$this->call('ProductsTableSeeder');\n\t\t$this->call('ProductsCategoriesTableSeeder');\n\t\t$this->call('SizeListsTableSeeder');\n\t\t$this->call('TypesTableSeeder');\n\t\t$this->call('UsersTableSeeder');\n\t\t$this->call('ContactsTableSeeder');\n\t\t$this->call('RolesTableSeeder');\n\t\t$this->call('PermissionsTableSeeder');\n\t\t$this->call('PermissionRoleTableSeeder');\n\t\t$this->call('AssignedRolesTableSeeder');\n\t\t$this->call('OrdersTableSeeder');\n\t\t$this->call('OrderDetailsTableSeeder');\n\t\tCache::flush();\n\t\t// BackgroundProcess::copyFromVI();\n\t}", "public function run()\n {\n Model::unguard();\n\n User::create([\n 'email' => '[email protected]',\n 'name' => 'admin',\n 'password' => Hash::make('1234'),\n 'email_verified_at' => Carbon::now()\n ]);\n\n factory(User::class, 200)->create();\n\n // $this->call(\"OthersTableSeeder\");\n }", "public function run()\n {\n $this->seedRegularUsers();\n $this->seedAdminUser();\n }", "public function run()\n {\n if (\\App::environment() === 'local') {\n\n // Delete existing data\n\n\n Eloquent::unguard();\n\n //disable foreign key check for this connection before running seeders\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\n // Truncate all tables, except migrations\n $tables = array_except(DB::select('SHOW TABLES'), ['migrations']);\n foreach ($tables as $table) {\n $tables_in_database = \"Tables_in_\" . Config::get('database.connections.mysql.database');\n DB::table($table->$tables_in_database)->truncate();\n }\n\n // supposed to only apply to a single connection and reset it's self\n // but I like to explicitly undo what I've done for clarity\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\n //get roles\n $this->call('AccountSeeder');\n $this->call('CountrySeeder');\n $this->call('StateSeeder');\n $this->call('CitySeeder');\n $this->call('OptionSeeder');\n $this->call('TagSeeder');\n $this->call('PrintTemplateSeeder');\n $this->call('SettingsSeeder');\n\n\n\n if(empty($web_installer)) {\n $admin = Sentinel::registerAndActivate(array(\n 'email' => '[email protected]',\n 'password' => \"admin\",\n 'first_name' => 'Admin',\n 'last_name' => 'Doe',\n ));\n $admin->user_id = $admin->id;\n $admin->save();\n\n $adminRole = Sentinel::findRoleById(1);\n $adminRole->users()->attach($admin);\n }\n else {\n $admin = Sentinel::findById(1);\n }\n\n //add dummy staff and customer\n $staff = Sentinel::registerAndActivate(array(\n 'email' => '[email protected]',\n 'password' => \"staff\",\n 'first_name' => 'Staff',\n 'last_name' => 'Doe',\n ));\n $admin->users()->save($staff);\n\n foreach ($this->getPermissions() as $permission) {\n $staff->addPermission($permission);\n }\n $staff->save();\n\n $customer = Sentinel::registerAndActivate(array(\n 'email' => '[email protected]',\n 'password' => \"customer\",\n 'first_name' => 'Customer',\n 'last_name' => 'Doe',\n ));\n Customer::create(array('user_id' => $customer->id, 'belong_user_id' => $staff->id));\n $staff->users()->save($customer);\n\n //add respective roles\n\n $staffRole = Sentinel::findRoleById(2);\n $staffRole->users()->attach($staff);\n $customerRole = Sentinel::findRoleById(3);\n $customerRole->users()->attach($customer);\n\n\n\n DB::table('sales_teams')->truncate();\n DB::table('opportunities')->truncate();\n\n //Delete existing seeded users except the first 4 users\n User::where('id', '>', 3)->get()->each(function ($user) {\n $user->forceDelete();\n });\n\n //Get the default ADMIN\n $user = User::find(1);\n $staffRole = Sentinel::getRoleRepository()->findByName('staff');\n $customerRole = Sentinel::getRoleRepository()->findByName('customer');\n\n //Seed Sales teams for default ADMIN\n foreach (range(1, 4) as $j) {\n $this->createSalesTeam($user->id, $j, $user);\n $this->createOpportunity($user, $user->id, $j);\n }\n\n\n //Get the default STAFF\n $staff = User::find(2);\n $this->createSalesTeam($staff->id, 1, $staff);\n $this->createSalesTeam($staff->id, 2, $staff);\n\n //Seed Sales teams for each STAFF\n foreach (range(1, 4) as $j) {\n $this->createSalesTeam($staff->id, $j, $staff);\n $this->createOpportunity($staff, $staff->id, $j);\n }\n\n foreach (range(1, 3) as $i) {\n $staff = $this->createStaff($i);\n $user->users()->save($staff);\n $staffRole->users()->attach($staff);\n\n $customer = $this->createCustomer($i);\n $staff->users()->save($customer);\n $customerRole->users()->attach($customer);\n $customer->customer()->save(factory(\\App\\Models\\Customer::class)->make());\n\n\n //Seed Sales teams for each STAFF\n foreach (range(1, 5) as $j) {\n $this->createSalesTeam($staff->id, $j, $staff);\n $this->createOpportunity($staff, $i, $j);\n }\n\n }\n\n //finally call it installation is finished\n file_put_contents(storage_path('installed'), 'Welcome to LCRM');\n }\n }", "public function run()\n {\n if (env('DB_DATABASE') == 'connection') {\n Connection::create([\n \"ruc\" => \"12312312312\",\n \"basedata\" => \"nbdata2018_1\",\n ]);\n \n Connection::create([\n \"ruc\" => \"12312312315\",\n \"basedata\" => \"nbdata2018_2\",\n ]);\n \n $this->call(ConnectionTableSeeder::class);\n } else {\n $this->call(AppSeeder::class);\n }\n }", "public function setupDatabase()\n {\n exec('rm ' . storage_path() . '/testdb.sqlite');\n exec('cp ' . 'database/database.sqlite ' . storage_path() . '/testdb.sqlite');\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Let's truncate our existing records to start from scratch.\n Assignation::truncate();\n\n $faker = \\Faker\\Factory::create();\n \n // And now, let's create a few articles in our database:\n for ($i = 0; $i < 40; $i++) {\n Assignation::create([\n 'ad_id' => $faker->numberBetween(1,20),\n 'buyer_id' => $faker->numberBetween(1,6),\n 'seller_id' => $faker->numberBetween(6,11),\n 'state' => NULL,\n ]);\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n # truncates tables before seeding\n foreach ($this->toTruncate as $table) {\n DB::table($table)->delete();\n }\n\n factory(App\\Models\\Product::class, 25)->create();\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n Post::truncate();\n Comment::truncate();\n // CommentReply::truncate();\n \n\n\n factory(User::class,10)->create();\n factory(Post::class,20)->create();\n factory(Comment::class,30)->create();\n // factory(CommentReply::class,30)->create();\n }", "public function run()\n\t{\n \n Eloquent::unguard();\n //DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n\t\t$this->call('UserTableSeeder');\n\t $this->call('LayerTableSeeder');\n $this->call('UserLevelTableSeeder');\n $this->call('RoleUserTableSeeder');\n $this->call('RoleLayerTableSeeder');\n $this->call('BookmarkTableSeeder');\n \n //DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n\t}", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n // Sample::truncate();\n // TestItem::truncate();\n // UOM::truncate();\n Role::truncate();\n User::truncate();\n\n // factory(Role::class, 4)->create();\n Role::create([\n 'name'=> 'Director',\n 'description'=> 'Director type'\n ]);\n\n Role::create([\n 'name'=> 'Admin',\n 'description'=> 'Admin type'\n ]);\n Role::create([\n 'name'=> 'Employee',\n 'description'=> 'Employee type'\n ]);\n Role::create([\n 'name'=> 'Technician',\n 'description'=> 'Technician type'\n ]);\n \n factory(User::class, 20)->create()->each(\n function ($user){\n $roles = \\App\\Role::all()->random(mt_rand(1, 2))->pluck('id');\n $user->roles()->attach($roles);\n }\n );\n }", "public function run()\n {\n DatabaseSeeder::seedLearningStylesProbs();\n DatabaseSeeder::seedCampusProbs();\n DatabaseSeeder::seedGenderProbs();\n DatabaseSeeder::seedTypeStudentProbs();\n DatabaseSeeder::seedTypeProfessorProbs();\n DatabaseSeeder::seedNetworkProbs();\n }", "public function run()\n {\n /** \n * Note: You must add these lines to your .env file for this Seeder to work (replace the values, obviously):\n SEEDER_USER_FIRST_NAME = 'Firstname'\n SEEDER_USER_LAST_NAME = 'Lastname'\n\t\tSEEDER_USER_DISPLAY_NAME = 'Firstname Lastname'\n\t\tSEEDER_USER_EMAIL = [email protected]\n SEEDER_USER_PASSWORD = yourpassword\n */\n\t\tDB::table('users')->insert([\n 'user_first_name' => env('SEEDER_USER_FIRST_NAME'),\n 'user_last_name' => env('SEEDER_USER_LAST_NAME'),\n 'user_name' => env('SEEDER_USER_DISPLAY_NAME'),\n\t\t\t'user_email' => env('SEEDER_USER_EMAIL'),\n 'user_status' => 1,\n \t'password' => Hash::make((env('SEEDER_USER_PASSWORD'))),\n 'permission_fk' => 1,\n 'created_at' => Carbon::now()->format('Y-m-d H:i:s'),\n 'updated_at' => Carbon::now()->format('Y-m-d H:i:s')\n ]);\n }", "public function run()\n {\n DB::statement('SET foreign_key_checks = 0');\n DB::table('topics')->truncate();\n\n factory(\\App\\Topic::class, 100)->create();\n // ->each(function($topic) {\n\n // // Seed para a relação com group\n // $topic->group()->save(factory(App\\Group::class)->make());\n\n // // Seed para a relação com topicMessages\n // $topic->topicMessages()->save(factory(App\\TopicMessage::class)->make());\n\n // // Seed para a relação com user\n // $topic->user()->save(factory(App\\User::class)->make());\n // });\n \n DB::statement('SET foreign_key_checks = 1');\n }", "public function run()\n {\n\n factory('App\\Models\\Pessoa', 60)->create();\n factory('App\\Models\\Profissional', 10)->create();\n factory('App\\Models\\Paciente', 50)->create();\n $this->call(UsersTableSeeder::class);\n $this->call(ProcedimentoTableSeeder::class);\n // $this->call(PessoaTableSeeder::class);\n // $this->call(ProfissionalTableSeeder::class);\n // $this->call(PacienteTableSeeder::class);\n // $this->call(AgendaProfissionalTableSeeder::class);\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n Categoria::truncate();\n Atractivo::truncate();\n Galeria::truncate();\n User::truncate();\n\n $this->call(CategoriasTableSeeder::class);\n $this->call(AtractivosTableSeeder::class);\n $this->call(GaleriasTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n\n }", "public function run(Faker $faker)\n {\n Schema::disableForeignKeyConstraints();\n DB::table('users')->insert([\n 'name' => $faker->name(),\n 'email' => '[email protected]',\n 'password' => Hash::make('12345678'),\n ]);\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // TO PREVENT CHECKS FOR foreien key in seeding\n\n User::truncate();\n Category::truncate();\n Product::truncate();\n Transaction::truncate();\n\n DB::table('category_product')->truncate();\n\n User::flushEventListeners();\n Category::flushEventListeners();\n Product::flushEventListeners();\n Transaction::flushEventListeners();\n\n $usersQuantities = 1000;\n $categoriesQuantities = 30;\n $productsQuantities = 1000;\n $transactionsQuantities = 1000;\n\n factory(User::class, $usersQuantities)->create();\n factory(Category::class, $categoriesQuantities)->create();\n\n factory(Product::class, $productsQuantities)->create()->each(\n function ($product) {\n $categories = Category::all()->random(mt_rand(1, 5))->pluck('id');\n $product->categories()->attach($categories);\n });\n\n factory(Transaction::class, $transactionsQuantities)->create();\n }", "public function run()\n {\n\t $this->call(CategoryTableSeed::class);\n\t $this->call(ProductTableSeed::class);\n\t $this->call(UserTableSeed::class);\n }", "public function run()\n {\n $this->cleanDatabase();\n\n factory(User::class, 50)->create();\n factory(Document::class, 30)->create();\n }", "public function run()\n {\n // \\DB::statement('SET_FOREIGN_KEY_CHECKS=0');\n \\DB::table('users')->truncate();\n \\DB::table('posts')->truncate();\n // \\DB::table('category')->truncate();\n \\DB::table('photos')->truncate();\n \\DB::table('comments')->truncate();\n \\DB::table('comment_replies')->truncate();\n\n \\App\\Models\\User::factory()->times(10)->hasPosts(1)->create();\n \\App\\Models\\Role::factory()->times(10)->create();\n \\App\\Models\\Category::factory()->times(10)->create();\n \\App\\Models\\Comment::factory()->times(10)->hasReplies(1)->create();\n \\App\\Models\\Photo::factory()->times(10)->create();\n\n \n // \\App\\Models\\User::factory(10)->create([\n // 'role_id'=>2,\n // 'is_active'=>1\n // ]);\n\n // factory(App\\Models\\Post::class, 10)->create();\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n \t// DB::table('webapps')->delete();\n\n $webapps = array(\n\n );\n\n // Uncomment the below to run the seeder\n // DB::table('webapps')->insert($webapps);\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name'=>\"test\",\n 'password' => Hash::make('123'),\n 'email'=>'[email protected]'\n ]);\n DB::table('tags')->insert(['name'=>'tags']);\n $this->call(UserSeed::class);\n $this->call(CategoriesSeed::class);\n $this->call(TopicsSeed::class);\n $this->call(CommentariesSeed::class);\n // $this->call(UsersTableSeeder::class);\n }", "public function run()\n {\n $tables = array(\n 'users',\n 'companies',\n 'stands',\n 'events',\n 'visitors',\n 'api_keys'\n );\n\n if (!App::runningUnitTests()) {\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n }\n\n foreach ($tables as $table) {\n DB::table($table)->truncate();\n }\n\n $this->call(UsersTableSeeder::class);\n $this->call(EventsTableSeeder::class);\n $this->call(CompaniesTableSeeder::class);\n $this->call(StandsTableSeeder::class);\n $this->call(VisitorsTableSeeder::class);\n\n if (!App::runningUnitTests()) {\n DB::statement('SET FOREIGN_KEY_CHECKS = 1');\n }\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n Language::truncate();\n Reason::truncate();\n Report::truncate();\n Category::truncate();\n Position::truncate();\n\n $languageQuantity = 10;\n $reasonQuantity = 10;\n $reportQuantity = 10;\n $categoryQuantity = 10;\n $positionQuantity = 10;\n\n factory(Language::class,$languageQuantity)->create();\n factory(Reason::class,$reasonQuantity)->create();\n \n factory(Report::class,$reportQuantity)->create();\n \n factory(Category::class,$categoryQuantity)->create();\n \n factory(Position::class,$positionQuantity)->create();\n\n }", "public function run()\n {\n $clear = $this->command->confirm('Wil je de database leegmaken? (Dit haalt alle DATA weg)');\n\n if ($clear):\n $this->command->callSilent('migrate:refresh');\n $this->command->info('Database Cleared, starting seeding');\n endif;\n\n $this->call([\n SeedSeeder::class,\n RoleSeeder::class,\n UserSeeder::class,\n // BoardgameSeeder::class,\n BoardgamesTableSeeder::class,\n StatusSeeder::class,\n TournamentSeeder::class,\n AchievementsSeeder::class,\n TournamentUsersSeeder::class,\n ]);\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n $this->call(PaisSeeder::class);\n $this->call(DepartamentoSeeder::class);\n $this->call(MunicipioSeeder::class);\n $this->call(PersonaSeeder::class);\n }", "public function run()\n {\n //\n if (App::environment() === 'production') {\n exit('Do not seed in production environment');\n }\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0'); // disable foreign key constraints\n\n DB::table('events')->truncate();\n \n Event::create([\n 'id' => 1,\n 'name' => 'Spot Registration For Throat Cancer',\n 'cancerId' => 1,\n 'startDate'\t\t=> Carbon::now(),\n 'endDate'\t\t=> Carbon::now()->addMonths(12),\n 'eventType'\t\t=> 'register',\n 'formId'\t\t=> null,\n ]);\n\n Event::create([\n 'id' => 2,\n 'name' => 'Spot Screening For Throat Cancer',\n 'cancerId' => 1,\n 'startDate'\t\t=> Carbon::now(),\n 'endDate'\t\t=> Carbon::now()->addMonths(12),\n 'eventType'\t\t=> 'screen',\n 'formId'\t\t=> 1,\n ]);\n \n Event::create([\n 'id' => 3,\n 'name' => 'Spot Registration For Skin Cancer',\n 'cancerId' => 2,\n 'startDate'\t\t=> Carbon::now(),\n 'endDate'\t\t=> Carbon::now()->addMonths(12),\n 'eventType'\t\t=> 'register',\n 'formId'\t\t=> null,\n ]);\n\n\n Event::create([\n 'id' => 3,\n 'name' => 'Registration cum Screening camp for Throat Cancer',\n 'cancerId' => 1,\n 'startDate'\t\t=> Carbon::now(),\n 'endDate'\t\t=> Carbon::now()->addWeeks(1),\n 'eventType'\t\t=> 'register_screen',\n 'formId'\t\t=> 1,\n ]);\n \n DB::statement('SET FOREIGN_KEY_CHECKS = 1'); // enable foreign key constraints\n\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // Para que no verifique el control de claves foráneas al hacer el truncate haremos:\n\t\tDB::statement('SET FOREIGN_KEY_CHECKS=0');\n\n\t\t// Primero hacemos un truncate de las tablas para que no se estén agregando datos\n\t\t// cada vez que ejecutamos el seeder.\n\t\t//Foto::truncate();\n\t\t//Album::truncate();\n\t\t//Usuario::truncate();\n DB::table('users')->delete();\n DB::table('ciudades')->delete();\n DB::table('tiendas')->delete();\n DB::table('ofertas')->delete();\n DB::table('ventas')->delete();\n\n\n\t\t// Es importante el orden de llamada.\n\t\t$this->call('UserSeeder');\n $this->call('CiudadSeeder');\n\t\t$this->call('TiendaSeeder');\n $this->call('OfertaSeeder');\n $this->call('VentaSeeder');\n }", "public function run()\n {\n $this->call(\\Database\\Seeders\\GroupByRecordTableSeeder::class);\n $this->call(\\Database\\Seeders\\SingleIndexRecordTableSeeder::class);\n $this->call(\\Database\\Seeders\\MultiIndexRecordTableSeeder::class);\n $this->call(\\Database\\Seeders\\JoinFiveTablesSeeder::class);\n\n// DB::table('users')->truncate();\n// DB::table('user_details')->truncate();\n//\n// // 試しに一回流す\n// $data = $this->makeData(0, 'userFactory', 1);\n// DB::table('users')->insert($data);\n// $data = $this->makeData(0, 'userDetailFactory', 1);\n// DB::table('user_details')->insert($data);\n//\n// // $this->call(UsersTableSeeder::class);\n// DB::table('users')->truncate();\n// DB::table('user_details')->truncate();\n//\n// for ($i = 0; $i < 40; $i++) {\n// $data = $this->makeData($i, 'userFactory', 2500);\n// DB::table('users')->insert($data);\n// }\n//\n// for ($i = 0; $i < 40; $i++) {\n// $data = $this->makeData($i, 'userDetailFactory', 2500);\n// DB::table('user_details')->insert($data);\n// }\n }", "public function run()\n {\n $this->truncateTables([\n 'users',\n 'categories',\n 'types',\n 'courses',\n 'classrooms',\n 'contents',\n 'companies',\n ]);\n\n $this->call(CompanyTableSeeder::class);\n $this->call(TypeTableSeeder::class);\n $this->call(RoleTableSeeder::class);\n $this->call(CategoryTableSeeder::class);\n $this->call(CoursesTableSeeder::class);\n $this->call(PermissionTableSeeder::class);\n $this->call(ContentTableSeeder::class);\n $this->call(UserTableSeeder::class);\n $this->call(ClassroomTableSeeder::class);\n $this->call(TestTableSeeder::class);\n $this->call(BankTableSeeder::class);\n\n\n // factory(\\App\\User::class, 50)\n // ->create()\n // ->each(function ($user) {\n // // $user->companies()->save();\n // $company = \\App\\Company::inRandomOrder()->first();\n // $user->companies()->attach($company->id);\n // $user->assignRole(['participante']);\n // });\n /*\n factory(\\App\\User::class, 50)\n ->create()\n ->each(function ($user) {\n $user->assignRole(['participante']);\n });*/\n }", "public function run()\n { \n\n $this->call(RoleSeeder::class);\n \n $this->call(UserSeeder::class);\n\n Storage::deleteDirectory('socials-icon');\n Storage::makeDirectory('socials-icon');\n $socials = Social::factory(7)->create();\n\n Storage::deleteDirectory('countries-flag');\n Storage::deleteDirectory('countries-firm');\n Storage::makeDirectory('countries-flag');\n Storage::makeDirectory('countries-firm');\n $countries = Country::factory(18)->create();\n\n // Se llenan datos de la tabla muchos a muchos - social_country\n foreach ($countries as $country) {\n foreach ($socials as $social) {\n\n $country->socials()->attach($social->id, [\n 'link' => 'https://www.facebook.com/ministeriopalabrayespiritu/'\n ]);\n }\n }\n\n Person::factory(50)->create();\n\n Category::factory(7)->create();\n\n Video::factory(25)->create(); \n\n $this->call(PostSeeder::class);\n\n Storage::deleteDirectory('documents');\n Storage::makeDirectory('documents');\n Document::factory(25)->create();\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n User::truncate();\n Question::truncate();\n Option::truncate();\n// Answer::truncate();\n Quiz::truncate();\n QuizQuestion::truncate();\n\n //for admin\n $admin = factory(User::class)->create([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'is_admin' => 1,\n ]);\n\n //for user\n $user = factory(User::class)->create([\n 'name' => 'User',\n 'email' => '[email protected]',\n ]);\n\n factory(Question::class, 100)->create()->each(function ($question) {\n factory(Option::class, mt_rand(2, 4))->create([\n 'question_id' => $question->id,\n ]);\n });\n\n factory(Quiz::class, 10)->create()->each(function ($quiz) {\n\n factory(QuizQuestion::class, mt_rand(5, 10))->create();\n });\n\n\n }", "public function run()\n {\n $this->call([\n SiteSettingsSeeder::class,\n LaratrustSeeder::class,\n CountrySeeder::class,\n GovernorateSeeder::class,\n FaqSeeder::class,\n SitePageSeeder::class,\n UsersSeeder::class,\n ]);\n\n Country::whereiso(\"EG\")->update(['enable_shipping' => true]);\n\n factory(User::class, 400)->create();\n\n Category::create([\n 'en' => [\n 'name' => \"cake tools\"\n ]\n ]);\n\n Category::create([\n 'en' => [\n 'name' => \"Party Supplies\"\n ]\n ]);\n\n $this->call([\n ProductCategorySeeder::class,\n ProductSeeder::class\n ]);\n }", "public function run()\n {\n $this->call(PermissionsTableSeeder::class);\n\n if (App::environment('local')) {\n $this->call(FakeUsersTableSeeder::class);\n $this->call(FakeArticlesTableSeeder::class);\n $this->call(FakeEventsTableSeeder::class);\n }\n }", "public function run()\n {\n Model::unguard();\n\n $this->call(CategoryTypesTableSeeder::class);\n $this->call(CategoryTableSeeder::class);\n $this->call(AccountTypesTableSeeder::class);\n $this->call(TransactionTypesTableSeeder::class);\n\n if (App::environment() !== 'production') {\n $this->call(UserTableSeeder::class);\n $this->call(AccountBudgetTableSeeder::class);\n $this->call(TransactionTableSeeder::class);\n }\n\n Model::reguard();\n }", "public function run()\n {\n User::truncate();\n Product::truncate();\n User::forceCreate([\n 'name' => 'foo',\n 'email' => '[email protected]',\n 'password' => bcrypt('password'),\n ]);\n factory(User::class, 5)->create();\n factory(Product::class, 5)->create();\n }", "public function run()\n {\n $faker = Faker::create();\n\n // $this->call(UsersTableSeeder::class);\n\n DB::table('posts')->insert([\n 'id'=>str_random(1),\n 'user_id'=> str_random(1),\n 'title' => $faker->name,\n 'body' => $faker->safeEmail,\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s'),\n ]);\n }", "public function run()\n {\n $this->call([UsersTableSeeder::class]);\n $this->call([ContratosTableSeeder::class]);\n $this->call([UsuariosTableSeeder::class]);\n $this->call([UnidadesTableSeeder::class]);\n $this->call([AtestadosTableSeeder::class]);\n }", "public function run()\n {\n Model::unguard();\n\n // $this->call(\"OthersTableSeeder\");\n\n // DB::table('locations')->insert([\n // 'id' => 1,\n // 'name' => 'Default',\n // 'name' => 'district',\n // 'district_id' => 1,\n // 'province_id' => 1,\n // ]);\n }", "public function run()\n {\n $data = include env('DATA_SEED');\n\n \\Illuminate\\Support\\Facades\\DB::table('endpoints')->insert((array)$data);\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n DB::table('admins')->truncate();\n\n for ($i = 0; $i < 10; $i++)\n {\n $faker = Factory::create('en_US');\n $values = [\n 'name' => $faker->userName,\n 'email' => $faker->freeEmail,\n 'password' => bcrypt($faker->password),\n 'phone' => $faker->phoneNumber,\n 'status' => random_int(0,1)\n ];\n admin::create($values);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n\n DB::beginTransaction();\n// $this->seed();\n DB::commit();\n\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n }", "public function run()\n {\n \\DB::table('provinces')->delete();\n \\DB::table('cities')->delete();\n \\DB::table('districts')->delete();\n // import provinces and cities from sql file\n $sqlFile = app_path() . '/../database/raw/administrative_indonesia_without_districts.sql';\n DB::unprepared(file_get_contents($sqlFile));\n $this->command->info('Successfully seed Provinces and Cities!');\n\n // import districts with latitude and longitude from csv file\n $csvFile = app_path() . '/../database/raw/administrative_indonesia_districts_with_lat_lng.csv';\n $districts = $this->csvToArray($csvFile);\n // check if lat lng exists\n foreach ($districts as $i => $d) {\n if ($d['latitude'] == '') $districts[$i]['latitude'] = 0;\n if ($d['longitude'] == '') $districts[$i]['longitude'] = 0;\n }\n // insert it\n $insert = District::insert($districts);\n if ($insert) $this->command->info('Successfully seed Districts!');\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n $this->call(RegionsTableSeeder::class);\n $this->call(ProvincesTableSeeder::class);\n $this->call(DistrictsTableSeeder::class);\n $this->call(SubDistrictsTableSeeder::class);\n $this->call(PostcodesTableSeeder::class);\n\n if (env('APP_ENV') !== 'production') {\n // Wipe up 5 churches, and each church has 5 cells, and each cell has 20 members associated with.\n // In other word, we wipe up 500 church members.\n for ($i = 0; $i < 2; $i++) {\n $church = factory(\\App\\Models\\Church::class)->create();\n\n $church->areas()->saveMany(factory(\\App\\Models\\Area::class, 2)->create([\n 'church_id' => $church->id\n ])->each(function($area) {\n $area->cells()->saveMany(factory(\\App\\Models\\Cell::class, 2)->create([\n 'area_id' => $area->id\n ])->each(function($cell) {\n $cell->members()->saveMany(factory(App\\Models\\Member::class, 10)->create([\n 'cell_id' => $cell\n ]));\n }));\n }));\n }\n }\n }", "public function run()\n {\n User::create([\n 'name' => 'Regynald',\n 'email' => '[email protected]',\n 'password' => Hash::make('123456789'),\n 'url' => 'http://zreyleo-code.com',\n ]);\n\n User::create([\n 'name' => 'Leonardo',\n 'email' => '[email protected]',\n 'password' => Hash::make('123456789')\n ]);\n\n // seed sin model\n /* DB::table('users')->insert([\n 'name' => 'Regynald',\n 'email' => '[email protected]',\n 'password' => Hash::make('123456789'),\n 'url' => 'http://zreyleo-code.com',\n 'created_at' => date('Y-m-d H:i:s'),\n 'updated_at' => date('Y-m-d H:i:s')\n ]); */\n }", "public function run()\n {\n\n DB::table('clients')->delete();\n DB::table('trips')->delete();\n error_log('empty tables done.');\n\n $random_cities = City::inRandomOrder()->select('ar_name')->limit(5)->get();\n $GLOBALS[\"random_cities\"] = $random_cities->pluck('ar_name')->toArray();\n\n $random_airlines = Airline::inRandomOrder()->select('code')->limit(5)->get();\n $GLOBALS[\"random_airlines\"] = $random_airlines->pluck('code')->toArray();\n\n factory(App\\Client::class, 5)->create();\n error_log('Client seed done.');\n\n\n factory(App\\Trip::class, 50)->create();\n error_log('Trip seed done.');\n\n\n factory(App\\Quicksearch::class, 10)->create();\n error_log('Quicksearch seed done.');\n }", "public function run()\n {\n // \\App\\Models\\User::factory(10)->create();\n\n User::factory()->create([\n 'name' => 'Carlos',\n 'email' => '[email protected]',\n 'email_verified_at' => now(),\n 'password' => bcrypt('123456'), // password\n 'remember_token' => Str::random(10),\n ]);\n \n $this->call([PostsTableSeeder::class]);\n $this->call([TagTableSeeder::class]);\n\n }", "public function run()\n {\n $this->environmentPath = env('APP_ENV') === 'production' ||\n env('APP_ENV') === 'qa' ||\n env('APP_ENV') === 'integration' ?\n 'Production':\n 'local';\n //disable FK\n Model::unguard();\n DB::statement(\"SET session_replication_role = 'replica';\");\n\n // $this->call(HrEmployeeTableSeeder::class);\n $this->call(\"Modules\\HR\\Database\\Seeders\\\\$this->environmentPath\\HrEmployeePosTableSeeder\");\n // $this->call(HrEmployeePresetsDiscountTableSeeder::class);\n\n // Enable FK\n DB::statement(\"SET session_replication_role = 'origin';\");\n Model::reguard();\n }", "public function run()\n {\n $this->call(RoleTableSeeder::class);\n $this->call(UserTableSeeder::class);\n \n factory('App\\Cat', 5)->create();\n $tags = factory('App\\Tag', 8)->create();\n\n factory(Post::class, 15)->create()->each(function($post) use ($tags){\n $post->comments()->save(factory(Comment::class)->make());\n $post->tags()->attach( $tags->random(mt_rand(1,4))->pluck('id')->toArray() );\n });\n }", "protected static function seed()\n {\n foreach (self::fetch('database/seeds', false) as $file) {\n Bus::need($file);\n }\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n $faker = F::create('App\\Proovedores');\n for($i=0; $i < 10; $i++){\n DB::table('users')->insert([\n 'usuario' => $i,\n 'password' => $i,\n 'email' => $faker->email,\n ]);\n }\n DB::statement('SET FOREIGN_KEY_CHECKS=1;');\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0;');\n // Delete all records.\n DB::table('users')->delete();\n // Reset AUTO_INCREMENT.\n DB::table('users')->truncate();\n\n // Dev user.\n App\\Models\\User::create([\n 'email' => '[email protected]',\n 'password' => '$2y$10$t6q81nz.XrMrh20NHDvxUu/szwHBwgzPd.01e8uuP0qVy0mPa6H/e',\n 'first_name' => 'L5',\n 'last_name' => 'App',\n 'username' => 'l5-app',\n 'is_email_verified' => 1,\n ]);\n\n // Dummy users.\n TestDummy::times(10)->create('App\\Models\\User');\n }", "public function run()\n {\n // Let's truncate our existing records to start from scratch.\n User::truncate();\n\n $faker = \\Faker\\Factory::create();\n\n // We did this for test purposes. Shouldn't be doing this for production\n $password = Hash::make('123456');\n\n User::create([\n 'name' => 'Administrator',\n 'email' => '[email protected]',\n 'password' => $password,\n ]);\n }", "public function run()\n {\n Model::unguard();\n \n factory('App\\User','admin')->create();\n factory('App\\Evento',100)->create();\n //factory('App\\User','miembro',10)->create();\n factory('App\\Telefono',13)->create();\n factory('App\\Notificacion',10)->create();\n factory('App\\Rubro',10)->create();\n factory('App\\Tecnologia',10)->create();\n factory('App\\Cultivo',10)->create();\n factory('App\\Etapa',10)->create();\n factory('App\\Variedad',10)->create();\n factory('App\\Caracteristica',10)->create();\n factory('App\\Practica',30)->create();\n factory('App\\Tag',15)->create();\n // $this->call(PracticaTableSeeder::class);\n $this->call(TrTableSeeder::class);\n $this->call(MesTableSeeder::class);\n $this->call(SemanasTableSeeder::class);\n $this->call(PsTableSeeder::class);\n $this->call(MsTableSeeder::class);\n $this->call(CeTableSeeder::class);\n $this->call(CvTableSeeder::class);\n $this->call(PtSeeder::class);\n \n\n Model::unguard();\n }", "public function run() {\n $this->call(UserSeeder::class);\n $this->call(PermissionSeeder::class);\n $this->call(CreateAdminUserSeeder::class);\n // $this->call(PhoneSeeder::class);\n // $this->call(AddressSeeder::class);\n\n $this->call(ContactFormSeeder::class);\n //$this->call(ContactSeeder::class);\n\n User::factory()->count(20)->create()->each(function ($user) {\n // Seed the relation with one address\n $address = Address::factory()->make();\n $user->address()->save($address);\n\n // Seed the relation with one phone\n $phone = Phone::factory()->make();\n $user->phone()->save($phone);\n\n // Seed the relation with 15 contacts\n $contact = Contact::factory()->count(25)->make();\n $user->contacts()->saveMany($contact);\n });\n }", "public function run()\n {\n $this->call(UsersSeeder::class);\n User::factory(2)->create();\n Company::factory(2)->create();\n\n }", "public function run()\n {\n DB::statement('SET FOREIGN_KEY_CHECKS=0');\n Activity::truncate();\n User::truncate();\n DB::statement('SET FOREIGN_KEY_CHECKS=1');\n $this->call(UserTableSeeder::class);\n $this->call(ActivityTableSeeder::class);\n }", "public function run()\n {\n $this->call(CategoriasTableSeeder::class);\n $this->call(UfsTableSeeder::class);\n $this->call(UsersTableSeeder::class);\n $this->call(UserTiposTableSeeder::class);\n factory(App\\User::class, 2)->create();\n/* factory(App\\Models\\Categoria::class, 20)->create();*/\n/* factory(App\\Models\\Anuncio::class, 50)->create();*/\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n\n DB::statement('SET FOREIGN_KEY_CHECKS = 0');\n\n \\App\\User::truncate();\n \\App\\Category::truncate();\n \\App\\Product::truncate();\n \\App\\Transaction::truncate();\n DB::table('category_product')->truncate();\n\n \\App\\User::flushEventListeners();\n \\App\\Category::flushEventListeners();\n \\App\\Product::flushEventListeners();\n \\App\\Transaction::flushEventListeners();\n\n\n $usersQuentity = 1000;\n $categoriesQuentity = 30;\n $productsQuentity = 1000;\n $transactionsQuentity = 1000;\n\n factory(\\App\\User::class, $usersQuentity)->create();\n factory(\\App\\Category::class, $categoriesQuentity)->create();\n factory(\\App\\Product::class, $productsQuentity)->create()->each(\n function ($product){\n $categories = \\App\\Category::all()->random(mt_rand(1, 5))->pluck('id');\n\n $product->categories()->attach($categories);\n }\n );\n factory(\\App\\Transaction::class, $transactionsQuentity)->create();\n\n }", "public function run()\n {\n Eloquent::unguard();\n \n $this->call('AdminMemberTableSeeder');\n $this->call('BankInfoTableSeeder');\n $this->call('LocationLookUpTableSeeder');\n $this->call('OrderStatusTableSeeder');\n $this->call('AdminRoleTableSeeder');\n\n }", "public static function setUpBeforeClass()\n {\n parent::setUpBeforeClass();\n $app = require __DIR__ . '/../../bootstrap/app.php';\n /** @var \\Pterodactyl\\Console\\Kernel $kernel */\n $kernel = $app->make(Kernel::class);\n $kernel->bootstrap();\n $kernel->call('migrate:fresh');\n\n \\Artisan::call('db:seed');\n }", "public function run()\n {\n Model::unguard();\n\n if( !User::where('email', '[email protected]')->count() ) {\n User::create([\n 'nombre'=>'Nick'\n ,'apellidos'=>'Palomino'\n ,'email'=>'[email protected]'\n ,'password'=> Hash::make('1234567u')\n ,'celular'=>'966463589'\n ]);\n }\n\n $this->call('CategoriaTableSeeder');\n $this->call('WhateverSeeder');\n $this->call('ProductTableSeeder');\n }", "public function run()\n {\n // $this->call(UsersTableSeeder::class);\n // $this->call(QuestionTableSeed::class);\n\n $this->call([\n QuestionTableSeed::class,\n AlternativeTableSeed::class,\n ScheduleActionTableSeeder::class,\n UserTableSeeder::class,\n CompanyClassificationTableSeed::class,\n ]);\n // DB::table('clients')->insert([\n // 'name' => 'Empresa-02',\n // 'email' => '[email protected]',\n // 'password' => bcrypt('07.052.477/0001-60'),\n // ]);\n }", "public function run()\n {\n Model::unguard();\n\n $this->command->info('seed start!');\n\n // 省市县\n $this->call('RegionTableSeeder');\n // 用户、角色\n $this->call('UserTableSeeder');\n // 权限\n $this->call('PurviewTableSeeder');\n // 博文分类\n $this->call('CategoryTableSeeder');\n // 博文、评论、标签\n $this->call('ArticleTableSeeder');\n // 心情\n $this->call('MoodTableSeeder');\n // 留言\n $this->call('MessageTableSeeder');\n // 文件\n $this->call('StorageTableSeeder');\n\n $this->command->info('seed end!');\n }", "public function run()\n {\n DB::table('users')->insert([\n 'name' => 'Admin',\n 'email' => '[email protected]',\n 'avatar' => \"avatar\",\n 'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi',\n ]);\n $this->call(CategorySeeder::class);\n // \\App\\Models\\Admin::factory(1)->create();\n \\App\\Models\\User::factory(10)->create();\n // \\App\\Models\\Category::factory(50)->create();\n \\App\\Models\\PetComment::factory(50)->create();\n $pets = \\App\\Models\\Pet::factory(50)->create();\n foreach ($pets as $pet) {\n \\App\\Models\\PetTag::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\PetPhotoUrl::factory(1)->create(['pet_id' => $pet->id]);\n \\App\\Models\\Order::factory(1)->create(['pet_id' => $pet->id]);\n };\n }", "public function run()\n {\n $this->call(RolesDatabaseSeeder::class);\n $this->call(UsersDatabaseSeeder::class);\n $this->call(LocalesDatabaseSeeder::class);\n $this->call(MainDatabaseSeeder::class);\n }", "public function run()\n {\n\n Schema::disableForeignKeyConstraints(); //in order to execute truncate before seeding\n\n $this->call(UsersTableSeeder::class);\n $this->call(PostCategoriesSeeder::class);\n $this->call(TagsSeeder::class);\n $this->call(PostsSeeder::class);\n\n Schema::enableForeignKeyConstraints();\n\n\n }", "public function run()\n {\n // DB::table('users')->insert([\n // ['id'=>1, 'email'=>'nhat','password'=>bcrypt(1234), 'lever'=>0]\n // ]);\n // $this->call(UsersTableSeeder::class);\n // $this->call(CatTableSeeder::class);\n // $this->call(TypeTableSeeder::class);\n // $this->call(AppTableSeeder::class);\n // $this->call(GameTableSeeder::class);\n \n \n }", "public function run()\n {\n //$this->call(UsersTableSeeder::class);\n $this->call(rootSeed::class);\n factory(App\\Models\\Egresado::class,'hombre',15)->create();\n factory(App\\Models\\Egresado::class,'mujer',15)->create();\n factory(App\\Models\\Administrador::class,5)->create();\n factory(App\\Models\\Notificacion::class,'post',10)->create();\n factory(App\\Models\\Notificacion::class,'mensaje',5)->create();\n factory(App\\Models\\Egresado::class,'bajaM',5)->create();\n factory(App\\Models\\Egresado::class,'bajaF',5)->create();\n factory(App\\Models\\Egresado::class,'suscritam',5)->create();\n factory(App\\Models\\Egresado::class,'suscritaf',5)->create();\n }", "public function run()\n {\n $this->seedUsers();\n $this->seedAdmins();\n $this->seedMeals();\n\n $this->seedOrder();\n $this->seedOrderlist();\n\n $this->seedReload();\n }", "public function run()\n\t{\n\t\t//composer require fzaninotto/faker\n\t\t\n\t\t$this->call(populateAllSeeder::class);\n\t\t\n\t}", "public function run()\n {\n $this->call([\n UserSeeder::class,\n ]);\n\n User::factory(20)->create();\n Author::factory(20)->create();\n Book::factory(60)->create();\n }", "public function run()\n {\n $this->call(CategoryTableSeeder::class);\n $this->call(ProductTableSeeder::class);\n\n \t\t\n\t\t\tDB::table('users')->insert([\n 'first_name' => 'Ignacio',\n 'last_name' => 'Garcia',\n 'email' => '[email protected]',\n 'password' => bcrypt('123456'),\n 'role' => '1',\n 'avatar' => 'CGnABxNYYn8N23RWlvTTP6C2nRjOLTf8IJcbLqRP.jpeg',\n ]);\n }", "public function run()\n {\n Model::unguard();\n\n $faker =Faker\\Factory::create();\n\n // $this->call(UserTableSeeder::class);\n\n $this->seedTasks($faker);\n $this->seedTags($faker);\n\n Model::reguard($faker);\n }", "public function run()\n {\n $this->call(UsersTableSeeder::class);\n\n $categories = factory(App\\Models\\Category::class, 10)->create();\n\n $categories->each(function ($category) {\n $category\n ->posts()\n ->saveMany(\n factory(App\\Models\\Post::class, 3)->make()\n );\n });\n }", "public function run()\n {\n Schema::disableForeignKeyConstraints();\n\n $this->call([\n CountriesSeeder::class,\n ProvincesSeeder::class,\n SettingsSeeder::class,\n AdminsTableSeeder::class,\n ]);\n }" ]
[ "0.8064933", "0.7848158", "0.7674873", "0.724396", "0.7216743", "0.7132209", "0.70970356", "0.70752203", "0.704928", "0.699208", "0.6987078", "0.69839287", "0.6966499", "0.68990964", "0.6868679", "0.68468624", "0.68307716", "0.68206114", "0.6803113", "0.6803113", "0.6801801", "0.6789746", "0.6788733", "0.6788008", "0.6786291", "0.67765796", "0.67742485", "0.677106", "0.67651874", "0.6761959", "0.675823", "0.67337847", "0.6733437", "0.67295784", "0.67290515", "0.6724652", "0.67226326", "0.6722267", "0.6721339", "0.6715842", "0.67070943", "0.67060536", "0.67031103", "0.6702514", "0.6702361", "0.67017967", "0.6695973", "0.6693496", "0.66868156", "0.66837406", "0.6678434", "0.66755766", "0.66726524", "0.666599", "0.664943", "0.6640641", "0.663921", "0.66387916", "0.6636016", "0.6633116", "0.6629787", "0.6627134", "0.6625862", "0.661699", "0.66093796", "0.6602538", "0.65996546", "0.659914", "0.6596484", "0.6596383", "0.65922767", "0.65922284", "0.65913564", "0.65889347", "0.65812707", "0.65811145", "0.6579546", "0.6578819", "0.6575912", "0.65749073", "0.6574314", "0.657148", "0.65696406", "0.6568972", "0.65624833", "0.6560332", "0.6559092", "0.6557491", "0.65555155", "0.6554255", "0.65509576", "0.6548099", "0.65479296", "0.6545845", "0.65443295", "0.65434265", "0.65432936", "0.654295", "0.65426385", "0.6541781", "0.6539325" ]
0.0
-1
get menu match with current url
public function getMenuByModelName($modelName){ $amenu = $this->table('permission') ->where('showInMenu=1 and type="backend_menu" and `level` like (SELECT CONCAT(p2.`level`,",","%") as `level` FROM permission p1 LEFT JOIN permission p2 ON p1.pId=p2.id WHERE p1.`name`="'.$modelName.'")') ->order('`level`') ->getField('id,pId,name,title,URL,icon,level'); //dump($this->getlastsql()); return $amenu; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ActiveMenu($requestUri)\n{\n $current_file_name = basename($_SERVER['REQUEST_URI'], \".php\");\n\n if ($current_file_name == $requestUri)\n echo 'class=\"active\"';\n}", "function menu_current_route($pattern,$active_string = 'active',$false=''){\n\n if (is_array($pattern)){\n foreach($pattern as $item){\n if (\\Route::is($item)){\n echo $active_string;\n return;\n }\n }\n }else{\n if (\\Route::is($pattern)){\n echo $active_string;\n return;\n }\n }\n\n return;\n }", "function afficheMenu($menus) {\n\n\n $adresse = $_SERVER[\"REQUEST_URI\"];\n\n foreach ($menus as $key => $infosMenus) {\n\n if ($adresse === $key) {\n echo \"<div class='sousMenuPleineLargeurPageEnCours'> <a href=$key class='lienMenuBlanc''>$infosMenus[0]</a> </div>\";\n } else {\n\n echo \"<div class='sousMenuPleineLargeur'> <a href=$key class='lienMenuBlancPageEnCours'>$infosMenus[0]</a> </div>\";\n }\n\n }\n\n\n}", "public function getMenu();", "private function searchRoute()\r\n {\r\n $currentUrl = self::cleanUrl(self::getCurentUrl());\r\n $activeMethod = self::getActiveMethod();\r\n\r\n foreach (array_reverse($this->routes) as $route) {\r\n if (preg_match('/^'.$route['regex'].'$/', $currentUrl) && $activeMethod === $route['method']) {\r\n $route['active'] = $currentUrl;\r\n return $route;\r\n }\r\n }\r\n }", "private function PH_PageMenu(){\n $site_menu = self::$xvi_api->GetSiteMenu();\n $page_menu = self::$xvi_api->GetPageMenu();\n \n $menu =\"\";\n foreach($site_menu as $menu_item=>$menu_path) {\n if (strcmp($menu_item,$page_menu[\"item\"])) { /*not selected menu item*/\n $menu .= \"<li><a href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n } else { /* it is selected menu*/\n $menu .= \"<li><a class=\\\"sel\\\" href=\\\"\".$menu_path.\"\\\"<span></span>\".$menu_item.\"</a></li>\";\n }\n }\n return $menu;\n }", "private function getMenuName() {\n $menu_name = FALSE;\n $menu_links = $this->menuLinkManager->loadLinksByRoute($this->currentRouteMatch->getRouteName(), $this->currentRouteMatch->getRawParameters()->all());\n if ($menu_links) {\n // Get the deepest link to this page and use that for the subnav.\n // @todo Consider a better approach like excluding utility nav links or\n // sorting them by main menu then footer then utility nav.\n $menu_link = end($menu_links);\n $menu_name = $menu_link->getMenuName();\n }\n\n return $menu_name;\n }", "function active_for($url)\n{\n $url = ltrim(URL::makeRelative($url), '/');\n\n return app()->request->is($url) ? 'selected' : '';\n}", "function menuItemIsActive($string) {\n $first_url_part = menuGetFirstUrlPart();\n\n return ($first_url_part === $string);\n}", "function getCurrentRoute() {\n $santitizedUrl = ''; \n if (!empty($_GET['route'])) {\n $santitizedUrl = trim($_GET['route']);\n }\n \n return $this->getMatchingRoute($santitizedUrl);\n }", "function getMainMenu() {\r\n $links = array();\r\n\r\n //Get nav menu id by name\r\n $menu_name = 'primary';\r\n $locations = get_nav_menu_locations();\r\n $menu_id = (isset($locations[$menu_name])) ? $locations[$menu_name] : 0;\r\n\r\n //Get nav menu items\r\n $items = wp_get_nav_menu_items( $menu_id, array(\r\n 'order' => 'ASC',\r\n 'orderby' => 'menu_order',\r\n 'post_type' => 'nav_menu_item',\r\n 'post_status' => 'publish',\r\n 'output' => ARRAY_A,\r\n 'output_key' => 'menu_order',\r\n 'nopaging' => true,\r\n 'update_post_term_cache' => false )\r\n );\r\n\r\n if(!empty($items)) {\r\n foreach($items as $item) {\r\n //active class for pages, categories\r\n $active = false;\r\n\r\n if( ($item->object == 'page') && (is_page($item->object_id)) ) {\r\n $active = 'active';\r\n } \r\n \r\n $links[$item->ID] = array(\r\n 'title' => $item->title,\r\n 'href' => $item->url,\r\n 'class' => $active\r\n );\r\n }\r\n }\r\n\r\n return $links;\r\n}", "function check_current_menu($page_name, $current_page) {\n\tif ($page_name === $current_page) return \"current\";\n\telse return \"\";\n}", "function menuGetFirstUrlPart() {\n $request_uri = Slim_Http_Uri::getUri();\n $url_parts = explode('/', $request_uri);\n array_shift($url_parts);\n\n return '/'. $url_parts[0];\n}", "static public function getMenu() {\n $query = mysql_query(\"SELECT `menu` FROM `info` WHERE `id` = '0'\");\n return mysql_result($query, 0, 'menu');\n }", "function get_navbar($menu) \n{\n\t$html = \"<nav class='navbar'>\\n\";\n\tforeach($menu['items'] as $item) \n\t{\n\t\tif(basename($_SERVER['SCRIPT_FILENAME']) == $item['url'])\n\t\t{\n\t\t\t$item['class'] .= ' selected'; \n\t\t}\n\t\t$html .= \"<p><a href='{$item['url']}' class='{$item['class']}'>{$item['text']}</a>\\n</p>\";\n\t}\n\t$html .= \"</nav>\";\n\treturn $html;\n}", "protected function getActiveMenu() {\n return $this->activeMenu;\n }", "public function getCurrentRoute(){\n\n\t\t$route = $this->getRouter()->match();\n\t\tif($route){\n\t\t\treturn $route['name'];\n\t\t}\n\t\telse {\n\t\t\treturn false;\n\t\t}\n\t}", "function getMenuPosition();", "function activate_menu($controller) {\n $CI = get_instance();\n // Getting router class to active.\n $class = $CI->router->fetch_class();\n return ($class == $controller) ? 'active' : '';\n }", "function wp_get_nav_menu_name($location)\n {\n }", "function tacensi_get_menu ( $location ) {\n\t$locations = get_nav_menu_locations();\n\t$menu_id = $locations[$location];\n\n\t// bail out if can't find the menu or the items\n\tif ( ! $menu_id ) return false;\n\n\t$nav = wp_get_nav_menu_items( $menu_id );\n\tif ( ! $nav ) return false;\n\n\t// menu_output\n\t$menu_out = '<nav class=\"site-nav\">' . \"\\n\";\n\n\t// current URL for active class\n\t$current_url = home_url() . $_SERVER[\"REQUEST_URI\"];\n\n\t// actual nav items\n\tforeach ( $nav as $item ) {\n\t\t$menu_out .= '<a href=\"' . $item->url . '\" ' .\n\t\t\t'class=\"site-nav__item';\n\n\t\tif ( strstr( $current_url, $item->url ) ) {\n\t\t\t$menu_out .= ' current';\n\t\t}\n\n\t\t$menu_out .= '\">' . $item->title . '</a>' . \"\\n\";\n\t}\n\n\t$menu_out .= '</nav>' . \"\\n\";\n\n\techo $menu_out;\n}", "public function menu_get_router()\n {\n return menu_get_router();\n }", "function active_menu($controller) {\n\t\t$CI =& get_instance();\n\n\t\t$query = $CI->db->query(\"\n\t\t\tSELECT *\n\t\t\tFROM \tmenu\n\t\t\tWHERE\n\t\t\t\t\tcontroller = '$controller'\n\t\t\");\n\t\t$active_menu = array();\n\t\tif ($query->num_rows()) {\n\t\t\t$active_menu = $query->row_array();\n\t\t}\n\t\treturn $active_menu;\n\t}", "function display_menu()\n{\n global $menu_options;\n foreach ($menu_options as $key => $value)\n {\n if ($value[2])\n echo \"<li><a href=\\\"index.php?content=$key\\\">\".$value[0].\"</a></li>\";\n }\n}", "private function getCurrentMenuName(){\n \n if(!$this->currentmenuname)\n $this->setCurrentMenuName();\n \n return $this->currentmenuname;\n \n }", "function get_nav_menu_locations()\n {\n }", "public function menu() {\n\t\treturn $this->getteams();\n\t}", "public function find_current_route()\n {\n\n if ( false !== $key = \\Chocolatine\\array_find( $this->routes, 'route', $this->current_pattern ) ) {\n $this->current_route = $this->routes[ $key ];\n }\n\n return $this->current_route;\n }", "function smarty_function_menu($params, &$smarty) {\n\tif ($params['admin']) {\n\t\treturn adminMenu($params, $smarty);\n\t} else if($params['company']) {\n\t\treturn companyMenu($params, $smarty);\n\t} else {\n\t\treturn frontendMenu($params, $smarty);\n\t}\n}", "function class_active($url) {\r\n $page = strrchr($_SERVER['PHP_SELF'], '/');\r\n if($page == $url) {\r\n return ' active ';\r\n }\r\n}", "public function MenuCurrentItem() {\n return $this->MainMenu()->find('Code', 'KapostAdmin');\n }", "function activeLink($page){\n\n\t\t/* Compare $page to $_GET */\n\t\tswitch($page){\n\t\tcase 'home':\n\t\t\tif(empty($_GET) || isset($_GET['home'])){\n\t\t\t\techo ' active';\n\t\t\t}\n\t\t\tbreak;\n\t\tcase 'about';\n\t\t\tif(isset($_GET['about'])){\n\t\t\t\techo ' active';\n\t\t\t}\n\t\t\tbreak;\n\t\tcase 'recent';\n\t\t\tif(isset($_GET['recent'])){\n\t\t\t\techo ' active';\n\t\t\t}\n\t\t\tbreak;\n\t\t}\n\t}", "function updateMenu($navLink)\n{\n // checking if the URI matches the passed in navigation link and if so, \n\t// return class = active which highlights the tab on the navigation bar. \n if (URI == $navLink)\n \t\treturn 'class=\"active\"';\n\n // checking if the navigation link is a substring of the URI and if so, return class = active which highlights \n\t// the tab on the navigation bar. \n // an example of this is index.php?category=none\n\n if (strpos(URI, $navLink) !== false)\n {\n return \"class='active'\";\n }\n}", "function nav_is($url)\n{\n $current = URL::makeAbsolute(URL::getCurrentWithQueryString());\n\n return $url === $current || Str::startsWith($current, $url . '/');\n}", "function getMenu()\n {\n return $this->getAttribute(\"menu\");\n }", "public function menu_ExtractBranch( $request, $type= \"module\", $menu= \"\" )\n\t\t{\n\t\t\tif ( $type == 'module')\n\t\t\t{\n\t\t\t\t$menu= ( empty($menu) ) ? $this->menu : $menu;\n\t\t\t\t$count= 0;\n\t\t\t\t// $this->echo_r( $this->menu[0] );\n\t\t\t\tif ( count( $menu ) > 0 )\n\t\t\t\tforeach ( $this->menu[0] as $item )\n\t\t\t\t{\n\t\t\t\t\tif ( $item['sys_name'] == $request )\n\t\t\t\t\t\treturn $menu[0][$count];\n\t\t\t\t\t$count++;\n\t\t\t\t}\n\t\t\t}\n\t\t\telseif ( $type == 'branch' )\n\t\t\t{\n\t\t\t\t$req= explode(\"-\", $request);\n\t\t\t\t$menu= $this->menu[0][$req[0]];\n\t\t\t\t\n\t\t\t\tif ( count($req) == 1 )\n\t\t\t\t{\n\t\t\t\t\treturn $menu;\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$children= $menu['children'];\n\t\t\t\t\t$req= array_slice( $req, 1 );\n\t\t\t\t\t$count= 0;\n\t\t\t\t\tforeach ( $req as $r )\n\t\t\t\t\t{\n\t\t\t\t\t\t$count++;\n\t\t\t\t\t\t$last= ( count($req) == $count ) ? true : false;\n\t\t\t\t\t\t$children= $this->menu_GrabChild( $r, $children, $last );\n\t\t\t\t\t}\n\t\t\t\t\treturn ( is_array($children) ) ? $children : false;\n\t\t\t\t}\n\t\t\t}\n\t\t\n\t\t}", "public function getCurentPage()\n\t{\n\t\t$pattern = '#[a-z]*.php$#';\n\t\tpreg_match($pattern, $_SERVER['REQUEST_URI'], $current_page);\n\t\tif(isset($current_page) && $current_page){\n\t\t\tforeach($current_page as $cp){\n\t\t\t\tswitch($cp){\n\t\t\t\t\tcase 'index.php': \n\t\t\t\t\treturn 'index';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'rooms.php':\n\t\t\t\t\treturn 'rooms';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'chat.php':\n\t\t\t\t\treturn 'chat';\n\t\t\t\t\tbreak;\n\t\t\t\t\tcase 'contact.php': \n\t\t\t\t\treturn 'contact';\n\t\t\t\t\tbreak;\n\t\t\t\t\tdefault: \t\n\t\t\t\t\treturn 'other';\n\t\t\t\t}\n\t\t\t}\n\t\t}else{\n\t\t\t$this->goToIndex();\n\t\t}\n\t}", "function match_against_router() {\n\n require_once APP_PATH . '/config/routing.php';\n\n if (isset($routes)) {\n $base_url = $this->get_base_url();\n\n foreach ($routes as $key => $val) {\n if ($key == $base_url) {\n return $val;\n }\n }\n }\n return false;\n }", "public function getPageMenu() {\n\t\t\tglobal $factory_impressive_page_menu;\n\n\t\t\treturn $factory_impressive_page_menu[ $this->getMenuScope() ];\n\t\t}", "function get_menu($param = NULL)\n\t{\n\t\tif (isset($param[\"icon\"]) and substr($param[\"icon\"], 0, 4) === \"http\")\n\t\t{\n\t\t\t$icon = $param[\"icon\"];\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$icon_name = empty($param[\"icon\"]) ? \"cog\" : $param[\"icon\"];\n\t\t\t$icon = icons::get_std_icon_url($icon_name);\n\t\t}\n\n\n\t\t$is = \"\";\n\t\tforeach($this->menus as $parent => $menudata)\n\t\t{\n\t\t\t$is .= '<div id=\"'.$parent.'\" class=\"menu\" onmouseover=\"menuMouseover(event)\">'.\"\\n${menudata}</div>\\n\";\n\t\t};\n\t\t$this->vars(array(\n\t\t\t\"ss\" => $is,\n\t\t\t\"menu_id\" => $this->menu_id,\n\t\t\t\"menu_icon\" => $icon,\n\t\t\t\"alt\" => isset($param[\"alt\"]) ? $param[\"alt\"] : null\n\t\t));\n\n\t\tif (!empty($param[\"text\"]))\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"text\" => $param[\"text\"]\n\t\t\t));\n\t\t\t$this->vars(array(\n\t\t\t\t\"HAS_TEXT\" => $href_ct = $this->parse(\"HAS_TEXT\")\n\t\t\t));\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"HAS_ICON\" => $href_ct = $this->parse(\"HAS_ICON\")\n\t\t\t));\n\t\t}\n\n\t\tif (!empty($param[\"is_toolbar\"]))\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"IS_TOOLBAR\" => $this->parse(\"IS_TOOLBAR\")\n\t\t\t));\n\t\t}\n\t\t\n\t\tif (aw_template::bootstrap())\n\t\t{\n\t\t\t$this->vars(array(\n\t\t\t\t\"DROPDOWN\" => $this->__parse_dropdown($this->menu_id),\n\t\t\t));\n\t\t}\n\n\t\tif (is_array($param) && !empty($param[\"load_on_demand_url\"]))\n\t\t{\n\t\t\tstatic $lod_num;\n\t\t\t$lod_num++;\n\t\t\treturn \"<div id='lod_\".$this->menu_id.\"'><a href='javascript:void(0);' onClick='tb_lod\".$lod_num.\"()' class='nupp'>$href_ct</a></div>\n\t\t\t<script language=javascript>\n\t\t\tfunction tb_lod\".$lod_num.\"()\n\t\t\t{\n\t\t\t\tel = document.getElementById(\\\"lod_\".$this->menu_id.\"\\\");\n\t\t\t\tel.innerHTML=aw_get_url_contents(\\\"\".$param[\"load_on_demand_url\"].\"\\\");\n\t\t\t\tnhr=document.getElementById(\\\"href_\".$this->menu_id.\"\\\");\n\t\t\t\tif (document.createEvent) {evObj = document.createEvent(\\\"MouseEvents\\\");evObj.initEvent( \\\"click\\\", true, true );nhr.dispatchEvent(evObj);}\n\t\t\t\telse {\n\t\t\t\t\tnhr.fireEvent(\\\"onclick\\\");\n\t\t\t\t}\n\t\t\t}\n\t\t\t</script>\n\t\t\t\";\n\t\t}\n\n\t\treturn $this->parse();\n\t}", "function get_active_menu (string $page, string $page_active, string $class_active = \"active\") {\n return $page == $page_active ? $class_active : \"\";\n }", "function get_active_menu (string $page, string $page_active, string $class_active = \"active\") {\n return $page == $page_active ? $class_active : \"\";\n }", "function route_match() {\n global $route;\n global $html;\n global $config;\n global $matched_route;\n\n $url = explode('index.php', $_SERVER['REQUEST_URI']);\n $url = @str_replace('.', '', substr($url[1], 1));\n if(strpos($url, '?') !== false) {\n $url = explode('?', $url);\n $url = $url[0];\n }\n\n if(!$url) {\n $matched_route = 'ROOT';\n require_once __DIR__ . '/app/' . $route['ROOT'];\n return true;\n }\n\n if(substr($url, -1) == '/') {\n $url = substr($url, 0, -1);\n }\n\n // Check for simple route match\n if(array_key_exists($url, $route)) {\n $matched_route = $url;\n require_once __DIR__ . '/app/' . $route[$url];\n return true;\n }\n\n // Check for regex\n foreach($route as $r => $page) {\n $matches = array();\n\n if(preg_match('#' . $r . '$#', $url, $matches)) {\n array_shift($matches);\n\n $_GET['custom_arguments'] = $matches;\n\n $matched_route = $r;\n require_once __DIR__ . '/app/' . $page;\n return true;\n }\n }\n\n return false;\n}", "function url_menu(string $slug) : string\n{\n return \\menu_page_url($slug, false);\n}", "function mnu_EchoMainMenu($selmenuid)\n{\n global $menu;\n for ($i = 0; $i < count($menu); $i++) {\n if ($menu[$i]['visible'] == true) {\n if (!isset($menu[$i]['newwindow']))\n $menu[$i]['newwindow'] = false;\n if ($menu[$i]['newwindow'] == true)\n $target_blank = \"target='_blank'\";\n else\n $target_blank = \"\";\n\n if ($menu[$i]['siteid'] == $selmenuid || is_array($menu[$i]['siteid']) && in_array($selmenuid, $menu[$i]['siteid'])) {\n echo '<li><a class=\"selected bg-green06\" href=\"' . $menu[$i]['filename'] . '\">' . htmlspecialchars($menu[$i]['menustring'], ENT_COMPAT, 'UTF-8') . '</a></li>';\n } else {\n echo '<li><a ' . $target_blank . ' href=\"' . $menu[$i]['filename'] . '\">' . htmlspecialchars($menu[$i]['menustring'], ENT_COMPAT, 'UTF-8') . '</a></li>';\n }\n }\n }\n}", "function identifyPage() {\n//\t\t$req_uri = $_SERVER['REQUEST_URI'];\n//\t\tprint \"init\";\n\t\t$query = new Query();\n\t\tif($query->sql(\"SELECT id, relation, name, url FROM \" . UT_MEN . \" WHERE url LIKE '%\".$this->url.\"%'\")) {\n\t\t\t$item->id = $query->getQueryResult(0, \"id\");\n\t\t\t$item->name = $this->translate($query->getQueryResult(0, \"name\"));\n\n\t\t\t$item->url = str_replace(FRAMEWORK_PATH.\"/admin\", \"\", $this->url);\n\t\t\t$item->url = str_replace(GLOBAL_PATH.\"/admin\", \"\", $item->url);\n\t\t\t$item->url = str_replace(REGIONAL_PATH.\"/admin\", \"\", $item->url);\n\n//\t\t\t$item->url = ereg_replace(FRAMEWORK_PATH.\"/admin|\".GLOBAL_PATH.\"/admin|\".REGIONAL_PATH.\"/admin\", \"\", $query->getQueryResult(0, \"url\"));\n\t\t\tarray_unshift($this->trail, $item);\n\t\t\t$relation = $query->getQueryResult(0, \"relation\");\n\t\t\tif($relation) {\n\t\t\t\t$this->pageTrail($relation);\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "function activation($in) {\n $directoryURI = $_SERVER['PHP_SELF'];\n $path = parse_url($directoryURI, PHP_URL_PATH);\n $components = explode('/', $path);\n $first_part = $components[1];\n\n if($first_part == $in) {\n echo 'class=\"active\"';\n }\n}", "function url_current()\n{\n return url(@$_GET['GET_VARS']);\n}", "function roots_cpt_active_menu($menu) {\n if ('base_service' === get_post_type()) {\n $menu = str_replace('active', '', $menu);\n $menu = str_replace('menu-services', 'menu-services active', $menu);\n }\n if ('base_portfolio' === get_post_type()) {\n $menu = str_replace('active', '', $menu);\n $menu = str_replace('menu-portfolio', 'menu-portfolio active', $menu);\n }\n return $menu;\n}", "public function getQueryMenus();", "public static function currentRouteName()\n {\n $uri = explode('?', $_SERVER['REQUEST_URI'])[0];\n\n foreach (self::$routes as $key => $val) \n {\n if ($uri === $val['url']) \n {\n return $key;\n }\n }\n }", "public function searchMenu()\n\t{\n\t\t// Ajax only controller\n\t\tif (!Request::ajax()) return Response::notFound();\n\n\t\t$post = Post::find(Config::get('mrcore.searchmenu'));\n\t\tif (!isset($post)) return Response::notFound();\n\n\t\t// Parse Post Now!\n\t\t$post->parse();\n\n\t\treturn $post->content;\n\t}", "function echoUrlForSubMenu ($subIndex) {\n //get current url\n $curUrl = $_SERVER[\"REQUEST_URI\"];\n //find where the end of the sub menu url is\n $endPosition = strpos($curUrl, $subIndex)+ strlen($subIndex);\n //remove the last part of the url + append the \"/\"\n $subUrl = substr($curUrl, 0, $endPosition) . \"/\";\n //return it\n return $subUrl;\n}", "function getClass($strUrl) {\n\n echo $strUrl == $_SERVER['REQUEST_URI'] ? 'active' : '';\n}", "static function getUserMenu()\r\n {\r\n if(isset($_SESSION[Session::MENU]))\r\n return $_SESSION[Session::MENU];\r\n else return null;\r\n }", "function drush_drushutils_find_callback() {\n $matches = array();\n $match_type = drush_get_option('match');\n\n $args = drush_get_arguments();\n $path_to_find = $args[1];\n\n foreach (module_implements('menu') as $module) {\n $menu_callbacks = module_invoke($module, 'menu');\n if (!empty($menu_callbacks)) {\n foreach ($menu_callbacks as $path => $callback) {\n switch ($match_type) {\n case 'partial':\n if (FALSE !== strpos($path, $path_to_find)) {\n $matches[] = array($module, $path);\n }\n break;\n\n case 'full':\n default:\n if ($path == $path_to_find) {\n $matches[] = array($module, $path);\n continue 2;\n }\n break;\n }\n }\n }\n }\n _drushutils_output_results($matches, $match_type);\n}", "function get_menu_items($title) {\n\t$items['home.php'] = \"Home\";\n\t$items['play_trivia.php'] = \"Play Trivia\";\n\t$items['view_leaders.php'] = \"View Leader Board\";\n\t$items['rank_question.php'] = \"Rank Questions\";\n\t$items['insert_question.php'] = \"Insert Question\";\n\t\n\tif ($_SESSION['admin']) {\t\n\t\t$items['insert_user.php'] = \"Delete User\";\n\t\t$items['delete_question.php'] = \"Delete Question\";\n\t}\t\t\n\t$items['logout.php'] = \"Logout\";\n\t\t\n\tforeach ($items as $key=>$value) {\n\t\t$active = '';\n\t\tif ($value==$title) $active = \"active\";\n\t\t$menu_items .= '\n\t\t <li class=\"nav-item\">\n\t\t <a class=\"nav-link '.$active.'\" href=\"'.$key.'\">'.$value.'</a>\n\t\t </li>\n\t\t';\n\t}\n\treturn $menu_items;\n}", "function getMenuTitle();", "public static function getMenu()\n\t{\n\t\treturn self::$menu;\n\t}", "function tieneAcceso($menu)\n{\n $ci = get_instance();\n $controlador = $ci->uri->segment(1);\n //$metodo = $ci->uri->segment(2);\n\n // Verificamos si la se esta accediento a un metodo de un controlador de\n // vista para compara con los slug registrados\n// if ($metodo != '') {\n// $funcion = $controlador ;\n// } else {\n $funcion = $controlador;\n// }\n\n if ($funcion === 'inicio') { // Si es inicio el controlador inicio con el metodo de cambio (que es metodo que llama a plantilla)\n return true;\n } else {\n if (in_array($funcion, $menu)) {\n return true;\n } else {\n return false;\n }\n }\n}", "public function getMenu($menu){\n $menus['sidebar'] = array(\n array(\n 'id' => 'inicio',\n 'label' => 'Inicio',\n 'link' => BASE_URL \n ),\n array(\n 'id' => 'login',\n 'label' => 'Cerrar Sesión',\n 'link' => BASE_URL . \"login/cerrar\"\n ),\n array(\n 'id' => 'login',\n 'label' => 'Iniciar Sesión',\n 'link' => BASE_URL . \"login\"\n ),\n array(\n 'id' => 'registro',\n 'label' => 'Registrarse',\n 'link' => BASE_URL . \"registro\"\n )\n );\n\n $menus['top'] = array(\n array(\n 'id' => 'inicio',\n 'label' => 'Inicio',\n 'link' => BASE_URL \n ),\n array(\n 'id' => 'post',\n 'label' => 'Post',\n 'link' => BASE_URL . \"post\"\n ),\n array(\n 'id' => 'configuracion',\n 'label' => 'Configuración',\n 'link' => BASE_URL . \"configuracion\"\n )\n );\n\n return $menus[$menu];\n }", "public function menu()\n {\n return $this->menu;\n }", "public function menu()\n {\n return $this->menu;\n }", "public function getMenu(){\n\n\t\treturn $this->get();\n\t}", "function has_nav_menu($location)\n {\n }", "public function getMenuSlug(): string;", "function is_sidebar_menu_active($current)\n{\n $CI =& get_instance();\n if ($CI->uri->segment(1) == $current) {\n return 'active';\n }\n return '';\n}", "abstract public function getMenuView(): string;", "public function get_menu()\n\t{\n\t\treturn $this->get_session('admin_menu_html');\n\t}", "public function current(){\n\t\t$actual_link = $this->protocol() . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];\n\t\treturn $actual_link;\n\t}", "function getSubMenuPageContent() {\n \tif(isSet($_GET['page'])) {\n \t\tswitch($_GET['page']) {\n \t\t\tcase 'lepress-my-subscriptions':\n \t\t\tcase 'lepress':\n \t\t\t\trequire_once('student_include/subscriptions.php');\n \t\t\t\tbreak;\n \t\t\tcase 'lepress-assignments':\n \t\t\t\trequire_once('student_include/assignments.php');\n \t\t\t\tbreak;\n \t\t\tcase 'lepress-groups':\n \t\t\t\trequire_once('student_include/my-groups.php');\n \t\t\t\tbreak;\n \t\t\tdefault:\n \t\t\t\techo \"tere\";\n \t\t\t\tbreak;\n \t\t}\n \t}\n }", "public function getMenu() {\r\n $sql = $this->db->query(\"SELECT * FROM ms_menu WHERE menu_isactive = 1 ORDER BY menu_urut\");\r\n if ($sql->num_rows() > 0) {\r\n return $sql->result_array();\r\n }\r\n return null;\r\n }", "function mf_get_menu_name($location){\n if(!has_nav_menu($location)) return false;\n $menus = get_nav_menu_locations();\n $menu_title = wp_get_nav_menu_object($menus[$location])->name;\n return $menu_title;\n}", "public function getShowInHome();", "public function getMenuOn( ) {\n return $this->menu;\n }", "function isCurrent($pageName){\n\tglobal $NAV_PAGE;\n\t//If the global matches the argument set as current\n\tif ($NAV_PAGE == $pageName){\n\t\techo \"currentNavItem\";\n\t}\n}", "function maiconfigurations_get_menu_by_slug( $slug ) {\n\n\tif ( $menu = get_term_by( 'slug', $slug, 'nav_menu' ) ) {\n\t\treturn $menu;\n\t}\n\n\tif ( $menu = get_term_by( 'slug', $slug . '-nav', 'nav_menu' ) ) {\n\t\treturn $menu;\n\t}\n\n\tif ( $menu = get_term_by( 'slug', $slug . '-menu', 'nav_menu' ) ) {\n\t\treturn $menu;\n\t}\n\n\treturn false;\n}", "function get_url_nav_bo($Rub) \r\n{\t\r\n\t$StrSQL = \"\r\n\t\t SELECT\r\n _nav.url_page\r\n\t\t FROM\r\n \t\t\t_nav\r\n\t \tWHERE\r\n\t\t\t\t\t\t\t_nav.id__nav=\".$Rub;\r\n\r\n\t$Rst = mysql_query($StrSQL);\r\n\t$url = mysql_result($Rst, 0, 0);\r\n\t\r\n\tif (!$url) $url = _URL_PAGE_PAR_DEFAUT;\r\n\t\r\n\t// on ajoute le Rub a la fin ssi si il n'est pas déja positionné dans url_nav (redirection d'une\r\n\t// rub vers une autre), et si ce n'est pas un lien externe\r\n\tif ( (!eregi(\"rub\",$url)) && (!eregi(\"http\",$url)) )\r\n\t{\r\n\t if (!eregi(\"\\?\",$url)) {\r\n\t \t\t$url .= \"?Rub=\".$Rub;\r\n\t } else {\r\n\t \t $url .= \"&Rub=\".$Rub;\r\n\t }\r\n\t}\r\n\r\n\treturn ($url);\t\r\n}", "function menu_page_url($menu_slug, $display = \\true)\n {\n }", "function getPage(){\n $current_location = \"index\";\n if($url_part = array_pop(explode(\"/\", $_SERVER[\"REQUEST_URI\"]))){\n $url_part = array_slice(explode(\".php\", $url_part),0,1);\n if(!empty($url_part)){\n return $url_part[0];\n }\n }\n return $current_location;\n}", "protected function getMenu() {\n $lMethods = $this->allcsvfilelist();\n natcasesort($lMethods);\n \n $lInherited = get_class_methods('CCor_Cnt');\n $lMenu = new CHtm_Vmenu(lan('sys-doc.menu'));\n foreach ( $lMethods as $lMethod ) {\n if (substr($lMethod, 0, 3) != 'act')\n continue;\n /*\n * if (substr ( $lMethod, 3, 1 ) == 'S')\n * continue;\n */\n if (in_array($lMethod, $lInherited))\n continue;\n \n $lAct = substr($lMethod, 3);\n $lMenu->addItem($lMethod, 'index.php?act=sys-doc.' . strtolower($lAct), $lAct);\n }\n \n $lMenu->setKey('act' . ucfirst($this->mAct));\n return $lMenu;\n }", "static public function _MENU(){\n if (b_reg::$current_module == VM_MODULE) start_VM();\n return loader::_fromCache('APImenu_vm'); \n }", "function internal_navigation_item($title, $href) {\n \n // Strip first forward slash (start of string)\n $script = substr($_SERVER['SCRIPT_NAME'], 1);\n \n if ($script === $href) {\n return \"<li><a class='active' href='$href'>$title</a></li>\";\n } else {\n return \"<li><a href='$href'>$title</a></li>\";\n }\n}", "function echoActiveClassIfRequestMatches($requestUri=array())\n{\n $routing_uri = $_SERVER['REQUEST_URI'];\n foreach($requestUri as $ruri) {\n if (strpos($routing_uri, $ruri) !== FALSE)\n echo ' class=\"active\"';\n }\n}", "public function getMenu()\n\t{\n\t\treturn $this->menu;\n\t}", "function active_menu()\n{\n $CI =& get_instance();\n\n $class = '';\n if($CI->router->fetch_class() == 'blog') {\n $class = 'class=\"navbar-item-active\"';\n }\n return $class;\n}", "public function get_portfolio_tree_menu_url();", "function get_registered_nav_menus()\n {\n }", "public function menu_get_active_title()\n {\n return menu_get_active_title();\n }", "public function getCurrentRoute()\n {\n return substr(\n $_SERVER['REQUEST_URI'],\n (strlen($this->config->get('site.dir')) - 1)\n );\n }", "public function menu_get_active_help()\n {\n return menu_get_active_help();\n }", "public function getMenu() {\n\t\treturn $this->menu;\n\t}", "public static function getMenuFromRoute($base = 'dashboard')\n {\n $routes = Route::getRoutesList()->all();\n /*\n * needed routes\n */\n $filtered_routes = [];\n foreach ($routes as $route) {\n if ($route['method'] == 'GET|HEAD' && str_contains($route['uri'], $base) && str_contains($route['name'], 'index')) {\n $filtered_routes[] = $route;\n }\n }\n if (empty($filtered_routes)) {\n return false;\n }\n /*\n * menu will have three levels\n *\n * level 0 - parent\n * this levels will only have one forward slash (/)\n * and the count will be 2\n * level 1 - parent & child\n * this levels will have tow forward slash (/)\n * and the count will be 3\n * level 2 - child\n * this levels will have three forward slash (/)\n * and the count will be 4\n */\n $menu = [];\n foreach ($filtered_routes as $filtered_route) {\n $exploded = explode('/', $filtered_route['uri']);\n $action = explode('@', $filtered_route['action']);\n switch (count($exploded)) {\n case 2: # level 0\n case 3: # level 1\n case 4: # level 2\n $menu[\\App\\Extras\\Utilities\\Utilities::flatArrayValues($exploded)] = $action[0];\n break;\n }\n }\n asort($menu , ARRAY_FILTER_USE_KEY);\n return $menu;\n }", "function loadMenu($arg_menu_name)\n{\n\tINCLUDE('menus/' . $arg_menu_name . '.mnu');\n\treturn $menu;\n}", "function getSfMenu($selected) {\n $activeMenusAndLinkContent = getActiveMenuAndLinkContent();\n $activeMenus = $activeMenusAndLinkContent['results'];\n $link_content_id = $activeMenusAndLinkContent['link_contents_id'];\n $link_content_details = getLinkContentDetails($link_content_id);\n \n// Format our active menus for sturcturing a tree for main menu\n $formatedMenus = formatTree($activeMenus, 1);\n $menuStr = \"<ul id='nav'>\";\n foreach ($formatedMenus as $menu) {\n if (!empty($menu['submenu'])) {\n $mnuclass = \"\";\n $p = $link_content_details[$menu['link_content']]['content_uri'];\n $link = $AbsoluteURL . 'index.php?p=' . $p;\n if ($menu['type'] == \"external\") {\n $link = $menu['external_link'];\n }\n if ($p == $selected) {\n $mnuclass = \"class='active'\";\n } elseif (is_submenu_selected($menu['submenu'], $selected, $link_content_details)) {\n $mnuclass = \"class='active'\";\n }\n\n $menuStr.='<li ' . $mnuclass . '><a href = \"' . $link . '\">' . $menu['menu_name'] . '</a>';\n $menuStr.=\"<ul>\";\n foreach ($menu['submenu'] as $submenu) {\n $submnuclass = \"\";\n $p = $link_content_details[$submenu['link_content']]['content_uri'];\n $link = $AbsoluteURL . 'index.php?p=' . $p;\n if ($submenu['type'] == \"external\") {\n $link = $submenu['external_link'];\n }\n if ($submenu['type'] == \"category\") {\n $link = \"index.php?p=allproducts&c=\".$submenu['menu_id'];\n }\n if ($p == $selected)\n $submnuclass = \"class='sub_active'\";\n\n $menuStr.='<li ' . $submnuclass . '><a href = \"' . $link . '\">' . $submenu['menu_name'] . '</a></li>';\n }\n $menuStr.=\"</ul></li>\";\n } else {\n $mnuclass = \"\";\n $p = $link_content_details[$menu['link_content']]['content_uri'];\n $link = $AbsoluteURL . 'index.php?p=' . $p;\n if ($menu['type'] == \"external\") {\n $link = $menu['external_link'];\n }\n if ($p == $selected)\n $mnuclass = \"class='active'\";\n $menuStr.='<li ' . $mnuclass . '><a href = \"' . $link . '\">' . $menu['menu_name'] . '</a><li>';\n }\n }\n $menuStr.=\"</ul>\";\n return $menuStr;\n}", "public function specific_menu($id)\r\n\t{\r\n\t\t$this->db->where('id',$id); \r\n\t\t$result = $this->db->get('menu'); \r\n\t\treturn $result->row();\r\n\t}", "public function getRouteMatch();", "function getpage() {\n global $pages; /* so the included files know about it */\n\n $page = $_GET['page'];\n if ((preg_match('^/[a-z][a-z]/', $page)) && (in_array($page, $pages)))\n return $page;\n else\n return 'news';\n}", "protected function menuVoters()\n {\n $matcher = $this->get('knp.menu.matcher');\n $matcher->addVoter(new UrlVoter(current_url()));\n $matcher->addVoter(new UriVoter(current_url()));\n }", "abstract public function getRouteMatch();", "public function getMenus() {}" ]
[ "0.6658788", "0.64975333", "0.6419532", "0.6251096", "0.6217671", "0.62124527", "0.6090748", "0.59952074", "0.59873813", "0.59745103", "0.59302694", "0.59079933", "0.585519", "0.5848429", "0.5845259", "0.58364683", "0.5817355", "0.58172256", "0.5790214", "0.5778908", "0.5777268", "0.5775613", "0.5758894", "0.5756786", "0.5746258", "0.5738608", "0.57371813", "0.5723295", "0.57093585", "0.57033175", "0.56919444", "0.5686235", "0.56781614", "0.56765795", "0.567183", "0.5667976", "0.5665366", "0.565505", "0.5644468", "0.56436163", "0.564263", "0.564263", "0.56422263", "0.56415254", "0.56368494", "0.56356716", "0.5629821", "0.5625314", "0.5618348", "0.56117094", "0.5606871", "0.5602382", "0.55970025", "0.55914706", "0.5585216", "0.5585192", "0.5574802", "0.55735886", "0.55698544", "0.55681664", "0.5562163", "0.556131", "0.556131", "0.55529445", "0.5534979", "0.5521368", "0.5487273", "0.5466724", "0.54641986", "0.5462196", "0.5458912", "0.5455697", "0.5455652", "0.54549813", "0.54481393", "0.5448013", "0.54452235", "0.54417354", "0.5435505", "0.5430005", "0.54208404", "0.54180074", "0.54152185", "0.54111373", "0.5410648", "0.5404716", "0.5398198", "0.53981286", "0.5393832", "0.5393556", "0.5387239", "0.5382601", "0.53803927", "0.53646034", "0.53594625", "0.535781", "0.5356292", "0.5355204", "0.5351029", "0.53338665", "0.53296393" ]
0.0
-1
data should be password
function login($username, $data) { if ($username != 'admin' || $data != 'secret') { return false; } return parent::login($username, $data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function password($data=''){\n\t\t\treturn true;\n\t\t}", "function hashPassword($data) { \r\n if (!$this->id && !isset($this->data[$this->name]['id'])) {\r\n if (!isset($this->data[$this->name]['FilterChar'])) {\r\n $this->data[$this->name]['FilterChar'] = self::createFilterChar();\r\n }\r\n if (isset($this->data[$this->name]['Username']) && isset($this->data[$this->name]['Password']) && isset($this->data[$this->name]['FilterChar'])) {\r\n\r\n $this->data[$this->name]['Password'] = sha1($this->data[$this->name]['Username'] . \"+\" . $this->data[$this->name]['Password'] . \"+\" . $this->data[$this->name]['FilterChar']);\r\n\r\n $this->data[$this->name]['FirstPass'] = $this->data[$this->name]['Password'];\r\n\r\n return $data;\r\n }\r\n }\r\n }", "public function password($data = '', $value = '', $extra = '')\n {\n if (is_object($value)) { // $_POST & Db value schema sync\n $value = $this->getRowValue($value, $data); \n }\n if (! is_array($data)) {\n $data = array('name' => $data);\n }\n $data['type'] = 'password';\n return $this->input($data, $value, $extra);\n }", "public function getPassword() {}", "public function getPassword();", "public function getPassword();", "public function getPassword();", "public function getPassword();", "public function getPassword();", "public function getPassword();", "public function getPassword();", "public function password($password);", "public function olvidoPassword(){\n\t}", "public function necesitaCambiarPassword();", "function password_add($data) {\n\t}", "public function password()\n {\n }", "function getPassword(){\n\n}", "public function testPasswordIsValid($data)\n {\n $pattern = \"/^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{8,}$/\";\n\n $this->assertMatchesRegularExpression($pattern,$data);\n\n }", "public function getPassword()\n {\n }", "public function getPassword()\n {\n }", "public function getPassword()\n {\n }", "public function getPassword()\n {\n }", "public function getPassword()\n {\n }", "public function getPassword()\n {\n }", "public function enforceRulePassword($data){\n if (strlen($data) >= 8){\n \t$validPassword= $data;\n \t} \n \telse{\n \t$validPassword= FALSE;\n\t\t\t}\n\t\t\t\n\t\t\t/*if (preg_match (\"/^.*(?=.{8,})(?=.*\\d)(?=.*[a-zA-Z]).*$/\", $data)){\n \t$validPassword= $data;\n \t} \n \telse{\n \t$validPassword= FALSE;\n\t\t\t}*/\n\t\t\t\n\t\t\treturn $validPassword;\n }", "public function password($data){\n\n\n \t$q = \"SELECT password FROM user_table WHERE password='$data[current_pass]'\";\n\n \t$result = $this->connection->query($q);\n\n \t // check if current password is correct\n\n \tif($result->num_rows >0){\n\n \n \t\t$id = $_SESSION['id'];\n\n\t \t\tif($data['new_pass']==$data['re_pass'])\n\t \t\t{\n\n\t \t\t\tif(strlen($data['new_pass'])<8){\n\n\t\t\t\t$_SESSION['message'] = \"Password must contain 8 letters\";\n\t\t\t\t $_SESSION['msg_type'] = \"danger\";\n\t\t\t\t}else{\n\n\t \t\t$q=\"UPDATE user_table SET password='$data[new_pass]' WHERE id='$id'\";\n\n\t \t\t$result = $this->connection->query($q);\n\n\t \t\t$_SESSION['message'] = \"Successfully changed\";\n\t \t\t$_SESSION['msg_type'] = \"success\";\n\n\t\t \t}\n\t \n\n\t \t}\n\t \telse\n\t \t{\n\n\t \t\t$_SESSION['message'] = \"New password does not match\";\n\t \t\t$_SESSION['msg_type'] = \"warning\";\n \n\t \t}\n\t }\n\t else\n\t {\n\n\t \t$_SESSION['message']= \"Invalid current password\";\n\t \t$_SESSION['msg_type'] = \"danger\";\n \n\t }\n }", "public function getSecuredPassword();", "public function getPassword(): string;", "public static function renderPassword();", "function get_password($usrid){\r\n\t\r\n}", "public function authenticationWithValidAlphaCharClassPassword() {}", "public function authenticationWithValidAlphaCharClassPassword() {}", "public function authenticationWithValidAlphaCharClassPassword() {}", "public function authenticationWithValidAsciiSpecialCharClassPassword() {}", "public function authenticationWithValidAsciiSpecialCharClassPassword() {}", "public function authenticationWithValidAsciiSpecialCharClassPassword() {}", "public function isPassword($password);", "public function setPassword(){\n\t}", "public function setPassword($value);", "public function getAuthPassword()\n {\n }", "public function getAuthPassword()\n {\n }", "public function getAuthPassword()\n {\n }", "public function restPassword(){\n\t}", "public function getPW() {}", "public function checkPassword($value);", "public function setpassword(){\n\t\t$args = $this->getArgs();\n\t\t$out = $this->getModel()->getUserDataByRenewToken(UserController::getRenewTokenHash($args[\"GET\"][\"token\"]));\n\t\tinclude 'gui/template/UserTemplate.php';\n\t}", "public function getPasswordAdapter();", "public function authenticationWithValidNumericCharClassPassword() {}", "public function authenticationWithValidNumericCharClassPassword() {}", "public function authenticationWithValidNumericCharClassPassword() {}", "public function setPassword($password);", "public function setPassword($password);", "public function setPassword($password);", "public function setPasswordField($password = true) {}", "public function check_password($password)\n {\n }", "public function testPasswordIsNotValid($data)\n {\n $pattern = \"/^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[0-9])(?=.*?[#?!@$%^&*-]).{8,}$/\";\n \n\n $this->assertDoesNotMatchRegularExpression($pattern,$data);\n\n }", "public function password(){\n $_error = \"enter the password\";\n\t\treturn $_error;\n\t}", "public function getPassword():? string;", "public function isPasswordField() {}", "public function getPassword(): string\n {\n }", "private function getPassword(): string {\n return $this->password;\n }", "function the_post_password()\n {\n }", "public function get_pass() \n {\n return $this->pass;\n }", "protected function password()\n {\n return 'password';\n }", "function getFieldPassword(){\n\t\t$form_ret = '';\n\t\t$dataField = get_option('axceleratelink_srms_opt_password');\n\t\t$dataTitle = get_option('axceleratelink_srms_opt_tit_password');\n\t\t$tooltip = setToolTipNotification('password');\t\t\n\t\tif ($dataField == 'true'){\n\t\t\t$form_ret .= \"</br><label>\".$dataTitle.\"<span class='red'>*</span>\".$tooltip.\"</label><br><input type='password' name='newpassword' value='' class='' id='password'></br><div id='password_err_con'></div>\";\t\t\n\t\t}\n\t\treturn $form_ret;\n\t}", "protected function getPassword()\r\n {\r\n return $this->processor_data['processor_params']['password'];\r\n }", "public static function createPassword($data = '', $value = '', $extra = '')\n {\n if (!is_array($data)) {\n $data = array('name' => $data);\n }\n\n $data['type'] = 'password';\n return self::createInput($data, $value, $extra);\n }", "function wp_validate_application_password($input_user)\n {\n }", "protected function getConfiguredPassword() {}", "function password($pass)\n\t{\n\t\tif (strcmp($pass, AUCTION_PASSWORD))\n\t\t\texit(\"Wrong password\");\n\t}", "function is_password_valid ($password, $user_data) {\n // the one in the user records.\n $is_valid = $password == $user_data['password'];\n return $is_valid;\n}", "public function getPassword() {\n return @$this->attributes['password'];\n }", "function _cek_password($str)\n{\n if ($str!=\"\") {\n if (pass_decrypt(profile(\"token\"),$str,profile(\"password\"))) {\n return true;\n }else {\n $this->form_validation->set_message('_cek_password', '* Password Salah');\n return false;\n }\n }else {\n return true;\n }\n}", "public function passwd() {\n\n $pass = $_POST['password'];\n\n $p = $this->inputmanager;\n\n return $p->passwdchk($pass);\n\n }", "public function modifpassword($user,$passwd){\n \n }", "public function getPassword(){\n return $this->password;\n }", "function rest_get_authenticated_app_password()\n {\n }", "private function pre_defined_password(): string\r\n {\r\n $regx = \"/^(?=.*[a-z])(?=.*[A-Z])(?=.*\\d)(?=.*[#$@!%&*?])[A-Za-z\\d#$@!%&*?]{6,30}$/\";\r\n if (!preg_match($regx, $this->field)) {\r\n return $this->message(\"must 1 uppercase, lowercase, number & special char\");\r\n }\r\n }", "public function getDataForMakePasswordMethod(): array\n {\n return [\n 0 => [\n 0 => [\n 'password' => 2,\n ],\n ],\n ];\n }", "public function authByUserPassword($password) {}", "public function setPassword($p) {\n $this->_password = $p;\n }", "public function usePassword($password)\n {\n // CODE...\n }", "function password( \n\t $name, $title = null, $value = null, \n\t $required = false, \n\t $attributes = null\n\t){\n return $this->input(\n\t $name, \n\t Form::TYPE_PASSWORD,\n\t $title, \n\t $value, \n\t $required, \n\t $attributes,\n\t null,\n\t Form::DATA_STRING\n );\n\t}", "function get_password($data) {\n $sql = \"SELECT\n *\n FROM\n logins\n WHERE \n password\n LIKE \n '$data'\n \";\n\n $query = $this->data->prepare($sql);\n $query->execute();\n\n $result = $query->rowCount();\n return $result;\n }", "public function hasPassword() : bool;", "protected function changePassword() {}", "public function password($text){\n\t\t$text['label'] = isset($text['label']) ? $text['label'] : 'Enter Text Here: ';\n\t\t$text['value'] = isset($text['value']) ? $text['value'] : '';\n\t\t$text['name'] = isset($text['name']) ? $text['name'] : '';\n\t\t$text['class'] = isset($text['class']) ? 'input_text '.trim($text['class']) : 'input_text';\n $text['onlyField'] = isset($text['onlyField']) ? $text['onlyField'] : false;\n $text['extraAtt'] = isset($text['extraAtt']) ? $text['extraAtt'] : '';\n\t\tif($text[\"onlyField\"]==true){\n return '<input type=\"password\" class=\"'.$text['class'].'\" name=\"'.$text['name'].'\" id=\"'.$text['name'].'\" value=\"'.$text['value'].'\" '.$text['extraAtt'].' />';\n }\n else{\n return '<div class=\"flclear clearfix\"></div>\n\t\t\t\t<label for=\"'.$text['name'].'\">'.$text['label'].'&nbsp;</label>\n \t<input type=\"password\" class=\"'.$text['class'].'\" name=\"'.$text['name'].'\" id=\"'.$text['name'].'\" value=\"'.$text['value'].'\" '.$text['extraAtt'].' />';\n }\n\n\t}", "function user_pass_ok($user_login, $user_pass)\n {\n }", "public function newPassword($data, $id) \n {\n $data['salt'] = $this->app['password']->generateSalt(time());\n $data['password'] = $this->app['password']->encode($data['password'], $data['salt']);\n \n return $this->update($data, $id);\n }", "public function getPassword() : ?string ;", "function hashPassword()\t{\n\t\t$fields = $this->_settings['fields'];\n\t\tif (!isset($this->model->data[$this->model->name][$fields['username']])) {\n\t\t\t$this->model->data[$this->model->name][$fields['password']] = Security::hash($this->model->data[$this->model->name][$fields['password']], null, true);\n\t\t}\n\t}", "function getPassword(){\n $options = sciploreDataAccessBundle::getGeneralOptions();\n //$options = $container->get('sciplore.options')->getGeneralOptions();\n $require_password = $options['authentifiaction_requires_password']; \n if($require_password==1){\n return $this->passphrase;\n }\n else{\n //hardcoded random default password. Must be sent by the authentification form in a hidden field.\n return 'WnDadvfhWqoJnHuXtyxwZxGbfHsXrNwI3Idns4d2Ie9BnEjYnr14ijyCr0YPg7i';\n }\n }", "function hashPassword($data, $enforce=false) {\n if($enforce && isset($this->data[$this->alias]['password']) && isset($this->data[$this->alias]['password']) ) {\n if(!empty($this->data[$this->alias]['password']) && !empty($this->data[$this->alias]['username']) ) {\n $stringToHash = $this->data[$this->alias]['username'].$this->data[$this->alias]['password'];\n $hasher = new SimplePasswordHasher(array('hashType' =>'sha1'));\n $this->data[$this->alias]['password'] = $hasher->hash($stringToHash);\n }\n }\n\n return $data;\n }", "private function getPassword()\n {\n return $this->password;\n }", "public function authenticationWithValidLatin1SpecialCharClassPassword() {}", "public function authenticationWithValidLatin1SpecialCharClassPassword() {}", "public function authenticationWithValidLatin1SpecialCharClassPassword() {}", "public function getPassword(): string\n {\n return $this->attributes['password'];\n }", "public function password($username)\n {\n }", "public function getPassword() {\n return $this->getValue('password');\n }", "public function authenticationWithValidLatin1UmlautCharClassPassword() {}" ]
[ "0.80325913", "0.7516402", "0.74679327", "0.72779524", "0.7274741", "0.7274741", "0.7274741", "0.7274741", "0.7274741", "0.7274741", "0.7274741", "0.72164", "0.71882075", "0.71621805", "0.7107044", "0.7079698", "0.70181787", "0.6996047", "0.6993264", "0.6993264", "0.6993264", "0.6993264", "0.6993264", "0.6993264", "0.6923252", "0.6919284", "0.69075584", "0.6905159", "0.6877781", "0.6859354", "0.68508047", "0.68508047", "0.68508047", "0.6830403", "0.6830403", "0.6830403", "0.68102074", "0.68038625", "0.675622", "0.6743785", "0.6743785", "0.6743785", "0.6734283", "0.67332584", "0.6685774", "0.66854316", "0.66710794", "0.6634296", "0.6634296", "0.6634296", "0.6588705", "0.6588705", "0.6588705", "0.6559385", "0.6546343", "0.65447277", "0.65392464", "0.6532549", "0.6528096", "0.6518686", "0.6514207", "0.6498878", "0.648913", "0.64821714", "0.64758337", "0.6460657", "0.6447985", "0.64448637", "0.64375216", "0.64244044", "0.6421587", "0.6420591", "0.64204836", "0.64169365", "0.6415601", "0.64089584", "0.63936496", "0.6384114", "0.63822776", "0.6380385", "0.63596374", "0.6352562", "0.63347787", "0.63337237", "0.633326", "0.6333012", "0.6317981", "0.631189", "0.63059044", "0.63036394", "0.6302245", "0.62878394", "0.62832886", "0.6276759", "0.6274799", "0.6274799", "0.6274799", "0.6269845", "0.626983", "0.6268243", "0.6266259" ]
0.0
-1
build_groups.php this page contains all of the functions that process group information Nagios VShell Copyright (c) 2010 Nagios Enterprises, LLC.
function build_group_array($objectarray, $type) { $membersArray = array(); $index = $type.'group_name'; foreach ($objectarray as $object) { $group = $object[$index]; if (isset($object['members'])) { $members = $object['members']; $lineitems = explode(',', trim($members)); //array_walk($lineitems, create_function('$v', '$v = trim($v);')); //XXX BAD to use create_function array_walk($lineitems, 'trim'); $group_members = NULL; if ($type == 'host' || $type == 'contact') { $group_members = $lineitems; } elseif ($type == 'service') { for ($i = 0; $i < count($lineitems); $i+=2) { $host = $lineitems[$i]; $service = $lineitems[$i+1]; $group_members[$host][] = $service; /* ( 'host_name' => $host, 'service_description' => $service); */ } } $membersArray[$group] = $group_members; } } return $membersArray; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function new_groups()\n {\n \n }", "public function groups();", "public function groups();", "function mozilla_create_group() {\n if(is_user_logged_in()) {\n $required = Array(\n 'group_name',\n 'group_type',\n 'group_desc',\n 'group_admin_id',\n 'my_nonce_field'\n );\n\n $optional = Array(\n 'group_address_type',\n 'group_address',\n 'group_meeting_details',\n 'group_discourse',\n 'group_facebook',\n 'group_telegram',\n 'group_github',\n 'group_twitter',\n 'group_matrix',\n 'group_other',\n 'group_country',\n 'group_city',\n 'group_language'\n );\n\n // If we're posting data lets create a group\n if($_SERVER['REQUEST_METHOD'] === 'POST') {\n if(isset($_POST['step']) && isset($_POST['my_nonce_field']) && wp_verify_nonce($_REQUEST['my_nonce_field'], 'protect_content')) {\n switch($_POST['step']) {\n case '1':\n // Gather information\n $error = false;\n foreach($required AS $field) {\n if(isset($_POST[$field])) {\n if($_POST[$field] === \"\" || $_POST[$field] === 0) {\n $error = true;\n }\n }\n }\n \n $_SESSION['form'] = $_POST;\n\n // Cleanup\n if($error) {\n if(isset($_SESSION['uploaded_file']) && file_exists($_SESSION['uploaded_file'])) {\n $image = getimagesize($_SESSION['uploaded_file']);\n if(isset($image[2]) && in_array($image[2], Array(IMAGETYPE_JPEG ,IMAGETYPE_PNG))) {\n unlink($_SESSION['uploaded_file']);\n }\n }\n\n $_POST['step'] = 0; \n }\n \n break;\n case 2:\n\n if(isset($_POST['agree']) && $_POST['agree']) {\n $args = Array(\n 'group_id' => 0,\n );\n \n $args['name'] = sanitize_text_field($_POST['group_name']);\n $args['description'] = sanitize_textarea_field($_POST['group_desc']);\n $args['status'] = 'private';\n \n $group_id = groups_create_group($args);\n $meta = Array();\n\n if($group_id) {\n // Loop through optional fields and save to meta\n foreach($optional AS $field) {\n if(isset($_POST[$field]) && $_POST[$field] !== \"\") {\n $meta[$field] = trim(sanitize_text_field($_POST[$field]));\n }\n }\n\n $group = groups_get_group(Array('group_id' => $group_id ));\n $user = wp_get_current_user();\n\n $auth0Ids = Array();\n $auth0Ids[] = mozilla_get_user_auth0($user->ID);\n\n if(isset($_POST['group_admin_id']) && $_POST['group_admin_id'] && $group->creator_id == $user->ID) {\n $group_admin_user_id = intval($_POST['group_admin_id']);\n\n $user_check = get_userdata($group_admin_user_id);\n\n if($user_check !== false) {\n groups_join_group($group_id, $group_admin_user_id);\n $member = new BP_Groups_Member($group_admin_user_id, $group_id); \n do_action('groups_promote_member', $group_id, $group_admin_user_id, 'admin'); \n $member->promote('admin'); \n $auth0Ids[] = mozilla_get_user_auth0($group_admin_user_id);\n }\n\n }\n\n // Required information but needs to be stored in meta data because buddypress does not support these fields\n $meta['group_image_url'] = trim(sanitize_text_field($_POST['image_url']));\n $meta['group_type'] = trim(sanitize_text_field($_POST['group_type']));\n \n if(isset($_POST['tags'])) {\n $tags = explode(',', $_POST['tags']);\n $meta['group_tags'] = array_filter($tags);\n }\n\n $discourse_data = Array();\n $discourse_data['name'] = $group->name;\n $discourse_data['description'] = $group->description;\n\n if(!empty($auth0Ids))\n $discourse_data['users'] = $auth0Ids;\n\n $discourse_group = mozilla_discourse_api('groups', $discourse_data, 'post');\n \n if($discourse_group) {\n $meta['discourse_group_id'] = intval(sanitize_text_field($discourse_group->id));\n }\n\n // Don't need this data anymore \n unset($discourse_data['users']);\n $discourse_data['groups'] = Array(intval($discourse_group->id));\n $discourse = mozilla_discourse_api('categories', $discourse_data, 'post');\n \n if($discourse && isset($discourse->id) && $discourse->id) {\n $meta['discourse_category_id'] = intval(sanitize_text_field($discourse->id));\n } \n \n $result = groups_update_groupmeta($group_id, 'meta', $meta);\n \n if($result) {\n unset($_SESSION['form']);\n $_POST = Array();\n $_POST['step'] = 3;\n \n $_POST['group_slug'] = $group->slug;\n } else {\n groups_delete_group($group_id);\n mozilla_discourse_api('categories', Array('category_id' => $discourse->id), 'delete');\n $_POST['step'] = 0;\n } \n }\n } else {\n $_POST['step'] = 2;\n }\n\n break; \n }\n }\n } else {\n unset($_SESSION['form']);\n }\n } else {\n wp_redirect(\"/\");\n }\n}", "function setup_groups() {\n global $CFG;\n\n /// find out current groups mode\n $this->group_selector = groups_print_course_menu($this->course, $this->pbarurl, true);\n $this->currentgroup = groups_get_course_group($this->course);\n\n if ($this->currentgroup) {\n $this->groupsql = \" LEFT JOIN {$CFG->prefix}groups_members gm ON gm.userid = u.id \";\n $this->groupwheresql = \" AND gm.groupid = $this->currentgroup \";\n }\n }", "function create_todos_groups(){\t\t\n\t\t$groups = array( 'master' => array() );\n\t\t$groups_str = array();\n\n\t\t//creating grounps or master group\n\t\tforeach ($this->get_bvars() as $key => $value) {\n\t\t\t$match = array();\n\t\t\tif( preg_match( '/group_(.*)/', $key, $match ) ){\n\t\t\t\t$groups[$match[1]] = array();\n\t\t\t\t$groups_str[] = $match[1];\n\t\t\t\tforeach ($this->bvars as $key2 => $value2) {\n\t\t\t\t\t$match2 = array();\n\t\t\t\t\tif ( preg_match( '/pa_' . $match[1] . '_(.*)/', $key2, $match2 ) ) {\n\n\t\t\t\t\t\t/*\n\t\t\t\t\t\t* 1st level \n\t\t\t\t\t\t* Checking if exact attr name class exists\n\t\t\t\t\t\t */\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tif ( class_exists( '\\gcalc\\pa\\\\' . $match2[0] ) ) {\n\t\t\t\t\t\t\t$class_name = $match2[0];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t* 2nd level\n\t\t\t\t\t\t\t* master process class\n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t$class_name = str_replace( $match[1] . '_', '', $match2[0] );\n\t\t\t\t\t\t\t$pa_class_name = '\\gcalc\\pa\\\\' . $class_name;\n\t\t\t\t\t\t\tif ( !class_exists( $pa_class_name ) ) {\n\t\t\t\t\t\t\t\tif ( class_exists( '\\gcalc\\pa\\\\' . $key2 ) ) {\n\t\t\t\t\t\t\t\t\t$class_name = $key2;\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\t\n\t\t\t\t\t\t$groups[ $match[ 1 ] ][ $key2 ]['class_name'] = $class_name;\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\t\t\t\t\n\t\t\t} \n\t\t}\n\n\t\t/*\n\t\t* Master group\n\t\t*/\n\t\t$groups_str = implode( '|', $groups_str );\n\t\tforeach ($this->bvars as $key => $value){\n\t\t\tif( ! preg_match( '/pa_['. $groups_str .')]{2,}(.*)/', $key) \n\t\t\t\t&& ! preg_match('/group_|apikey|apisecret|Authorization/', $key) \n\n\t\t\t){\n\t\t\t\t$class_name = $key;\n\t\t\t\t$groups[ 'master' ][$key]['class_name'] = $class_name;\t\t\t\t\n\t\t\t} \n\t\t}\n\n\n\n\t\t$this->todo_groups = $groups;\t\t\n\t}", "function groups() {\n\t\t$this->validate();\n\t\t$this->setupTemplate();\n\n\t\t$journal =& Request::getJournal();\n\n\t\t$rangeInfo =& $this->getRangeInfo('groups');\n\n\t\t$groupDao =& DAORegistry::getDAO('GroupDAO');\n\t\t$groups =& $groupDao->getGroups(ASSOC_TYPE_JOURNAL, $journal->getId(), null, $rangeInfo);\n\n\t\t$templateMgr =& TemplateManager::getManager();\n\t\t$templateMgr->addJavaScript('lib/pkp/js/lib/jquery/plugins/jquery.tablednd.js');\n\t\t$templateMgr->addJavaScript('lib/pkp/js/functions/tablednd.js');\n\t\t$templateMgr->assign_by_ref('groups', $groups);\n\t\t$templateMgr->assign('boardEnabled', $journal->getSetting('boardEnabled'));\n\t\t$templateMgr->display('manager/groups/groups.tpl');\n\t}", "function group_create($data){\n $dval = $data['umd_val'];\n if(!isset($this->domains[$dval])) return 2;\n if(!in_array($dval,$this->quest_provider('d:group','create',TRUE,FALSE)))\n return 3;\n $tmp = $this->domains[$dval]->group_create($data);\n if($tmp>0) return $tmp;\n return $this->gdn_make($data['gname'],$dval);\n }", "function build_hostgroup_details($group_members) //make this return the totals array for hosts and services \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n//\t//add filter for user-level filtering \n//\tif(!$NagiosUser->is_admin()) {\n\t\t//print $type; \n//\t\t$hosts = user_filtering($hosts,'hosts'); \t\n//\t}\n\n\t$hostgroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t\t$hostgroup_details[] = $hosts[$member];\n\t}\n\n\treturn $hostgroup_details;\n}", "function fillGroups() \n\t{\n\t\t$this->groups[] = array(-1,\"<\".\"Admin\".\">\");\n\t\t$this->groupFullChecked[] = true;\n\t\t\n\t\t$trs = db_query(\"select , from `uggroups` order by \",$this->conn);\n\t\twhile($tdata = db_fetch_numarray($trs))\n\t\t{\n\t\t\t$this->groups[] = array($tdata[0],$tdata[1]);\n\t\t\t$this->groupFullChecked[] = true;\n\t\t}\n\t}", "public function group_list()\n\t{\n\t\t$data = [\n\t\t\t'group' => $this->todo->get_group_list((int) $this->session->userdata('uid'))\n\t\t];\n\t\t$this->page->set_title(\"Group List\");\n\t\t$this->page->build('friend/group_list', $data);\n\t}", "public function postProcess(): void {\n $groupsToAddTo = (array) $this->getSubmittedValue('groups');\n $summaryInfo = ['groups' => [], 'tags' => []];\n foreach ($groupsToAddTo as $groupID) {\n // This is a convenience for now - really url & name should be determined at\n // presentation stage - ie the summary screen. The only info we are really\n // preserving is which groups were created vs already existed.\n $summaryInfo['groups'][$groupID] = [\n 'url' => CRM_Utils_System::url('civicrm/group/search', 'reset=1&force=1&context=smog&gid=' . $groupID),\n 'name' => Group::get(FALSE)\n ->addWhere('id', '=', $groupID)\n ->addSelect('name')\n ->execute()\n ->first()['name'],\n 'new' => FALSE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n\n if ($this->getSubmittedValue('newGroupName')) {\n /* Create a new group */\n $groupsToAddTo[] = $groupID = Group::create(FALSE)->setValues([\n 'title' => $this->getSubmittedValue('newGroupName'),\n 'description' => $this->getSubmittedValue('newGroupDesc'),\n 'group_type' => $this->getSubmittedValue('newGroupType') ?? [],\n 'is_active' => TRUE,\n ])->execute()->first()['id'];\n $summaryInfo['groups'][$groupID] = [\n 'url' => CRM_Utils_System::url('civicrm/group/search', 'reset=1&force=1&context=smog&gid=' . $groupID),\n 'name' => $this->getSubmittedValue('newGroupName'),\n 'new' => TRUE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n $tagsToAdd = (array) $this->getSubmittedValue('tag');\n foreach ($tagsToAdd as $tagID) {\n // This is a convenience for now - really url & name should be determined at\n // presentation stage - ie the summary screen. The only info we are really\n // preserving is which tags were created vs already existed.\n $summaryInfo['tags'][$tagID] = [\n 'url' => CRM_Utils_System::url('civicrm/contact/search', 'reset=1&force=1&context=smog&id=' . $tagID),\n 'name' => Tag::get(FALSE)\n ->addWhere('id', '=', $tagID)\n ->addSelect('name')\n ->execute()\n ->first()['name'],\n 'new' => TRUE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n if ($this->getSubmittedValue('newTagName')) {\n $tagsToAdd[] = $tagID = Tag::create(FALSE)->setValues([\n 'name' => $this->getSubmittedValue('newTagName'),\n 'description' => $this->getSubmittedValue('newTagDesc'),\n 'is_selectable' => TRUE,\n 'used_for' => 'civicrm_contact',\n //NYSS new tags during import should be imported as keywords\n 'parent_id'\t=> 296,\n ])->execute()->first()['id'];\n $summaryInfo['tags'][$tagID] = [\n 'url' => CRM_Utils_System::url('civicrm/contact/search', 'reset=1&force=1&context=smog&id=' . $tagID),\n 'name' => $this->getSubmittedValue('newTagName'),\n 'new' => FALSE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n // Store the actions to take on each row & the data to present at the end to the userJob.\n $this->updateUserJobMetadata('post_actions', [\n 'group' => $groupsToAddTo,\n 'tag' => $tagsToAdd,\n ]);\n $this->updateUserJobMetadata('summary_info', $summaryInfo);\n\n // If ACL applies to the current user, update cache before running the import.\n if (!CRM_Core_Permission::check('view all contacts')) {\n $userID = CRM_Core_Session::getLoggedInContactID();\n CRM_ACL_BAO_Cache::deleteEntry($userID);\n CRM_ACL_BAO_Cache::deleteContactCacheEntry($userID);\n }\n\n $this->runTheImport();\n }", "function system_add_group($paramv)\n{\n}", "public function create_group()\r\n\t{\r\n\t\t// Load template\r\n\t\tinclude(BLUPATH_TEMPLATES .'/site/modules/create_group.php');\r\n\t}", "public function groups() {\n\t\t//variabel\n\t\t$data['datas'] = $this->PbkGroups_model->get_all();\n\t\t\n\t\t$template_data['title'] = 'SMS Gateway ';\n\t\t$template_data['subtitle'] = 'Kirim SMS';\n $template_data['crumb'] = ['SMS Gateway' => 'smsgateway', 'SMS Groups' => 'smsgateway/kirimsms/groups',];\n\t\t//view\n\t\t$this->layout->set_wrapper('groups_form', $data);\n\t\t$this->layout->auth();\n\t\t$this->layout->render('admin', $template_data);\n\t}", "function add_buildgroup_sortlist($groupname)\n{\n // This information can be provided as a query string, otherwise we apply\n // some default ordering here. Default sort ordering for a group is based\n // on the groupname.\n //\n // Sort settings should probably be definable/overrideable by the user as wel\n // on the users page, or perhaps by the project admin on the project page.\n //\n $st = '';\n $xml = '';\n\n if(isset($_GET[\"sort\"]))\n {\n $xml .= add_XML_value(\"sortlist\", \"{sortlist: \" . $_GET[\"sort\"] . \"}\");\n return $xml;\n }\n\n $gn = strtolower($groupname);\n\n if (strpos($gn, 'nightly') !== FALSE)\n {\n $st = 'SortAsNightly';\n }\n else if ((strpos($gn, 'continuous') !== FALSE) || (strpos($gn, 'experimental') !== FALSE))\n {\n $st = 'SortByTime';\n }\n\n switch($st)\n {\n case 'SortAsNightly':\n $xml .= add_XML_value(\"sortlist\", \"{sortlist: [[4,1],[7,1],[11,1],[10,1],[5,1],[8,1]]}\");\n // Theoretically, most important to least important:\n // configure errors DESC, build errors DESC, tests failed DESC, tests not run DESC,\n // configure warnings DESC, build warnings DESC\n break;\n\n case 'SortByTime':\n $xml .= add_XML_value(\"sortlist\", \"{sortlist: [[14,1]]}\");\n // build time DESC\n break;\n\n // By default, no javascript-based sorting. Accept the ordering naturally as it came from\n // MySQL and the php processing code...\n }\n\n return $xml;\n}", "function &group_list($start=NULL, $limit=NULL, $direction=0, $where=NULL)\n\n {\n\n global $database, $user;\n\n \n\n\t $message_array = array();\n\n \n\n\t // MAKE SURE MESSAGES ARE ALLOWED\n\n\t \n\n \n\n // BEGIN MESSAGE QUERY\n\n $sql = \"\n\n SELECT\n\n *\n\n FROM\n\n se_groups\n\n WHERE\n\n owner='{$user->user_info['user_username']}'\n\n \";\n\n // EXECUTE QUERY\n\n $resource = $database->database_query($sql);\n\n \n\n // GET MESSAGES\n\n\t while( $message_info=$database->database_fetch_assoc($resource) )\n\n {\n\n // CREATE AN OBJECT FOR MESSAGE AUTHOR/RECIPIENT\n\n $pm_user = new SEUser();\n\n $pm_user->user_info['id'] = $message_info['id'];\n\n $pm_user->user_info['grup'] = $message_info['grup'];\n\n $pm_user->user_info['owner'] = $message_info['owner'];\n\n $pm_user->user_displayname();\n\n \n\n // Remove breaks for preview\n\n $message_info['pm_body'] = str_replace(\"<br>\", \"\", $message_info['pm_body']);\n\n \n\n // SET MESSAGE ARRAY\n\n $message_array[] = array(\n\n 'pmconvo_id' => $message_info['id'],\n\n 'pmconvo_grup' => $message_info['grup'],\n\n 'pm_owner' => $message_info['owner'],\n\t\t'pm_body' => $message_info['pm_body']\n\t\t\n\n );\n\n \n\n unset($pm_user);\n\n }\n\n \n\n return $message_array;\n\n }", "public function create_group() {\r\n $this->layout = '';\r\n\r\n $this->displayGroupType();\r\n\r\n $this->loadModel('GetRegisteredGroupData');\r\n $group_info = $this->GetRegisteredGroupData->find('all', array(\r\n 'order' => array('GetRegisteredGroupData.group_name' => 'asc')));\r\n\r\n $this->set('groupInfo', $group_info);\r\n }", "function mapgroups() {\r\n global $xdb;\r\n\t$limit = (!empty($_GET[\"groupslimit\"])) ? $_REQUEST[\"groupslimit\"] :X1_adminquerylimit ;\r\n\t$page = (!empty($_GET[\"groupspage\"])) ? $_REQUEST[\"groupspage\"] :1;\r\n\t$limitvalue = $page * $limit - ($limit); \r\n\t$result = $xdb->GetAll(\"SELECT * FROM \".X1_prefix.X1_DB_mapgroups);\r\n\t$totalgroups = count($result);\r\n\t$c =\"<table class='\".X1plugin_admintable.\"' width='100%'>\r\n\t<thead class='\".X1plugin_tablehead.\"'>\r\n\t\t<tr>\r\n\t\t\t<th colspan='4' align='left'>\".XL_amapgroups_add.\"</th>\r\n\t\t\t<th>\".XL_save.\"</th>\r\n\t\t</tr>\r\n </thead>\r\n <tbody class='\".X1plugin_tablebody.\"'>\r\n\t\t<tr>\r\n\t\t\t<td class='alt1' width='96%' colspan='4'>\r\n\t\t\t\t<form method='post' action='\".X1_adminpostfile.\"' style='\".X1_formstyle.\"'>\r\n\t\t\t\t\t<input type='int' value='2' size='2' name='num_mapgroups'>\r\n\t\t\t\t\t<input type='image' title='\".XL_amapgroups_add.\"' src='\".X1_imgpath.X1_addimage.\"'>\r\n\t\t\t\t\t<input name='\".X1_actionoperator.\"' type='hidden' value='addmapgroups''>\r\n\t\t\t\t</form>\r\n\t\t\t</td>\r\n\t\t\t<td class='alt2' width='4%' align='center'>\r\n\t\t\t\t<form action='\".X1_adminpostfile.\"' method='POST' style='\".X1_formstyle.\"'>\r\n\t\t\t\t<input type='image' title='\".XL_save.\"' src='\".X1_imgpath.X1_saveimage.\"'>\r\n\t\t\t</td>\r\n\t\t</tr>\r\n\t\t</tbody>\r\n\t\t<thead class='\".X1plugin_tablehead.\"'>\r\n\t\t\t<tr>\r\n\t\t\t\t<th>\".XL_amapgroups_id.\"</th>\r\n\t\t\t\t<th>\".XL_amapgroups_name.\"</th>\r\n\t\t\t\t<th>\".XL_amapgroups_contents.\"</th>\r\n\t\t\t\t<th>\".XL_amapgroups_edit.\"</th>\r\n\t\t\t\t<th><img src='\".X1_imgpath.X1_delimage.\"' title='\".XL_delete.\"' border='0'></td>\r\n\t\t\t</tr>\r\n </thead>\r\n <tbody class='\".X1plugin_tablebody.\"'>\";\r\n\t$rows = $xdb->GetAll(\"SELECT * FROM \".X1_prefix.X1_DB_mapgroups.\" ORDER BY id LIMIT 500\");\r\n\t$count = 0;\r\n\tif($rows){\r\n\t\tforeach($rows AS $row){\r\n\t\t\t$tents = explode(\",\",$row[2]);\r\n\t\t\t$tents = array_chunk($tents, 3);\r\n\t\t\tif(is_array($tents))$contents = implode(\",\", X1_mapid2names($tents[0]));\r\n\t\t\t$c .= \"<tr>\r\n\t\t\t\t\t<td class='alt1'><input type='text' name='nlv_\".$count.\"[]' value='\".$row[0].\"' readonly size='2'></td>\r\n\t\t\t\t\t<td class='alt2'><input type='text' name='nlv_\".$count.\"[]' value='\".$row[1].\"' size='30'></td>\r\n\t\t\t\t\t<td class='alt1'>$contents</td>\r\n\t\t\t\t\t<td class='alt2'><a href='\".$_SERVER['SCRIPT_NAME'].\"?\".X1_linkactionoperator.\"=addmapstogroup&amp;groupid=$row[0]'>\".XL_edit.\"</a></td>\r\n\t\t\t\t\t<td class='alt1' align='center'><input type='checkbox' name='nlv_\".$count.\"[]' value='checked'>\r\n\t\t\t\t\t</td>\r\n\t\t\t\t</tr>\";\r\n\t\t\t\t$count++;\r\n\t\t}\r\n\t}else{\r\n\t\t$c .= \"<tr><td colspan='6'>\".XL_amapgroups_none.\"</td></tr>\";\r\n\t}\r\n\t\t$c .= \"\r\n\t\t\t</tbody>\r\n <tfoot class='\".X1plugin_tablefoot.\"'>\r\n <tr>\r\n <td colspan='6'>&nbsp;\r\n <input type='hidden' name='\".X1_actionoperator.\"' value='updatemapgroups'>\r\n <input type='hidden' name='num_rows' value='$count'>\r\n </td>\r\n </tr>\r\n </tfoot>\r\n </table>\r\n\t</form>\";\r\n\treturn X1plugin_output($c, 1);\r\n}", "function secGroups($function, $group=NULL) {\n $g=array();\n if (true || $_SERVER['REMOTE_ADDR'] == '80.13.99.120' || $_SERVER['REMOTE_ADDR'] == '78.231.77.57'){\n $g['tests'] = array('none');\n }\n $g['wtsCheckLine'] = array('none');\n $g['ajaxMotDePasse'] = array('none');\n $g['wtsLireOffres'] = array('none');\n $g['viewOffre'] = array('none');\n $g['wtscommande']=array('none');\n $g['wtssaisieforfaits']=array('none');\n $g['wtsCtrlSaisieForfaits'] = array('none');\n $g['wtsCaddieDisp']=array('none');\n $g['wtsAjaxCaddieDisp'] = array('none');\n $g['wtsadd2caddie']=array('none');\n $g['wtsCaddieSuppr']=array('none');\n $g['wtsCaddieToggleLine']=array('none');\n $g['wtsCaddieSupprPack']=array('none'); // a tester\n $g['wtsPreValidateOrder'] = array('none');\n $g['wtsDevis'] = array('none');\n $g['wtsCtrlValidateOrder'] = array('none');\n $g['wtsValidateOrder'] = array('none');\n $g['wtsCtrlValidateCustomerCreation'] = array('none');\n $g['wtsValidateCustomerCreation'] = array('none');\n $g['wtsPrePaiement'] = array('none');\n $g['wtsDisplayOrder'] = array('none');\n $g['wtsCheckWTP'] = array('none');\n $g['wtsAddCard'] = array('none');\n $g['wtsPaiementZero'] = array('none');\n $g['wtsPaiementCheque'] = array('none');\n $g['wtsAdhesion'] = array('none');\n $g['wtsUseReduction'] = array('none');\n \n $g['checkStructures'] = array('admin');\n $g['repairStructures'] = array('admin');\n $g['repairOneStructure'] = array('admin');\n $g['checkSets'] = array('admin');\n $g['verifgrps'] = array('admin');\n $g['verifVentePro'] = array('admin');\n $g['checkEPLProducts'] = array('admin');\n\n $g['getCaddie'] = array('none');\n \n $g['procAuthGroup'] = array('none');\n $g['closeAuthGroup'] = array('none');\n $g['ajaxProcAuthMembre'] = array('none'); // non ecrite\n $g['initCurrentUser'] = array('none');\n $g['closeAuthMembre'] = array('none');\n\n // fonctions de la vente pro\n $g['wtsprolistewtp'] = array('none'); // ro normalement\n $g['wtsproadd2caddie'] = array('none'); // ro normalement\n $g['wtsProPaiement'] = array('none');\n $g['wtsProCancelOrder'] = array('none');\n $g['proAccount'] = array('none');\n // fonctions de la gestion des comtpes clients\n $g['myAccount'] = array('none');\n $g['procCreateMyAccount'] = array('none');\n $g['procEditMyAccount'] = array('none');\n $g['procEditProAccount'] = array('none');\n\n if(isset($g[$function])) {\n if(!empty($group)) return in_array($group, $g[$function]);\n return $g[$function];\n }\n return parent::secGroups($function, $group);\n }", "function setupNewsgroups() {\n\t\t$this->setIfNot('hdr_group', 'free.pt');\n\t\t$this->setIfNot('nzb_group', 'alt.binaries.ftd');\n\t\t$this->setIfNot('comment_group', 'free.usenet');\n\t\t$this->setIfNot('report_group', 'free.willey');\n\t\t$this->setIfNot('report_group', 'free.willey');\n\t}", "function system_addto_group($paramv)\n{\n}", "function CreateGroup(){\n $grpname = \"\"; $grpdesc=\"\";\n extract($_POST);\n $grpid = $this->generateGuid();\n $vs = [$grpname, $grpid, $grpdesc];\n $f = array(\"grpname\", \"grpid\", \"grpdesc\");\n $cg = $this->Insert($this->grptable, $f, $vs);\n return $cg;\n }", "function group_prepare_usergroups_for_display($groups, $returnto='mygroups') {\n if (!$groups) {\n return;\n }\n\n // Retrieve a list of all the group admins, for placing in each $group object\n $groupadmins = array();\n $groupids = array_map(create_function('$a', 'return $a->id;'), $groups);\n if ($groupids) {\n $groupadmins = get_records_sql_array('SELECT \"group\", member\n FROM {group_member}\n WHERE \"group\" IN (' . implode(',', db_array_to_ph($groupids)) . \")\n AND role = 'admin'\", $groupids);\n\t\t\t\n if (!$groupadmins) {\n $groupadmins = array();\n }\n }\n\n $i = 0;\n foreach ($groups as $group) {\n $group->admins = array();\n foreach ($groupadmins as $admin) {\n if ($admin->group == $group->id) {\n $group->admins[] = $admin->member;\n }\n }\n $group->description = str_shorten_html($group->description, 100, true);\n if ($group->membershiptype == 'member') {\n $group->canleave = group_user_can_leave($group->id);\n }\n else if ($group->jointype == 'open') {\n $group->groupjoin = group_get_join_form('joingroup' . $i++, $group->id);\n }\n else if ($group->membershiptype == 'invite') {\n $group->invite = group_get_accept_form('invite' . $i++, $group->id, $returnto);\n }\n }\n}", "function create_Listgroup($name,$listGroups)\r\n{ \r\n //adding the header line\r\n $contenue=get_string('group','local_course_group').\"; \".get_string('subGroup','local_course_group').\"; \".get_string('nameStudents','local_course_group'); \r\n foreach ($listGroups as $mainGroup => $groups) {\r\n foreach ($groups as $group => $member) {\r\n $contenue=$contenue.\"\\n\".\"$mainGroup; \"; //adding the groups of the student\r\n if($group!=$mainGroup) //if there is a sub-group\r\n $contenue=$contenue.\"$group; \";\r\n else\r\n $contenue=$contenue.get_string('none','local_course_group').\"; \";\r\n for($i=0;$i<count($member);$i++) \r\n $contenue=$contenue.\"$member[$i] \"; //adding all the student of the groups\r\n }\r\n }\r\n\r\n header('Content-Type: application/csv'); //force download of the file\r\n header('Content-Disposition: attachment; filename='. $name);\r\n header('Pragma: no-cache');\r\n header('Cache-Control: no-cache, must-revalidate');\r\n header('Expires: 0');\r\n echo $contenue;\r\n\r\n exit;\r\n}", "function system_mod_group($paramvect)\n{\n}", "function group_create($data) {\n if (!is_array($data)) {\n throw new InvalidArgumentException(\"group_create: data must be an array, see the doc comment for this \"\n . \"function for details on its format\");\n }\n\n if (!isset($data['name'])) {\n throw new InvalidArgumentException(\"group_create: must specify a name for the group\");\n }\n\n if (!isset($data['grouptype']) || !in_array($data['grouptype'], group_get_grouptypes())) {\n throw new InvalidArgumentException(\"group_create: grouptype specified must be an installed grouptype\");\n }\n\n safe_require('grouptype', $data['grouptype']);\n\n if (isset($data['jointype'])) {\n if (!in_array($data['jointype'], call_static_method('GroupType' . $data['grouptype'], 'allowed_join_types'))) {\n throw new InvalidArgumentException(\"group_create: jointype specified is not allowed by the grouptype specified\");\n }\n }\n else {\n throw new InvalidArgumentException(\"group_create: jointype specified must be one of the valid join types\");\n }\n\n if (!isset($data['ctime'])) {\n $data['ctime'] = time();\n }\n $data['ctime'] = db_format_timestamp($data['ctime']);\n\n if (!is_array($data['members']) || count($data['members']) == 0) {\n throw new InvalidArgumentException(\"group_create: at least one member must be specified for adding to the group\");\n }\n\n $data['public'] = (isset($data['public'])) ? intval($data['public']) : 0;\n $data['usersautoadded'] = (isset($data['usersautoadded'])) ? intval($data['usersautoadded']) : 0;\n\n db_begin();\n\n//Start-Anusha\n /*$id = insert_record(\n 'group',\n (object) array(\n 'name' => $data['name'],\n 'description' => $data['description'],\n 'grouptype' => $data['grouptype'],\n 'jointype' => $data['jointype'],\n 'ctime' => $data['ctime'],\n 'mtime' => $data['ctime'],\n 'public' => $data['public'],\n 'usersautoadded' => $data['usersautoadded'],\n ),\n 'id',\n true\n );*/\n\t\n\t//Start -Eshwari added courseoutcome\n\t $id = insert_record(\n 'group',\n (object) array(\n 'name' => $data['name'],\n 'description' => $data['description'],\n 'grouptype' => $data['grouptype'],\n 'jointype' => $data['jointype'],\n 'ctime' => $data['ctime'],\n 'mtime' => $data['ctime'],\n 'public' => $data['public'],\n 'usersautoadded' => $data['usersautoadded'],\n\t\t\t'outcome' => $data['outcome'],\n\t\t\t'courseoutcome' => $data['courseoutcome'],\n\t\t\t'coursetemplate' => $data['coursetemplate'],\n\t\t\t'courseoffering' => $data['courseoffering'],\n\t\t\t'parent_group' => $data['parent_group'],\n ),\n 'id',\n true\n );\n//End-Anusha\n\n foreach ($data['members'] as $userid => $role) {\n insert_record(\n 'group_member',\n (object) array(\n 'group' => $id,\n 'member' => $userid,\n 'role' => $role,\n 'ctime' => $data['ctime'],\n )\n );\n }\n\n // Copy views for the new group\n $templates = get_column('view_autocreate_grouptype', 'view', 'grouptype', $data['grouptype']);\n $templates = get_records_sql_array(\"\n SELECT v.id, v.title, v.description \n FROM {view} v\n INNER JOIN {view_autocreate_grouptype} vag ON vag.view = v.id\n WHERE vag.grouptype = 'standard'\", array());\n if ($templates) {\n require_once(get_config('libroot') . 'view.php');\n foreach ($templates as $template) {\n list($view) = View::create_from_template(array(\n 'group' => $id,\n 'title' => $template->title,\n 'description' => $template->description,\n ), $template->id);\n $view->set_access(array(array(\n 'type' => 'group',\n 'id' => $id,\n 'startdate' => null,\n 'stopdate' => null,\n 'role' => null\n )));\n }\n }\n\n $data['id'] = $id;\n handle_event('creategroup', $data);\n db_commit();\n\n return $id;\n}", "function build_host_servicegroup_details($group_members) \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n\n\t$servicegroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t{\n\t\t\tif (isset($hosts[$member]['services']))\n\t\t\t\tforeach ($hosts[$member]['services'] as $service) \n\t\t\t\t{\n\t\t\t\t\tif($NagiosUser->is_authorized_for_service($member,$service)) //user-level filtering \n\t\t\t\t\t\t$servicegroup_details[] = $service;\t\n\t\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\treturn $servicegroup_details;\n}", "function member_groups_page() {\r\n require_once( $plugin_dir . \"email-newsletter-files/page-groups.php\" );\r\n }", "function build_servicegroups_array()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$servicegroups = $NagiosData->getProperty('servicegroups');\t\t\t\n\t$services = $NagiosData->getProperty('services');\t\t\n\t$services = user_filtering($services,'services'); \n\t\n\t$servicegroups_details = array(); //multi-dim array to hold servicegroups \t\n\tforeach($servicegroups as $groupname => $members)\n\t{\n\t\t$servicegroups_details[$groupname] = array();\n \t\t//array_dump($members); \n\t\tforeach($services as $service)\n\t\t{\t\n\t\t\tif(isset($members[$service['host_name']]) && in_array($service['service_description'],$members[$service['host_name']]))\t{\n\t\t\t\tprocess_service_status_keys($service);\t\t\n\t\t\t\t$servicegroups_details[$groupname][] = $service;\t\t\t\n\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\n\treturn $servicegroups_details; \n}", "protected function getGroupList() {}", "protected function getGroupList() {}", "public function findGroups() {\n\t\t\n\t}", "function _addLayoutGroup($parentLayGrp, $custLayGrp, $ovServer)\n{\n\t// layout group ($parentLayGrp) on the OV server specified ($ovServer). \n\t//\n\t// Inputs:\n\t//\t$parentLayGrp - parent group. null if assigned to root of tree.\n\t//\t$custLayGrp - custom's layout group name.\n\t//\t$ovServer - OV server to add group.\n\t// Output: none\n\t//\n _log(\"addLayoutGroup: Starting.\",\"info\");\n _log(\"addLayoutGroup: adding group $parentLayGrp/$custLayGrp on $ovServer\",\"info\");\n global $opcdir, $output, $opclaygrp_cmd, $gRoshTimeOut;\n\n if ($parentLayGrp == '')\n {\n\t\t$group = $custLayGrp;\n\t}\n\telse\n\t{\n\t\t$group = $parentLayGrp . '/' . $custLayGrp;\n\t}\n\t$cmd = \"/opsw/bin/rosh -W $gRoshTimeOut -n $ovServer -l root '$opclaygrp_cmd \";\n\t$cmd .= \"-add_lay_group lay_group=$group '\";\n \n _log(\"addLayoutGroup: cmd: $cmd\",\"debug\");\n _execCmdWithRetry($cmd);\n _log(\"output is $output\",\"debug\");\n\n _parseOutputForError($output_array,'ERROR','addLayoutGroup');\n _log(\"addLayoutGroup: Exiting.\",\"info\");\n}", "public static function getGroupList() {\n $params = $_GET;\n if (isset($params['parent_id'])) {\n // requesting child groups for a given parent\n $params['page'] = 1;\n $params['rp'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n else {\n $requiredParams = [];\n $optionalParams = [\n 'title' => 'String',\n 'created_by' => 'String',\n 'group_type' => 'String',\n 'visibility' => 'String',\n 'component_mode' => 'String',\n 'status' => 'Integer',\n 'parentsOnly' => 'Integer',\n 'showOrgInfo' => 'Boolean',\n 'savedSearch' => 'Integer',\n // Ignore 'parent_id' as that case is handled above\n ];\n $params = CRM_Core_Page_AJAX::defaultSortAndPagerParams();\n $params += CRM_Core_Page_AJAX::validateParams($requiredParams, $optionalParams);\n\n // get group list\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n\n // if no groups found with parent-child hierarchy and logged in user say can view child groups only (an ACL case),\n // go ahead with flat hierarchy, CRM-12225\n if (empty($groups)) {\n $groupsAccessible = CRM_Core_PseudoConstant::group();\n $parentsOnly = $params['parentsOnly'] ?? NULL;\n if (!empty($groupsAccessible) && $parentsOnly) {\n // recompute group list with flat hierarchy\n $params['parentsOnly'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n }\n\n //NYSS 5259 convert line breaks to html\n foreach ( $groups['data'] as &$group ) {\n $group['description'] = str_replace('\\r\\n', '\\n', $group['description']);\n $group['description'] = str_replace('\\r', '\\n', $group['description']);\n $group['description'] = str_replace('\\n', '<br />', $group['description']);\n } \n }\n\n CRM_Utils_JSON::output($groups);\n }", "function init_groups() {\r\n\tif (!HYPEGALLERY_GROUP_ALBUMS) {\r\n\t\treturn;\r\n\t}\r\n\tadd_group_tool_option('albums', elgg_echo('gallery:groupoption:enable'), true);\r\n\telgg_extend_view('groups/tool_latest', 'framework/gallery/group_module');\r\n}", "function CBGroups() {\n global $Cbucket;\n $this->cat_tbl = 'group_categories';\n $this->gp_tbl = 'groups';\n $this->gp_mem_tbl = 'group_members';\n //We will using CB Commenting system as posts\n //$this->gp_post_tbl = 'group_posts';\n $this->gp_topic_tbl = 'group_topics';\n $this->gp_invite_tbl = 'group_invitations';\n $this->gp_vdo_tbl = 'group_videos';\n\n //Adding Actions such Report, share,fav etc\n $this->action = new cbactions();\n $this->action->type = 'g';\n $this->action->name = 'group';\n $this->action->obj_class = 'cbgroup';\n $this->action->check_func = 'group_exists';\n $this->action->type_tbl = $this->gp_tbl;\n $this->action->type_id_field = 'group_id';\n \n \n if (isSectionEnabled('groups'))\n $Cbucket->search_types['groups'] = \"cbgroup\";\n \n }", "public static function groups_page()\n\t{\n\n\t\t//If the form was submitted\n\t\tif ( $_POST ){\n\n\t\t\t//Do a bit of validation\n\t\t\tif ( ! $_POST['mz_group_name'] ){\n\t\t\t\t$error = 'You must fill in the form';\n\t\t\t\tmz_Groups::newGroupForm( $error );\n\t\t\t} else {\n\t\t\t\t//Make the update\n\t\t\t\t$mz_group_name = esc_sql( stripslashes( $_POST['mz_group_name'] ) );\n\t\t\t\tglobal $wpdb;\n\t\t\t\t$ins = $wpdb->query('INSERT INTO ' . $wpdb->prefix . GROUPS_DB_TABLE . ' ( groupname , groupactive ) VALUES (\"' . $mz_group_name . '\" , \"0\") ');\n\t\t\t}\n\n\t\t}\n\n\n\t\techo '<div class=\"wrap\">';\n\t\techo '<h2>Mentorz - Group Administration</h2>';\n\n\t\t//Generate the form\n\t\tmz_Groups::newGroupForm();\n\n\t\tglobal $wpdb;\n\t\t$results = $wpdb->get_results('SELECT * FROM ' . $wpdb->prefix . GROUPS_DB_TABLE , ARRAY_A);\n\n\t\tif(count($results)){\n\t\t\t\n\t\t\techo '<p>&nbsp;</p>';\n\t\t\techo '<table cellspacing=\"0\" class=\"widefat\">';\n\t\t\techo '<thead>';\n\t\t\t\techo '<tr>';\n\t\t\t\t\techo '<th class=\"column-title\"><span>Group Name</span></th>';\n\t\t\t\t\t//echo '<th class=\"column-title\">Group Active</th>';\n\t\t\t\t\techo '<th class=\"column-title\">Edit</th>';\n\t\t\t\t\techo '<th class=\"column-title\">Delete</th>';\n echo '<th class=\"column-title\">Info</th>';\n\n echo '</tr>';\n\t\t\techo '</thead>';\n\n\t\t\tforeach ($results as $key => $value) {\n\n\t\t\t\t//Clean up the status\n\t\t\t\t$status = $value['groupactive'];\n\t\t\t\tif ( $status == 0 ){\n\t\t\t\t\t$status = \"Inactive\";\n\t\t\t\t} elseif ( $status == 1 ){\n\t\t\t\t\t$status = \"Active\";\n\t\t\t\t}\n\n\t\t\t\techo '<tbody>';\n\t\t\t\t\techo '<tr>';\n\t\t\t\t\t\techo '<td>' . $value['groupname'] . '</td>';\n\t\t\t\t\t\t//echo '<td>' . $status . '</td>';\n\t\t\t\t\t\techo '<td style=\"width: 30px;\">';\n\t\t\t\t\t\t\techo '<a href=\"' . str_replace( '%7E', '~', $_SERVER['REQUEST_URI']) . '&edit='.$value['groupid'].'\" class=\"\">EDIT</a>';\n\t\t\t\t\t\techo '</td>';\n\t\t\t\t\t\techo '<td style=\"width: 30px;\">';\n\t\t\t\t\t\t\techo '<a href=\"' . str_replace( '%7E', '~', $_SERVER['REQUEST_URI']) . '&del='.$value['groupid'].'\" class=\"\">DELETE</a>';\n\t\t\t\t\t\techo '</td>';\n echo '<td style=\"width: 30px;\">';\n echo '<a href=\"#\" class=\"mz_accordion_button\" rel=\"mz_accord_'.$value['groupid'].'\">INFO</a>';\n echo '</td>';\n\t\t\t\t\techo '</tr>';\n\n echo '<tr class=\"mz_accord mz_accord_'.$value['groupid'].'_inner\">';\n echo '<td style=\"width: 30px;\" colspan=\"99\">';\n echo '<div>';\n\n $mentor = mz_Func::get_group_mentor( $value['groupid'] );\n\n if ( $mentor ){\n echo '<h4>The group mentor is ' . mz_Func::get_group_mentor( $value['groupid'] ) . '</h4>';\n } else {\n echo '<h4>The group does not have a mentor</h4>';\n }\n\n $students = mz_func::get_all_students_in_group( $value['groupid'] );\n\n if ( $students ){\n\n echo '<h4>The groups beneficiaries are</h4>';\n echo '<ul>';\n\n foreach ( $students as $student ) {\n\n echo '<li>'.mz_Func::get_users_display_name( $student['userid'] ).'</li>';\n\n }\n\n echo '</ul>';\n\n } else {\n\n echo '<h4>The group does not have any beneficiaries</h4>';\n\n }\n\n\n\n echo '</div>';\n echo '</td>';\n echo '</tr>';\n\n\t\t\t\techo '</tbody>';\n\n\n\t\t\t}//fe\n\n\t\t} else {\n\n\t\t\techo '<h3>There are no groups yet</h3>';\n\t\t\t\n\t\t}\n\n\t\techo '</div>';\n\n\t}", "function _start_group($key='', $value='', $name=''){\n\t$out = array(\n\t\t'id' => $name.'__group-'.$key,\n\t\t'type' => 'group-start',\n\t\t'name' => $value['name'],\n\t\t'desc' => $value['desc'],\n\t\t'no_esc_html' => true,\n\t\t'label_tag' => 'h3',\n\t\t'class' => 'custom_layout_options',\n\t); \n\treturn $out;\n}", "function ajax_get_all_groups() {\r\n global $wpdb;\r\n\r\n $groups = $this->get_groups();\r\n\r\n if ( is_array( $groups ) && 0 < count( $groups ) ) {\r\n\r\n $i = 0;\r\n $n = ceil( count( $groups ) / 5 );\r\n\r\n $html = '';\r\n $html .= '<ul class=\"clients_list\">';\r\n\r\n\r\n\r\n foreach ( $groups as $group ) {\r\n if ( $i%$n == 0 && 0 != $i )\r\n $html .= '</ul><ul class=\"clients_list\">';\r\n\r\n $html .= '<li><label>';\r\n $html .= '<input type=\"checkbox\" name=\"groups_id[]\" value=\"' . $group['group_id'] . '\" /> ';\r\n $html .= $group['group_id'] . ' - ' . $group['group_name'];\r\n $html .= '</label></li>';\r\n\r\n $i++;\r\n }\r\n\r\n $html .= '</ul>';\r\n } else {\r\n $html = 'false';\r\n }\r\n\r\n die( $html );\r\n\r\n }", "function getGroup() ;", "function createGroupSelector($groupname,$target=\"gencerts.php\") {\r\n \r\n global $db;\r\n \r\n // create group selector\r\n $cont = '<div>';\r\n $cont .= '<form method=\"get\" action=\"'.$target.'\">';\r\n $cont .= '<label for=\"groupname\">select group</label>';\r\n $cont .= '<input type=\"hidden\" name=\"mode\" value=\"'. $this->mode .'\" />';\r\n $cont .= '<select name=\"groupname\" id=\"group\" onchange=\"document.selectGroup.submit()\">';\r\n \r\n $cont .= '<option value=\"\"' . ($groupname == ''?' selected=\"selected\"':'') . '></option>';\r\n \r\n $db->query('SELECT * FROM ' . TABLE_GROUPLIST . ' ORDER BY groupname ASC');\r\n \r\n while ($r = $db->next())\r\n $cont .= '<option' . ($groupname == $r['groupname']?' selected=\"selected\"':'') . '>' . $r['groupname'] . '</option>';\r\n \r\n $cont .= '</select>';\r\n if($this->mode != 'pwlist-print')\r\n $cont .= '<input type=\"submit\" name=\"print\" value=\"printable\"\\>';\r\n else\r\n $cont .= '</form>';\r\n $cont .= '</div>';\r\n \r\n return $cont;\r\n }", "public static function getPluignGroups()\n\t\t{\n\n\t\t\t$groups = array(\n\n\t\t\t\t'christina' => array(\n\t\t\t\t\t'id'\t\t\t\t=> 'christina',\n\t\t\t\t\t'title'\t\t\t\t=> 'Christina',\n\t\t\t\t\t'icon' \t\t\t\t=> 'admin-appearance',\n\t\t\t\t\t'excerpt' \t\t\t=> 'Enable your students to submit assignments, have them collaborate in groups and get inline feedback.',\n\t\t\t\t\t'image' \t\t\t=> 'http://dummyimage.com/308x160',\n\t\t\t\t\t'link' \t\t\t\t=> 'http://code.ubc.ca/studiorum/courses/christina',\n\t\t\t\t\t'content' \t\t\t=> __( '<p>Create assignments - with deadlines - that enable your students to submit their work in a beautiful rich text editor. The student (and peers in their custom user groups) are able to make inline comments to get fine-grained critique.</p>', 'studiorum' ),\n\t\t\t\t\t'content_sidebar' \t=> 'http://dummyimage.com/300x150',\n\t\t\t\t\t'date'\t\t\t\t=> '2014-06-01',\n\t\t\t\t\t'plugins'\t\t\t=> array(\n\t\t\t\t\t\t'gravityforms/gravityforms.php',\n\t\t\t\t\t\t'gravity-forms-custom-post-types/gfcptaddon.php',\n\t\t\t\t\t\t'gravity-forms-wysiwyg/gf_wysiwyg.php',\n\t\t\t\t\t\t'studiorum-lectio/studiorum-lectio.php',\n\t\t\t\t\t\t'studiorum-side-comments/studiorum-side-comments.php',\n\t\t\t\t\t\t'studiorum-user-groups/studiorum-user-groups.php'\n\t\t\t\t\t),\n\t\t\t\t\t'examples' \t\t\t=> array(\n\t\t\t\t\t\t'http://arts.ubc.ca/arts-one/'\n\t\t\t\t\t)\n\t\t\t\t),\n\t\t\t\t\n\t\t\t\t'simon' => array(\n\t\t\t\t\t'id'\t\t\t\t=> 'simon',\n\t\t\t\t\t'title'\t\t\t\t=> 'Simon',\n\t\t\t\t\t'icon' \t\t\t\t=> 'lightbulb',\n\t\t\t\t\t'excerpt' \t\t\t=> 'Enable students to rate each others\\' work simply and easily using a hot-or-not style voting system.',\n\t\t\t\t\t'image' \t\t\t=> 'http://dummyimage.com/308x160/222/fff',\n\t\t\t\t\t'link' \t\t\t\t=> 'http://code.ubc.ca/studiorum/courses/simon',\n\t\t\t\t\t'content' \t\t\t=> __( '<p>Provide a simple way for your students to provide hot-or-not style feedback to easily discover which content is best.</p>', 'studiorum' ),\n\t\t\t\t\t'content_sidebar' \t=> 'http://dummyimage.com/300x150',\n\t\t\t\t\t'date'\t\t\t\t=> '2014-07-01',\n\t\t\t\t\t'plugins'\t\t\t=> array(\n\t\t\t\t\t\t'gravityforms/gravityforms.php',\n\t\t\t\t\t\t'gravity-forms-custom-post-types/gfcptaddon.php',\n\t\t\t\t\t\t'gravity-forms-wysiwyg/gf_wysiwyg.php',\n\t\t\t\t\t\t'studiorum-lectio/studiorum-lectio.php',\n\t\t\t\t\t\t'custom-css-meta-box/custom-css-meta-box.php'\n\t\t\t\t\t),\n\t\t\t\t\t'examples' \t\t\t=> array(\n\t\t\t\t\t\t'http://physics.ubc.ca/'\n\t\t\t\t\t)\n\t\t\t\t),\n\n\t\t\t\t'paul' => array(\n\t\t\t\t\t'id'\t\t\t\t=> 'paul',\n\t\t\t\t\t'title'\t\t\t\t=> 'Paul',\n\t\t\t\t\t'icon' \t\t\t\t=> 'share',\n\t\t\t\t\t'excerpt' \t\t\t=> 'Curate content via delicious.com and show it on your site in a beautiful, searchable, engaging way.',\n\t\t\t\t\t'image' \t\t\t=> 'http://dummyimage.com/308x160/fff/333',\n\t\t\t\t\t'link' \t\t\t\t=> 'http://code.ubc.ca/studiorum/courses/paul',\n\t\t\t\t\t'content' \t\t\t=> __( '<p>Curate and tag content using the popular delicious.com service and then allow students to search quickly and easily to see the content you want them to see.</p>', 'studiorum' ),\n\t\t\t\t\t'content_sidebar' \t=> 'http://dummyimage.com/300x150',\n\t\t\t\t\t'date'\t\t\t\t=> '2014-05-01',\n\t\t\t\t\t'plugins'\t\t\t=> array(\n\t\t\t\t\t\t'studiorum-hon/studiorum-delicious.php'\n\t\t\t\t\t),\n\t\t\t\t\t'examples' \t\t\t=> array(\n\t\t\t\t\t\t'http://sauder.ubc.ca/'\n\t\t\t\t\t)\n\t\t\t\t),\n\n\t\t\t);\n\n\t\t\treturn $groups;\n\n\t\t}", "function fantacalcio_admin_groups_list() {\n $out = \"\";\n \n $out .= l(\"Aggiungi girone\", \"admin/fantacalcio/groups/add\", array(\n \"attributes\" => array(\"class\" => \"btn btn-info\"))) . \"<br/><br/>\";\n \n $groups = Group::all();\n $competitions = Competition::all();\n if ($groups) {\n $header = array(\n t(\"Girone\"), \n t(\"Attivo\"), \n t(\"Calendario\"), \n t(\"Classfica\"), \n t(\"Formazioni\"), \n t(\"Newsletter\"));\n foreach ($groups as $g_id => $group) {\n $rows[] = array(\n l($competitions[$group->competition_id]->name . \" - \" . $group->name, \"admin/fantacalcio/groups/\" . $g_id), \n fantacalcio_check_value($group->active), \n \n // \"<img src='\" .base_path() . drupal_get_path(\"module\", \"fantacalcio\") . \"/images/\" . get_image_check($group->active) . \"'>\",\n $group->matches_order, \n $group->standings_order, \n $group->lineups_order, \n $group->newsletters_order);\n }\n $out .= theme(\"table\", (array(\n \"header\" => $header, \n \"rows\" => $rows, \n \"attributes\" => array(\"class\" => array(\"table\", \"table-responsive\")), \n \"empty\" => t(\"Nessun gruppo\"))));\n }\n \n return $out;\n}", "function get_hostgroup_data()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\n\t$hostgroups = $NagiosData->getProperty('hostgroups');\n\t$hosts = $NagiosData->getProperty('hosts');\n\n\t$hostgroup_data = array();\n\tforeach ($hostgroups as $group => $members) \n\t{\n\t\t\n\t\t\n\t\t$hostgroup_data[$group] = array(\n\t\t\t'member_data' => array(),\n\t\t\t'host_counts' => get_state_of('hosts', build_hostgroup_details($members)),\n\t\t\t'service_counts' => get_state_of('services', build_host_servicegroup_details($members))\n\t\t\t);\n\t\t\n\t\t//skip ahead if there are no authorized hosts\t\t\t\n\t\tif(array_sum($hostgroup_data[$group]['host_counts'])==0) continue; //skip empty groups \n\t\t\t\n\t\tforeach ($members as $member) \n\t\t{\n\t\t\n\t\t\tif(!$NagiosUser->is_authorized_for_host($member)) continue; //user-level filtering \t\t\n\t\t\n\t\t\t$host = $hosts[$member];\n\t\t\tprocess_host_status_keys($host); \n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_name'] = $host['host_name'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_state'] = $host['current_state'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['state_class'] = get_color_code($host);\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'] = array();\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_url'] = \n\t\t\t\tBASEURL.'index.php?type=hostdetail&name_filter='.urlencode($host['host_name']);\n\n\t\t\t\n\t\t\tif (isset($host['services'])) {\n\t\t\t\tforeach($host['services'] as $service) {\n\t\t\t\t\n\t\t\t\t\tif(!$NagiosUser->is_authorized_for_service($member,$service['service_description'])) continue; //user-level filtering \t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\tprocess_service_status_keys($service);\n\t\t\t\t\t$service_data = array(\n\t\t\t\t\t\t'state_class' => get_color_code($service),\n\t\t\t\t\t\t'description' => $service['service_description'],\n\t\t\t\t\t\t'service_url' => htmlentities(BASEURL.'index.php?type=servicedetail&name_filter='.$service['service_id']),\n\t\t\t\t\t);\n\t\t\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'][] = $service_data;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t}\n\treturn $hostgroup_data;\n}", "abstract protected function getGroupList() ;", "function createAnEvent($group)\n{\n $dataerror = false; //no error\n if ($group != null) {\n //If the required informations exist and if they are valid:\n if (isset($group['name'], $group['password'], $group['visibility']) && chkLength($group['name'], 50) && $group['visibility'] > 0 && $group['visibility'] < 13) {\n if (isset($group['context'])) {\n if (chkLength($group['context'], 200) == false) {\n $dataerror = true;\n }\n }\n if (isset($group['description'])) {\n if (chkLength($group['description'], 200) == false) {\n $dataerror = true;\n }\n }\n $group['restrict_access'] = chkToTinyint($group['restrict_access']);\n\n //Check password for important action\n if (checkUserPassword($_SESSION['user']['id'], $group['password'])) {\n\n unset($group['password']); //unset for not include it in the creation of the group\n $group['status'] = \"Créé le \" . date(\"d M y\");\n $group['creator_id'] = $_SESSION['user']['id'];\n $group['creation_date'] = timeToDT(time());\n\n createGroup($group);\n flshmsg(16); //\"group well created\" msg\n groups(); //back to groups page\n } else {\n flshmsg(15); //password error for action\n $dataerror = false; //unset error to protect the flshmsg of password error\n require_once \"view/createAGroup.php\";\n }\n displaydebug($group);\n } else {\n $dataerror = true;\n }\n if ($dataerror) {\n flshmsg(14);\n require_once \"view/createAGroup.php\";\n }\n displaydebug($dataerror);\n displaydebug($_SESSION);\n } else {\n require_once \"view/createAGroup.php\";\n }\n}", "function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++) { //for each group\n if (isset($groups[$i])) { // Patched by SysCo/al\n $line=trim($groups[$i]);\n \n if (strlen($line)>0){ \n //more presumptions, they're all prefixed with CN= (but no more yet, patched by SysCo/al\n //so we ditch the first three characters and the group\n //name goes up to the first comma\n $bits=explode(\",\",$line);\n if (1== count($bits)) {\n $group_array[]=$bits[0]; // Patched by SysCo/al\n } else {\n $prefix_len=strpos($bits[0], \"=\"); // Patched by SysCo/al to allow also various length (not only 3)\n if (FALSE === $prefix_len) {\n $group_array[]=$bits[0];\n } else {\n $group_array[]=substr($bits[0],$prefix_len+1); // Patched by SysCo/al\n }\n }\n }\n }\n }\n return ($group_array);\t\n }", "function createGroup($post,$deviceType,$appVersion,$OSVersion,$browserVersion)\n{\n $con=connectToDB(); //connect to the DB\n mysql_query('SET NAMES UTF8');\n\tsession_start();\n $OrgID=$_SESSION['OrgID'];\n\t$GroupName=$post['GroupName'];\n\t$StatusID='1';\n\t$CreatedDateTime = date('Y-m-d H:i:s');\n\t$ModifyDateTime = date('Y-m-d H:i:s');\n\t\n\t\n\t\n $result = mysql_query(\"INSERT INTO `SCP_Groups` (`GroupName`, `OrgID`, `StatusID`,`CreatedDateTime`, `ModifyDateTime`) VALUES ('$GroupName','$OrgID', '$StatusID','$CreatedDateTime', '$ModifyDateTime')\");\n if (!$result) die('Invalid query: ' . mysql_error());\n\n if($result) {\n $data['responseData'] = '';\n $data['message'] = \"Group create sucessfully\";\n $data['responseCode'] = \"200\";\n $data['status'] = \"1\";\n } else {\n $data['responseData'] = '';\n $data['message'] = \"Error in Creation\";\n $data['responseCode'] = \"201\";\n $data['status'] = \"0\";\n }\n print json_encode($data);\n mysql_close($con); //close the connection\n}", "public function groupAction(){\n $group_DB = new Application_Model_DbTable_Group();\n \n $group_id = $this->_request->getParam('g');\n $target_id = $this->_request->getParam('t');\n $game_id = $this->_request->getParam('gm');\n \n //Return After Planining\n if( $group_id && $target_id ){\n $group = $group_DB->get( $group_id );\n $this->view->group = $group;\n $this->view->group_id = $group_id;\n $this->view->target_id = $target_id;\n $this->view->game_id = $game_id;\n }\n else if( $group_id ){\n $group = $group_DB->get( $group_id );\n $this->view->group_id = $group_id;\n $this->view->group = $group;\n }\n $comments_DB = new Application_Model_DbTable_Comments();\n if (!isset($_SESSION['Default']['field'])) {\n $this->view->comments = \"\";\n $this->view->field_error = true;\n } else {\n $last_comment = $comments_DB->getLast($group_id, $_SESSION['Default']['field']);\n $this->view->comments = $last_comment['text'];\n }\n }", "public function run()\n {\n $g1 = ['b_group' => 'AB-' , 'slug' => str_slug('AB negative')];\n\t\t$g2 = ['b_group' => 'AB+' , 'slug' => str_slug('AB positive')];\n\t\t$g3 = ['b_group' => 'B-' , 'slug' => str_slug('B negative')];\n\t\t$g4 = ['b_group' => 'B+' , 'slug' => str_slug('B positive')];\n\t\t$g5 = ['b_group' => 'A-' , 'slug' => str_slug('A negative')];\n\t\t$g6 = ['b_group' => 'A+' , 'slug' => str_slug('A positive')];\n\t\t$g7 = ['b_group' => 'O-' , 'slug' => str_slug('O negative')];\n\t\t$g8 = ['b_group' => 'O+' , 'slug' => str_slug('O positive')];\n\n\n\t\tGroups::create($g1);\n\t\tGroups::create($g2);\n\t\tGroups::create($g3);\n\t\tGroups::create($g4);\n\t\tGroups::create($g5);\n\t\tGroups::create($g6);\n\t\tGroups::create($g7);\n\t\tGroups::create($g8);\n\n\n\n\t}", "public function getGroupList()\n\t{\n\t\t$db = FabrikWorker::getDbo(true);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('DISTINCT(group_id)')->from('#__{package}_formgroup');\n\t\t$db->setQuery($query);\n\t\t$usedgroups = $db->loadResultArray();\n\t\tJArrayHelper::toInteger($usedgroups);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('id AS value, name AS text')->from('#__{package}_groups');\n\t\tif (!empty($usedgroups)) {\n\t\t\t$query->where('id NOT IN('.implode(\",\", $usedgroups) .')');\n\t\t}\n\t\t$query->where('published <> -2');\n\t\t$query->order(FabrikString::safeColName('text'));\n\t\t$db->setQuery($query);\n\t\t$groups = $db->loadObjectList();\n\t\t$list = JHTML::_('select.genericlist', $groups, 'jform[groups]', \"class=\\\"inputbox\\\" size=\\\"10\\\" style=\\\"width:100%;\\\" \", 'value', 'text', null, $this->id . '-from');\n\t\treturn array($groups, $list);\n\t}", "function group_list()\n {\n //create model object\n $groupObj=new groupModel();\n \n \n //get all listing\n $groupObj->getgroupList();\n \n \n $jsData = Layout::bufferContent(URI::getAbsModulePath().\"/js/group_list.php\");\n \n \n //create javascript variable for ajax url\n Layout::addFooter($jsData);\n\n //render layout\n Layout::renderLayout();\n \n }", "function phpkd_vblvb_settinggroup($dogroup, $advanced = 0)\n{\n\tglobal $settingscache, $grouptitlecache, $vbulletin, $vbphrase, $bgcounter, $settingphrase;\n\n\tif (!is_array($settingscache[\"$dogroup\"]))\n\t{\n\t\treturn;\n\t}\n\n\tprint_column_style_code(array('width:45%', 'width:55%'));\n\n\techo \"<thead>\\r\\n\";\n\n\tprint_table_header(\n\t\t$settingphrase[\"settinggroup_$grouptitlecache[$dogroup]\"]\n\t\t . iif($vbulletin->debug && PHPKD_VBLVB_DEBUG,\n\t\t\t'<span class=\"normal\">' .\n\t\t\tconstruct_link_code($vbphrase['edit'], \"phpkd_vblvb.php?\" . $vbulletin->session->vars['sessionurl'] . \"do=editgroup&amp;grouptitle=$dogroup\") .\n\t\t\tconstruct_link_code($vbphrase['delete'], \"phpkd_vblvb.php?\" . $vbulletin->session->vars['sessionurl'] . \"do=removegroup&amp;grouptitle=$dogroup\") .\n\t\t\tconstruct_link_code($vbphrase['add_setting'], \"phpkd_vblvb.php?\" . $vbulletin->session->vars['sessionurl'] . \"do=addsetting&amp;grouptitle=$dogroup\") .\n\t\t\t'</span>'\n\t\t)\n\t);\n\n\techo \"</thead>\\r\\n\";\n\n\t$bgcounter = 1;\n\n\tforeach ($settingscache[\"$dogroup\"] AS $settingid => $setting)\n\t{\n\t\tif (($advanced || !$setting['advanced']) && !empty($setting['varname']))\n\t\t{\n\t\t\tphpkd_vblvb_setting($setting, $settingphrase);\n\t\t}\n\t}\n}", "function createGroup($groupinfo) {\n // make sure user is authorized to do this\n die ('unimplemented: '.__CLASS__.'::'.__FUNCTION__.' ('.__LINE__.':'.__FILE__.')');\n }", "public function createDefaultSDLTMemberGroups()\n {\n $cisoGroup = Group::get()->find('Code', UserGroupConstant::GROUP_CODE_CISO);\n\n if (!($cisoGroup && $cisoGroup->ID)) {\n $cisoGroup = Group::create();\n $cisoGroup->Title = 'NZTA-SDLT-CISO';\n $cisoGroup->Code = UserGroupConstant::GROUP_CODE_CISO;\n $cisoGroup->write();\n }\n\n $saGroup = Group::get()->find('Code', UserGroupConstant::GROUP_CODE_SA);\n\n if (!($saGroup && $saGroup->ID)) {\n $saGroup = Group::create();\n $saGroup->Title = 'NZTA-SDLT-SecurityArchitect';\n $saGroup->Code = UserGroupConstant::GROUP_CODE_SA;\n $saGroup->write();\n }\n\n $usersGroup = Group::get()->find('Code', UserGroupConstant::GROUP_CODE_USER);\n\n if (!($usersGroup && $usersGroup->ID)) {\n $usersGroup = Group::create();\n $usersGroup->Title = 'NZTA-SDLT-Users';\n $usersGroup->Code = UserGroupConstant::GROUP_CODE_USER;\n $usersGroup->write();\n }\n }", "function adrotate_manage_group() {\n\tglobal $wpdb, $adrotate_config, $adrotate_debug;\n\n\t$status = $view = $group_edit_id = '';\n\tif(isset($_GET['status'])) $status = esc_attr($_GET['status']);\n\tif(isset($_GET['view'])) $view = esc_attr($_GET['view']);\n\tif(isset($_GET['group'])) $group_edit_id = esc_attr($_GET['group']);\n\n\tif(isset($_GET['month']) AND isset($_GET['year'])) {\n\t\t$month = esc_attr($_GET['month']);\n\t\t$year = esc_attr($_GET['year']);\n\t} else {\n\t\t$month = date(\"m\");\n\t\t$year = date(\"Y\");\n\t}\n\t$monthstart = mktime(0, 0, 0, $month, 1, $year);\n\t$monthend = mktime(0, 0, 0, $month+1, 0, $year);\t\n\n\t$now \t\t\t= adrotate_now();\n\t$today \t\t\t= adrotate_date_start('day');\n\t$in2days \t\t= $now + 172800;\n\t$in7days \t\t= $now + 604800;\n\t?>\n\t<div class=\"wrap\">\n\t\t<h1><?php _e('Groups', 'adrotate-pro'); ?></h1>\n\n\t\t<?php if($status > 0) adrotate_status($status); ?>\n\n\t\t<div class=\"tablenav\">\n\t\t\t<div class=\"alignleft actions\">\n\t\t\t\t<a class=\"row-title\" href=\"<?php echo admin_url('/admin.php?page=adrotate-groups');?>\"><?php _e('Manage', 'adrotate-pro'); ?></a> | \n\t\t\t\t<a class=\"row-title\" href=\"<?php echo admin_url('/admin.php?page=adrotate-groups&view=addnew');?>\"><?php _e('Add New', 'adrotate-pro'); ?></a>\n\t\t\t</div>\n\t\t</div>\n\n \t<?php\n\t if ($view == \"\") {\n\t\t\tinclude(\"dashboard/publisher/groups-main.php\");\n\t \t} else if($view == \"addnew\" OR $view == \"edit\") {\n\t\t\tinclude(\"dashboard/publisher/groups-edit.php\");\n\t \t}\n\t \t?>\n\t\t<br class=\"clear\" />\n\n\t\t<?php echo adrotate_trademark(); ?>\n\n\t</div>\n<?php\n}", "public function groupList(){\n\t\techo json_encode($this->read_database->get_groups());\n\t}", "function create_group()\n\t{\n\t\t$this->data['title'] = $this->lang->line('create_group_title');\n\n\t\tif (!$this->ion_auth->logged_in() || !$this->ion_auth->is_admin())\n\t\t{\n\t\t\tredirect('auth', 'refresh');\n\t\t}\n\n\t\t//validate form input\n\t\t$this->form_validation->set_rules('group_name', $this->lang->line('create_group_validation_name_label'), 'required|alpha_dash|xss_clean');\n\t\t$this->form_validation->set_rules('description', $this->lang->line('create_group_validation_desc_label'), 'xss_clean');\n\n\t\tif ($this->form_validation->run() == TRUE)\n\t\t{\n\t\t\t$new_group_id = $this->ion_auth->create_group($this->input->post('group_name'), $this->input->post('description'));\n\t\t\tif($new_group_id)\n\t\t\t{\n\t\t\t\t// check to see if we are creating the group\n\t\t\t\t// redirect them back to the admin page\n\t\t\t\t$this->session->set_flashdata('message', $this->ion_auth->messages());\n\t\t\t\tredirect(\"auth\", 'refresh');\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//display the create group form\n\t\t\t//set the flash data error message if there is one\n\t\t\t$this->data['message'] = (validation_errors() ? validation_errors() : ($this->ion_auth->errors() ? $this->ion_auth->errors() : $this->session->flashdata('message')));\n\n\t\t\t$this->data['group_name'] = array(\n\t\t\t\t'name' => 'group_name',\n\t\t\t\t'id' => 'group_name',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'value' => $this->form_validation->set_value('group_name'),\n\t\t\t);\n\t\t\t$this->data['description'] = array(\n\t\t\t\t'name' => 'description',\n\t\t\t\t'id' => 'description',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'value' => $this->form_validation->set_value('description'),\n\t\t\t);\n\n\t\t\t$this->_render_page('auth/create_group', $this->data);\n\t\t}\n\t}", "function setup_groups() {\n\t$taxonomy_capabilities = array(\n\t\t'manage_terms' => 'manage_categories',\n\t\t'edit_terms' => 'manage_categories',\n\t\t'delete_terms' => 'manage_categories',\n\t\t'assign_terms' => 'edit_posts',\n\t);\n\n\t$taxonomy_labels = array(\n\t\t'name' => esc_html__( 'External Connection Groups' ),\n\t\t'singular_name' => esc_html__( 'External Connection Group' ),\n\t\t'search_items' => esc_html__( 'Search External Connection Groups' ),\n\t\t'popular_items' => esc_html__( 'Popular External Connection Groups' ),\n\t\t'all_items' => esc_html__( 'All External Connection Groups' ),\n\t\t'parent_item' => esc_html__( 'Parent External Connection Group' ),\n\t\t'parent_item_colon' => esc_html__( 'Parent External Connection Group' ),\n\t\t'edit_item' => esc_html__( 'Edit External Connection Group' ),\n\t\t'update_item' => esc_html__( 'Update External Connection Group' ),\n\t\t'add_new_item' => esc_html__( 'Add New External Connection Group' ),\n\t\t'new_item_name' => esc_html__( 'New External Connection Group Name' ),\n\n\t);\n\t$args = array(\n\t\t'labels' => $taxonomy_labels,\n\t\t'public' => false,\n\t\t'show_ui' => true,\n\t\t'meta_box_cb' => false,\n\t\t'show_tagcloud' => false,\n\t\t'show_in_nav_menus' => false,\n\t\t'hierarchical' => true,\n\t\t'rewrite' => false,\n\t\t'capabilities' => $taxonomy_capabilities,\n\n\t);\n\tregister_taxonomy( 'dt_ext_connection_group', 'dt_ext_connection', $args );\n}", "function createGroup($_name,$_owner) {\n $group = R::dispense('groups');\n $group->name = $_name;\n $group->owner = $_owner;\n $id = R::store($group);\n \n $groupMembers = R::dispense('groupmembers');\n $groupMembers->member_id = $_SESSION['user_id'];\n $groupMembers->group_id = $id;\n R::store($groupMembers);\n \n return $id;\n}", "function b_system_info_show($options)\n{\n $xoops = Xoops::getInstance();\n $xoops->db();\n global $xoopsDB;\n $myts = MyTextSanitizer::getInstance();\n $block = array();\n if (!empty($options[3])) {\n $block['showgroups'] = true;\n $result = $xoopsDB->query(\"SELECT u.uid, u.uname, u.email, u.user_viewemail, u.user_avatar, g.name AS groupname FROM \" . $xoopsDB->prefix(\"groups_users_link\") . \" l LEFT JOIN \" . $xoopsDB->prefix(\"users\") . \" u ON l.uid=u.uid LEFT JOIN \" . $xoopsDB->prefix(\"groups\") . \" g ON l.groupid=g.groupid WHERE g.group_type='Admin' ORDER BY l.groupid, u.uid\");\n if ($xoopsDB->getRowsNum($result) > 0) {\n $prev_caption = \"\";\n $i = 0;\n while ($userinfo = $xoopsDB->fetchArray($result)) {\n if ($prev_caption != $userinfo['groupname']) {\n $prev_caption = $userinfo['groupname'];\n $block['groups'][$i]['name'] = $myts->htmlSpecialChars($userinfo['groupname']);\n }\n if ($xoops->isUser()) {\n $block['groups'][$i]['users'][] = array(\n 'id' => $userinfo['uid'],\n 'name' => $myts->htmlspecialchars($userinfo['uname']),\n 'pm_link' => XOOPS_URL . \"/pmlite.php?send2=1&amp;to_userid=\" . $userinfo['uid'],\n 'avatar' => XOOPS_UPLOAD_URL . '/' . $userinfo['user_avatar']\n );\n } else {\n if ($userinfo['user_viewemail']) {\n $block['groups'][$i]['users'][] = array(\n 'id' => $userinfo['uid'],\n 'name' => $myts->htmlspecialchars($userinfo['uname']),\n 'msg_link' => $userinfo['email'],\n 'avatar' => XOOPS_UPLOAD_URL . '/' . $userinfo['user_avatar']\n );\n } else {\n $block['groups'][$i]['users'][] = array(\n 'id' => $userinfo['uid'],\n 'name' => $myts->htmlspecialchars($userinfo['uname'])\n );\n }\n }\n $i++;\n }\n }\n } else {\n $block['showgroups'] = false;\n }\n $block['logourl'] = XOOPS_URL . '/images/' . $options[2];\n $block['recommendlink'] = \"<a href=\\\"javascript:openWithSelfMain('\" . XOOPS_URL . \"/misc.php?action=showpopups&amp;type=friend&amp;op=sendform&amp;t=\" . time() . \"','friend',\" . $options[0] . \",\" . $options[1] . \")\\\">\" . SystemLocale::RECOMMEND_US . \"</a>\";\n return $block;\n}", "function groups_create_automatic_grouping($courseid, $nostudentspergroup, \n $nogroups, $distribevenly, \n $groupingsettings, \n $groupid = false, \n $alphabetical = false) {\n\t\n\tif (!$nostudentspergroup and !$noteacherspergroup and !$nogroups) {\n\t\t$groupingid = false;\n\t} else {\n\t\t// Set $userids to the list of students that we want to put into groups \n\t\t// in the grouping\n\t\tif (!$groupid) {\n\t\t\t$users = get_course_students($courseid);\n \t\t$userids = groups_users_to_userids($users); \n\t\t} else {\n\t\t\t$userids = groups_get_members($groupid);\n\t\t}\n\t\t\n\t \t// Distribute the users into sets according to the parameters specified \n\t $userarrays = groups_distribute_in_random_sets($userids, \n\t $nostudentspergroup, $nogroups, $distribevenly, !$alphabetical); \n\n\t if (!$userarrays) {\n\t \t$groupingid = false;\n\t } else { \n\t \t// Create the grouping that the groups we create will go into \n\t \t$groupingid = groups_create_grouping($courseid, $groupingsettings);\n\t \t \n\t \t// Get the prefix for the names of each group and default group \n\t \t// description to give each group\n\t \tif (!$groupingsettings->prefix) {\n\t \t\t$prefix = get_string('defaultgroupprefix', 'groups');\n\t \t} else {\n\t \t\t$prefix = $groupingsettings->prefix;\n\t \t}\n\t \t\n\t \tif (!$groupingsettings->defaultgroupdescription) {\n\t \t\t$defaultgroupdescription = '';\n\t \t} else {\n\t \t\t$defaultgroupdescription = $groupingsettings->defaultgroupdescription;\n\t \t}\n\t \t\n\t \t// Now create a group for each set of students, add the group to the \n\t \t// grouping and then add the students\t\n\t \t$i = 1;\n\t\t foreach ($userarrays as $userids) {\n\t\t \t$groupsettings->name = $prefix.' '.$i;\n\t\t \t$groupsettings->description = $defaultgroupdescription;\n\t\t \t$i++;\n\t\t \t$groupid = groups_create_group($courseid, $groupsettings);\n\t\t \t$groupadded = groups_add_group_to_grouping($groupid, \n\t\t \t $groupingid);\n\t\t \tif (!$groupid or !$groupadded) {\n\t\t \t\t$groupingid = false;\n\t\t \t} else {\n\t\t\t\t\tif ($userids) {\n\t\t\t\t\t\tforeach($userids as $userid) {\n\t\t \t\t\t\t$usersadded = groups_add_member($groupid, $userid);\n\t\t\t\t\t\t\t// If unsuccessful just carry on I guess\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t \t}\n\t\t }\n\t }\n\t}\n return $groupingid;\n}", "function create_group( $args ) {\r\n global $wpdb;\r\n\r\n //checking that Client Circle not exist other ID\r\n $result = $wpdb->get_row( $wpdb->prepare( \"SELECT group_id FROM {$wpdb->prefix}wpc_client_groups WHERE LOWER(group_name) = '%s'\", strtolower( $args['group_name'] ) ), \"ARRAY_A\");\r\n if ( $result ) {\r\n if ( \"0\" != $args['group_id'] && $result['group_id'] == $args['group_id'] ) {\r\n\r\n } else {\r\n //if Client Circle exist with other ID\r\n wp_redirect( add_query_arg( array( 'page' => 'wpclients_groups', 'updated' => 'true', 'dmsg' => urlencode( __( 'The Group already exists!!!', WPC_CLIENT_TEXT_DOMAIN ) ) ), 'admin.php' ) );\r\n exit;\r\n }\r\n }\r\n\r\n\r\n if ( '0' != $args['group_id'] ) {\r\n //update when edit Client Circle\r\n $result = $wpdb->query( $wpdb->prepare( \"UPDATE {$wpdb->prefix}wpc_client_groups SET group_name = '%s', auto_select = '%s', auto_add_clients = '%s' WHERE group_id = %d\",\r\n trim( $args['group_name'] ),\r\n $args['auto_select'],\r\n $args['auto_add_clients'],\r\n $args['group_id'] ) );\r\n wp_redirect( add_query_arg( array( 'page' => 'wpclients_groups', 'updated' => 'true', 'dmsg' => urlencode( __( 'The changes of the group are saved!', WPC_CLIENT_TEXT_DOMAIN ) ) ), 'admin.php' ) );\r\n exit;\r\n } else {\r\n //create new Client Circle\r\n $result = $wpdb->query( $wpdb->prepare( \"INSERT INTO {$wpdb->prefix}wpc_client_groups SET group_name = '%s', auto_select = '%s', auto_add_clients = '%s'\",\r\n trim( $args['group_name'] ),\r\n $args['auto_select'],\r\n $args['auto_add_clients']\r\n ) );\r\n\r\n //assign all clients\r\n if ( '1' == $args['assign_all'] ) {\r\n $new_group_id = $wpdb->insert_id;\r\n\r\n $args = array(\r\n 'role' => 'wpc_client',\r\n );\r\n\r\n $clients = get_users( $args );\r\n\r\n if ( is_array( $clients ) && 0 < count( $clients ) )\r\n foreach ( $clients as $client ) {\r\n $wpdb->query( $wpdb->prepare( \"INSERT INTO {$wpdb->prefix}wpc_client_group_clients SET group_id = %d, client_id = '%d'\", $new_group_id, $client->ID ) );\r\n }\r\n\r\n }\r\n\r\n\r\n wp_redirect( add_query_arg( array( 'page' => 'wpclients_groups', 'updated' => 'true', 'dmsg' => urlencode( __( 'Client Circle is created!', WPC_CLIENT_TEXT_DOMAIN ) ) ), 'admin.php' ) );\r\n exit;\r\n }\r\n\r\n }", "function getGroups() {\n die ('unimplemented: '.__CLASS__.'::'.__FUNCTION__.' ('.__LINE__.':'.__FILE__.')');\n }", "public function account_group()\n {\n //goal: one controller and one module for complete genric Creation.\n $form_validation='account_group';\n $table_name='account_group';\n $view='accounts/account_group';\n $field='account_group_name';\n $this->insert_genric($form_validation,$table_name,$view,$field);\n }", "public function account_group()\n {\n //goal: one controller and one module for complete genric Creation.\n $form_validation='account_group';\n $table_name='account_group';\n $view='accounts/account_group';\n $field='account_group_name';\n $this->insert_genric($form_validation,$table_name,$view,$field);\n }", "private function parseGroups()\n\t{\n\t\t/**\n\t\t * Grupos\n\t\t */\n\t\t$groups = $this->habbo->groups;\n\n\t\t/**\n\t\t * Convertirlos a Entity\n\t\t */\n\t\tforeach( $groups as $group )\n\t\t\t$this->addGroup( new Group( $group ) );\n\t}", "public function main() {\n\n\t\t$this->out('Group Shell');\n\t\t$this->hr();\n\t\t$this->out('[C]reate a group');\n\t\t$this->out('[Q]uit');\n\n\t\t$classToBake = strtoupper($this->in('What would you like to do?', array('C', 'Q')));\n\t\tswitch ($classToBake) {\n\t\t\tcase 'C':\n\t\t\t\t$this->hr();\n\t\t\t\t$this->create();\n\t\t\t\tbreak;\n\t\t\tcase 'Q':\n\t\t\t\texit(0);\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$this->out('You have made an invalid selection. Please choose an action from the list.');\n\t\t}\n\t\t$this->hr();\n\t\t$this->main();\n\t}", "function renderSmallGroupList($db, $group, $groupLeader) { \n ?><div class=\"content\">\n <!-- make sure theyre in a group -->\n <?php if ($group == 0) {\n echo \"<h2>You're not in a group yet!</h2>\";\n } else {\n $myGroup = getGroup($db, $group);\n ?>\n <h2 class=\"subtitle\"><?php echo sizeof($myGroup) ?> members</h2>\n <table>\n <?php // start looping through group members\n foreach ($myGroup as $a) {\n ?>\n <tr>\n <td>\n <a href=\"/?page=viewProfile&amp;id=<?=$a['id']?>\">\n <?php \n if($a['displayName'] == \"\") {\n echo $a['name'];\n } else {\n echo $a['displayName'];\n } \n ?>\n </a>\n </td>\n </tr>\n <?php } // end looping through group members ?>\n </table>\n <a class=\"button left\" href=\"/?page=group\">Manage Group</a>\n <?php } // end if?>\n </div><?php \n}", "private function _show_list_of_groups() {\n // show groups of current user\n // create group button\n $this->load->model('membership_model');\n \n $user_id = $this->session->userdata('user')['id'];\n\n $where = array(\n 'm.user_id' => $user_id,\n 'm.status' => 1,\n 'g.status' => 1\n );\n \n $groups = $this->membership_model->fetch($where);\n\n // 1 is owner\n $where['m.type'] = 1;\n // allow status 2 for my groups for hidden\n // 0 is deleted\n unset($where['g.status']);\n $where['g.status !='] = 0;\n $my_groups = $this->membership_model->fetch($where);\n \n // membership type 2 is normal member\n $where['m.type'] = 2;\n $where['g.status'] = 1;\n $other_groups = $this->membership_model->fetch($where);\n\n // can be any type for invited\n unset($where['m.type']);\n $where['m.status'] = 2;\n $invited_groups = $this->membership_model->fetch($where);\n \n $data = array(\n 'title' => 'Groups',\n 'msg' => $this->session->flashdata('msg'),\n 'groups' => $groups,\n 'my_groups' => $my_groups,\n 'other_groups' => $other_groups,\n 'invited_groups' => $invited_groups\n );\n $this->_view(\n array('templates/nav', 'pages/dashboard/groups', 'alerts/msg'),\n array_merge($this->_nav_items, $data)\n );\n }", "public static function getAllGroups($entriesOnly = FALSE) {\n global $lC_Database, $lC_Language, $_module;\n\n $lC_Language->loadIniFile('administrators.php');\n \n $media = $_GET['media']; \n\n $QadminGroups = $lC_Database->query('select id, name from :table_administrators_groups order by id');\n $QadminGroups->bindTable(':table_administrators_groups', TABLE_ADMINISTRATORS_GROUPS);\n $QadminGroups->execute();\n\n $result = array('entries' => array());\n $result = array('aaData' => array());\n while ( $QadminGroups->next() ) {\n $name = '<td>' . $QadminGroups->valueProtected('name') . '</td>';\n $modules = '<td class=\"hide-on-tablet\">' . self::getAccessBlocks($QadminGroups->valueInt('id')) . '</td>';\n $members = '<td>' . self::getTotalMembers($QadminGroups->valueInt('id')) . '</td>';\n $action = '<td class=\"align-right vertical-center\"><span class=\"button-group compact\">\n <a href=\"' . ((int)($_SESSION['admin']['access'][$_module] < 3) ? '#' : lc_href_link_admin(FILENAME_DEFAULT, 'administrators&set=access&gid=' . $QadminGroups->valueInt('id'))) . '\" class=\"button icon-pencil ' . ((int)($_SESSION['admin']['access'][$_module] < 3) ? 'disabled' : NULL) . '\">' . (($media === 'mobile-portrait' || $media === 'mobile-landscape') ? NULL : $lC_Language->get('icon_edit')) . '</a>\n <a href=\"' . ((int)($_SESSION['admin']['access'][$_module] < 4) ? '#' : 'javascript://\" onclick=\"deleteGroup(\\'' . $QadminGroups->valueInt('id') . '\\', \\'' . urlencode($QadminGroups->valueProtected('name')) . '\\')') . '\" class=\"button icon-trash with-tooltip ' . ((int)($_SESSION['admin']['access'][$_module] < 4) ? 'disabled' : NULL) . '\" title=\"' . $lC_Language->get('icon_delete') . '\"></a></span></td>';\n // modification of default top level admin is prohibited\n if ($QadminGroups->valueInt('id') == '1' || $QadminGroups->value('name') == $lC_Language->get('text_top_administrator')) $action = '';\n $result['aaData'][] = array(\"$name\", \"$modules\", \"$members\", \"$action\");\n $result['entries'][] = $QadminGroups->toArray();\n }\n\n $QadminGroups->freeResult();\n\n if ($entriesOnly) return $result['entries'];\n return $result;\n }", "function pi_authoring_render_group_tree($group_list, &$group_data)\n{\n\t$rows_to_return = array();\n\t// Check everything in the list and return either the name or the \n\t// expanded sub-list (if it's an array) \n\tforeach($group_list as $group_id => $group_items) \n\t{\n\t\t$item_name = theme('pi_group_title', l($group_data[$group_id]['title'], 'node/' . $group_id . '/edit', array('query' => drupal_get_destination()) ), $group_data[$group_id]['group_type']);\t\t\n\t\tif(is_array($group_items))\n\t\t{\n\t\t\t//pi_debug_message(\"expanding $group_id :\" . count($group_items));\n\t\t\t$expanded_group_list = pi_authoring_render_group_tree($group_items, $group_data);\n\t\t\t$rows_to_return[] = theme('item_list', $expanded_group_list, $item_name);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//pi_debug_message(\"not expanding $group_id :\" . $item_name);\n\t\t\t$rows_to_return[] = $item_name;\n\t\t}\n\t}\n\treturn $rows_to_return;\n}", "function groupsHTML($arrAllGroups) {\n global $LANG;\n $intLastGroup=0;\n if (is_array($arrAllGroups)) {\n $intGroups = count($arrAllGroups);\n // Build Groups\n foreach($arrAllGroups as $intGroupKey => $arrSingleGroup) {\n $strOutput .= '<tr class=\"bgColor5\">\n <td colspan=\"3\"><b><em>'.$LANG->getLL(\"conditions_group\").' ' . ($intLastGroup+1) .'</em></b></td>\n <td colspan=\"2\"><b>'.$LANG->getLL(\"conditions_condition\").'</b></td>\n </tr>'.chr(10);\n $strGroupButtons = !$this->blnLocalization?implode(chr(10),$this->getGroupButtons($intGroupKey,$intGroups)):'&nbsp;';\n // Build Rules\n foreach($arrSingleGroup['rule'] as $intRuleKey => $arrRule) {\n $arrRule['field'] = stripslashes($arrRule['field']);\n $strOutput .= '<tr class=\"bgColor4\">'.chr(10);\n if ($intRuleKey!=0) {\n $strOutput .= '<td align=\"right\">'.$LANG->getLL(\"conditions_and\").'</td>'.chr(10);\n } else {\n \t$intExtraRow = !$this->blnLocalization?1:0;\n $strOutput .= '<td rowspan=\"'.(count($arrSingleGroup['rule'])+$intExtraRow).'\" class=\"bgColor5\">\n \t\t\t'.$strGroupButtons.'\n \t\t\t</td>\n <td><b>'.$LANG->getLL(\"conditions_rules\").'</b></td>'.chr(10);\n }\n $strOutput .= '<td style=\"white-space:nowrap;\">';\n if (!$this->blnLocalization) {\n\t\t\t\t\t\t$strOutput .= '<select name=\"'.$this->strExtKey.'[grps]['.$intGroupKey.'][rule]['.$intRuleKey.'][field]\" onChange=\"submit();\">\n\t \t\t\t'.implode(chr(10),$this->getFields($arrRule['field'])).'\n\t \t\t\t</select>';\n } else {\n \t$arrFields = $this->getFields($arrRule['field']);\n \t$strOutput .= '<input name=\"'.$this->strExtKey.'[grps]['.$intGroupKey.'][rule]['.$intRuleKey.'][field]\" type=\"hidden\" value=\"'.$arrFields['uid'].'\" />'.$arrFields['title'];\n }\n\t\t\t\t\t$strOutput .= '</td>\n <td style=\"white-space:nowrap;\">';\n $strOutput .= implode(chr(10),$this->getOperators($this->strExtKey.'[grps]['.$intGroupKey.'][rule]['.$intRuleKey.']',$arrRule));\n $strOutput .= '</td>\n <td width=\"11\">';\n // No trashbin when single rule in a group\n if (!$this->blnLocalization && count($arrSingleGroup['rule'])>1) {\n $strOutput .= '<input type=\"image\" name=\"'.$this->strExtKey.'[rule_remove]['.$intGroupKey.']['.$intRuleKey.']\"'.IconUtility::skinImg($this->objDoc->backPath,'gfx/garbage.gif').BackendUtility::titleAltAttrib($LANG->getLL(\"conditions_ruleRemove\")).' />'.chr(10);\n } else {\n \t$strOutput .='&nbsp;';\n }\n $strOutput .= '</td></tr>'.chr(10);\n }\n if (!$this->blnLocalization) {\n\t $strOutput .= '<tr class=\"bgColor4\">\n\t <td align=\"right\">'.$LANG->getLL(\"conditions_and\").'</td>\n\t <td><select name=\"'.$this->strExtKey.'[grps]['.$intGroupKey.'][rule]['.($intRuleKey+1).'][field]\" onChange=\"submit();\">\n\t <option value=\"'.$this->extKey.'_new\">'.$LANG->getLL('conditions_newField').'</option>\n\t '. implode(chr(10),$this->getFields()).'\n\t </select></td>\n\t <td colspan=\"2\"></td>\n\t </tr>'.chr(10);\n }\n $intLastGroup = $intGroupKey;\n }\n }\n // Build New Group\n if (!$this->blnLocalization) {\n\t $strOutput .= '<tr class=\"bgColor6\">\n\t <td colspan=\"5\"><b>'.$LANG->getLL(\"conditions_new\").'</b></td>\n\t </tr>\n\t <tr class=\"bgColor6\">\n\t <td>&nbsp;</td>\n\t <td><b>'.$LANG->getLL(\"conditions_rules\").'</b></td>\n\t <td colspan=\"3\"><select name=\"'.$this->strExtKey.'[grps]['.($intLastGroup+1).'][rule][0][field]\" onChange=\"submit();\">\n\t <option value=\"'.$this->extKey.'_new\">'.$LANG->getLL('conditions_newField').'</option>'\n\t . implode(chr(10),$this->getFields()).'\n\t </select></td>\n\t </tr>'.chr(10);\n }\n return $strOutput;\n\t}", "function create_group()\n\t{\n\t\t$this->data['title'] = $this->lang->line('create_group_title');\n\n\t\tif (!$this->ion_auth->logged_in() || !$this->ion_auth->is_admin())\n\t\t{\n\t\t\tredirect('auth', 'refresh');\n\t\t}\n\n\t\t// validate form input\n\t\t$this->form_validation->set_rules('group_name', $this->lang->line('create_group_validation_name_label'), 'required|alpha_dash');\n\n\t\tif ($this->form_validation->run() == TRUE)\n\t\t{\n\t\t\t$new_group_id = $this->ion_auth->create_group($this->input->post('group_name'), $this->input->post('description'));\n\t\t\tif($new_group_id)\n\t\t\t{\n\t\t\t\t// check to see if we are creating the group\n\t\t\t\t// redirect them back to the admin page\n\t\t\t\t$this->session->set_flashdata('message', $this->ion_auth->messages());\n\t\t\t\tredirect(\"auth\", 'refresh');\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// display the create group form\n\t\t\t// set the flash data error message if there is one\n\t\t\t$this->data['message'] = (validation_errors() ? validation_errors() : ($this->ion_auth->errors() ? $this->ion_auth->errors() : $this->session->flashdata('message')));\n\n\t\t\t$this->data['group_name'] = array(\n\t\t\t\t'name' => 'group_name',\n\t\t\t\t'id' => 'group_name',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'value' => $this->form_validation->set_value('group_name'),\n\t\t\t);\n\t\t\t$this->data['description'] = array(\n\t\t\t\t'name' => 'description',\n\t\t\t\t'id' => 'description',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'value' => $this->form_validation->set_value('description'),\n\t\t\t);\n\n\t\t\t$this->_render_page('auth/create_group', $this->data);\n\t\t}\n\t}", "function loadAllGroupSetting($post,$deviceType,$appVersion,$OSVersion,$browserVersion)\n{\n $con=connectToDB(); //connect to the DB\n mysql_query('SET NAMES UTF8');\n\t session_start();\n $OrgID=$_SESSION['OrgID'];\n $result = mysql_query(\"SELECT * FROM SCP_Groups WHERE OrgID='\".$OrgID.\"'\");\n //CHECK FOR ERROR\n if (!$result) die('Invalid query: ' . mysql_error());\n $rows = array();\n while($row = mysql_fetch_assoc($result)) {\n\t\t if($row['StatusID'] == 1) {\n\t\t\t\t$row['Status'] = 'Active';\n\t\t\t} else {\n\t\t\t\t$row['Status'] = 'Deactive';\n\t\t\t}\n\t\t\t$rows[] = $row;\n }\n if($rows) {\n $data['responseData'] = $rows;\n $data['message'] = \"All Groups get successfully\";\n $data['responseCode'] = \"200\";\n $data['status'] = \"1\";\n } else {\n $data['responseData'] = '';\n $data['message'] = \"No Groups Found\";\n $data['responseCode'] = \"201\";\n $data['status'] = \"0\";\n }\n print json_encode($data);\n mysql_close($con); //close the connection\n}", "static function get_apigroup();", "function addGroupHandler() {\n global $inputs;\n\n $lastId = insert('group',[\n 'admin_id' => getLogin()['uid'],\n 'group_name' => $inputs['name'],\n 'description' => $inputs['desc'],\n ]);\n\n formatOutput(true, 'add success');\n}", "public function getGroups() {}", "function wp_cache_add_global_groups($groups)\n {\n }", "function GroupListBilling($section, $err=\"\"){\n\tglobal $smarty, $dbconn, $config, $page, $lang;\n\n\tif(isset($_SERVER[\"PHP_SELF\"]))\n\t\t$file_name = AfterLastSlash($_SERVER[\"PHP_SELF\"]);\n\telse\n\t\t$file_name = \"admin_pay_services.php\";\n\n\tIndexAdminPage('admin_billing');\n\n\tif ($err){\n\t\t$form[\"err\"] = $err;\n\t\t$smarty->assign(\"error\", $lang[\"content\"][$err]);\t\n\t}\n\t$settings[\"site_unit_costunit\"] = GetSiteSettings('site_unit_costunit');\n\n\t$sorter = (isset($_REQUEST[\"sorter\"]) && !empty($_REQUEST[\"sorter\"])) ? $_REQUEST[\"sorter\"] : \"cost\";\n\t$order = (isset($_REQUEST[\"order\"]) && !empty($_REQUEST[\"order\"])) ? intval($_REQUEST[\"order\"]) : 1;\n\n\t///////// sorter & order\n\tswitch ($order){\n\t\tcase \"1\":\n\t\t\t$order_str = \" ASC\";\n\t\t\t$order_new = 2;\n\t\t\t$order_icon = \"&darr;\";\n\t\t\tbreak;\n\t\tdefault:\n\t\t\t$order_str = \" DESC\";\n\t\t\t$order_new = 1;\n\t\t\t$order_icon = \"&uarr;\";\n\t\t\tbreak;\n\t}\n\t$smarty->assign(\"order\", $order_new);\n\t$smarty->assign(\"order_icon\", $order_icon);\n\n\t$sorter_str = \" ORDER BY \";\n\tswitch($sorter) {\n\t\tcase \"cost\": $sorter_str .= \" cost\"; break;\n\t}\n\t$smarty->assign(\"sorter\", $sorter);\n\n\t///// groups\n\t$strSQL = \"SELECT id, speed from \".GROUPS_TABLE.\" where type='f' order by id\";\n\t$rs = $dbconn->Execute($strSQL);\n\t$i=0;\n\twhile(!$rs->EOF){\n\t\t$row = $rs->GetRowAssoc(false);\n\t\t$groups[$i][\"id\"] = $row[\"id\"];\n\t\t$groups[$i][\"name\"] = $lang[\"groups\"][$row[\"id\"]];\n\t\t$groups[$i][\"cost\"] = $row[\"speed\"];\n\n\t\t$j = 0;\n\t\t$strSQL_p = \"SELECT id, cost, period, amount FROM \".GROUP_PERIOD_TABLE.\" \".\n\t\t\t\t\t\"WHERE id_group='\".$row[\"id\"].\"' AND status='1' $sorter_str $order_str\";\n\t\t$rs_p = $dbconn->Execute($strSQL_p);\n\t\twhile(!$rs_p->EOF){\n\t\t\t$row_p = $rs_p->GetRowAssoc(false);\n\t\t\t$groups[$i][\"period\"][$j][\"id\"] = $row_p[\"id\"];\n\t\t\t$groups[$i][\"period\"][$j][\"count\"] = $row_p[\"amount\"];\n\t\t\t$groups[$i][\"period\"][$j][\"period\"] = $row_p[\"period\"];\n\t\t\t$groups[$i][\"period\"][$j][\"cost\"] = $row_p[\"cost\"];\n\t\t\t$groups[$i][\"period\"][$j][\"del_link\"] = \"./\".$file_name.\"?sel=speed&par=delete&id=\".$row_p[\"id\"];\n\t\t\t$rs_p->MoveNext();\n\t\t\t$j++;\n\t\t}\n\t\t$rs->MoveNext();\n\t\t$i++;\n\t}\n\t$smarty->assign(\"groups\", $groups);\n\n\t$form[\"hiddens\"] = \"<input type=hidden name=sel value=speed><input type=hidden name=section value=$section>\";\n\t$form[\"action\"] = $file_name;\n\t$form[\"costunits\"] = $settings[\"site_unit_costunit\"];\n\t$form[\"currency\"] = $form[\"costunits\"];\n\n\t$smarty->assign(\"form\", $form);\n\t$smarty->display(TrimSlash($config[\"admin_theme_path\"]).\"/admin_pay_services.tpl\");\n\texit;\n}", "function createGroup($args) {\n\t\t$this->editGroup($args);\n\t}", "function show_visible_groups($course, $listmembers, $listgroups, $filerefphp) {\t\r\n\t// Print out the selection boxes and fill with groups/members\r\n\techo \"<tr><td width=\\\"45%\\\" align=\\\"center\\\"><form name=\\\"form2\\\" id=\\\"form2\\\">\r\n\t\t<input type=\\\"hidden\\\" name=\\\"id\\\" value=\\\"$course->id\\\"><select name=\\\"groups\\\" size=\\\"15\\\" onChange=\\\"updateMembers(this)\\\" multiple>\";\r\n\tif (!empty($listgroups)) {\r\n\t\tforeach ($listgroups as $id => $listgroup) {\r\n\t\t\t$selected = '';\r\n\t\t\tif ($id == $selectedgroup) {\r\n\t\t\t $selected = 'selected=\"selected\"';\r\n\t\t\t}\r\n\t\t\techo \"<option $selected value=\\\"$id\\\">$listgroup</option>\";\r\n\t\t}\r\n\t}\r\n\techo \"</select></form></td>\";\r\n\t$sharestring = get_string('share', 'block_shared_files');\r\n\techo \"<td width=\\\"10%\\\" align=\\\"center\\\"><form name=\\\"formx\\\" id=\\\"formx\\\" method=\\\"post\\\" action=\\\"$filerefphp\\\">\";\r\n\techo \"<input type=\\\"hidden\\\" name=\\\"grpid\\\" value=\\\"\\\"><INPUT TYPE=\\\"hidden\\\" NAME=\\\"bookid\\\" VALUE=\\\"$bookid\\\"><input type=\\\"hidden\\\" name=\\\"id\\\" value=\\\"$course->id\\\"><input name=\\\"gshare\\\" type=\\\"submit\\\" value=\\\"$sharestring\\\"></form></td>\";\t\r\n\techo \"<td width=\\\"45%\\\" align=\\\"center\\\"><form name=\\\"form3\\\" id=\\\"form3\\\">\r\n <input type=\\\"hidden\\\" name=\\\"id\\\" value=\\\"$course->id\\\">\r\n <select name=\\\"members[]\\\" size=\\\"15\\\">\";\r\n if (!empty($members)) {\r\n \tforeach ($members as $id => $membername) {\r\n \techo \"<option value=\\\"$id\\\">$membername</option>\";\r\n \t}\r\n\t}\r\n echo \"</select></form></td></tr>\";\r\n}", "public function run()\n {\n $groups=[\n ['name'=>'普通会员组','is_default'=>true],\n ['name'=>'VIP'],\n ];\n collect($groups)->map(function ($group) {\n Group::create($group);\n });\n }", "function bpgex_include() {\n\trequire( dirname( __FILE__ ) . '/bp-groups-example.php' );\n}", "function getInGroup($groupID) {\n\t\tglobal $forumVariables;\n\t\t$process = new process;\n\t\t$forums = \"\";\n\t\t$db = new dbHandler();\t\t\t\t//Makes databasehandler to db\n\t\t$groupID = $db->SQLsecure($groupID);\n\t\t\n\t\trequire_once('permissionHandler.php');\n\t\t$permissions = new permissionHandler;\n\n\t\t//Get member permissions\n\t\t$permission = $permissions->permissions(\"view\");\n\t\n\t\t$i = 0;\t\t\t\t\t\t//Sets the conuntvariable to 0\n\t\t$last = \"\";\t\t\t\t//Variable for forumID in last loop\n\t\t\t\n\t\t$processForumName = \"\";\n\t\t$processInfoText = \"\";\n\t\t\n\t\t$sql = \"SELECT _'pfx'_forums.*, _'pfx'_posts.postID, _'pfx'_posts.madeBy, _'pfx'_posts.threadID, _'pfx'_posts.lastEdit AS lastPostDate, _'pfx'_members.memberID, _'pfx'_members.userName FROM ((_'pfx'_forums LEFT JOIN _'pfx'_posts ON _'pfx'_forums.lastPost = _'pfx'_posts.postID) LEFT JOIN _'pfx'_members ON _'pfx'_members.memberID = _'pfx'_posts.madeBy) WHERE _'pfx'_forums.groupID = '\".$groupID.\"' ORDER BY _'pfx'_forums.sort DESC\";\n\t\t$result = $db->runSQL($sql);\n\t\tif($db->numRows($result) == 0)\n\t\t\treturn false;\n\t\twhile($row = $db->fetchArray($result)) {\n\t\t\t$continue = false;\t\n\t\t\tforeach($permission as $element) {\n\t\t\t\tif($element['forumID'] == $row['forumID'] && !$element['permission'])\n\t\t\t\t\t$continue = true;\n\t\t\t}\n\t\t\tif($continue) {\t\t//Hide forum if user not has permission to see it \n\t\t\t\tcontinue;\n\t\t\t}\n\t\t\n\t\t\t$forums[$i]['forumID'] = $row['forumID'];\t\t//Sets the forumIDs to each group in the three dimentional array\n\t\t\t$forums[$i]['forumName'] = $row['name'];\t\t//Sets the forumnames to each group in the three dimentional array\n\t\t\t$forums[$i]['forumLastEdit'] = $row['lastEdit'];\t//Sets the forum last edit to each group in the three dimentional array\n\t\t\t$forums[$i]['forumInfoText'] = $row['infoText'];\t//Sets the forum info text to each group in the three dimentional array\t\n\t\t\t$forums[$i]['forumGroupID'] = $row['groupID'];\t//Sets the forum group name to each group in the three dimentional array\n\t\t\t$forums[$i]['forumLocked'] = $row['locked'];\n\t\t\t\t\t\t\n\t\t\t$forums[$i]['forumCountPosts'] = $row['posts'];\n\t\t\t$forums[$i]['forumCountThreads'] = $row['threads'];\n\t\t\t\n\t\t\t$forums[$i]['forumLastPost'] = $row['lastPostDate'];\n\t\t\tif($forums[$i]['forumLastPost'] == \"0000-00-00 00:00:00\") //If date is null(default value) then put nothing to variable\n\t\t\t\t$forums[$i]['forumLastPost'] = \"\";\n\t\t\t$forums[$i]['forumLastPostUsername'] = $row['userName'];\n\t\t\t$forums[$i]['forumLastPostMemberID'] = $row['memberID'];\n\t\t\t$forums[$i]['forumLastPostThreadID'] = $row['threadID'];\n\t\t\t$forums[$i]['forumLastPostID'] = $row['postID'];\n\t\t\t\n\t\t\t$processForumName[$i] = $forums[$i]['forumName'];\n\t\t\t$processInfoText[$i] = $forums[$i]['forumInfoText'];\n\t\t\t\n\t\t\t$i++;\n\t\t}\n\t\tif(empty($forums))\n\t\t\treturn false;\n\t\t\n\t\tif($forumVariables['inlogged']) {\n\t\t\t$sqlNewPosts = \"SELECT _'pfx'_forums.forumID, COUNT( _'pfx'_posts.postID ) AS newPosts FROM _'pfx'_forums INNER JOIN _'pfx'_threads INNER JOIN _'pfx'_posts ON _'pfx'_forums.forumID = _'pfx'_threads.forumID ON _'pfx'_threads.threadID = _'pfx'_posts.threadID WHERE _'pfx'_posts.lastEdit > '\".$forumVariables['lastLoginDate'].\"' AND _'pfx'_posts.editedBy != '\".$forumVariables['inloggedMemberID'].\"' GROUP BY _'pfx'_forums.forumID\";\n\t\t\t$resultNewPosts = $db->runSQL($sqlNewPosts);\n\t\t\twhile($rowNewPosts = $db->fetchArray($resultNewPosts)) {\n\t\t\t\t$k = 0;\n\t\t\t\tforeach($forums as $forumsElements) {\n\t\t\t\t\tif($forumsElements['forumID'] == $rowNewPosts['forumID'])\n\t\t\t\t\t\t$forums[$k]['forumNewPosts'] = $rowNewPosts['newPosts'];\n\t\t\t\t\t$k++;\t\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t$k = 0;\n\t\tforeach($forums as $forumsElements) {\n\t\t\tif(empty($forums[$k]['forumNewPosts']))\n\t\t\t\t$forums[$k]['forumNewPosts'] = 0;\t\t\n\t\t\t$k++;\t\n\t\t}\t\n\t\t\t\n\t\tif(!empty($processForumName) && !empty($processInfoText)) {\n\t\t\t$processForumName = $process->headline($processForumName);\n\t\t\t$processInfoText = $process->text($processInfoText);\n\n\t\t\t$k = 0;\n\t\t\tforeach($processForumName as $processForumNameElement) {\n\t\t\t\t$forums[$k]['forumName'] = $processForumNameElement;\n\t\t\t\t$k++;\n\t\t\t}\n\t\t\t$k = 0;\n\t\t\tforeach($processInfoText as $processInfoTextElement) {\n\t\t\t\t$forums[$k]['forumInfoText'] = $processInfoTextElement;\n\t\t\t\t$k++;\n\t\t\t}\n\t\t}\n\t\treturn $forums; //Returns an three dimentional array \n\t}", "function getMemberGroupInfo1() {\n global $inputs;\n\n $res = getAll('SELECT mg.*,\n\t m.name\n FROM member_group mg\n JOIN member m\n ON m.id = mg.member_id\n WHERE group_id = ?' , [$inputs['id']]);\n formatOutput(true, 'success', $res);\n}", "public function create_group()\n\t{\n\t\t$this->data['title'] = $this->lang->line('create_group_title');\n\n\t\tif (!$this->ion_auth->logged_in() || !$this->ion_auth->is_admin())\n\t\t{\n\t\t\tredirect('auth', 'refresh');\n\t\t}\n\n\t\t// validate form input\n\t\t$this->form_validation->set_rules('group_name', $this->lang->line('create_group_validation_name_label'), 'required|alpha_dash');\n\n\t\tif ($this->form_validation->run() == TRUE)\n\t\t{\n\t\t\t$new_group_id = $this->ion_auth->create_group($this->input->post('group_name'), $this->input->post('description'));\n\t\t\tif($new_group_id)\n\t\t\t{\n\t\t\t\t// check to see if we are creating the group\n\t\t\t\t// redirect them back to the admin page\n\t\t\t\t$this->session->set_flashdata('message', $this->ion_auth->messages());\n\t\t\t\tredirect(\"auth\", 'refresh');\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\t// display the create group form\n\t\t\t// set the flash data error message if there is one\n\t\t\t$this->data['message'] = (validation_errors() ? validation_errors() : ($this->ion_auth->errors() ? $this->ion_auth->errors() : $this->session->flashdata('message')));\n\n\t\t\t$this->data['group_name'] = array(\n\t\t\t\t'name' => 'group_name',\n\t\t\t\t'id' => 'group_name',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'value' => $this->form_validation->set_value('group_name'),\n\t\t\t);\n\t\t\t$this->data['description'] = array(\n\t\t\t\t'name' => 'description',\n\t\t\t\t'id' => 'description',\n\t\t\t\t'type' => 'text',\n\t\t\t\t'value' => $this->form_validation->set_value('description'),\n\t\t\t);\n\n\t\t\t$this->_render_page('auth/create_group', $this->data);\n\t\t}\n\t}", "public function group()\n {\n $this->doGroup('group', \\func_get_args());\n }", "public function create_group() {\r\n\r\n $user_id = $this->session->userdata('user_id');\r\n $this->data['dataHeader'] = $this->users->get_allData($user_id);\r\n\r\n $this->data['title'] = $this->lang->line('create_group_title');\r\n\r\n if (!$this->ion_auth->logged_in() || !$this->ion_auth->is_admin()) {\r\n redirect('auth', 'refresh');\r\n }\r\n\r\n // validate form input\r\n $this->form_validation->set_rules('group_name', $this->lang->line('create_group_validation_name_label'), 'required|alpha_dash');\r\n\r\n if ($this->form_validation->run() == TRUE) {\r\n $new_group_id = $this->ion_auth->create_group($this->input->post('group_name'), $this->input->post('description'));\r\n if ($new_group_id) {\r\n // check to see if we are creating the group\r\n // redirect them back to the admin page\r\n $this->session->set_flashdata('message', $this->ion_auth->messages());\r\n redirect(\"auth\", 'refresh');\r\n }\r\n } else {\r\n // display the create group form\r\n // set the flash data error message if there is one\r\n $this->data['message'] = (validation_errors() ? validation_errors() : ($this->ion_auth->errors() ? $this->ion_auth->errors() : $this->session->flashdata('message')));\r\n\r\n $this->data['group_name'] = array(\r\n 'name' => 'group_name',\r\n 'id' => 'group_name',\r\n 'type' => 'text',\r\n 'required' => 'required',\r\n 'class' => 'form-control',\r\n 'value' => $this->form_validation->set_value('group_name'),\r\n );\r\n $this->data['description'] = array(\r\n 'name' => 'description',\r\n 'id' => 'description',\r\n 'class' => 'form-control',\r\n 'type' => 'text',\r\n 'value' => $this->form_validation->set_value('description'),\r\n );\r\n\r\n\r\n $this->template->set_master_template('template.php');\r\n $this->template->write_view('header', 'backend/header', (isset($this->data) ? $this->data : NULL));\r\n $this->template->write_view('sidebar', 'backend/sidebar', (isset($this->data) ? $this->data : NULL));\r\n $this->template->write_view('content', 'create_group', (isset($this->data) ? $this->data : NULL), TRUE);\r\n $this->template->write_view('footer', 'backend/footer', '', TRUE);\r\n $this->template->render();\r\n\r\n// $this->_render_page('auth/create_group', $this->data);\r\n }\r\n }", "protected function set_initial_groups()\n {\n $this->_groups = apply_filters('ngg_admin_requirements_manager_groups', array('phpext' => __('NextGen Gallery requires the following PHP extensions to function correctly. Please contact your hosting provider or systems admin and ask them for assistance:', 'nggallery'), 'phpver' => __('NextGen Gallery has degraded functionality because of your PHP version. Please contact your hosting provider or systems admin and ask them for assistance:', 'nggallery'), 'dirperms' => __('NextGen Gallery has found an issue trying to access the following files or directories. Please ensure the following locations have the correct permissions:', 'nggallery')));\n }", "function eio_grp_add($grp, $req)\n{\n}", "public static abstract function getGroupList();", "function AnnouncementSelectMembergroup()\n{\n\tglobal $txt, $context, $topic;\n\n\t$groups = getAnnounceGroups();\n\n\t$context['groups'] = array();\n\tif (in_array(0, $groups))\n\t{\n\t\t$context['groups'][0] = array(\n\t\t\t'id' => 0,\n\t\t\t'name' => $txt['announce_regular_members'],\n\t\t\t'member_count' => 'n/a',\n\t\t);\n\t}\n\n\t// Get all membergroups that have access to the board the announcement was made on.\n\t$request = wesql::query('\n\t\tSELECT mg.id_group, COUNT(mem.id_member) AS num_members\n\t\tFROM {db_prefix}membergroups AS mg\n\t\t\tLEFT JOIN {db_prefix}members AS mem ON (mem.id_group = mg.id_group OR FIND_IN_SET(mg.id_group, mem.additional_groups) != 0 OR mg.id_group = mem.id_post_group)\n\t\tWHERE mg.id_group IN ({array_int:group_list})\n\t\tGROUP BY mg.id_group',\n\t\tarray(\n\t\t\t'group_list' => $groups,\n\t\t\t'newbie_id_group' => 4,\n\t\t)\n\t);\n\twhile ($row = wesql::fetch_assoc($request))\n\t{\n\t\t$context['groups'][$row['id_group']] = array(\n\t\t\t'id' => $row['id_group'],\n\t\t\t'name' => '',\n\t\t\t'member_count' => $row['num_members'],\n\t\t);\n\t}\n\twesql::free_result($request);\n\n\t// Now get the membergroup names.\n\t$request = wesql::query('\n\t\tSELECT id_group, group_name\n\t\tFROM {db_prefix}membergroups\n\t\tWHERE id_group IN ({array_int:group_list})',\n\t\tarray(\n\t\t\t'group_list' => $groups,\n\t\t)\n\t);\n\twhile ($row = wesql::fetch_assoc($request))\n\t\t$context['groups'][$row['id_group']]['name'] = $row['group_name'];\n\twesql::free_result($request);\n\n\t// Get the subject of the topic we're about to announce.\n\t$request = wesql::query('\n\t\tSELECT m.subject\n\t\tFROM {db_prefix}topics AS t\n\t\t\tINNER JOIN {db_prefix}messages AS m ON (m.id_msg = t.id_first_msg)\n\t\tWHERE t.id_topic = {int:current_topic}',\n\t\tarray(\n\t\t\t'current_topic' => $topic,\n\t\t)\n\t);\n\tlist ($context['topic_subject']) = wesql::fetch_row($request);\n\twesql::free_result($request);\n\n\tcensorText($context['announce_topic']['subject']);\n\n\t$context['move'] = isset($_REQUEST['move']) ? 1 : 0;\n\t$context['go_back'] = isset($_REQUEST['goback']) ? 1 : 0;\n\n\twetem::load('announce');\n}", "function display_lights_groups($prefid = \"\", $cbpos = \"E\", $brislider = false) {\n\tglobal $HueAPI, $trs;\n\t\n\techo \"<TABLE CLASS=det_table>\";\n\techo \"<THEAD>\";\n\techo \"<TR CLASS=grp>\";\n\techo \"<TD><SPAN CLASS=\\\"grp ui-icon ui-icon-circle-minus\\\" gnum=0 open></SPAN>\";\n\tif ($cbpos == \"B\") {\n\t\tdisplay_td_checkbox($prefid, \"all\");\n\t}\n\techo \"<TD CLASS=\\\"label all\\\"><LABEL FOR=\" . $prefid . \"cb_all>\" . $trs[\"All\"] . \"</LABEL>\";\n\techo \"<TD><BUTTON ID=\" . $prefid . \"allon>On</BUTTON><BUTTON ID=\" . $prefid . \"alloff>Off</BUTTON>\";\n\tif ($cbpos == \"E\") {\n\t\tdisplay_td_checkbox($prefid, \"all\");\n\t}\n\tif ($brislider) {\n\t\tdisplay_bri_slider($prefid, \"all\", \"all\");\n\t}\n\t\n\techo \"<TBODY>\";\n\tforeach ($HueAPI->info['groups'] as $gnum => $gval) { // Existing groups\n\t\techo \"<TR CLASS=grp gnum=$gnum>\";\n\t\techo \"<TD><SPAN CLASS=\\\"grp ui-icon ui-icon-circle-minus\\\" gnum=$gnum open></SPAN>\";\n\t\tif ($cbpos == \"B\") {\n\t\t\tdisplay_td_checkbox($prefid, \"$gnum\", \"grp\", $gnum);\n\t\t}\n\t\techo \"<TD CLASS=\\\"label grp\\\"><LABEL FOR=\" . $prefid . \"cb_$gnum gnum=$gnum>\" . $gval['name'] . \"</LABEL>\";\n\t\techo \"<TD><BUTTON CLASS=gron gnum=$gnum>On</BUTTON><BUTTON CLASS=groff gnum=$gnum>Off</BUTTON>\";\n\t\tif ($cbpos == \"E\") {\n\t\t\tdisplay_td_checkbox($prefid, $gnum, \"grp\", $gnum);\n\t\t}\n\t\tif ($brislider) {\n\t\t\tdisplay_bri_slider($prefid, $gnum, $gnum);\n\t\t}\n\t\tforeach ($gval['lights'] as $internal => $lnum) {\n\t\t\tdisplay_light_row($prefid, $lnum, $gnum, $cbpos, $brislider);\n\t\t}\n\t}\n\t\n\t// Lamps without group\n\techo \"<TR CLASS=grp gnum=other>\";\n\techo \"<TD><SPAN CLASS=\\\"grp ui-icon ui-icon-circle-minus\\\" gnum=other open></SPAN>\";\n\tif ($cbpos == \"B\") {\n\t\tdisplay_td_checkbox($prefid, \"other\", \"grp\", \"other\");\n\t}\n\techo \"<TD CLASS=\\\"label grp\\\"><LABEL FOR=\" . $prefid . \"cb_other>\" . $trs[\"Lamps\"] . \"</LABEL>\";\n\techo \"<TD><BUTTON ID=\" . $prefid . \"otheron>On</BUTTON><BUTTON ID=\" . $prefid . \"otheroff>Off</BUTTON>\";\n\tif ($cbpos == \"E\") {\n\t\tdisplay_td_checkbox($prefid, \"other\", \"grp\", \"other\");\n\t}\n\tif ($brislider) {\n\t\tdisplay_bri_slider($prefid, \"other\", \"other\");\n\t}\n\tforeach ($HueAPI->info['lights'] as $lnum => $lval) {\n\t\tif (!isset($lval['grp'])) {\n\t\t\tdisplay_light_row($prefid, $lnum, \"other\", $cbpos, $brislider);\n\t\t}\n\t}\n\techo \"</DIV>\";\n\t\n\techo \"</TABLE>\";\n}", "abstract protected function _buildGroupBy( $group );", "function groups_create_grouping($data) {\n global $CFG;\n\n $data->timecreated = time();\n $data->timemodified = $data->timecreated;\n $data->name = trim($data->name);\n\n $id = insert_record('groupings', $data);\n\n if ($id) {\n //trigger groups events\n $data->id = $id;\n events_trigger('groups_grouping_created', stripslashes_recursive($data));\n }\n\n return $id;\n}", "function _createGroup($aNew=true)\n\t{\n\t\t$ut = $this->_ut;\n\t\t$dt = $this->_dt;\n\n\t\t// Get the informations\n\t\t$infos = array('draw_id' => kform::getInput(\"drawId\"),\n 'draw_type' => kform::getInput(\"drawType\"),\n 'draw_nbp3' => kform::getInput(\"drawNbp3\"),\n 'draw_nbs3' => kform::getInput(\"drawNbs3\"),\n 'draw_nbp4' => kform::getInput(\"drawNbp4\"),\n 'draw_nbs4' => kform::getInput(\"drawNbs4\"),\n 'draw_nbp5' => kform::getInput(\"drawNbp5\"),\n 'draw_nbs5' => kform::getInput(\"drawNbs5\"),\n 'draw_nbpl' => kform::getInput(\"drawNbpl\"),\n 'draw_nbq' => kform::getInput(\"drawNbq\"),\n 'draw_nbplq' => kform::getInput(\"drawNbplq\"),\n 'draw_third' => kform::getInput(\"drawThird\", false),\n 'draw_name' => kform::getInput(\"drawName\"),\n 'draw_nbSecond' => kform::getInput(\"drawNbSecond\"),\n\t\t\t\t\t 'group' => kform::getInput(\"group\", ''),\n\t\t\t\t\t 'draw_nbPairs' => kform::getInput('drawNbPairs'),\n\t\t\t\t\t 'rund_rge' => kform::getInput('rundFinalPlace')\n\t\t);\n\n\t\t// Control the informations\n\t\tif ($infos['group'] == \"\")\n\t\t{\n\t\t\t$infos['errMsg'] = 'groupname';\n\t\t\t$this->_displayFormNewGroup($infos);\n\t\t}\n\t\tif ( $infos['draw_nbp3'] < 0 || $infos['draw_nbs3'] < 0 ||\n\t\t$infos['draw_nbp4'] < 0 || $infos['draw_nbs4'] < 0 ||\n\t\t$infos['draw_nbp5'] < 0 || $infos['draw_nbs5'] < 0 ||\n\t\t$infos['draw_nbq'] < 0 )\n\t\t{\n\t\t\t$infos['errMsg'] = 'msgPositif';\n\t\t\t$this->_displayFormNewGroup($infos);\n\t\t}\n\t\tif ($infos['draw_type'] == WBS_GROUP)\n\t\t{\n\t\t\t$infos['draw_nbpl'] =\n\t\t\t$infos['draw_nbp3'] * $infos['draw_nbs3'] +\n\t\t\t$infos['draw_nbp4'] * $infos['draw_nbs4'] +\n\t\t\t$infos['draw_nbp5'] * $infos['draw_nbs5'] +\n\t\t\tkform::getInput(\"drawNbSecond\",0);\n\t\t\t$infos['draw_nbplq'] = 0;\n\t\t\t$infos['draw_nbq'] = 0;\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$infos['draw_nbp3'] = 0;\n\t\t\t$infos['draw_nbp4'] = 0;\n\t\t\t$infos['draw_nbp5'] = 0;\n\t\t\tif ($infos['draw_type'] == WBS_KO)\n\t\t\t{\n\t\t\t\t$infos['draw_nbq'] = 0;\n\t\t\t\t$infos['draw_nbplq'] = 0;\n\t\t\t}\n\t\t\telse if ($infos['draw_type'] == WBS_CONSOL)\n\t\t\t{\n\t\t\t\t$infos['draw_nbq'] = 0;\n\t\t\t\t$infos['draw_nbplq'] = 0;\n\t\t\t}\n\t\t}\n\t\t// Add the draws\n\t\t$res = $dt->updateGroups($infos, $aNew);\n\t\tif (is_array($res))\n\t\t{\n\t\t\t$infos['errMsg'] = $res['errMsg'];\n\t\t\t$this->_displayFormNewGroup($infos);\n\t\t}\n\t\t$page = new utPage('none');\n\t\t$page->close();\n\t\texit();\n\t}", "function CreateGroup ($name, $description, $grouptype, $parentgroupid, $autocreateapps = 'False') {\n $path = REST_PATH . 'groups.xml';\n \n $name = filter_var($name, FILTER_SANITIZE_STRING);\n $description = filter_var($description, FILTER_SANITIZE_STRING); \n\n // Setup the POST NAME/VALUE pairs\n $postdata = http_build_query(\n array(\n 'Name' => $name,\n 'GroupType' => $grouptype,\n\t'Description' => $description,\n\t'ParentGroupId' => $parentgroupid,\n\t'AutoCreateApplications' => $autocreateapps\n )\n );\n\n // Call Rest API\n $result = CallRestApi($path, $postdata, 'POST');\n \n // Read the returned XML\n $xml = simplexml_load_string($result) or die(\"Error: Cannot create object\");\n\n // Get the Group ID\n $newGroupId = $xml->Group->Id;\n\n if ($newGroupId == '')\n $newGroupId = -1;\n\n return $newGroupId;\n}", "public function create_group()\r\n\t{\r\n\t\t$this->data['title'] = $this->lang->line('create_group_title');\r\n\r\n\t\tif (!$this->ion_auth->logged_in() || !$this->ion_auth->is_admin())\r\n\t\t{\r\n\t\t\tredirect('auth', 'refresh');\r\n\t\t}\r\n\r\n\t\t// validate form input\r\n\t\t$this->form_validation->set_rules('group_name', $this->lang->line('create_group_validation_name_label'), 'required|alpha_dash');\r\n\r\n\t\tif ($this->form_validation->run() == TRUE)\r\n\t\t{\r\n\t\t\t$new_group_id = $this->ion_auth->create_group($this->input->post('group_name'), $this->input->post('description'));\r\n\t\t\tif($new_group_id)\r\n\t\t\t{\r\n\t\t\t\t// check to see if we are creating the group\r\n\t\t\t\t// redirect them back to the admin page\r\n\t\t\t\t$this->session->set_flashdata('message', $this->ion_auth->messages());\r\n\t\t\t\tredirect(\"auth\", 'refresh');\r\n\t\t\t}\r\n\t\t}\r\n\t\telse\r\n\t\t{\r\n\t\t\t// display the create group form\r\n\t\t\t// set the flash data error message if there is one\r\n\t\t\t$this->data['message'] = (validation_errors() ? validation_errors() : ($this->ion_auth->errors() ? $this->ion_auth->errors() : $this->session->flashdata('message')));\r\n\r\n\t\t\t$this->data['group_name'] = array(\r\n\t\t\t\t'name' => 'group_name',\r\n\t\t\t\t'id' => 'group_name',\r\n\t\t\t\t'type' => 'text',\r\n\t\t\t\t'value' => $this->form_validation->set_value('group_name'),\r\n\t\t\t);\r\n\t\t\t$this->data['description'] = array(\r\n\t\t\t\t'name' => 'description',\r\n\t\t\t\t'id' => 'description',\r\n\t\t\t\t'type' => 'text',\r\n\t\t\t\t'value' => $this->form_validation->set_value('description'),\r\n\t\t\t);\r\n\t\t\t\r\n\t\t\t$this->_render_page('auth/create_group', $this->data);\r\n\t\t}\r\n\t}" ]
[ "0.70125216", "0.68689626", "0.68689626", "0.6655086", "0.66346204", "0.66253877", "0.6613663", "0.6607884", "0.6581542", "0.65693575", "0.6543739", "0.6500262", "0.64747936", "0.64500016", "0.64476997", "0.64324826", "0.64166325", "0.6393976", "0.63431096", "0.63422686", "0.6289751", "0.6289734", "0.6279535", "0.62506264", "0.62415034", "0.621473", "0.61912143", "0.6189972", "0.61864775", "0.615978", "0.61577463", "0.61577463", "0.6155369", "0.6152707", "0.6141731", "0.6137801", "0.6136106", "0.6126761", "0.61152035", "0.6110661", "0.60986155", "0.6085832", "0.6060662", "0.6055201", "0.6054555", "0.6033574", "0.60054594", "0.5995426", "0.59782386", "0.5974404", "0.5967453", "0.59611154", "0.5953997", "0.5953052", "0.5942628", "0.5939386", "0.5936529", "0.5931346", "0.5921341", "0.59126806", "0.59003514", "0.58997583", "0.5895033", "0.5887455", "0.5886005", "0.5881867", "0.5881867", "0.58805233", "0.5871272", "0.587061", "0.5866616", "0.58647263", "0.58592224", "0.58563614", "0.585159", "0.5829037", "0.5826326", "0.5825661", "0.5824829", "0.58236545", "0.58235025", "0.5820893", "0.58122", "0.5811775", "0.5797235", "0.5796122", "0.5791128", "0.57855403", "0.57854974", "0.57850134", "0.5771116", "0.5762008", "0.57619154", "0.5759649", "0.57575417", "0.5751829", "0.57496065", "0.57469296", "0.57420975", "0.57359165" ]
0.5795913
86
/ returns group status details array $groups = $hostsgroups or $servicegroups
function build_hostgroup_details($group_members) //make this return the totals array for hosts and services { global $NagiosData; global $NagiosUser; $hosts = $NagiosData->getProperty('hosts'); // //add filter for user-level filtering // if(!$NagiosUser->is_admin()) { //print $type; // $hosts = user_filtering($hosts,'hosts'); // } $hostgroup_details = array(); foreach($group_members as $member) { if($NagiosUser->is_authorized_for_host($member)) //user-level filtering $hostgroup_details[] = $hosts[$member]; } return $hostgroup_details; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function get_group_hoststatus($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false)\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$filter_sql = '';\n\t\t$extra_join = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\t#$svc_field = '';\n\t\t#$svc_groupby = ' GROUP BY myhost';\n\t\t#$svc_where = '';\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t\t#$svc_groupby = \" GROUP BY \".$grouptype.\"group_name, host.host_name\";\n\t\t\t#$svc_where = \" AND service.host_name=host.host_name \";\n\t\t}\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '1=1 ';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\tif (!$auth->view_hosts_root && !($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$extra_join = \"INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id);\n\t\t}\n\n\t\t$fields = 'h.host_name, h.current_state, h.address, h.action_url, h.notes_url, h.icon_image, h.icon_image_alt,';\n\t\tif ($auth->view_hosts_root) {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON ssg.{$grouptype}group = sg.id\n\t\t\t\tWHERE\n\t\t\t\t\t{$all_sql} {$filter_sql}\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t} elseif (!$auth->view_services_root && $grouptype == 'service') {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON ssg.{$grouptype}group = sg.id\n\t\t\t\t$extra_join\n\t\t\t\tWHERE\n\t\t\t\t\t{$all_sql}\n\t\t\t\t\t{$filter_sql}\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t} else {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.\".$grouptype.\"group\n\t\t\t\t$extra_join\n\t\t\t\tWHERE\n\t\t\t\t\t\".$all_sql.\"\n\t\t\t\t\t\".$filter_sql.\"\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t}\n\t\t$result = $db->query($sql);\n\t\t#echo $sql.\"<hr />\";\n\t\treturn $result;\n\t}", "public static function get_group_info($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false, $service_props=false, $host_props=false, $limit=false, $sort_field=false, $sort_order='DESC')\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\t\t$filter_sql = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t}\n\n\t\t$limit_str = !empty($limit) ? trim($limit) : '';\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"AND sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\t$sort_string = \"\";\n\t\tif (empty($sort_field)) {\n\t\t\t$sort_string = \"h.host_name,s.current_state, s.service_description \".$sort_order;\n\t\t} else {\n\t\t\t$sort_string = $sort_field.' '.$sort_order;\n\t\t}\n\n\t\t$service_props_sql = Host_Model::build_service_props_query($service_props, 's.', 'h.');\n\t\t$host_props_sql = Host_Model::build_host_props_query($host_props, 'h.');\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_str = '';\n\t\tif ($auth->view_hosts_root || ($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$auth_str = \"\";\n\t\t} else {\n\t\t\t$auth_str = \" INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id).\" \";\n\t\t}\n\t\t$sql = \"SELECT\n\t\t\t\th.host_name,\n\t\t\t\th.address,\n\t\t\t\th.alias,\n\t\t\t\th.current_state AS host_state,\n\t\t\t\t(UNIX_TIMESTAMP() - \".($grouptype == 'service' ? 's' : 'h').\".last_state_change) AS duration,\n\t\t\t\tUNIX_TIMESTAMP() AS cur_time,\n\t\t\t\th.output AS host_output,\n\t\t\t\th.long_output AS host_long_output,\n\t\t\t\th.problem_has_been_acknowledged AS hostproblem_is_acknowledged,\n\t\t\t\th.scheduled_downtime_depth AS hostscheduled_downtime_depth,\n\t\t\t\th.notifications_enabled AS host_notifications_enabled,\n\t\t\t\th.active_checks_enabled AS host_active_checks_enabled,\n\t\t\t\th.action_url AS host_action_url,\n\t\t\t\th.icon_image AS host_icon_image,\n\t\t\t\th.icon_image_alt AS host_icon_image_alt,\n\t\t\t\th.is_flapping AS host_is_flapping,\n\t\t\t\th.notes_url AS host_notes_url,\n\t\t\t\th.display_name AS host_display_name,\n\t\t\t\ts.id AS service_id,\n\t\t\t\ts.current_state AS service_state,\n\t\t\t\t(UNIX_TIMESTAMP() - s.last_state_change) AS service_duration,\n\t\t\t\tUNIX_TIMESTAMP() AS service_cur_time,\n\t\t\t\ts.active_checks_enabled,\n\t\t\t\ts.current_state,\n\t\t\t\ts.problem_has_been_acknowledged,\n\t\t\t\t(s.scheduled_downtime_depth + h.scheduled_downtime_depth) AS scheduled_downtime_depth,\n\t\t\t\ts.last_check,\n\t\t\t\ts.output,\n\t\t\t\ts.long_output,\n\t\t\t\ts.notes_url,\n\t\t\t\ts.action_url,\n\t\t\t\ts.current_attempt,\n\t\t\t\ts.max_check_attempts,\n\t\t\t\ts.should_be_scheduled,\n\t\t\t\ts.next_check,\n\t\t\t\ts.notifications_enabled,\n\t\t\t\ts.service_description,\n\t\t\t\ts.display_name AS display_name\n\t\t\tFROM host h\n\t\t\tLEFT JOIN service s ON h.host_name=s.host_name\n\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.{$grouptype}group\n\t\t\t$auth_str\n\t\t\tWHERE 1 = 1\n\t\t\t\t{$all_sql} {$filter_sql} {$service_props_sql}\n\t\t\t\t{$host_props_sql}\n\t\t\tORDER BY \".$sort_string.\" \".$limit_str;\n\t\treturn $db->query($sql);\n\t}", "function build_servicegroups_array()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$servicegroups = $NagiosData->getProperty('servicegroups');\t\t\t\n\t$services = $NagiosData->getProperty('services');\t\t\n\t$services = user_filtering($services,'services'); \n\t\n\t$servicegroups_details = array(); //multi-dim array to hold servicegroups \t\n\tforeach($servicegroups as $groupname => $members)\n\t{\n\t\t$servicegroups_details[$groupname] = array();\n \t\t//array_dump($members); \n\t\tforeach($services as $service)\n\t\t{\t\n\t\t\tif(isset($members[$service['host_name']]) && in_array($service['service_description'],$members[$service['host_name']]))\t{\n\t\t\t\tprocess_service_status_keys($service);\t\t\n\t\t\t\t$servicegroups_details[$groupname][] = $service;\t\t\t\n\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\n\treturn $servicegroups_details; \n}", "function build_host_servicegroup_details($group_members) \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n\n\t$servicegroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t{\n\t\t\tif (isset($hosts[$member]['services']))\n\t\t\t\tforeach ($hosts[$member]['services'] as $service) \n\t\t\t\t{\n\t\t\t\t\tif($NagiosUser->is_authorized_for_service($member,$service)) //user-level filtering \n\t\t\t\t\t\t$servicegroup_details[] = $service;\t\n\t\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\treturn $servicegroup_details;\n}", "function get_hostgroup_data()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\n\t$hostgroups = $NagiosData->getProperty('hostgroups');\n\t$hosts = $NagiosData->getProperty('hosts');\n\n\t$hostgroup_data = array();\n\tforeach ($hostgroups as $group => $members) \n\t{\n\t\t\n\t\t\n\t\t$hostgroup_data[$group] = array(\n\t\t\t'member_data' => array(),\n\t\t\t'host_counts' => get_state_of('hosts', build_hostgroup_details($members)),\n\t\t\t'service_counts' => get_state_of('services', build_host_servicegroup_details($members))\n\t\t\t);\n\t\t\n\t\t//skip ahead if there are no authorized hosts\t\t\t\n\t\tif(array_sum($hostgroup_data[$group]['host_counts'])==0) continue; //skip empty groups \n\t\t\t\n\t\tforeach ($members as $member) \n\t\t{\n\t\t\n\t\t\tif(!$NagiosUser->is_authorized_for_host($member)) continue; //user-level filtering \t\t\n\t\t\n\t\t\t$host = $hosts[$member];\n\t\t\tprocess_host_status_keys($host); \n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_name'] = $host['host_name'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_state'] = $host['current_state'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['state_class'] = get_color_code($host);\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'] = array();\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_url'] = \n\t\t\t\tBASEURL.'index.php?type=hostdetail&name_filter='.urlencode($host['host_name']);\n\n\t\t\t\n\t\t\tif (isset($host['services'])) {\n\t\t\t\tforeach($host['services'] as $service) {\n\t\t\t\t\n\t\t\t\t\tif(!$NagiosUser->is_authorized_for_service($member,$service['service_description'])) continue; //user-level filtering \t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\tprocess_service_status_keys($service);\n\t\t\t\t\t$service_data = array(\n\t\t\t\t\t\t'state_class' => get_color_code($service),\n\t\t\t\t\t\t'description' => $service['service_description'],\n\t\t\t\t\t\t'service_url' => htmlentities(BASEURL.'index.php?type=servicedetail&name_filter='.$service['service_id']),\n\t\t\t\t\t);\n\t\t\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'][] = $service_data;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t}\n\treturn $hostgroup_data;\n}", "public static function group_overview($type='service', $group=false, $hostprops=false, $serviceprops=false, $hoststatustypes=false, $servicestatustypes=false)\n\t{\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_objects = array();\n\t\tif ($type == 'service') {\n\t\t\t$auth_objects = $auth->get_authorized_servicegroups();\n\t\t} elseif ($type == 'host') {\n\t\t\t$auth_objects = $auth->get_authorized_hostgroups();\n\t\t}\n\n\t\t$contact = $auth->id;\n\t\t$auth_ids = array_keys($auth_objects);\n\t\tif (empty($auth_ids) || empty($group)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$db = Database::instance();\n\n\t\tif (empty($group)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$host_match = $auth->view_hosts_root ? ''\n\t\t\t: \" AND h.id IN (SELECT host FROM contact_access WHERE contact=\".(int)$contact.\" AND service IS NULL) \";\n\t\tif (!empty($hostprops)) {\n\t\t\t$host_match .= Host_Model::build_host_props_query($hostprops, 'host.');\n\t\t}\n\n\t\t$service_match = $auth->view_hosts_root || $auth->view_services_root ? ''\n\t\t\t: \" AND service.id IN (SELECT service FROM contact_access WHERE contact=\".(int)$contact.\" AND service IS NOT NULL) \";\n\n\t\tif (!empty($serviceprops)) {\n\t\t\t$service_match .= Host_Model::build_service_props_query($serviceprops, 'service.', 'h.');\n\t\t}\n\n\t\t$filter_host_sql = false;\n\t\t$filter_service_sql = false;\n\t\tif (!empty($hoststatustypes)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatustypes);\n\t\t\t$filter_host_sql = \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\tif (!empty($servicestatustypes)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatustypes);\n\t\t\t$filter_service_sql = \" AND service.current_state IN ($bits) \";\n\t\t}\n\n\t\tswitch ($type) {\n\t\t\tcase 'host':\n\t\t\t\t# restrict host access for authorized contacts\n\t\t\t\tif (!$auth->view_hosts_root) {\n\t\t\t\t\t$hostgroups = $auth->hostgroups_r;\n\t\t\t\t\tif (!is_array($hostgroups) || !array_key_exists($group, $hostgroups)) {\n\t\t\t\t\t\t# user doesn't have access\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$svc_query = \"SELECT COUNT(*) FROM service WHERE service.host_name = h.host_name \".\n\t\t\t\t\t\"AND current_state = %s \".$service_match.$filter_service_sql;\n\n\t\t\t\t$sql = \"SELECT h.host_name, h.current_state, h.address, h.action_url, h.notes_url, h.icon_image,h.icon_image_alt,\".\n\t\t\t\t\t\"h.display_name, h.current_attempt, h.max_check_attempts, (\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_OK).\") AS services_ok,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_WARNING).\") AS services_warning,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_CRITICAL).\") AS services_critical,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_UNKNOWN).\") AS services_unknown,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_PENDING).\") AS services_pending \".\n\t\t\t\t\t\"FROM hostgroup hg, host h, host_hostgroup hhg \".\n\t\t\t\t\t\"WHERE hhg.hostgroup=hg.id AND h.id=hhg.host \".\n\t\t\t\t\t\"AND hg.hostgroup_name=\".$db->escape($group).$filter_host_sql.Host_Model::build_host_props_query($hostprops, 'h.');\n\t\t\t\tbreak;\n\t\t\tcase 'service':\n\t\t\t\tif (!$auth->view_hosts_root && !$auth->view_services_root) {\n\t\t\t\t\t$servicegroups = $auth->servicegroups_r;\n\t\t\t\t\tif (!is_array($servicegroups) || !array_key_exists($group, $servicegroups)) {\n\t\t\t\t\t\t# user doesn't have access\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$svc_query = \"SELECT COUNT(*) FROM service \".\n\t\t\t\t\t\"INNER JOIN service_servicegroup ON service.id = service_servicegroup.service \".\n\t\t\t\t\t\"WHERE service.host_name = h.host_name \".\n\t\t\t\t\t\"AND service_servicegroup.servicegroup = servicegroup.id \".\n\t\t\t\t\t\"AND current_state = %s \".$service_match.$filter_service_sql;\n\t\t\t\t$sql = \"SELECT DISTINCT h.host_name, h.current_state, h.address, h.action_url, \".\n\t\t\t\t\t\"h.notes_url, h.icon_image, h.icon_image_alt, h.display_name, \".\n\t\t\t\t\t\"h.current_attempt, h.max_check_attempts, (\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_OK).\") AS services_ok,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_WARNING).\") AS services_warning,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_CRITICAL).\") AS services_critical,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_UNKNOWN).\") AS services_unknown,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_PENDING).\") AS services_pending \".\n\t\t\t\t\t\"FROM host h \".\n\t\t\t\t\t\"INNER JOIN service ON h.host_name = service.host_name \" .\n\t\t\t\t\t\"INNER JOIN service_servicegroup ON service_servicegroup.service = service.id \".\n\t\t\t\t\t\"INNER JOIN servicegroup ON servicegroup.id = service_servicegroup.servicegroup \".\n\t\t\t\t\t\"WHERE servicegroup.servicegroup_name = \".$db->escape($group).\n\t\t\t\t\t$host_match.$filter_host_sql;\n\t\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treturn false;\n\t\t}\n\n\t\t$result = $db->query($sql);\n\t\treturn count($result)>0 ? $result : false;\n\t}", "public function getGroups($status_info)\n {\n $all_gateways = $this->gatewaysIndexedByName();\n $result = array();\n if (isset($this->configHandle->gateways)) {\n foreach ($this->configHandle->gateways->children() as $tag => $gw_group) {\n if ($tag == \"gateway_group\" && !empty($gw_group)) {\n $tiers = array();\n if (isset($gw_group->item)) {\n foreach ($gw_group->item as $item) {\n list($gw, $tier) = explode(\"|\", $item);\n if (!isset($tiers[$tier])) {\n $tiers[$tier] = [];\n }\n $tiers[$tier][] = $gw;\n }\n }\n ksort($tiers);\n $all_tiers = [];\n foreach ($tiers as $tieridx => $tier) {\n $all_tiers[$tieridx] = array();\n if (!isset($result[(string)$gw_group->name])) {\n $result[(string)$gw_group->name] = array();\n }\n // check status for all gateways in this tier\n foreach ($tier as $gwname) {\n if (!empty($all_gateways[$gwname]['gateway']) && !empty($status_info[$gwname])) {\n $gateway = $all_gateways[$gwname];\n switch ($status_info[$gwname]['status']) {\n case 'down':\n case 'force_down':\n $is_up = false;\n break;\n case 'delay+loss':\n $is_up = stristr($gw_group->trigger, 'latency') === false && stristr($gw_group->trigger, 'loss') === false;\n break;\n case 'delay':\n $is_up = stristr($gw_group->trigger, 'latency') === false;\n break;\n case 'loss':\n $is_up = stristr($gw_group->trigger, 'loss') === false;\n break;\n default:\n $is_up = true;\n }\n $gateway_item = [\n 'int' => $gateway['if'],\n 'gwip' => $gateway['gateway'],\n 'poolopts' => isset($gw_group->poolopts) ? (string)$gw_group->poolopts : null,\n 'weight' => !empty($gateway['weight']) ? $gateway['weight'] : 1\n ];\n $all_tiers[$tieridx][] = $gateway_item;\n if ($is_up) {\n $result[(string)$gw_group->name][] = $gateway_item;\n }\n }\n }\n // exit when tier has (a) usable gateway(s)\n if (!empty($result[(string)$gw_group->name])) {\n break;\n }\n }\n // XXX: backwards compatibility, when no tiers are up, we seem to select all from the first\n // found tier. not very useful, since we already seem to know these are down.\n if (empty($result[(string)$gw_group->name])) {\n $result[(string)$gw_group->name] = $all_tiers[array_keys($tiers)[0]];\n }\n }\n }\n }\n return $result;\n }", "public function findServiceGroups(): array;", "function check_membership($hostname='', $servicename='', $servicegroup_name='')\n{\n\tglobal $NagiosData;\n\t$hostgroups_objs = $NagiosData->getProperty('hostgroups_objs');\n\t$servicegroups_objs = $NagiosData->getProperty('servicegroups_objs');\n\n\t$hostname = trim($hostname);\n\t$servicename = trim($servicename);\n\t$servicegroup_name = trim($servicegroup_name);\n\n\t$memberships = array();\n\tif($hostname!='' && $servicename!='')\n\t{\n\t\t//search servicegroups array \n\t\t\n\t\t//create regexp string for 'host,service'\n\t\t$hostservice = \"$hostname,$servicename\";\n\t\t$hostservice_regex = preg_quote($hostservice, '/');\n\n\t\t//check regex against servicegroup 'members' index \n\t\tif ($servicegroup_name!='' && isset($servicegroups_objs[$servicegroup_name])) {\n\t\t\t$group = $servicegroups_objs[$servicegroup_name];\n\t\t\tif (preg_match(\"/$hostservice_regex/\", $group['members'])) {\n\t\t\t\t$str = isset($group['alias']) ? $group['alias'] : $group['servicegroup_name']; \n\t\t\t\t$memberships[] = $str;\n\t\t\t}\n\n\t\t} else {\n\t\t\tforeach($servicegroups_objs as $group)\n\t\t\t{\n\t\t\t\tif(isset($group['members']) && preg_match(\"/$hostservice_regex/\", $group['members']))\n\t\t\t\t{\n\t\t\t\t\t//use alias as default display name, else use groupname \n\t\t\t\t\t$str = isset($group['alias']) ? $group['alias'] : $group['servicegroup_name']; \n\t\t\t\t\t$memberships[] = $str;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\t//check for host membership \n\telseif($hostname!='' && $servicename=='')\n\t{\n\t\n\t\t$hostname_regex = preg_quote($hostname, '/');\n\t\tforeach($hostgroups_objs as $group)\n\t\t{\n\t\t\tif(isset($group['members']) && preg_match(\"/$hostname_regex/\", $group['members']))\n\t\t\t{\n\t\t\t\t//use alias as default display name, else use groupname \n\t\t\t\t$str = isset($group['alias']) ? $group['alias'] : $group['hostgroup_name'];\n\t\t\t\t$memberships[] = $str;\n\t\t\t}\n\t\t}\n\t}\n\t \n return empty($memberships) ? NULL : join(' ', $memberships);\n}", "public function ADStaff_Get_Group_List(){\n\t \n\t $result_key = parent::Initial_Result('groups');\n\t $result = &$this->ModelResult[$result_key];\n\t \n\t try{\n\t\t// 查詢資料庫\n\t\t$DB_OBJ = $this->DBLink->prepare(parent::SQL_Permission_Filter(SQL_AdStaff::SELECT_GROUP_LIST()));\n\t\tif(!$DB_OBJ->execute()){\n\t\t throw new Exception('_SYSTEM_ERROR_DB_ACCESS_FAIL'); \n\t\t}\n\t\t$groups = $DB_OBJ->fetchAll(PDO::FETCH_ASSOC);\n\t\t$result['action'] = true;\t\t\n\t\t$result['data'] = $groups;\t\t\n\t } catch (Exception $e) {\n $result['message'][] = $e->getMessage();\n }\n\t return $result;\n\t}", "public function getGroups() {}", "public static function getGroups(): array\n {\n return [\"group2\"];\n }", "public function adminHasRetrievedGroupListUsingTheGraphApi(): array {\n\t\t$response = GraphHelper::getGroups(\n\t\t\t$this->featureContext->getBaseUrl(),\n\t\t\t$this->featureContext->getStepLineRef(),\n\t\t\t$this->featureContext->getAdminUsername(),\n\t\t\t$this->featureContext->getAdminPassword()\n\t\t);\n\t\tif ($response->getStatusCode() === 200) {\n\t\t\t$jsonResponseBody = $this->featureContext->getJsonDecodedResponse($response);\n\t\t\treturn $jsonResponseBody[\"value\"];\n\t\t} else {\n\t\t\t$this->throwHttpException($response, \"Could not retrieve groups list.\");\n\t\t}\n\t}", "public function getGroups();", "public function getGroups();", "static function getGroupStatuses($group_name)\n {\n return self::findAll([\n 'group_name' => $group_name\n ]);\n }", "public function groups();", "public function groups();", "public function listGroups()\n {\n\t\t$data = $this->call(array(), \"GET\", \"groups.json\");\n\t\t$data = $data->{'groups'};\n\t\t$groupArray = new ArrayObject();\n\t\tfor($i = 0; $i<count($data);$i++){\n\t\t\t$groupArray->append(new Group($data[$i], $this));\n\t\t}\n\t\treturn $groupArray;\n }", "public function getUserGroups()\n\t{\n\t\tself::authenticate();\n\n\t\t$uname = FormUtil::getPassedValue('user', null);\n\t\tif($uname == null) {\n\t\t\treturn self::retError('ERROR: No user name passed!');\n\t\t}\n\n\t\t$uid = UserUtil::getIdFromName($uname);\n\t\tif($uid == false) {\n\t\t\treturn self::ret(false);\n\t\t}\n\n\t\t$groups = UserUtil::getGroupsForUser($uid);\n\t\t$return = array();\n\t\tforeach($groups as $item) {\n\t\t\t$group = UserUtil::getGroup($item);\n\t\t\t$return[] = $group['name'];\n\t\t}\n\t\tif(SecurityUtil::checkPermission('Owncloud::Admin', '::', ACCESS_MODERATE, $uid)) {\n\t\t\t$return[] = 'admin';\n\t\t}\n\t\treturn self::ret($return);\n\t}", "public function get_group($user_id){\r\n\t\r\n\t$user_id1 = ($user_id != NULL)?\"'\".$this->hrm_mysql_connect->real_escape_string($user_id).\"'\":'NULL';\r\n\t$sql = $this->hrm_mysql_connect->query(\"SELECT a.leave_group, b.name, b.supervisor_id, b.delegate, b.status, c.user_firstname, c.user_lastname, c.user_email FROM leave_reg a JOIN leave_groups b ON a.leave_group = b.group_id JOIN hrm_users c ON b.supervisor_id = c.user_id WHERE a.user_id=$user_id1\");\r\n\tif($sql){\r\n\t$sup = $sql->fetch_assoc();\r\n\t$g_name = $sup['name'];\r\n\t$g_deleg = $sup['delegate'];\r\n\t$g_status = $sup['status'];\r\n\tif($g_status==3 && $g_deleg!=0){\r\n\t\t$user_id2 = ($g_deleg != NULL)?\"'\".$this->hrm_mysql_connect->real_escape_string($g_deleg).\"'\":'NULL';\r\n\t\t$sql2 = $this->hrm_mysql_connect->query(\"SELECT user_firstname, user_lastname, user_email FROM hrm_users WHERE user_id=$user_id2\");\r\n\t\t$sup_deleg = $sql2->fetch_assoc();\r\n\t\t$delegate = 1;\r\n\t\t$sup_id = $g_deleg;\r\n\t\t$sup_name = $sup_deleg['user_firstname'].' '.$sup_deleg['user_lastname'];\r\n\t\t$sup_email = $sup_deleg['user_email'];\r\n\t\t}else {\r\n\t$delegate = 0;\r\n\t$sup_id = $sup['supervisor_id'];\r\n\t$sup_name = $sup['user_firstname'].' '.$sup['user_lastname'];\r\n\t$sup_email = $sup['user_email'];\r\n\t\t\t}\r\n\t\t\treturn array($g_name, $sup_id, $sup_name, $sup_email, $delegate);\r\n\t}else{\r\n\t\treturn 0;\r\n\t\t}\r\n}", "public function status() {\r\n \r\n // Does the Group object have an ID?\r\n if ( is_null( $this->id ) ) trigger_error ( \"Group::status(): Attempt to update a Group object that does not have it\\'s value property set.\", E_USER_ERROR );\r\n \r\n // Update the Group status\r\n $conn = new PDO( DB_DSN, DB_USERNAME, DB_PASSWORD ); \r\n $conn->setAttribute( PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION );\r\n $sql = \"UPDATE \" . DB_PREFIX . \"groups SET status = :status WHERE id = :id;\";\r\n \r\n $st = $conn->prepare ( $sql );\r\n $st->bindValue( \":id\", $this->id, PDO::PARAM_INT );\r\n $st->bindValue( \":status\", $this->status, PDO::PARAM_INT );\r\n $st->execute();\r\n \r\n $conn = null;\r\n \r\n }", "public function getGroupList()\n {\n $statusArray = [\n self::GROUP_APPLICATION => 'Приложения',\n self::GROUP_FILM => 'Фильмы',\n self::GROUP_MUSIC => 'Музыка',\n self::GROUP_BOOK => 'Книги',\n self::GROUP_PRESS => 'Пресса'\n ];\n\n return $statusArray;\n }", "public function getGroups(): array;", "function all_groups($include_desc = false,\n $search = \"*\",\n $sorted = true,\n $local_group = FALSE // $local_group switch added by SysCo/al\n )\n {\n $this->_warning_message = \"\";\n if (!$this->_bind){ return (false); }\n\n if (2 == $this->_ldap_server_type) { // Generic LDAP\n $filter=\"(|(objectClass=posixGroup)(objectClass=groupofNames))\";\n $fields=array($this->_group_cn_identifier,\"description\");\n } else { // Active Directory\n //perform the search and grab all their details\n if ($local_group) {\n $group_account_type = \"(|(samaccounttype=\".ADLDAP_SECURITY_LOCAL_GROUP.\")(samaccounttype=\". ADLDAP_SECURITY_GLOBAL_GROUP.\"))\";\n } else {\n $group_account_type = \"(samaccounttype=\".ADLDAP_SECURITY_GLOBAL_GROUP.\")\";\n }\n $filter = \"(&(objectCategory=group)\".$group_account_type.\"(cn=\".$search.\"))\";\n $fields = array($this->_group_cn_identifier,\"description\");\n }\n\n $groups_array = array();\n\n $pageSize = 1000;\n $page_cookie = '';\n do {\n if (function_exists('ldap_control_paged_result')) {\n ldap_control_paged_result($this->_conn, $pageSize, false, $page_cookie);\n }\n $sr = @ldap_search($this->_conn,$this->_base_dn,$filter,$fields);\n \n if ((!function_exists('ldap_control_paged_result')) && (4 == ldap_errno($this->_conn))) {\n $cr = @ldap_count_entries($this->_conn,$sr);\n $this->_warning_message = \"LDAP server cannot return more than $cr records.\";\n }\n \n $entries = $this->ldap_get_entries_raw($sr);\n\n for ($i=0; $i<$entries[\"count\"]; $i++){\n if ($include_desc && strlen($entries[$i][\"description\"][0]) > 0 ){\n $groups_array[ $entries[$i][$this->_group_cn_identifier][0] ] = $entries[$i][\"description\"][0];\n } elseif ($include_desc){\n $groups_array[ $entries[$i][$this->_group_cn_identifier][0] ] = $entries[$i][$this->_group_cn_identifier][0];\n } else {\n array_push($groups_array, $entries[$i][$this->_group_cn_identifier][0]);\n }\n }\n if (function_exists('ldap_control_paged_result_response')) {\n ldap_control_paged_result_response($this->_conn, $sr, $page_cookie);\n }\n }\n while($page_cookie !== null && $page_cookie != '');\n \n if (function_exists('ldap_control_paged_result')) {\n // Reset LDAP paged result\n ldap_control_paged_result($this->_conn, $pageSize, false);\n }\n \n if( $sorted ){\n asort($groups_array);\n }\n \n return ($groups_array);\n \n }", "public function getGroups($username, $password) {\nglobal $_LW;\nif (!isset($this->client)) { // require the client\n\treturn false;\n};\n$this->client->getGroups($username, $password); // perform the API call\nreturn @$this->client->groups;\n}", "function getMySqlServerGroups() {\n if ($this->connectToMySqlWithParams('localhost:3307', 'root', 'myzconun')) {\n $query = sprintf(\"SELECT * FROM scuola.mysql_servers_groups\");\n\n // Perform Query\n $result = mysql_query($query);\n }\n $this->closeConnection();\n return $result;\n }", "public function retrieveGroups()\n {\n return $this->start()->uri(\"/api/group\")\n ->get()\n ->go();\n }", "private function _show_list_of_groups() {\n // show groups of current user\n // create group button\n $this->load->model('membership_model');\n \n $user_id = $this->session->userdata('user')['id'];\n\n $where = array(\n 'm.user_id' => $user_id,\n 'm.status' => 1,\n 'g.status' => 1\n );\n \n $groups = $this->membership_model->fetch($where);\n\n // 1 is owner\n $where['m.type'] = 1;\n // allow status 2 for my groups for hidden\n // 0 is deleted\n unset($where['g.status']);\n $where['g.status !='] = 0;\n $my_groups = $this->membership_model->fetch($where);\n \n // membership type 2 is normal member\n $where['m.type'] = 2;\n $where['g.status'] = 1;\n $other_groups = $this->membership_model->fetch($where);\n\n // can be any type for invited\n unset($where['m.type']);\n $where['m.status'] = 2;\n $invited_groups = $this->membership_model->fetch($where);\n \n $data = array(\n 'title' => 'Groups',\n 'msg' => $this->session->flashdata('msg'),\n 'groups' => $groups,\n 'my_groups' => $my_groups,\n 'other_groups' => $other_groups,\n 'invited_groups' => $invited_groups\n );\n $this->_view(\n array('templates/nav', 'pages/dashboard/groups', 'alerts/msg'),\n array_merge($this->_nav_items, $data)\n );\n }", "public function getUserGroups()\n {\n $query = \"SELECT groupName FROM UserGroupAccess\";\n if(($result = $this->getQuery($query,true)) != NULL)\n {\n return $result;\n }\n else\n return false;\n }", "public function getAllGroups();", "public function findGroups() {\n\t\t\n\t}", "private function validateGroupStatus(){\n\t\n\t global $db;\n\t \n\t #see if this is guest, if so, do some hard-coded checks.\n\t\tif($this->user == \"guest\"){\n\t\t if(($this->user == \"guest\") and ($this->gid == 0)){\n\t\t return(true);\n\t\t }else{\n\t\t return(false);\n\t\t }\n\t\t}else{\n\t\t\t$db->SQL = \"SELECT gid FROM ebb_group_users WHERE Username='\".$this->user.\"' AND Status='Active' LIMIT 1\";\n\t\t\t$validateGroupStatus = $db->affectedRows();\n\n\t\t\tif($validateGroupStatus == 1){\n\t\t\t return (true);\n\t\t\t}else{\n\t\t\t return(false);\n\t\t\t}\n\t\t}\n\t}", "public function getGroups()\n {\n return $this->groups;\n }", "public static function getGroups(): array\r\n {\r\n // TODO: Implement getGroups() method.\r\n return [\r\n 'test',\r\n 'dev',\r\n ];\r\n }", "public function getGroups()\n\t{\n\t\treturn $this->groups;\n\t}", "private function _get_groups() {\n\n\t\t$request = new Gitlab();\n\t\t$gitlab = $request->init_request();\n\n\t\t$groups = [];\n\t\t$page_index = 1;\n\n\t\tdo {\n\n\t\t\t$response = $gitlab->get( \"groups?per_page=100&page=$page_index\" );\n\t\t\t$response_arr = json_decode( $response->body, true );\n\n\t\t\t$groups = array_merge( $groups, $response_arr );\n\n\t\t\t$page_index = get_next_page( $response );\n\n\t\t} while ( ! empty( $page_index ) );\n\n\t\treturn $groups;\n\n\t}", "public function getGroups() {\n return $this->groups;\n }", "public function groupList(){\n\t\techo json_encode($this->read_database->get_groups());\n\t}", "function _get_user_groups(){\r\n $groups = array();\r\n for($i=0; $i<get_sso_option('rules_number'); $i++){\r\n $rule = _get_rule($i);\r\n if($rule != FALSE){\r\n\t $is_group = _run_rule($rule['var'], $rule['regexp'], $rule['group']);\r\n\t if($is_group === TRUE) $groups[] = $rule['group'];\r\n }\r\n }\r\n return $groups;\r\n}", "public function getGroupsList(){\n return $this->_get(1);\n }", "private function getGroups()\n {\n $where = '';\n if ($this->userGroups)\n {\n $groups = explode(',', $this->userGroups);\n $where .= \" uid IN ('\" . implode(\"','\", $groups) . \"') \";\n }\n $result = $GLOBALS['TYPO3_DB']->exec_SELECTquery('*', 'fe_groups', $where);\n $res = array();\n while (($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($result)))\n {\n $res[$row['uid']] = $row;\n }\n\n $this->loadGroupIcons($res);\n\n return $res;\n }", "public function ListGroups(){\n\t\t$query = \"SELECT groupTitle FROM [PUBLISH GROUPS TABLE] ORDER BY groupTitle ASC\";\n\t\treturn array(\"results\" => $this->SelectQueryHelper());\n\t}", "public function get_groups($args = [])\n {\n global $db, $system;\n /* initialize arguments */\n $user_id = !isset($args['user_id']) ? null : $args['user_id'];\n $offset = !isset($args['offset']) ? 0 : $args['offset'];\n $get_all = !isset($args['get_all']) ? false : true;\n $suggested = !isset($args['suggested']) ? false : true;\n $random = !isset($args['random']) ? false : true;\n $managed = !isset($args['managed']) ? false : true;\n $results = !isset($args['results']) ? $system['max_results_even'] : $args['results'];\n /* initialize vars */\n $groups = [];\n $offset *= $results;\n /* get suggested groups */\n if ($suggested) {\n $where_statement = \"\";\n /* make a list from joined groups (approved|pending) */\n $groups_ids = $this->get_groups_ids();\n if ($groups_ids) {\n $groups_list = implode(',', $groups_ids);\n $where_statement .= \"AND group_id NOT IN (\" . $groups_list . \") \";\n }\n $sort_statement = ($random) ? \" ORDER BY RAND() \" : \" ORDER BY group_id DESC \";\n $limit_statement = ($get_all) ? \"\" : sprintf(\"LIMIT %s, %s\", secure($offset, 'int', false), secure($results, 'int', false));\n $get_groups = $db->query(\"SELECT * FROM `groups` WHERE group_privacy != 'secret' \" . $where_statement . $sort_statement . $limit_statement) or _error(\"SQL_ERROR_THROWEN\");\n /* get the \"taget\" all groups who admin */\n } elseif ($managed) {\n $get_groups = $db->query(sprintf(\"SELECT `groups`.* FROM groups_admins INNER JOIN `groups` ON groups_admins.group_id = `groups`.group_id WHERE groups_admins.user_id = %s ORDER BY group_id DESC\", secure($user_id, 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n /* get the \"viewer\" groups who admin */\n } elseif ($user_id == null) {\n $limit_statement = ($get_all) ? \"\" : sprintf(\"LIMIT %s, %s\", secure($offset, 'int', false), secure($results, 'int', false));\n $get_groups = $db->query(sprintf(\"SELECT `groups`.* FROM groups_admins INNER JOIN `groups` ON groups_admins.group_id = `groups`.group_id WHERE groups_admins.user_id = %s ORDER BY group_id DESC \" . $limit_statement, secure($this->_data['user_id'], 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n /* get the \"target\" groups*/\n } else {\n /* get the target user's privacy */\n $get_privacy = $db->query(sprintf(\"SELECT user_privacy_groups FROM users WHERE user_id = %s\", secure($user_id, 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n $privacy = $get_privacy->fetch_assoc();\n /* check the target user's privacy */\n if (!$this->check_privacy($privacy['user_privacy_groups'], $user_id)) {\n return $groups;\n }\n /* if the viewer not the target exclude secret groups */\n $where_statement = ($this->_data['user_id'] == $user_id) ? \"\" : \"AND `groups`.group_privacy != 'secret'\";\n $limit_statement = ($get_all) ? \"\" : sprintf(\"LIMIT %s, %s\", secure($offset, 'int', false), secure($results, 'int', false));\n $get_groups = $db->query(sprintf(\"SELECT `groups`.* FROM `groups` INNER JOIN groups_members ON `groups`.group_id = groups_members.group_id WHERE groups_members.approved = '1' AND groups_members.user_id = %s \" . $where_statement . \" ORDER BY group_id DESC \" . $limit_statement, secure($user_id, 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n }\n if ($get_groups->num_rows > 0) {\n while ($group = $get_groups->fetch_assoc()) {\n $group['group_picture'] = get_picture($group['group_picture'], 'group');\n /* check if the viewer joined the group */\n $group['i_joined'] = $this->check_group_membership($this->_data['user_id'], $group['group_id']);;\n $groups[] = $group;\n }\n }\n return $groups;\n }", "public function get_groups()\n\t{\n\t\tif (empty($this->user))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn array(array('UniGroup', $this->user[static::_column('group')]));\n\t}", "function getGroups($username){\r\n\t\t//SELEZIONO DAL DATABASE L'ELENCO DEI GRUPPI AI QUALI L'UTENTE APPARTIENE\r\n\t\t$sql = \"SELECT groupname FROM \".$this->schema.\".user_group WHERE username='$username'\";\r\n\t\tprint_debug($sql,null,'tabella');\r\n\t\tif($this->db->sql_query($sql)){\t\t//STRUTTURA GRUPPI GISCLIENT\r\n\t\t\t$ris=$this->db->sql_fetchlist('groupname');\r\n\t\t\tif(!$ris) {\r\n\t\t\t\t$this->error->getError(\"C001\");\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\tforeach($ris as $g){\r\n\t\t\t\t$this->groups[]=$g;\r\n\t\t\t}\r\n\t\t\treturn $this->groups;\r\n\t\t}\r\n\t\telse{\r\n\t\t\t$this->error->setNote($sql);\r\n\t\t\t$this->error->getError(\"1\");\t\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "public function getGroupsList(){\n return $this->_get(4);\n }", "public function getGroupsList(){\n return $this->_get(4);\n }", "public function getGroupsList(){\n return $this->_get(3);\n }", "function loadGroups($adminGroups = NULL) {\n $this->groupList = array();\n $sql = \"SELECT surfergroup_id,\n surfergroup_title,\n surfergroup_profile_page,\n surfergroup_redirect_page,\n surfergroup_admin_group,\n surfergroup_identifier\n FROM %s\";\n if ($adminGroups !== NULL) {\n if (!in_array(0, $adminGroups)) {\n $adminGroups[] = 0;\n }\n $sql .= \" WHERE \".str_replace(\n '%',\n '%%',\n $this->databaseGetSqlCondition(array('surfergroup_admin_group' => $adminGroups))\n );\n }\n $sql .= \" ORDER BY surfergroup_title\";\n if ($res = $this->databaseQueryFmt($sql, array($this->tableGroups))) {\n while ($row = $res->fetchRow(DB_FETCHMODE_ASSOC)) {\n $this->groupList[$row['surfergroup_id']] = $row;\n }\n $res->free();\n if (!empty($this->groupList)) {\n return TRUE;\n }\n }\n return FALSE;\n }", "public static function getSubadminStatus(): array\n {\n $groupsSqlString = '';\n $groupId = [];\n\n $isSubAdmin = false;\n $canActivateUsers = false;\n\n foreach ($GLOBALS['BE_USER']->userGroups as $singleGroup) {\n if ($singleGroup['tx_groupdelegation_issubadmingroup']=== 1) {\n $isSubAdmin = true;\n if ($singleGroup['tx_groupdelegation_canactivate']=== 1) {\n $canActivateUsers = true;\n }\n $groupId[] = $singleGroup['uid'];\n }\n }\n if ($isSubAdmin===true) {\n $groupsSqlString = implode(',', $groupId);\n }\n\n return [$isSubAdmin, $canActivateUsers, $groupsSqlString];\n }", "function timeconditions_timegroups_list_groups() {\n\tglobal $db;\n\t$tmparray = array();\n\n\t$sql = \"select id, description from timegroups_groups order by description\";\n\t$results = $db->getAll($sql);\n\tif(DB::IsError($results)) {\n\t\t$results = null;\n\t}\n\tforeach ($results as $val) {\n\t\t$tmparray[] = array($val[0], $val[1], \"value\" => $val[0], \"text\" => $val[1]);\n\t}\n\treturn $tmparray;\n}", "function secGroups($function, $group=NULL) {\n $g=array();\n $g['index']=array('ro','rw','rwv','admin');\n $g['clearStats']=array('admin');\n if(isset($g[$function])) {\n if(!empty($group)) return in_array($group, $g[$function]);\n return $g[$function];\n }\n return parent::secGroups($function,$group);\n }", "function fetchAllGroups() {\n try {\n global $db_table_prefix;\n\n $results = array();\n\n $db = pdoConnect();\n\n $sqlVars = array();\n\n $query = \"SELECT\n id,\n name,\n is_default,\n can_delete,\n home_page_id\n FROM \".$db_table_prefix.\"groups\";\n\n $stmt = $db->prepare($query);\n\n if (!$stmt->execute($sqlVars)){\n // Error\n return false;\n }\n\n while ($r = $stmt->fetch(PDO::FETCH_ASSOC)) {\n $id = $r['id'];\n $results[$id] = $r;\n }\n $stmt = null;\n\n return $results;\n\n } catch (PDOException $e) {\n addAlert(\"danger\", \"Oops, looks like our database encountered an error.\");\n error_log(\"Error in \" . $e->getFile() . \" on line \" . $e->getLine() . \": \" . $e->getMessage());\n return false;\n } catch (ErrorException $e) {\n addAlert(\"danger\", \"Oops, looks like our server might have goofed. If you're an admin, please check the PHP error logs.\");\n return false;\n }\n}", "public function GetGroup() {\n $resource = $this->Retrieve();\n $query = mysqli_query($resource, \"SELECT grpname, grpdesc FROM `group`\");\n while ($row = mysqli_fetch_object($query)) {\n $p[] = $row;\n }\n return json_encode($p);\n }", "function get_group_by_name($group_name) {\r\n // set connection var\r\n global $db;\r\n\r\n //query to get all associated groups\r\n $sql = \"SELECT id\r\n FROM groups\r\n WHERE is_active = '1'\r\n AND local = '0'\r\n AND name = '$group_name'\r\n ORDER BY name ASC;\";\r\n\r\n $groups_data = array();\r\n $groups = array();\r\n\r\n foreach ($db->query($sql) as $key => $value) {\r\n $groups_data[$key] = $value;\r\n foreach ($groups_data[$key] as $subkey => $subvalue) {\r\n if (is_int($subkey)) {\r\n $groups[] = $subvalue;\r\n }\r\n }\r\n }\r\n\r\n return $groups;\r\n}", "function AnnouncementSelectMembergroup()\n{\n\tglobal $txt, $context, $topic;\n\n\t$groups = getAnnounceGroups();\n\n\t$context['groups'] = array();\n\tif (in_array(0, $groups))\n\t{\n\t\t$context['groups'][0] = array(\n\t\t\t'id' => 0,\n\t\t\t'name' => $txt['announce_regular_members'],\n\t\t\t'member_count' => 'n/a',\n\t\t);\n\t}\n\n\t// Get all membergroups that have access to the board the announcement was made on.\n\t$request = wesql::query('\n\t\tSELECT mg.id_group, COUNT(mem.id_member) AS num_members\n\t\tFROM {db_prefix}membergroups AS mg\n\t\t\tLEFT JOIN {db_prefix}members AS mem ON (mem.id_group = mg.id_group OR FIND_IN_SET(mg.id_group, mem.additional_groups) != 0 OR mg.id_group = mem.id_post_group)\n\t\tWHERE mg.id_group IN ({array_int:group_list})\n\t\tGROUP BY mg.id_group',\n\t\tarray(\n\t\t\t'group_list' => $groups,\n\t\t\t'newbie_id_group' => 4,\n\t\t)\n\t);\n\twhile ($row = wesql::fetch_assoc($request))\n\t{\n\t\t$context['groups'][$row['id_group']] = array(\n\t\t\t'id' => $row['id_group'],\n\t\t\t'name' => '',\n\t\t\t'member_count' => $row['num_members'],\n\t\t);\n\t}\n\twesql::free_result($request);\n\n\t// Now get the membergroup names.\n\t$request = wesql::query('\n\t\tSELECT id_group, group_name\n\t\tFROM {db_prefix}membergroups\n\t\tWHERE id_group IN ({array_int:group_list})',\n\t\tarray(\n\t\t\t'group_list' => $groups,\n\t\t)\n\t);\n\twhile ($row = wesql::fetch_assoc($request))\n\t\t$context['groups'][$row['id_group']]['name'] = $row['group_name'];\n\twesql::free_result($request);\n\n\t// Get the subject of the topic we're about to announce.\n\t$request = wesql::query('\n\t\tSELECT m.subject\n\t\tFROM {db_prefix}topics AS t\n\t\t\tINNER JOIN {db_prefix}messages AS m ON (m.id_msg = t.id_first_msg)\n\t\tWHERE t.id_topic = {int:current_topic}',\n\t\tarray(\n\t\t\t'current_topic' => $topic,\n\t\t)\n\t);\n\tlist ($context['topic_subject']) = wesql::fetch_row($request);\n\twesql::free_result($request);\n\n\tcensorText($context['announce_topic']['subject']);\n\n\t$context['move'] = isset($_REQUEST['move']) ? 1 : 0;\n\t$context['go_back'] = isset($_REQUEST['goback']) ? 1 : 0;\n\n\twetem::load('announce');\n}", "public function listgroups() {\n\t\t//Return result to jTable\n\t\t$jTableResult = array();\n\t\t$jTableResult['Result'] = \"OK\";\n\t\t$jTableResult['TotalRecordCount'] = $this->Groupmodel->countAll();\n\t\t$jTableResult['Records'] = $this->Groupmodel->ListAll($this->input->get('jtSorting', TRUE), $this->input->get('jtPageSize', TRUE), $this->input->get('jtStartIndex', TRUE));\n\t\tprint json_encode($jTableResult);\n\t}", "function checkBluegroup($group=null){\n if ($group) {\n// define('IIP_AUTH_GROUP', trim($group));\n // check for group cached response\n// if (! in_array($group, $GLOBALS['ltcuser']['groups'])) {\n // search bluegroups\n $result = $this->group_auth($GLOBALS['ltcuser']['dn'], $group);\n if (defined('IIP_AUTH_ERRNO') && IIP_AUTH_ERRNO == 3) {\n $this->_do_ldap_error();\n }\n \n // check for an auth failure and bail\n if (! $result) {\n $this->_do_auth_error();\n }\n \n // cache the results in session\n $GLOBALS['ltcuser']['groups'][] = $group;\n $_SESSION['ltcuser'] = $GLOBALS['ltcuser'];\n }\n }", "function fetchGroupDetails($group_id) {\n try {\n global $db_table_prefix;\n\n $db = pdoConnect();\n\n $sqlVars = array();\n\n $query = \"SELECT\n id,\n name,\n is_default,\n can_delete,\n home_page_id\n FROM \".$db_table_prefix.\"groups\n WHERE\n id = :group_id\n LIMIT 1\";\n\n $stmt = $db->prepare($query);\n\n $sqlVars[':group_id'] = $group_id;\n\n if (!$stmt->execute($sqlVars)){\n // Error\n return false;\n }\n\n if (!($results = $stmt->fetch(PDO::FETCH_ASSOC)))\n return false;\n\n $stmt = null;\n\n return $results;\n\n } catch (PDOException $e) {\n addAlert(\"danger\", \"Oops, looks like our database encountered an error.\");\n error_log(\"Error in \" . $e->getFile() . \" on line \" . $e->getLine() . \": \" . $e->getMessage());\n return false;\n } catch (ErrorException $e) {\n addAlert(\"danger\", \"Oops, looks like our server might have goofed. If you're an admin, please check the PHP error logs.\");\n return false;\n }\n}", "public function groups() : array\n {\n return $this->groups;\n }", "public function groups() : array\n {\n return $this->groups;\n }", "function get_this_group($grp_id)\n{\n\t$db=new db_util();\n\t$query_string=\"SELECT * FROM vm_group WHERE v_group_id=$grp_id\";\n\t$result=$db->query($query_string);\n\treturn $result;\n}", "public function listgroup() { \n \n if (!is_null(auth()->guard('api')->user()->groups)){\n \n //$user->find(Auth::user()->id); \n $data = auth()->guard('api')->user()->groups->toArray();\n $response = [ \n 'success' => true, \n 'data' => $data, \n 'message' => 'Group retrieved successfully.' \n ]; \n return response()->json($response, 200);\n }\n else { \n return response()->json(['error' => 'Unauthorised'], 401); \n } \n }", "public function getGroupsDescription()\n {\n if (class_exists(Subsite::class)) {\n Subsite::disable_subsite_filter(true);\n }\n\n // Get the member's groups, if any\n $groups = $this->owner->Groups();\n if ($groups->Count()) {\n // Collect the group names\n $groupNames = array();\n foreach ($groups as $group) {\n /** @var Group $group */\n $groupNames[] = html_entity_decode($group->getTreeTitle() ?? '');\n }\n // return a csv string of the group names, sans-markup\n $result = preg_replace(\"#</?[^>]>#\", '', implode(', ', $groupNames));\n } else {\n // If no groups then return a status label\n $result = _t(__CLASS__ . '.NOGROUPS', 'Not in a Security Group');\n }\n\n if (class_exists(Subsite::class)) {\n Subsite::disable_subsite_filter(false);\n }\n return $result;\n }", "public function get_group_name ($id)\n\t\t{\n\t\t\t$sql = \"SELECT name FROM group_list \n\t\t\t\t\tWHERE id =:id\n\t\t\t\t\tAND status = 'enabled'\";\n\t\t\t$check_query = PDO::prepare($sql);\n\t\t\t$check_query->execute(['id'=>$id]);\n\t\t\t// echo print_r($check_query->errorInfo());\n\t\t\treturn $record_array = $check_query->fetch(PDO::FETCH_ASSOC)['name'];\n\t\t}", "function wg_interface_status() {\n\tglobal $wgg;\n\n\t$if_group = escapeshellarg($wgg['if_group']);\n\n\t$status = array();\n\texec(\"{$wgg['ifconfig']} -a -g {$if_group}\", $status);\n\n\t$output = implode(\"\\n\", $status);\n\treturn $output;\n\n}", "public function get_groups($data)\n\t{\n\t\t\n\t $sql = $this->db->get_where('grupos', $data);\n\t\treturn $sql->result();\n\t}", "function &group_list($start=NULL, $limit=NULL, $direction=0, $where=NULL)\n\n {\n\n global $database, $user;\n\n \n\n\t $message_array = array();\n\n \n\n\t // MAKE SURE MESSAGES ARE ALLOWED\n\n\t \n\n \n\n // BEGIN MESSAGE QUERY\n\n $sql = \"\n\n SELECT\n\n *\n\n FROM\n\n se_groups\n\n WHERE\n\n owner='{$user->user_info['user_username']}'\n\n \";\n\n // EXECUTE QUERY\n\n $resource = $database->database_query($sql);\n\n \n\n // GET MESSAGES\n\n\t while( $message_info=$database->database_fetch_assoc($resource) )\n\n {\n\n // CREATE AN OBJECT FOR MESSAGE AUTHOR/RECIPIENT\n\n $pm_user = new SEUser();\n\n $pm_user->user_info['id'] = $message_info['id'];\n\n $pm_user->user_info['grup'] = $message_info['grup'];\n\n $pm_user->user_info['owner'] = $message_info['owner'];\n\n $pm_user->user_displayname();\n\n \n\n // Remove breaks for preview\n\n $message_info['pm_body'] = str_replace(\"<br>\", \"\", $message_info['pm_body']);\n\n \n\n // SET MESSAGE ARRAY\n\n $message_array[] = array(\n\n 'pmconvo_id' => $message_info['id'],\n\n 'pmconvo_grup' => $message_info['grup'],\n\n 'pm_owner' => $message_info['owner'],\n\t\t'pm_body' => $message_info['pm_body']\n\t\t\n\n );\n\n \n\n unset($pm_user);\n\n }\n\n \n\n return $message_array;\n\n }", "public function getGroupByName($groupName);", "function allGroupsIn($username, $permission){\n \t$con = new mysqli('localhost','heng','@powell135','200ok');\n \tif ($con -> connect_errno){\n \t\treturn CONNECTION_FAIL;\n \t}\n//\t$permission = MANAGER;\n\t$status = CONFIRMED;\n \t$query = \"select jnjn_group.groupid,name from jnjn_group inner join jnjn_user_group on jnjn_group.groupid=jnjn_user_group.groupid where username='$username' and status='$status' and permission='$permission'\";\n \t$result = $con -> query($query);\n \t$groupids = array();\n \twhile($row = mysqli_fetch_array($result)){\n \t\t$groupids[$row['name']] = $row['groupid'];\n \t}\n \t$result -> close();\n \treturn $groupids;\n }", "public function hasGroups(){\n return $this->_has(1);\n }", "public function getUsersInGroup()\n\t{\n\t\tself::authenticate();\n\n\t\t$group = FormUtil::getPassedValue('group', null, 'GETPOST');\n\n\t\tif($group == null) {\n\t\t\treturn self::retError('ERROR: No group passed!');\n\t\t}\n\n\t\t$group = UserUtil::getGroups('name = \\'' . mysql_escape_string($group) . '\\'');\n\t\t$return = array();\n\t\tif(count($group) == 1) {\n\t\t\tforeach($group as $item) {\n\t\t\t\t$users = UserUtil::getUsersForGroup($item['gid']);\n\t\t\t\tforeach($users as $uid) {\n\t\t\t\t\t$return[] = UserUtil::getVar('uname', $uid);\n\t\t\t\t}\n\t\t\t}\n\t\t} else {\n\t\t\t$return = array();\n\t\t}\n\n\t\treturn self::ret($return);\n\t}", "public function getUsergroup() {}", "function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++) { //for each group\n if (isset($groups[$i])) { // Patched by SysCo/al\n $line=trim($groups[$i]);\n \n if (strlen($line)>0){ \n //more presumptions, they're all prefixed with CN= (but no more yet, patched by SysCo/al\n //so we ditch the first three characters and the group\n //name goes up to the first comma\n $bits=explode(\",\",$line);\n if (1== count($bits)) {\n $group_array[]=$bits[0]; // Patched by SysCo/al\n } else {\n $prefix_len=strpos($bits[0], \"=\"); // Patched by SysCo/al to allow also various length (not only 3)\n if (FALSE === $prefix_len) {\n $group_array[]=$bits[0];\n } else {\n $group_array[]=substr($bits[0],$prefix_len+1); // Patched by SysCo/al\n }\n }\n }\n }\n }\n return ($group_array);\t\n }", "protected function readGroups() {\n\t\tif ($this->items) {\n\t\t\t$sql = \"SELECT\t\tuser_group.*, (SELECT COUNT(*) FROM wcf\".WCF_N.\"_user_to_groups WHERE groupID = user_group.groupID) AS members\n\t\t\t\tFROM\t\twcf\".WCF_N.\"_group user_group\n\t\t\t\tORDER BY\t\".($this->sortField != 'members' ? 'user_group.' : '').$this->sortField.\" \".$this->sortOrder;\n\t\t\t$result = WCF::getDB()->sendQuery($sql, $this->itemsPerPage, ($this->pageNo - 1) * $this->itemsPerPage);\n\t\t\twhile ($row = WCF::getDB()->fetchArray($result)) {\n\t\t\t\t$row['deletable'] = (!WCF::getUser()->getPermission('admin.user.canDeleteGroup') || Group::isMember($row['groupID']) || !Group::isAccessibleGroup($row['groupID']) || $row['groupType'] == Group::EVERYONE || $row['groupType'] == Group::GUESTS || $row['groupType'] == Group::USERS) ? 0 : 1;\n\t\t\t\t$row['editable'] = (WCF::getUser()->getPermission('admin.user.canEditGroup') && Group::isAccessibleGroup($row['groupID'])) ? 1 : 0;\n\t\t\t\t\n\t\t\t\t$this->groups[] = $row;\n\t\t\t}\n\t\t}\n\t}", "public function setGroups($groups);", "public function member_group_query($groups, $max = null, $start = 0)\n {\n $_groups = '';\n foreach ($groups as $group) {\n if ($_groups != '') {\n $_groups .= ' OR ';\n }\n $_groups .= 'u.usergroup=' . strval($group);\n }\n if ($_groups == '') {\n return array();\n }\n\n return $this->connection->query('SELECT * FROM ' . $this->connection->get_table_prefix() . 'users u LEFT JOIN ' . $this->connection->get_table_prefix() . 'usergroups g ON u.usergroup=g.gid WHERE ' . $_groups . ' ORDER BY u.usergroup ASC', $max, $start, false, true);\n }", "function validate_group_with_host(&$PAGE_GROUPS, &$PAGE_HOSTS, $reset_host = true) {\n\tglobal $page;\n\n\t$config = select_config();\n\t$dd_first_entry = $config['dropdown_first_entry'];\n\n\t$group_var = 'web.latest.groupid';\n\t$host_var = 'web.latest.hostid';\n\n\t$_REQUEST['groupid'] = get_request('groupid', CProfile::get($group_var, -1));\n\t$_REQUEST['hostid'] = get_request('hostid', CProfile::get($host_var, -1));\n\n\tif ($_REQUEST['groupid'] > 0) {\n\t\tif ($_REQUEST['hostid'] > 0) {\n\t\t\tif (!DBfetch(DBselect('SELECT hg.groupid FROM hosts_groups hg WHERE hg.hostid='.$_REQUEST['hostid'].' AND hg.groupid='.$_REQUEST['groupid']))) {\n\t\t\t\t$_REQUEST['hostid'] = 0;\n\t\t\t}\n\t\t}\n\t\telseif ($reset_host) {\n\t\t\t$_REQUEST['hostid'] = 0;\n\t\t}\n\t}\n\telse {\n\t\t$_REQUEST['groupid'] = 0;\n\n\t\tif ($reset_host && $dd_first_entry == ZBX_DROPDOWN_FIRST_NONE) {\n\t\t\t$_REQUEST['hostid'] = 0;\n\t\t}\n\t}\n\n\t$PAGE_GROUPS['selected'] = $_REQUEST['groupid'];\n\t$PAGE_HOSTS['selected'] = $_REQUEST['hostid'];\n\n\tif ($PAGE_GROUPS['selected'] == 0 && $dd_first_entry == ZBX_DROPDOWN_FIRST_NONE && $reset_host) {\n\t\t$PAGE_GROUPS['groupids'] = array();\n\t}\n\tif ($PAGE_HOSTS['selected'] == 0 && $dd_first_entry == ZBX_DROPDOWN_FIRST_NONE && $reset_host) {\n\t\t$PAGE_HOSTS['hostids'] = array();\n\t}\n\tif ($PAGE_GROUPS['original'] > -1) {\n\t\tCProfile::update('web.'.$page['menu'].'.groupid', $_REQUEST['groupid'], PROFILE_TYPE_ID);\n\t}\n\tif ($PAGE_HOSTS['original'] > -1) {\n\t\tCProfile::update('web.'.$page['menu'].'.hostid', $_REQUEST['hostid'], PROFILE_TYPE_ID);\n\t}\n\tCProfile::update($group_var, $_REQUEST['groupid'], PROFILE_TYPE_ID);\n\tCProfile::update($host_var, $_REQUEST['hostid'], PROFILE_TYPE_ID);\n}", "public function getGroupsById($groups_ids) {\n\t\treturn SQLQuery::create()->select(\"StudentsGroup\")->whereIn(\"StudentsGroup\",\"id\",$groups_ids)->execute();\n\t}", "public static function getGroups(): array\r\n {\r\n return [\r\n 'dev',\r\n 'pre',\r\n ];\r\n }", "public function getGroups() {\n\t\treturn array(\n\t\t\t'user_meta' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => 'Usage of users/usermeta tables is highly discouraged in VIP context, For storing user additional user metadata, you should look at User Attributes.',\n\t\t\t\t'object_vars' => array(\n\t\t\t\t\t'$wpdb->users',\n\t\t\t\t\t'$wpdb->usermeta',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'cache_constraints' => array(\n\t\t\t\t'type' => 'warning',\n\t\t\t\t'message' => 'Due to using Batcache, server side based client related logic will not work, use JS instead.',\n\t\t\t\t'variables' => array(\n\t\t\t\t\t'$_COOKIE',\n\t\t\t\t\t),\n\t\t\t\t'array_members' => array(\n\t\t\t\t\t'$_SERVER[\\'HTTP_USER_AGENT\\']',\n\t\t\t\t\t'$_SERVER[\\'REMOTE_ADDR\\']',\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\t}", "public function getGroupList()\n\t{\n\t\t$db = Zend_Db_Table::getDefaultAdapter();\n\t\t$query = \"select id,group_name from main_groups where isactive = 1 order by group_name\";\n\t\t$result = $db->query($query);\n\t\t$group_arr = array();\n\t\twhile($row = $result->fetch())\n\t\t{\n\t\t\t$group_arr[$row['id']] = $row['group_name'];\n\t\t}\n\n\t\treturn $group_arr;\n\t}", "public function getGroup();", "public function getGroup();", "public function getGroup();", "public function getGroupList()\n\t{\n\t\t$db = FabrikWorker::getDbo(true);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('DISTINCT(group_id)')->from('#__{package}_formgroup');\n\t\t$db->setQuery($query);\n\t\t$usedgroups = $db->loadResultArray();\n\t\tJArrayHelper::toInteger($usedgroups);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('id AS value, name AS text')->from('#__{package}_groups');\n\t\tif (!empty($usedgroups)) {\n\t\t\t$query->where('id NOT IN('.implode(\",\", $usedgroups) .')');\n\t\t}\n\t\t$query->where('published <> -2');\n\t\t$query->order(FabrikString::safeColName('text'));\n\t\t$db->setQuery($query);\n\t\t$groups = $db->loadObjectList();\n\t\t$list = JHTML::_('select.genericlist', $groups, 'jform[groups]', \"class=\\\"inputbox\\\" size=\\\"10\\\" style=\\\"width:100%;\\\" \", 'value', 'text', null, $this->id . '-from');\n\t\treturn array($groups, $list);\n\t}", "function get_groups() {\r\n global $wpdb;\r\n $groups = $wpdb->get_results( \"SELECT wcg.*, count(wcgc.client_id) as clients_count FROM {$wpdb->prefix}wpc_client_groups wcg LEFT JOIN {$wpdb->prefix}wpc_client_group_clients wcgc ON wcgc.group_id = wcg.group_id GROUP BY wcg.group_id\", \"ARRAY_A\");\r\n return $groups;\r\n }", "function listGroups($refresh = false)\n {\n return array();\n }", "function get_group_array()\n{\n\tglobal $db_raid, $table_prefix, $db_raid;\n\tglobal $db_allgroups_id, $db_allgroups_name, $db_table_allgroups ;\n\n\t$group = array();\n\t\n\t$sql = sprintf(\"SELECT \" . $db_allgroups_id . \" , \". $db_allgroups_name .\n\t\t\t\" FROM \" . $table_prefix . $db_table_allgroups .\n\t\t\t\" ORDER BY \". $db_allgroups_id);\n\t\n\t$result_group = $db_raid->sql_query($sql) or print_error($sql, $db_raid->sql_error(), 1);\n\twhile ($data_wrm = $db_raid->sql_fetchrow($result_group,true))\n\t{\n\t\t$group[$data_wrm[$db_allgroups_id]] = $data_wrm[$db_allgroups_name];\n\t}\n\n\treturn $group;\n}", "public function getGroupGroups($id_grp) {\n\n $result = array(); // container for final results array\n\n $groupSelectParents = $this->_db->select()\n ->from(array('ghg' => 'grp_has_grp'),\n array('id_parent_grp', 'id_child_grp'))\n ->joinLeft(array('ugg' => 'usr_groups_grp'),\n 'ugg.id_grp = ghg.id_child_grp',\n array('id_grp', 'group_name_grp', 'description_grp', 'body_grp'))\n ->joinLeft(array('ghau' => 'grp_has_admin_usr'),\n 'ghau.id_grp = ugg.id_grp',\n array('id_usr'))\n ->joinLeft(array('uu' => 'users_usr'),\n 'uu.id_usr = ghau.id_usr',\n array('id_usr', 'login_name_usr'))\n ->where('ghg.id_parent_grp = ?', $id_grp)\n ->group('ugg.id_grp');\n\n $groupSelectChilds = $this->_db->select()\n ->from(array('ghg' => 'grp_has_grp'),\n array('id_parent_grp', 'id_child_grp'))\n ->joinLeft(array('ugg' => 'usr_groups_grp'),\n 'ugg.id_grp = ghg.id_parent_grp',\n array('id_grp', 'group_name_grp', 'description_grp', 'body_grp'))\n ->joinLeft(array('ghau' => 'grp_has_admin_usr'),\n 'ghau.id_grp = ugg.id_grp',\n array('id_usr'))\n ->joinLeft(array('uu' => 'users_usr'),\n 'uu.id_usr = ghau.id_usr',\n array('id_usr', 'login_name_usr'))\n ->where('ghg.id_child_grp = ?', $id_grp)\n ->group('ugg.id_grp');\n\n $result['parents'] = $this->_db->fetchAll($groupSelectParents);\n $result['childs'] = $this->_db->fetchAll($groupSelectChilds);\n\n return $result;\n }", "protected function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++){ // For each group\n \t\n \tif (isset($groups[$i])) {\n \t$line=$groups[$i];\n \t} else {\n \t\t$line = '';\n \t}\n \n if (strlen($line)>0){ \n // More presumptions, they're all prefixed with CN=\n // so we ditch the first three characters and the group\n // name goes up to the first comma\n $bits=explode(\",\",$line);\n $group_array[]=substr($bits[0],3,(strlen($bits[0])-3));\n }\n }\n return ($group_array); \n }", "function getGroups()\n {\n//\t\t$this->_groups = array();\n if ( empty( $this->_groups ) ) {\n $member_handler = &zarilia_gethandler( 'member' );\n if ( $this->getVar( 'uid' ) ) {\n $this->_groups = $member_handler->getGroupsByUser( $this->getVar( 'uid' ) );\t\t\t\t\n } else {\n $this->_groups = array( 0 => ZAR_GROUP_ANONYMOUS );\n }\n }\t\t\n return $this->_groups;\n }", "public function get_property_groups(){\n\t\t$endpoint = 'groups';\n\t\ttry{\n\t\t\treturn json_decode($this->execute_get_request($this->get_request_url($endpoint,null)));\n\t\t}\n\t\tcatch(HubSpot_Exception $e){\n\t\t\tprint_r('Unable to retrieve property groups: '.$e);\n\t\t}\n\n\t}", "public function listAllGroups(): array\n {\n // call data service method to get groups\n $raw = AdminGroupsDataAccessService::read();\n\n // convert to array : GroupModel\n $groups = array();\n $i = 0;\n foreach ($raw as $row) {\n $groups[$i++] = new GroupModel($row[\"ID\"], $row[\"TITLE\"], $row[\"DESCRIPTION\"], $row[\"SUMMARY\"]);\n }\n\n // return array of GroupModel\n return $groups;\n }", "function getGroups() {\n $groups = $this->groups;\n if (is_string($groups)) {\n $groups = explode(',', $groups);\n }\n return $groups;\n }", "public function getGroupConfig()\n {\n $groups = [];\n $config = $this->getAllConfigInfo();\n\n foreach ($config as $process) {\n $groupName = $process['group'];\n\n if (! isset($groups[$groupName])) {\n $groups[$groupName] = [\n 'name' => $groupName,\n 'priority' => $process['group_prio'],\n 'inuse' => $process['inuse'],\n 'processes' => [],\n ];\n }\n\n $groups[$groupName]['processes'][$process['name']] = [\n 'name' => $process['name'],\n 'priority' => $process['process_prio'],\n 'autostart' => $process['autostart'],\n ];\n }\n\n return $groups;\n }", "function get_group_admins($gid) {\n global $db;\n \n $gid = mysql_clean($gid);\n \n $app_query = \"\";\n\n $app_query = \" AND \" . tbl($this->gp_mem_tbl) . \".active='$approved'\";\n\n //List of fields we need from a user table\n $user_fields = get_user_fields();\n\n $user_fields = apply_filters($user_fields, 'get_group_members');\n \n \n $fields_arr = array(\n // 'groups' => $fields,\n 'users' => $user_fields,\n 'members' => array('is_admin','ban','active')\n );\n \n $fields = tbl_fields($fields_arr);\n \n $query = \" SELECT \".$fields.\" FROM \".tbl('group_members').\" AS members \";\n $query .= \" LEFT JOIN \".tbl('users'). \" AS users ON \";\n $query .= \" users.userid = members.userid \";\n $query .= \" WHERE members.group_id='$gid' AND members.is_admin='yes' \";\n \n \n $result = db_select($query);\n\n if ($db->num_rows > 0)\n return $result;\n else\n return false;\n }", "function get_groups() {\n\t\tif (!isset($_SESSION['groups']))\n\t\t\tlgi_mysql_fetch_session(\"SELECT GROUP_CONCAT(`name`) AS `groups` FROM %t(usergroups) AS p, %t(usercerts) AS c WHERE p.`usercertid`=c.`id` AND c.`user`='%%'\", $this->userid);\n\t\treturn explode(',', $_SESSION['groups']);\n\t}", "public function getUserGroups()\n\t{\n\t\t\n\t\t$groups = array();\n\t\t$db \t= $this->getUserDbTable();\n\t\t$id \t= $this->getUserId();\n\t\t\n\t\tif ($id)\n\t\t{\t\n\t\t\t$groups \t= $db->getAdapter()->select()->from(array('gmt'=>'groups_members_table'))\n\t\t\t\t\t\t\t\t\t\t ->joinInner(array('gt'=>'groups_table'), 'gmt.group_id = gt.group_id')\n\t\t\t\t\t\t\t\t\t\t ->where('gmt.user_id = ? ', $id)\n\t\t\t\t\t\t\t\t\t\t ->query()->fetchAll();\n\t\t}\t\n\t\t/* Automatically append group 0===Public group */\n\t\t$public \t\t= $db->getAdapter()->select()->from(array('gmt'=>'groups_table'))->where('group_privacy_level = ? ', 0)\n\t\t\t\t\t\t\t\t\t ->query()->fetch();\n\t\t$groups[] = $public;\n\t\t\n\t\treturn $groups;\n\t}" ]
[ "0.7473587", "0.7172479", "0.68586606", "0.67845494", "0.67313975", "0.6435015", "0.6431374", "0.62554127", "0.6209404", "0.61725014", "0.61519873", "0.6061574", "0.60278887", "0.5987841", "0.5987841", "0.5968226", "0.5897901", "0.5897901", "0.589366", "0.58876103", "0.58853835", "0.5861075", "0.5855475", "0.5848313", "0.58458614", "0.5842776", "0.58415294", "0.5793261", "0.579288", "0.5708825", "0.57054484", "0.5691311", "0.569107", "0.5690209", "0.5661318", "0.5658995", "0.5643789", "0.5636512", "0.56352466", "0.5612184", "0.5610774", "0.56048274", "0.5604076", "0.5599244", "0.5587876", "0.557925", "0.55727977", "0.55727977", "0.55543613", "0.5545356", "0.55446213", "0.55293334", "0.5522123", "0.5508778", "0.5501008", "0.5498197", "0.5487189", "0.54839766", "0.5478197", "0.54766434", "0.54729676", "0.54729676", "0.54623514", "0.54579085", "0.54572576", "0.5454489", "0.54504275", "0.54493153", "0.5447444", "0.5444277", "0.5444084", "0.5431611", "0.54309046", "0.54278314", "0.5426955", "0.54262394", "0.5420651", "0.5418471", "0.54031074", "0.54005605", "0.53969556", "0.5395768", "0.5392936", "0.5387689", "0.5387689", "0.5387689", "0.53865355", "0.53849155", "0.5379632", "0.53740895", "0.53668356", "0.53618956", "0.5360267", "0.53522736", "0.53517663", "0.53491884", "0.5344802", "0.5339443", "0.5334258", "0.5327922" ]
0.66780156
5
/ returns group details array. This function is used on the hostgroups page for the grid view $groups = $hostsgroups or $servicegroups
function build_host_servicegroup_details($group_members) { global $NagiosData; global $NagiosUser; $hosts = $NagiosData->getProperty('hosts'); $servicegroup_details = array(); foreach($group_members as $member) { if($NagiosUser->is_authorized_for_host($member)) //user-level filtering { if (isset($hosts[$member]['services'])) foreach ($hosts[$member]['services'] as $service) { if($NagiosUser->is_authorized_for_service($member,$service)) //user-level filtering $servicegroup_details[] = $service; } } } return $servicegroup_details; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function build_hostgroup_details($group_members) //make this return the totals array for hosts and services \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n//\t//add filter for user-level filtering \n//\tif(!$NagiosUser->is_admin()) {\n\t\t//print $type; \n//\t\t$hosts = user_filtering($hosts,'hosts'); \t\n//\t}\n\n\t$hostgroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t\t$hostgroup_details[] = $hosts[$member];\n\t}\n\n\treturn $hostgroup_details;\n}", "function get_hostgroup_data()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\n\t$hostgroups = $NagiosData->getProperty('hostgroups');\n\t$hosts = $NagiosData->getProperty('hosts');\n\n\t$hostgroup_data = array();\n\tforeach ($hostgroups as $group => $members) \n\t{\n\t\t\n\t\t\n\t\t$hostgroup_data[$group] = array(\n\t\t\t'member_data' => array(),\n\t\t\t'host_counts' => get_state_of('hosts', build_hostgroup_details($members)),\n\t\t\t'service_counts' => get_state_of('services', build_host_servicegroup_details($members))\n\t\t\t);\n\t\t\n\t\t//skip ahead if there are no authorized hosts\t\t\t\n\t\tif(array_sum($hostgroup_data[$group]['host_counts'])==0) continue; //skip empty groups \n\t\t\t\n\t\tforeach ($members as $member) \n\t\t{\n\t\t\n\t\t\tif(!$NagiosUser->is_authorized_for_host($member)) continue; //user-level filtering \t\t\n\t\t\n\t\t\t$host = $hosts[$member];\n\t\t\tprocess_host_status_keys($host); \n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_name'] = $host['host_name'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_state'] = $host['current_state'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['state_class'] = get_color_code($host);\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'] = array();\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_url'] = \n\t\t\t\tBASEURL.'index.php?type=hostdetail&name_filter='.urlencode($host['host_name']);\n\n\t\t\t\n\t\t\tif (isset($host['services'])) {\n\t\t\t\tforeach($host['services'] as $service) {\n\t\t\t\t\n\t\t\t\t\tif(!$NagiosUser->is_authorized_for_service($member,$service['service_description'])) continue; //user-level filtering \t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\tprocess_service_status_keys($service);\n\t\t\t\t\t$service_data = array(\n\t\t\t\t\t\t'state_class' => get_color_code($service),\n\t\t\t\t\t\t'description' => $service['service_description'],\n\t\t\t\t\t\t'service_url' => htmlentities(BASEURL.'index.php?type=servicedetail&name_filter='.$service['service_id']),\n\t\t\t\t\t);\n\t\t\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'][] = $service_data;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t}\n\treturn $hostgroup_data;\n}", "public function getGroups() {}", "public function getGroups();", "public function getGroups();", "function build_servicegroups_array()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$servicegroups = $NagiosData->getProperty('servicegroups');\t\t\t\n\t$services = $NagiosData->getProperty('services');\t\t\n\t$services = user_filtering($services,'services'); \n\t\n\t$servicegroups_details = array(); //multi-dim array to hold servicegroups \t\n\tforeach($servicegroups as $groupname => $members)\n\t{\n\t\t$servicegroups_details[$groupname] = array();\n \t\t//array_dump($members); \n\t\tforeach($services as $service)\n\t\t{\t\n\t\t\tif(isset($members[$service['host_name']]) && in_array($service['service_description'],$members[$service['host_name']]))\t{\n\t\t\t\tprocess_service_status_keys($service);\t\t\n\t\t\t\t$servicegroups_details[$groupname][] = $service;\t\t\t\n\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\n\treturn $servicegroups_details; \n}", "public function listGroups()\n {\n\t\t$data = $this->call(array(), \"GET\", \"groups.json\");\n\t\t$data = $data->{'groups'};\n\t\t$groupArray = new ArrayObject();\n\t\tfor($i = 0; $i<count($data);$i++){\n\t\t\t$groupArray->append(new Group($data[$i], $this));\n\t\t}\n\t\treturn $groupArray;\n }", "public static function getGroups(): array\n {\n return [\"group2\"];\n }", "private function getGroups()\n {\n $where = '';\n if ($this->userGroups)\n {\n $groups = explode(',', $this->userGroups);\n $where .= \" uid IN ('\" . implode(\"','\", $groups) . \"') \";\n }\n $result = $GLOBALS['TYPO3_DB']->exec_SELECTquery('*', 'fe_groups', $where);\n $res = array();\n while (($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($result)))\n {\n $res[$row['uid']] = $row;\n }\n\n $this->loadGroupIcons($res);\n\n return $res;\n }", "public function ListGroups(){\n\t\t$query = \"SELECT groupTitle FROM [PUBLISH GROUPS TABLE] ORDER BY groupTitle ASC\";\n\t\treturn array(\"results\" => $this->SelectQueryHelper());\n\t}", "public function getGroups(): array;", "public function groups();", "public function groups();", "public function getGroupList()\n\t{\n\t\t$db = Zend_Db_Table::getDefaultAdapter();\n\t\t$query = \"select id,group_name from main_groups where isactive = 1 order by group_name\";\n\t\t$result = $db->query($query);\n\t\t$group_arr = array();\n\t\twhile($row = $result->fetch())\n\t\t{\n\t\t\t$group_arr[$row['id']] = $row['group_name'];\n\t\t}\n\n\t\treturn $group_arr;\n\t}", "public function getAllGroups();", "public function getGroups()\n {\n return $this->groups;\n }", "public static function getGroupList() {\n $params = $_GET;\n if (isset($params['parent_id'])) {\n // requesting child groups for a given parent\n $params['page'] = 1;\n $params['rp'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n else {\n $requiredParams = [];\n $optionalParams = [\n 'title' => 'String',\n 'created_by' => 'String',\n 'group_type' => 'String',\n 'visibility' => 'String',\n 'component_mode' => 'String',\n 'status' => 'Integer',\n 'parentsOnly' => 'Integer',\n 'showOrgInfo' => 'Boolean',\n 'savedSearch' => 'Integer',\n // Ignore 'parent_id' as that case is handled above\n ];\n $params = CRM_Core_Page_AJAX::defaultSortAndPagerParams();\n $params += CRM_Core_Page_AJAX::validateParams($requiredParams, $optionalParams);\n\n // get group list\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n\n // if no groups found with parent-child hierarchy and logged in user say can view child groups only (an ACL case),\n // go ahead with flat hierarchy, CRM-12225\n if (empty($groups)) {\n $groupsAccessible = CRM_Core_PseudoConstant::group();\n $parentsOnly = $params['parentsOnly'] ?? NULL;\n if (!empty($groupsAccessible) && $parentsOnly) {\n // recompute group list with flat hierarchy\n $params['parentsOnly'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n }\n\n //NYSS 5259 convert line breaks to html\n foreach ( $groups['data'] as &$group ) {\n $group['description'] = str_replace('\\r\\n', '\\n', $group['description']);\n $group['description'] = str_replace('\\r', '\\n', $group['description']);\n $group['description'] = str_replace('\\n', '<br />', $group['description']);\n } \n }\n\n CRM_Utils_JSON::output($groups);\n }", "function get_group_array()\n{\n\tglobal $db_raid, $table_prefix, $db_raid;\n\tglobal $db_allgroups_id, $db_allgroups_name, $db_table_allgroups ;\n\n\t$group = array();\n\t\n\t$sql = sprintf(\"SELECT \" . $db_allgroups_id . \" , \". $db_allgroups_name .\n\t\t\t\" FROM \" . $table_prefix . $db_table_allgroups .\n\t\t\t\" ORDER BY \". $db_allgroups_id);\n\t\n\t$result_group = $db_raid->sql_query($sql) or print_error($sql, $db_raid->sql_error(), 1);\n\twhile ($data_wrm = $db_raid->sql_fetchrow($result_group,true))\n\t{\n\t\t$group[$data_wrm[$db_allgroups_id]] = $data_wrm[$db_allgroups_name];\n\t}\n\n\treturn $group;\n}", "function getGroups(){\r\n\t\t$this->connectService->connect();\r\n\t\t$result = mysql_query(\"select id_group_photo,description_group_photo from group_photos order by 2\");\r\n\r\n\t\t$groups = array();\r\n\t\tfor($i = 0 ; $i < mysql_num_rows($result) ; $i++){\r\n\t\t\t$groups[mysql_result($result,$i,0)] = mysql_result($result,$i,1);\r\n\t\t}\r\n\r\n\t\t$this->connectService->close();\r\n\t\treturn $groups;\r\n\t}", "public function getGroups() {\n return $this->groups;\n }", "public function groupList(){\n\t\techo json_encode($this->read_database->get_groups());\n\t}", "public function getGroups()\n\t{\n\t\treturn $this->groups;\n\t}", "public function groups() : array\n {\n return $this->groups;\n }", "public function groups() : array\n {\n return $this->groups;\n }", "function get_group_by_id($group_id) {\n $sql = \"SELECT a.*, portal_nm \n FROM com_group a \n INNER JOIN com_portal b ON a.portal_id = b.portal_id\n WHERE group_id = ?\";\n $query = $this->db->query($sql, $group_id);\n if ($query->num_rows() > 0) {\n $result = $query->row_array();\n $query->free_result();\n return $result;\n } else {\n return array();\n }\n }", "public function getGroupsList(){\n return $this->_get(4);\n }", "public function getGroupsList(){\n return $this->_get(4);\n }", "public static function get_group_info($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false, $service_props=false, $host_props=false, $limit=false, $sort_field=false, $sort_order='DESC')\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\t\t$filter_sql = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t}\n\n\t\t$limit_str = !empty($limit) ? trim($limit) : '';\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"AND sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\t$sort_string = \"\";\n\t\tif (empty($sort_field)) {\n\t\t\t$sort_string = \"h.host_name,s.current_state, s.service_description \".$sort_order;\n\t\t} else {\n\t\t\t$sort_string = $sort_field.' '.$sort_order;\n\t\t}\n\n\t\t$service_props_sql = Host_Model::build_service_props_query($service_props, 's.', 'h.');\n\t\t$host_props_sql = Host_Model::build_host_props_query($host_props, 'h.');\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_str = '';\n\t\tif ($auth->view_hosts_root || ($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$auth_str = \"\";\n\t\t} else {\n\t\t\t$auth_str = \" INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id).\" \";\n\t\t}\n\t\t$sql = \"SELECT\n\t\t\t\th.host_name,\n\t\t\t\th.address,\n\t\t\t\th.alias,\n\t\t\t\th.current_state AS host_state,\n\t\t\t\t(UNIX_TIMESTAMP() - \".($grouptype == 'service' ? 's' : 'h').\".last_state_change) AS duration,\n\t\t\t\tUNIX_TIMESTAMP() AS cur_time,\n\t\t\t\th.output AS host_output,\n\t\t\t\th.long_output AS host_long_output,\n\t\t\t\th.problem_has_been_acknowledged AS hostproblem_is_acknowledged,\n\t\t\t\th.scheduled_downtime_depth AS hostscheduled_downtime_depth,\n\t\t\t\th.notifications_enabled AS host_notifications_enabled,\n\t\t\t\th.active_checks_enabled AS host_active_checks_enabled,\n\t\t\t\th.action_url AS host_action_url,\n\t\t\t\th.icon_image AS host_icon_image,\n\t\t\t\th.icon_image_alt AS host_icon_image_alt,\n\t\t\t\th.is_flapping AS host_is_flapping,\n\t\t\t\th.notes_url AS host_notes_url,\n\t\t\t\th.display_name AS host_display_name,\n\t\t\t\ts.id AS service_id,\n\t\t\t\ts.current_state AS service_state,\n\t\t\t\t(UNIX_TIMESTAMP() - s.last_state_change) AS service_duration,\n\t\t\t\tUNIX_TIMESTAMP() AS service_cur_time,\n\t\t\t\ts.active_checks_enabled,\n\t\t\t\ts.current_state,\n\t\t\t\ts.problem_has_been_acknowledged,\n\t\t\t\t(s.scheduled_downtime_depth + h.scheduled_downtime_depth) AS scheduled_downtime_depth,\n\t\t\t\ts.last_check,\n\t\t\t\ts.output,\n\t\t\t\ts.long_output,\n\t\t\t\ts.notes_url,\n\t\t\t\ts.action_url,\n\t\t\t\ts.current_attempt,\n\t\t\t\ts.max_check_attempts,\n\t\t\t\ts.should_be_scheduled,\n\t\t\t\ts.next_check,\n\t\t\t\ts.notifications_enabled,\n\t\t\t\ts.service_description,\n\t\t\t\ts.display_name AS display_name\n\t\t\tFROM host h\n\t\t\tLEFT JOIN service s ON h.host_name=s.host_name\n\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.{$grouptype}group\n\t\t\t$auth_str\n\t\t\tWHERE 1 = 1\n\t\t\t\t{$all_sql} {$filter_sql} {$service_props_sql}\n\t\t\t\t{$host_props_sql}\n\t\t\tORDER BY \".$sort_string.\" \".$limit_str;\n\t\treturn $db->query($sql);\n\t}", "protected function getGroups()\n\t{\n\t\t$groups = array();\n\n\t\t$groups[''] = array();\n\t\t$groups[''][] = JHtml::_('select.option', $this->value, $this->value, 'value', 'text');\n\n\t\t$this->addGroup($groups, 'User', \t\t$this->getUserFields());\n\t\t$this->addGroup($groups, 'Order', \t\t$this->getOrderFields());\n\t\t$this->addGroup($groups, 'Shipping', \t$this->getAddressFields('shipping'));\n\t\t$this->addGroup($groups, 'Billing',\t$this->getAddressFields('billing'));\n\t\t$this->addGroup($groups, 'Item',\t\t$this->getItemFields());\n\n\t\treset($groups);\n\n\t\treturn $groups;\n\t}", "public function getGroupsList(){\n return $this->_get(3);\n }", "private function _get_groups() {\n\n\t\t$request = new Gitlab();\n\t\t$gitlab = $request->init_request();\n\n\t\t$groups = [];\n\t\t$page_index = 1;\n\n\t\tdo {\n\n\t\t\t$response = $gitlab->get( \"groups?per_page=100&page=$page_index\" );\n\t\t\t$response_arr = json_decode( $response->body, true );\n\n\t\t\t$groups = array_merge( $groups, $response_arr );\n\n\t\t\t$page_index = get_next_page( $response );\n\n\t\t} while ( ! empty( $page_index ) );\n\n\t\treturn $groups;\n\n\t}", "public function getGroupsList(){\n return $this->_get(1);\n }", "public function GetGroup() {\n $resource = $this->Retrieve();\n $query = mysqli_query($resource, \"SELECT grpname, grpdesc FROM `group`\");\n while ($row = mysqli_fetch_object($query)) {\n $p[] = $row;\n }\n return json_encode($p);\n }", "public function getGroupList()\n\t{\n\t\t$db = FabrikWorker::getDbo(true);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('DISTINCT(group_id)')->from('#__{package}_formgroup');\n\t\t$db->setQuery($query);\n\t\t$usedgroups = $db->loadResultArray();\n\t\tJArrayHelper::toInteger($usedgroups);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('id AS value, name AS text')->from('#__{package}_groups');\n\t\tif (!empty($usedgroups)) {\n\t\t\t$query->where('id NOT IN('.implode(\",\", $usedgroups) .')');\n\t\t}\n\t\t$query->where('published <> -2');\n\t\t$query->order(FabrikString::safeColName('text'));\n\t\t$db->setQuery($query);\n\t\t$groups = $db->loadObjectList();\n\t\t$list = JHTML::_('select.genericlist', $groups, 'jform[groups]', \"class=\\\"inputbox\\\" size=\\\"10\\\" style=\\\"width:100%;\\\" \", 'value', 'text', null, $this->id . '-from');\n\t\treturn array($groups, $list);\n\t}", "public function ADStaff_Get_Group_List(){\n\t \n\t $result_key = parent::Initial_Result('groups');\n\t $result = &$this->ModelResult[$result_key];\n\t \n\t try{\n\t\t// 查詢資料庫\n\t\t$DB_OBJ = $this->DBLink->prepare(parent::SQL_Permission_Filter(SQL_AdStaff::SELECT_GROUP_LIST()));\n\t\tif(!$DB_OBJ->execute()){\n\t\t throw new Exception('_SYSTEM_ERROR_DB_ACCESS_FAIL'); \n\t\t}\n\t\t$groups = $DB_OBJ->fetchAll(PDO::FETCH_ASSOC);\n\t\t$result['action'] = true;\t\t\n\t\t$result['data'] = $groups;\t\t\n\t } catch (Exception $e) {\n $result['message'][] = $e->getMessage();\n }\n\t return $result;\n\t}", "public function getGroups() {\n\t\treturn array(\n\t\t\t'user_meta' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => 'Usage of users/usermeta tables is highly discouraged in VIP context, For storing user additional user metadata, you should look at User Attributes.',\n\t\t\t\t'object_vars' => array(\n\t\t\t\t\t'$wpdb->users',\n\t\t\t\t\t'$wpdb->usermeta',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'cache_constraints' => array(\n\t\t\t\t'type' => 'warning',\n\t\t\t\t'message' => 'Due to using Batcache, server side based client related logic will not work, use JS instead.',\n\t\t\t\t'variables' => array(\n\t\t\t\t\t'$_COOKIE',\n\t\t\t\t\t),\n\t\t\t\t'array_members' => array(\n\t\t\t\t\t'$_SERVER[\\'HTTP_USER_AGENT\\']',\n\t\t\t\t\t'$_SERVER[\\'REMOTE_ADDR\\']',\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\t}", "public function a_get_groups()\n {\n $query = Group::query();\n \n $query\n ->select(array(\n \"$this->groups_tb_id as id\",\n \"$this->groups_tb_name as name\",\n ));\n\n return $query\n ->get()\n ->toArray();\n }", "function fetchAllGroups() {\n try {\n global $db_table_prefix;\n\n $results = array();\n\n $db = pdoConnect();\n\n $sqlVars = array();\n\n $query = \"SELECT\n id,\n name,\n is_default,\n can_delete,\n home_page_id\n FROM \".$db_table_prefix.\"groups\";\n\n $stmt = $db->prepare($query);\n\n if (!$stmt->execute($sqlVars)){\n // Error\n return false;\n }\n\n while ($r = $stmt->fetch(PDO::FETCH_ASSOC)) {\n $id = $r['id'];\n $results[$id] = $r;\n }\n $stmt = null;\n\n return $results;\n\n } catch (PDOException $e) {\n addAlert(\"danger\", \"Oops, looks like our database encountered an error.\");\n error_log(\"Error in \" . $e->getFile() . \" on line \" . $e->getLine() . \": \" . $e->getMessage());\n return false;\n } catch (ErrorException $e) {\n addAlert(\"danger\", \"Oops, looks like our server might have goofed. If you're an admin, please check the PHP error logs.\");\n return false;\n }\n}", "public function adminHasRetrievedGroupListUsingTheGraphApi(): array {\n\t\t$response = GraphHelper::getGroups(\n\t\t\t$this->featureContext->getBaseUrl(),\n\t\t\t$this->featureContext->getStepLineRef(),\n\t\t\t$this->featureContext->getAdminUsername(),\n\t\t\t$this->featureContext->getAdminPassword()\n\t\t);\n\t\tif ($response->getStatusCode() === 200) {\n\t\t\t$jsonResponseBody = $this->featureContext->getJsonDecodedResponse($response);\n\t\t\treturn $jsonResponseBody[\"value\"];\n\t\t} else {\n\t\t\t$this->throwHttpException($response, \"Could not retrieve groups list.\");\n\t\t}\n\t}", "public function get_groups()\n {\n $qry = ee()->db->where('site_id', ee()->publisher_lib->site_id)\n ->order_by('group_name', 'asc')\n ->get('category_groups');\n\n $groups = array();\n\n if ($qry->num_rows())\n {\n foreach ($qry->result() as $group)\n {\n $groups[$group->group_id] = $group;\n }\n }\n\n return $groups;\n }", "function timeconditions_timegroups_list_groups() {\n\tglobal $db;\n\t$tmparray = array();\n\n\t$sql = \"select id, description from timegroups_groups order by description\";\n\t$results = $db->getAll($sql);\n\tif(DB::IsError($results)) {\n\t\t$results = null;\n\t}\n\tforeach ($results as $val) {\n\t\t$tmparray[] = array($val[0], $val[1], \"value\" => $val[0], \"text\" => $val[1]);\n\t}\n\treturn $tmparray;\n}", "public function findServiceGroups(): array;", "public static function HostGroup(){\n return bzhyCBase::getInstanceByObject('hostgroup',[]);\n }", "function getGroups()\n {\n//\t\t$this->_groups = array();\n if ( empty( $this->_groups ) ) {\n $member_handler = &zarilia_gethandler( 'member' );\n if ( $this->getVar( 'uid' ) ) {\n $this->_groups = $member_handler->getGroupsByUser( $this->getVar( 'uid' ) );\t\t\t\t\n } else {\n $this->_groups = array( 0 => ZAR_GROUP_ANONYMOUS );\n }\n }\t\t\n return $this->_groups;\n }", "public function listAllGroups(): array\n {\n // call data service method to get groups\n $raw = AdminGroupsDataAccessService::read();\n\n // convert to array : GroupModel\n $groups = array();\n $i = 0;\n foreach ($raw as $row) {\n $groups[$i++] = new GroupModel($row[\"ID\"], $row[\"TITLE\"], $row[\"DESCRIPTION\"], $row[\"SUMMARY\"]);\n }\n\n // return array of GroupModel\n return $groups;\n }", "public function getUserGroups()\n\t{\n\t\tself::authenticate();\n\n\t\t$uname = FormUtil::getPassedValue('user', null);\n\t\tif($uname == null) {\n\t\t\treturn self::retError('ERROR: No user name passed!');\n\t\t}\n\n\t\t$uid = UserUtil::getIdFromName($uname);\n\t\tif($uid == false) {\n\t\t\treturn self::ret(false);\n\t\t}\n\n\t\t$groups = UserUtil::getGroupsForUser($uid);\n\t\t$return = array();\n\t\tforeach($groups as $item) {\n\t\t\t$group = UserUtil::getGroup($item);\n\t\t\t$return[] = $group['name'];\n\t\t}\n\t\tif(SecurityUtil::checkPermission('Owncloud::Admin', '::', ACCESS_MODERATE, $uid)) {\n\t\t\t$return[] = 'admin';\n\t\t}\n\t\treturn self::ret($return);\n\t}", "public function get_groups($args = [])\n {\n global $db, $system;\n /* initialize arguments */\n $user_id = !isset($args['user_id']) ? null : $args['user_id'];\n $offset = !isset($args['offset']) ? 0 : $args['offset'];\n $get_all = !isset($args['get_all']) ? false : true;\n $suggested = !isset($args['suggested']) ? false : true;\n $random = !isset($args['random']) ? false : true;\n $managed = !isset($args['managed']) ? false : true;\n $results = !isset($args['results']) ? $system['max_results_even'] : $args['results'];\n /* initialize vars */\n $groups = [];\n $offset *= $results;\n /* get suggested groups */\n if ($suggested) {\n $where_statement = \"\";\n /* make a list from joined groups (approved|pending) */\n $groups_ids = $this->get_groups_ids();\n if ($groups_ids) {\n $groups_list = implode(',', $groups_ids);\n $where_statement .= \"AND group_id NOT IN (\" . $groups_list . \") \";\n }\n $sort_statement = ($random) ? \" ORDER BY RAND() \" : \" ORDER BY group_id DESC \";\n $limit_statement = ($get_all) ? \"\" : sprintf(\"LIMIT %s, %s\", secure($offset, 'int', false), secure($results, 'int', false));\n $get_groups = $db->query(\"SELECT * FROM `groups` WHERE group_privacy != 'secret' \" . $where_statement . $sort_statement . $limit_statement) or _error(\"SQL_ERROR_THROWEN\");\n /* get the \"taget\" all groups who admin */\n } elseif ($managed) {\n $get_groups = $db->query(sprintf(\"SELECT `groups`.* FROM groups_admins INNER JOIN `groups` ON groups_admins.group_id = `groups`.group_id WHERE groups_admins.user_id = %s ORDER BY group_id DESC\", secure($user_id, 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n /* get the \"viewer\" groups who admin */\n } elseif ($user_id == null) {\n $limit_statement = ($get_all) ? \"\" : sprintf(\"LIMIT %s, %s\", secure($offset, 'int', false), secure($results, 'int', false));\n $get_groups = $db->query(sprintf(\"SELECT `groups`.* FROM groups_admins INNER JOIN `groups` ON groups_admins.group_id = `groups`.group_id WHERE groups_admins.user_id = %s ORDER BY group_id DESC \" . $limit_statement, secure($this->_data['user_id'], 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n /* get the \"target\" groups*/\n } else {\n /* get the target user's privacy */\n $get_privacy = $db->query(sprintf(\"SELECT user_privacy_groups FROM users WHERE user_id = %s\", secure($user_id, 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n $privacy = $get_privacy->fetch_assoc();\n /* check the target user's privacy */\n if (!$this->check_privacy($privacy['user_privacy_groups'], $user_id)) {\n return $groups;\n }\n /* if the viewer not the target exclude secret groups */\n $where_statement = ($this->_data['user_id'] == $user_id) ? \"\" : \"AND `groups`.group_privacy != 'secret'\";\n $limit_statement = ($get_all) ? \"\" : sprintf(\"LIMIT %s, %s\", secure($offset, 'int', false), secure($results, 'int', false));\n $get_groups = $db->query(sprintf(\"SELECT `groups`.* FROM `groups` INNER JOIN groups_members ON `groups`.group_id = groups_members.group_id WHERE groups_members.approved = '1' AND groups_members.user_id = %s \" . $where_statement . \" ORDER BY group_id DESC \" . $limit_statement, secure($user_id, 'int'))) or _error(\"SQL_ERROR_THROWEN\");\n }\n if ($get_groups->num_rows > 0) {\n while ($group = $get_groups->fetch_assoc()) {\n $group['group_picture'] = get_picture($group['group_picture'], 'group');\n /* check if the viewer joined the group */\n $group['i_joined'] = $this->check_group_membership($this->_data['user_id'], $group['group_id']);;\n $groups[] = $group;\n }\n }\n return $groups;\n }", "public function retrieveGroups()\n {\n return $this->start()->uri(\"/api/group\")\n ->get()\n ->go();\n }", "function all_groups($include_desc = false,\n $search = \"*\",\n $sorted = true,\n $local_group = FALSE // $local_group switch added by SysCo/al\n )\n {\n $this->_warning_message = \"\";\n if (!$this->_bind){ return (false); }\n\n if (2 == $this->_ldap_server_type) { // Generic LDAP\n $filter=\"(|(objectClass=posixGroup)(objectClass=groupofNames))\";\n $fields=array($this->_group_cn_identifier,\"description\");\n } else { // Active Directory\n //perform the search and grab all their details\n if ($local_group) {\n $group_account_type = \"(|(samaccounttype=\".ADLDAP_SECURITY_LOCAL_GROUP.\")(samaccounttype=\". ADLDAP_SECURITY_GLOBAL_GROUP.\"))\";\n } else {\n $group_account_type = \"(samaccounttype=\".ADLDAP_SECURITY_GLOBAL_GROUP.\")\";\n }\n $filter = \"(&(objectCategory=group)\".$group_account_type.\"(cn=\".$search.\"))\";\n $fields = array($this->_group_cn_identifier,\"description\");\n }\n\n $groups_array = array();\n\n $pageSize = 1000;\n $page_cookie = '';\n do {\n if (function_exists('ldap_control_paged_result')) {\n ldap_control_paged_result($this->_conn, $pageSize, false, $page_cookie);\n }\n $sr = @ldap_search($this->_conn,$this->_base_dn,$filter,$fields);\n \n if ((!function_exists('ldap_control_paged_result')) && (4 == ldap_errno($this->_conn))) {\n $cr = @ldap_count_entries($this->_conn,$sr);\n $this->_warning_message = \"LDAP server cannot return more than $cr records.\";\n }\n \n $entries = $this->ldap_get_entries_raw($sr);\n\n for ($i=0; $i<$entries[\"count\"]; $i++){\n if ($include_desc && strlen($entries[$i][\"description\"][0]) > 0 ){\n $groups_array[ $entries[$i][$this->_group_cn_identifier][0] ] = $entries[$i][\"description\"][0];\n } elseif ($include_desc){\n $groups_array[ $entries[$i][$this->_group_cn_identifier][0] ] = $entries[$i][$this->_group_cn_identifier][0];\n } else {\n array_push($groups_array, $entries[$i][$this->_group_cn_identifier][0]);\n }\n }\n if (function_exists('ldap_control_paged_result_response')) {\n ldap_control_paged_result_response($this->_conn, $sr, $page_cookie);\n }\n }\n while($page_cookie !== null && $page_cookie != '');\n \n if (function_exists('ldap_control_paged_result')) {\n // Reset LDAP paged result\n ldap_control_paged_result($this->_conn, $pageSize, false);\n }\n \n if( $sorted ){\n asort($groups_array);\n }\n \n return ($groups_array);\n \n }", "protected function getGroups()\n\t{\n\t\tif (isset($this->element['groups']))\n\t\t{\n\t\t\treturn explode(',', $this->element['groups']);\n\t\t}\n\n\t\treturn;\n\t}", "public function getGroups(){\n $groups = Group::get()->toArray();\n $groups_array = array();\n foreach($groups as $group){\n $groups_array[$group['id']]['group_name'] = $group['group_name'];\n $groups_array[$group['id']]['user_ids'] = explode(\",\",$group['user_ids']);\n }\n return $groups_array;\n }", "public function getGroupConfig()\n {\n $groups = [];\n $config = $this->getAllConfigInfo();\n\n foreach ($config as $process) {\n $groupName = $process['group'];\n\n if (! isset($groups[$groupName])) {\n $groups[$groupName] = [\n 'name' => $groupName,\n 'priority' => $process['group_prio'],\n 'inuse' => $process['inuse'],\n 'processes' => [],\n ];\n }\n\n $groups[$groupName]['processes'][$process['name']] = [\n 'name' => $process['name'],\n 'priority' => $process['process_prio'],\n 'autostart' => $process['autostart'],\n ];\n }\n\n return $groups;\n }", "public function getUserGroups()\n\t{\n\t\t\n\t\t$groups = array();\n\t\t$db \t= $this->getUserDbTable();\n\t\t$id \t= $this->getUserId();\n\t\t\n\t\tif ($id)\n\t\t{\t\n\t\t\t$groups \t= $db->getAdapter()->select()->from(array('gmt'=>'groups_members_table'))\n\t\t\t\t\t\t\t\t\t\t ->joinInner(array('gt'=>'groups_table'), 'gmt.group_id = gt.group_id')\n\t\t\t\t\t\t\t\t\t\t ->where('gmt.user_id = ? ', $id)\n\t\t\t\t\t\t\t\t\t\t ->query()->fetchAll();\n\t\t}\t\n\t\t/* Automatically append group 0===Public group */\n\t\t$public \t\t= $db->getAdapter()->select()->from(array('gmt'=>'groups_table'))->where('group_privacy_level = ? ', 0)\n\t\t\t\t\t\t\t\t\t ->query()->fetch();\n\t\t$groups[] = $public;\n\t\t\n\t\treturn $groups;\n\t}", "public function getAllGroups() {\n\t\t$groups = $this->group->getAll();\n\t\treturn $groups;\n\t}", "public function getGroups() {\n return parent::getGroups();\n }", "public function get_property_groups(){\n\t\t$endpoint = 'groups';\n\t\ttry{\n\t\t\treturn json_decode($this->execute_get_request($this->get_request_url($endpoint,null)));\n\t\t}\n\t\tcatch(HubSpot_Exception $e){\n\t\t\tprint_r('Unable to retrieve property groups: '.$e);\n\t\t}\n\n\t}", "function getGroups() {\n $groups = $this->groups;\n if (is_string($groups)) {\n $groups = explode(',', $groups);\n }\n return $groups;\n }", "public static function group_overview($type='service', $group=false, $hostprops=false, $serviceprops=false, $hoststatustypes=false, $servicestatustypes=false)\n\t{\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_objects = array();\n\t\tif ($type == 'service') {\n\t\t\t$auth_objects = $auth->get_authorized_servicegroups();\n\t\t} elseif ($type == 'host') {\n\t\t\t$auth_objects = $auth->get_authorized_hostgroups();\n\t\t}\n\n\t\t$contact = $auth->id;\n\t\t$auth_ids = array_keys($auth_objects);\n\t\tif (empty($auth_ids) || empty($group)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$db = Database::instance();\n\n\t\tif (empty($group)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$host_match = $auth->view_hosts_root ? ''\n\t\t\t: \" AND h.id IN (SELECT host FROM contact_access WHERE contact=\".(int)$contact.\" AND service IS NULL) \";\n\t\tif (!empty($hostprops)) {\n\t\t\t$host_match .= Host_Model::build_host_props_query($hostprops, 'host.');\n\t\t}\n\n\t\t$service_match = $auth->view_hosts_root || $auth->view_services_root ? ''\n\t\t\t: \" AND service.id IN (SELECT service FROM contact_access WHERE contact=\".(int)$contact.\" AND service IS NOT NULL) \";\n\n\t\tif (!empty($serviceprops)) {\n\t\t\t$service_match .= Host_Model::build_service_props_query($serviceprops, 'service.', 'h.');\n\t\t}\n\n\t\t$filter_host_sql = false;\n\t\t$filter_service_sql = false;\n\t\tif (!empty($hoststatustypes)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatustypes);\n\t\t\t$filter_host_sql = \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\tif (!empty($servicestatustypes)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatustypes);\n\t\t\t$filter_service_sql = \" AND service.current_state IN ($bits) \";\n\t\t}\n\n\t\tswitch ($type) {\n\t\t\tcase 'host':\n\t\t\t\t# restrict host access for authorized contacts\n\t\t\t\tif (!$auth->view_hosts_root) {\n\t\t\t\t\t$hostgroups = $auth->hostgroups_r;\n\t\t\t\t\tif (!is_array($hostgroups) || !array_key_exists($group, $hostgroups)) {\n\t\t\t\t\t\t# user doesn't have access\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$svc_query = \"SELECT COUNT(*) FROM service WHERE service.host_name = h.host_name \".\n\t\t\t\t\t\"AND current_state = %s \".$service_match.$filter_service_sql;\n\n\t\t\t\t$sql = \"SELECT h.host_name, h.current_state, h.address, h.action_url, h.notes_url, h.icon_image,h.icon_image_alt,\".\n\t\t\t\t\t\"h.display_name, h.current_attempt, h.max_check_attempts, (\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_OK).\") AS services_ok,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_WARNING).\") AS services_warning,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_CRITICAL).\") AS services_critical,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_UNKNOWN).\") AS services_unknown,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_PENDING).\") AS services_pending \".\n\t\t\t\t\t\"FROM hostgroup hg, host h, host_hostgroup hhg \".\n\t\t\t\t\t\"WHERE hhg.hostgroup=hg.id AND h.id=hhg.host \".\n\t\t\t\t\t\"AND hg.hostgroup_name=\".$db->escape($group).$filter_host_sql.Host_Model::build_host_props_query($hostprops, 'h.');\n\t\t\t\tbreak;\n\t\t\tcase 'service':\n\t\t\t\tif (!$auth->view_hosts_root && !$auth->view_services_root) {\n\t\t\t\t\t$servicegroups = $auth->servicegroups_r;\n\t\t\t\t\tif (!is_array($servicegroups) || !array_key_exists($group, $servicegroups)) {\n\t\t\t\t\t\t# user doesn't have access\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$svc_query = \"SELECT COUNT(*) FROM service \".\n\t\t\t\t\t\"INNER JOIN service_servicegroup ON service.id = service_servicegroup.service \".\n\t\t\t\t\t\"WHERE service.host_name = h.host_name \".\n\t\t\t\t\t\"AND service_servicegroup.servicegroup = servicegroup.id \".\n\t\t\t\t\t\"AND current_state = %s \".$service_match.$filter_service_sql;\n\t\t\t\t$sql = \"SELECT DISTINCT h.host_name, h.current_state, h.address, h.action_url, \".\n\t\t\t\t\t\"h.notes_url, h.icon_image, h.icon_image_alt, h.display_name, \".\n\t\t\t\t\t\"h.current_attempt, h.max_check_attempts, (\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_OK).\") AS services_ok,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_WARNING).\") AS services_warning,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_CRITICAL).\") AS services_critical,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_UNKNOWN).\") AS services_unknown,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_PENDING).\") AS services_pending \".\n\t\t\t\t\t\"FROM host h \".\n\t\t\t\t\t\"INNER JOIN service ON h.host_name = service.host_name \" .\n\t\t\t\t\t\"INNER JOIN service_servicegroup ON service_servicegroup.service = service.id \".\n\t\t\t\t\t\"INNER JOIN servicegroup ON servicegroup.id = service_servicegroup.servicegroup \".\n\t\t\t\t\t\"WHERE servicegroup.servicegroup_name = \".$db->escape($group).\n\t\t\t\t\t$host_match.$filter_host_sql;\n\t\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treturn false;\n\t\t}\n\n\t\t$result = $db->query($sql);\n\t\treturn count($result)>0 ? $result : false;\n\t}", "public function format()\n {\n $result = array();\n\n foreach ($this->groups as $group) {\n $result[] = array(\n 'id' => $group->getInternalId(),\n 'external_id' => $group->getExternalId(),\n 'value' => $group->getName(),\n 'label' => $group->getName(),\n );\n }\n\n return $result;\n }", "public function groups()\n {\n $response = $this->request->post($this->requestUrl('get_groups'), $this->params);\n\n return $response->groups;\n }", "public function getAllGroups(){\n // Get list\n $lists = array(); \n $data = Group::where('account_id', $this->getAccountId()) \n ->where('user_id', $this->user_id)\n ->get() \n ->toArray();\n $lists = $data;\n return $lists;\n }", "public static function getGroups(): array\r\n {\r\n // TODO: Implement getGroups() method.\r\n return [\r\n 'test',\r\n 'dev',\r\n ];\r\n }", "public function getDashboardGroups(): array;", "public static function groupList()\r\n\t{\r\n\t\t$arrayData = array();\r\n\t\t$criteria=new CDbCriteria;\r\n\t\t$criteria->order = 'level DESC';\r\n\t\t$criteria->compare('level <',Yii::app()->user->level -1,false);\r\n\t\t$result = self::model()->findAll($criteria);\r\n\t\tforeach ($result as $r) {\r\n\t\t\t$arrayData[$r->id] = $r->groupname;\r\n\t\t}\r\n\t\treturn $arrayData;\r\n\t}", "public function get_groups()\n\t{\n\t\tif (empty($this->user))\n\t\t{\n\t\t\treturn false;\n\t\t}\n\n\t\treturn array(array('UniGroup', $this->user[static::_column('group')]));\n\t}", "public function getGroup();", "public function getGroup();", "public function getGroup();", "public function GetGroupsList()\n\t{\n\t\t$queryGroupList = \"SELECT id, group_name FROM groups ORDER BY group_name\";\n $groupList = $this->sqlDataBase->query($queryGroupList);\n $groupListArr = $groupList->fetchAll(PDO::FETCH_ASSOC);\n\n return $groupListArr;\n\t}", "function fetchGroupDetails($group_id) {\n try {\n global $db_table_prefix;\n\n $db = pdoConnect();\n\n $sqlVars = array();\n\n $query = \"SELECT\n id,\n name,\n is_default,\n can_delete,\n home_page_id\n FROM \".$db_table_prefix.\"groups\n WHERE\n id = :group_id\n LIMIT 1\";\n\n $stmt = $db->prepare($query);\n\n $sqlVars[':group_id'] = $group_id;\n\n if (!$stmt->execute($sqlVars)){\n // Error\n return false;\n }\n\n if (!($results = $stmt->fetch(PDO::FETCH_ASSOC)))\n return false;\n\n $stmt = null;\n\n return $results;\n\n } catch (PDOException $e) {\n addAlert(\"danger\", \"Oops, looks like our database encountered an error.\");\n error_log(\"Error in \" . $e->getFile() . \" on line \" . $e->getLine() . \": \" . $e->getMessage());\n return false;\n } catch (ErrorException $e) {\n addAlert(\"danger\", \"Oops, looks like our server might have goofed. If you're an admin, please check the PHP error logs.\");\n return false;\n }\n}", "function listGroups($refresh = false)\n {\n return array();\n }", "public static function get_group_hoststatus($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false)\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$filter_sql = '';\n\t\t$extra_join = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\t#$svc_field = '';\n\t\t#$svc_groupby = ' GROUP BY myhost';\n\t\t#$svc_where = '';\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t\t#$svc_groupby = \" GROUP BY \".$grouptype.\"group_name, host.host_name\";\n\t\t\t#$svc_where = \" AND service.host_name=host.host_name \";\n\t\t}\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '1=1 ';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\tif (!$auth->view_hosts_root && !($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$extra_join = \"INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id);\n\t\t}\n\n\t\t$fields = 'h.host_name, h.current_state, h.address, h.action_url, h.notes_url, h.icon_image, h.icon_image_alt,';\n\t\tif ($auth->view_hosts_root) {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON ssg.{$grouptype}group = sg.id\n\t\t\t\tWHERE\n\t\t\t\t\t{$all_sql} {$filter_sql}\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t} elseif (!$auth->view_services_root && $grouptype == 'service') {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON ssg.{$grouptype}group = sg.id\n\t\t\t\t$extra_join\n\t\t\t\tWHERE\n\t\t\t\t\t{$all_sql}\n\t\t\t\t\t{$filter_sql}\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t} else {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.\".$grouptype.\"group\n\t\t\t\t$extra_join\n\t\t\t\tWHERE\n\t\t\t\t\t\".$all_sql.\"\n\t\t\t\t\t\".$filter_sql.\"\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t}\n\t\t$result = $db->query($sql);\n\t\t#echo $sql.\"<hr />\";\n\t\treturn $result;\n\t}", "public function getGroups() {\n\t\t$groups = array(\n\t\t\t'get_posts' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use WP_Query instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'get_posts',\n\t\t\t\t\t'wp_get_recent_posts',\n\t\t\t\t\t'get_children',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_get_post_terms' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use get_the_terms() instead. Use wp_list_pluck() to get the IDs.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_get_post_terms',\n\t\t\t\t\t'wp_get_object_terms',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_get_post_categories' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use the equivalent get_the_* version instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_get_post_categories',\n\t\t\t\t\t'wp_get_post_tags',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_old_slug_redirect' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use wpcom_vip_old_slug_redirect() instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_old_slug_redirect',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'get_term_by' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => \"%s() is an uncached function; use wpcom_vip_get_term_by() instead.\",\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'get_term_by',\n\t\t\t\t\t'get_cat_ID',\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\n\t\t$wpcom_vip_fns = array(\n\t\t\t'get_category_by_slug',\n\t\t\t'get_term_link',\n\t\t\t'get_page_by_title',\n\t\t\t'get_page_by_path',\n\t\t\t'url_to_postid',\n\t\t);\n\t\tforeach ( $wpcom_vip_fns as $function ) {\n\t\t\t$groups[ $function ] = array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => \"%s() is an uncached function; use wpcom_vip_$function() instead.\",\n\t\t\t\t'functions' => array(\n\t\t\t\t\t$function\n\t\t\t\t),\n\t\t\t);\n\t\t}\n\n\t\treturn $groups;\n\t}", "function loadGroups($adminGroups = NULL) {\n $this->groupList = array();\n $sql = \"SELECT surfergroup_id,\n surfergroup_title,\n surfergroup_profile_page,\n surfergroup_redirect_page,\n surfergroup_admin_group,\n surfergroup_identifier\n FROM %s\";\n if ($adminGroups !== NULL) {\n if (!in_array(0, $adminGroups)) {\n $adminGroups[] = 0;\n }\n $sql .= \" WHERE \".str_replace(\n '%',\n '%%',\n $this->databaseGetSqlCondition(array('surfergroup_admin_group' => $adminGroups))\n );\n }\n $sql .= \" ORDER BY surfergroup_title\";\n if ($res = $this->databaseQueryFmt($sql, array($this->tableGroups))) {\n while ($row = $res->fetchRow(DB_FETCHMODE_ASSOC)) {\n $this->groupList[$row['surfergroup_id']] = $row;\n }\n $res->free();\n if (!empty($this->groupList)) {\n return TRUE;\n }\n }\n return FALSE;\n }", "public function getDetails($group_id);", "public function findGroups() {\n\t\t\n\t}", "protected function readGroups() {\n\t\tif ($this->items) {\n\t\t\t$sql = \"SELECT\t\tuser_group.*, (SELECT COUNT(*) FROM wcf\".WCF_N.\"_user_to_groups WHERE groupID = user_group.groupID) AS members\n\t\t\t\tFROM\t\twcf\".WCF_N.\"_group user_group\n\t\t\t\tORDER BY\t\".($this->sortField != 'members' ? 'user_group.' : '').$this->sortField.\" \".$this->sortOrder;\n\t\t\t$result = WCF::getDB()->sendQuery($sql, $this->itemsPerPage, ($this->pageNo - 1) * $this->itemsPerPage);\n\t\t\twhile ($row = WCF::getDB()->fetchArray($result)) {\n\t\t\t\t$row['deletable'] = (!WCF::getUser()->getPermission('admin.user.canDeleteGroup') || Group::isMember($row['groupID']) || !Group::isAccessibleGroup($row['groupID']) || $row['groupType'] == Group::EVERYONE || $row['groupType'] == Group::GUESTS || $row['groupType'] == Group::USERS) ? 0 : 1;\n\t\t\t\t$row['editable'] = (WCF::getUser()->getPermission('admin.user.canEditGroup') && Group::isAccessibleGroup($row['groupID'])) ? 1 : 0;\n\t\t\t\t\n\t\t\t\t$this->groups[] = $row;\n\t\t\t}\n\t\t}\n\t}", "public function getGroupNames()\n {\n $groups = deserialize( $this->groups );\n if ( ! count( $groups ) )\n {\n return array();\n }\n\n $query = 'select name from ' . $this->group_table . ' where ';\n $params = array();\n foreach ( $groups as $group )\n {\n $query .= 'id = ? or ';\n $params[] = $group;\n }\n\n $query = substr( $query, 0, strlen( $query ) - 4 );\n\n $records = $this->Database->prepare( $query )\n ->execute( $params );\n\n $group_names = array();\n while ( $records->next() )\n {\n $group_names[] = $records->name;\n }\n\n return $group_names;\n }", "protected function _getGroups() {\n\t\t$groups = Mage::getResourceModel('flexslider/group_collection');\n\t\t$options = array('' => $this->__('-- Please Select --'));\n\n\t\tforeach($groups as $group) {\n\t\t\t$options[$group->getId()] = $group->getTitle();\n\t\t}\n\n\t\treturn $options;\n\t}", "public function getGroups() {\r\n // Array to hold the group objects\r\n $groups = [];\r\n // Loop through each of the groups the user belongs to\r\n foreach ($this->groups as $group) {\r\n // Get the group from the database\r\n $grp = UserGroup::getByName($group);\r\n // If the group has a valid ID (not 0 or less)\r\n if ($grp->id != 0) {\r\n // Add the group to the array\r\n $groups[] = $grp;\r\n }\r\n }\r\n // Return the groups array\r\n return $groups;\r\n }", "public function groups()\n {\n $return = ['everyone'];\n\n $groups = GroupMember::where('user_id', $this->id())\n ->sort('`group` ASC')\n ->all();\n\n foreach ($groups as $group) {\n $return[] = $group->group;\n }\n\n return $return;\n }", "protected function getGroupList() {}", "protected function getGroupList() {}", "public function get_groups($data)\n\t{\n\t\t\n\t $sql = $this->db->get_where('grupos', $data);\n\t\treturn $sql->result();\n\t}", "function get_groups() {\n\t\tif (!isset($_SESSION['groups']))\n\t\t\tlgi_mysql_fetch_session(\"SELECT GROUP_CONCAT(`name`) AS `groups` FROM %t(usergroups) AS p, %t(usercerts) AS c WHERE p.`usercertid`=c.`id` AND c.`user`='%%'\", $this->userid);\n\t\treturn explode(',', $_SESSION['groups']);\n\t}", "function _get_user_groups(){\r\n $groups = array();\r\n for($i=0; $i<get_sso_option('rules_number'); $i++){\r\n $rule = _get_rule($i);\r\n if($rule != FALSE){\r\n\t $is_group = _run_rule($rule['var'], $rule['regexp'], $rule['group']);\r\n\t if($is_group === TRUE) $groups[] = $rule['group'];\r\n }\r\n }\r\n return $groups;\r\n}", "public function groups() {\n\t\tif (empty($this->_compiledGroupNames)) {\n\t\t\tforeach ($this->settings['groups'] as $group) {\n\t\t\t\t$this->_compiledGroupNames[] = $this->settings['prefix'] . $group;\n\t\t\t}\n\t\t}\n\n\t\t$groups = $this->_Memcached->getMulti($this->_compiledGroupNames);\n\t\tif (count($groups) !== count($this->settings['groups'])) {\n\t\t\tforeach ($this->_compiledGroupNames as $group) {\n\t\t\t\tif (!isset($groups[$group])) {\n\t\t\t\t\t$this->_Memcached->set($group, 1, 0);\n\t\t\t\t\t$groups[$group] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t\tksort($groups);\n\t\t}\n\n\t\t$result = array();\n\t\t$groups = array_values($groups);\n\t\tforeach ($this->settings['groups'] as $i => $group) {\n\t\t\t$result[] = $group . $groups[$i];\n\t\t}\n\n\t\treturn $result;\n\t}", "function get_groups() {\r\n global $wpdb;\r\n $groups = $wpdb->get_results( \"SELECT wcg.*, count(wcgc.client_id) as clients_count FROM {$wpdb->prefix}wpc_client_groups wcg LEFT JOIN {$wpdb->prefix}wpc_client_group_clients wcgc ON wcgc.group_id = wcg.group_id GROUP BY wcg.group_id\", \"ARRAY_A\");\r\n return $groups;\r\n }", "function permission_group_details($groupId)\n\t{\n\t\tlog_message('debug', '_setting/permission_group_details');\n\t\tlog_message('debug', '_setting/permission_group_details:: [1] groupId='.$groupId);\n\n\t\t$details = array('id'=>'', 'name'=>'', 'is_removable', 'rules'=>array(), 'permissions'=>array());\n\n\t\t# Details\n\t\t$group = server_curl(IAM_SERVER_URL, array('__action'=>'get_row_as_array', 'query'=>'get_group_by_id', 'variables'=>array('group_id'=>$groupId )));\n\t\t$details['id'] = $group['id'];\n\t\t$details['name'] = $group['name'];\n\t\t$details['is_removable'] = $group['is_removable'];\n\t\t$details['group_type'] = $group['group_type'];\n\t\t$details['group_category'] = $group['group_category'];\n\n\t\t# Rules\n\t\t$rules = server_curl(IAM_SERVER_URL, array('__action'=>'get_list', 'query'=>'get_group_rules', 'variables'=>array('group_id'=>$groupId )));\n\n\t\t$finalList = array();\n\t\t# Store the rules by their id\n\t\tforeach($rules AS $row) {\n\t\t\t$finalList[$row['id']] = $row;\n\t\t}\n\t\t$details['rules'] = $finalList;\n\n\t\t# Permissions\n\t\t$permissions = server_curl(IAM_SERVER_URL, array('__action'=>'get_list', 'query'=>'get_group_permissions', 'variables'=>array('group_id'=>$groupId )));\n\t\t$finalList = array();\n\t\t# Group the permissions by their category\n\t\tforeach($permissions AS $row) {\n\t\t\tif(empty($finalList[$row['category']])) $finalList[$row['category']] = array();\n\t\t\t$finalList[$row['category']][$row['permission_id']] = $row;\n\t\t}\n\t\t$details['permissions'] = $finalList;\n\n\t\tlog_message('debug', '_setting/permission_group_details:: [2] details='.json_encode($details));\n\n\t\treturn $details;\n\t}", "public function getGroupGroups($id_grp) {\n\n $result = array(); // container for final results array\n\n $groupSelectParents = $this->_db->select()\n ->from(array('ghg' => 'grp_has_grp'),\n array('id_parent_grp', 'id_child_grp'))\n ->joinLeft(array('ugg' => 'usr_groups_grp'),\n 'ugg.id_grp = ghg.id_child_grp',\n array('id_grp', 'group_name_grp', 'description_grp', 'body_grp'))\n ->joinLeft(array('ghau' => 'grp_has_admin_usr'),\n 'ghau.id_grp = ugg.id_grp',\n array('id_usr'))\n ->joinLeft(array('uu' => 'users_usr'),\n 'uu.id_usr = ghau.id_usr',\n array('id_usr', 'login_name_usr'))\n ->where('ghg.id_parent_grp = ?', $id_grp)\n ->group('ugg.id_grp');\n\n $groupSelectChilds = $this->_db->select()\n ->from(array('ghg' => 'grp_has_grp'),\n array('id_parent_grp', 'id_child_grp'))\n ->joinLeft(array('ugg' => 'usr_groups_grp'),\n 'ugg.id_grp = ghg.id_parent_grp',\n array('id_grp', 'group_name_grp', 'description_grp', 'body_grp'))\n ->joinLeft(array('ghau' => 'grp_has_admin_usr'),\n 'ghau.id_grp = ugg.id_grp',\n array('id_usr'))\n ->joinLeft(array('uu' => 'users_usr'),\n 'uu.id_usr = ghau.id_usr',\n array('id_usr', 'login_name_usr'))\n ->where('ghg.id_child_grp = ?', $id_grp)\n ->group('ugg.id_grp');\n\n $result['parents'] = $this->_db->fetchAll($groupSelectParents);\n $result['childs'] = $this->_db->fetchAll($groupSelectChilds);\n\n return $result;\n }", "public function findHostGroups(?int $hostId): array;", "function fillGroups() \n\t{\n\t\t$this->groups[] = array(-1,\"<\".\"Admin\".\">\");\n\t\t$this->groupFullChecked[] = true;\n\t\t\n\t\t$trs = db_query(\"select , from `uggroups` order by \",$this->conn);\n\t\twhile($tdata = db_fetch_numarray($trs))\n\t\t{\n\t\t\t$this->groups[] = array($tdata[0],$tdata[1]);\n\t\t\t$this->groupFullChecked[] = true;\n\t\t}\n\t}", "function get_group_by_name($group_name) {\r\n // set connection var\r\n global $db;\r\n\r\n //query to get all associated groups\r\n $sql = \"SELECT id\r\n FROM groups\r\n WHERE is_active = '1'\r\n AND local = '0'\r\n AND name = '$group_name'\r\n ORDER BY name ASC;\";\r\n\r\n $groups_data = array();\r\n $groups = array();\r\n\r\n foreach ($db->query($sql) as $key => $value) {\r\n $groups_data[$key] = $value;\r\n foreach ($groups_data[$key] as $subkey => $subvalue) {\r\n if (is_int($subkey)) {\r\n $groups[] = $subvalue;\r\n }\r\n }\r\n }\r\n\r\n return $groups;\r\n}", "function getMySqlServerGroups() {\n if ($this->connectToMySqlWithParams('localhost:3307', 'root', 'myzconun')) {\n $query = sprintf(\"SELECT * FROM scuola.mysql_servers_groups\");\n\n // Perform Query\n $result = mysql_query($query);\n }\n $this->closeConnection();\n return $result;\n }", "public static function getAll(){\n $conn = DataManager::getInstance()->getConnection();\n if(!$conn || $conn->connect_error) exit();\n $statement = $conn->prepare('SELECT `id` FROM `groups` WHERE 1');\n if(!$statement || !$statement->execute()) exit();\n $result_set = $statement->get_result();\n $group_ids = array();\n while($row = $result_set->fetch_assoc()){\n array_push($group_ids, $row['id']);\n }\n $output = array();\n foreach($group_ids as $id){\n array_push($output, self::fromId($id));\n }\n return $output;\n }", "function timeconditions_timegroups_get_group($timegroup) {\n\tglobal $db;\n\n\t$sql = \"select id, description from timegroups_groups where id = $timegroup\";\n\t$results = $db->getAll($sql);\n\tif(DB::IsError($results)) {\n \t\t$results = null;\n\t}\n\t$tmparray = array($results[0][0], $results[0][1]);\n\treturn $tmparray;\n}", "function getActionGroups($limit = NULL, $offset = NULL) {\n $sql = \"SELECT actiongroup_id, actiongroup_name\n FROM %s\n ORDER BY actiongroup_name ASC\";\n $sqlParams = array($this->tableGroups);\n $result = array();\n if ($res = $this->databaseQueryFmt($sql, $sqlParams, $limit, $offset)) {\n while ($row = $res->fetchRow(DB_FETCHMODE_ASSOC)) {\n $result[$row['actiongroup_id']] = $row['actiongroup_name'];\n }\n }\n return $result;\n }", "public function groups()\n {\n #$ignore = array('internal', 'id', 'toc', 'todo', 'method');\n $titles = array(\n 'return' => 'Response',\n 'example' => $this->hasMany('example') ? 'Examples' : 'Example',\n 'copyright' => 'Copyright',\n 'see' => 'See also',\n 'link' => $this->hasMany('link') ? 'Links' : 'Link',\n );\n $groups = array();\n\n foreach ($titles as $key => $title) {\n if(\n isset($this->{$key})\n #&& !in_array($key, $ignore)\n ) {\n $groups[] = array(\n 'title' => $title,\n 'items' => (array) $this->get($key)\n );\n }\n }\n\n return $groups;\n }", "public function getGroups()\n\t{\n\t\tself::authenticate();\n\n\t\t$search = FormUtil::getPassedValue('search', null, 'GETPOST');\n\t\tif($search == 'admin') {\n\t\t\t$return = array('admin');\n\t\t} else {\n\t\t\t$return = array();\n\t\t}\n\n\t\tif($search != '') {\n\t\t\t$where = 'name LIKE \\'' . mysql_escape_string($search) . '%\\'';\n\t\t} else {\n\t\t\t$where = '';\n\t\t}\n\t\t$offset = (integer)FormUtil::getPassedValue('offset', -1);\n\t\tif($offset == null) {\n\t\t\t$offset = -1;\n\t\t}\n\t\t$limit = (integer)FormUtil::getPassedValue('limit', -1);\n\t\tif($limit == null) {\n\t\t\t$limit = -1;\n\t\t}\n\n\t\t$groups = UserUtil::getGroups($where, 'name', $offset, $limit);\n\n\t\t$return = array();\n\t\tforeach($groups as $item) {\n\t\t\t$return[] = $item['name'];\n\t\t}\n\n\t\treturn self::ret($return);\n\t}", "function get_groups($box)\n {\n $arr = array();\n foreach ($box['groups'] as $group_key)\n {\n $group = $this->fs_groups->get($group_key);\n if (is_array($group))\n {\n $group['tag_id'] = $box['tag_id'] . '-' . $group['key'];\n $arr[] = $group;\n }\n }\n sort_by_order(&$arr);\n return $arr;\n }" ]
[ "0.7404986", "0.739806", "0.69599473", "0.6900292", "0.6900292", "0.6831377", "0.6788465", "0.67660385", "0.6744251", "0.66424835", "0.6615234", "0.65767515", "0.65767515", "0.65120876", "0.65056247", "0.6474259", "0.64639544", "0.6457269", "0.64553773", "0.6442838", "0.6439043", "0.64289093", "0.64281774", "0.64281774", "0.64249766", "0.6424639", "0.6424639", "0.6424071", "0.64228666", "0.6414348", "0.64124155", "0.64063364", "0.6385192", "0.6378854", "0.63717794", "0.63667744", "0.6341632", "0.6322175", "0.6317755", "0.62913316", "0.62767726", "0.62614816", "0.62592524", "0.6258749", "0.62479216", "0.6234452", "0.6222869", "0.62091255", "0.62080324", "0.6203802", "0.61939764", "0.61674833", "0.6161902", "0.61615324", "0.616144", "0.61486715", "0.6136842", "0.6136838", "0.61338776", "0.6129392", "0.6124005", "0.6111287", "0.6105731", "0.609732", "0.6084696", "0.60663235", "0.60663235", "0.60663235", "0.6064139", "0.6053155", "0.6050011", "0.60490423", "0.6039227", "0.6037356", "0.60341215", "0.6028807", "0.6021265", "0.6018941", "0.6015103", "0.6010022", "0.60030913", "0.60009545", "0.60009545", "0.5990766", "0.59881234", "0.59876746", "0.5985917", "0.59845424", "0.59820044", "0.59783036", "0.59753036", "0.59608793", "0.5949803", "0.59475344", "0.59443825", "0.59432715", "0.59290755", "0.59262395", "0.59242696", "0.5917952" ]
0.7285822
2
/ used on host and service details pages Expecting host name and/or service name checks against list of groups members returns a list of groups separated by spaces
function check_membership($hostname='', $servicename='', $servicegroup_name='') { global $NagiosData; $hostgroups_objs = $NagiosData->getProperty('hostgroups_objs'); $servicegroups_objs = $NagiosData->getProperty('servicegroups_objs'); $hostname = trim($hostname); $servicename = trim($servicename); $servicegroup_name = trim($servicegroup_name); $memberships = array(); if($hostname!='' && $servicename!='') { //search servicegroups array //create regexp string for 'host,service' $hostservice = "$hostname,$servicename"; $hostservice_regex = preg_quote($hostservice, '/'); //check regex against servicegroup 'members' index if ($servicegroup_name!='' && isset($servicegroups_objs[$servicegroup_name])) { $group = $servicegroups_objs[$servicegroup_name]; if (preg_match("/$hostservice_regex/", $group['members'])) { $str = isset($group['alias']) ? $group['alias'] : $group['servicegroup_name']; $memberships[] = $str; } } else { foreach($servicegroups_objs as $group) { if(isset($group['members']) && preg_match("/$hostservice_regex/", $group['members'])) { //use alias as default display name, else use groupname $str = isset($group['alias']) ? $group['alias'] : $group['servicegroup_name']; $memberships[] = $str; } } } } //check for host membership elseif($hostname!='' && $servicename=='') { $hostname_regex = preg_quote($hostname, '/'); foreach($hostgroups_objs as $group) { if(isset($group['members']) && preg_match("/$hostname_regex/", $group['members'])) { //use alias as default display name, else use groupname $str = isset($group['alias']) ? $group['alias'] : $group['hostgroup_name']; $memberships[] = $str; } } } return empty($memberships) ? NULL : join(' ', $memberships); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function build_host_servicegroup_details($group_members) \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n\n\t$servicegroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t{\n\t\t\tif (isset($hosts[$member]['services']))\n\t\t\t\tforeach ($hosts[$member]['services'] as $service) \n\t\t\t\t{\n\t\t\t\t\tif($NagiosUser->is_authorized_for_service($member,$service)) //user-level filtering \n\t\t\t\t\t\t$servicegroup_details[] = $service;\t\n\t\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\treturn $servicegroup_details;\n}", "function build_hostgroup_details($group_members) //make this return the totals array for hosts and services \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n//\t//add filter for user-level filtering \n//\tif(!$NagiosUser->is_admin()) {\n\t\t//print $type; \n//\t\t$hosts = user_filtering($hosts,'hosts'); \t\n//\t}\n\n\t$hostgroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t\t$hostgroup_details[] = $hosts[$member];\n\t}\n\n\treturn $hostgroup_details;\n}", "public function getGroups() {}", "function get_hostgroup_data()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\n\t$hostgroups = $NagiosData->getProperty('hostgroups');\n\t$hosts = $NagiosData->getProperty('hosts');\n\n\t$hostgroup_data = array();\n\tforeach ($hostgroups as $group => $members) \n\t{\n\t\t\n\t\t\n\t\t$hostgroup_data[$group] = array(\n\t\t\t'member_data' => array(),\n\t\t\t'host_counts' => get_state_of('hosts', build_hostgroup_details($members)),\n\t\t\t'service_counts' => get_state_of('services', build_host_servicegroup_details($members))\n\t\t\t);\n\t\t\n\t\t//skip ahead if there are no authorized hosts\t\t\t\n\t\tif(array_sum($hostgroup_data[$group]['host_counts'])==0) continue; //skip empty groups \n\t\t\t\n\t\tforeach ($members as $member) \n\t\t{\n\t\t\n\t\t\tif(!$NagiosUser->is_authorized_for_host($member)) continue; //user-level filtering \t\t\n\t\t\n\t\t\t$host = $hosts[$member];\n\t\t\tprocess_host_status_keys($host); \n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_name'] = $host['host_name'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_state'] = $host['current_state'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['state_class'] = get_color_code($host);\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'] = array();\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_url'] = \n\t\t\t\tBASEURL.'index.php?type=hostdetail&name_filter='.urlencode($host['host_name']);\n\n\t\t\t\n\t\t\tif (isset($host['services'])) {\n\t\t\t\tforeach($host['services'] as $service) {\n\t\t\t\t\n\t\t\t\t\tif(!$NagiosUser->is_authorized_for_service($member,$service['service_description'])) continue; //user-level filtering \t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\tprocess_service_status_keys($service);\n\t\t\t\t\t$service_data = array(\n\t\t\t\t\t\t'state_class' => get_color_code($service),\n\t\t\t\t\t\t'description' => $service['service_description'],\n\t\t\t\t\t\t'service_url' => htmlentities(BASEURL.'index.php?type=servicedetail&name_filter='.$service['service_id']),\n\t\t\t\t\t);\n\t\t\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'][] = $service_data;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t}\n\treturn $hostgroup_data;\n}", "function build_servicegroups_array()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$servicegroups = $NagiosData->getProperty('servicegroups');\t\t\t\n\t$services = $NagiosData->getProperty('services');\t\t\n\t$services = user_filtering($services,'services'); \n\t\n\t$servicegroups_details = array(); //multi-dim array to hold servicegroups \t\n\tforeach($servicegroups as $groupname => $members)\n\t{\n\t\t$servicegroups_details[$groupname] = array();\n \t\t//array_dump($members); \n\t\tforeach($services as $service)\n\t\t{\t\n\t\t\tif(isset($members[$service['host_name']]) && in_array($service['service_description'],$members[$service['host_name']]))\t{\n\t\t\t\tprocess_service_status_keys($service);\t\t\n\t\t\t\t$servicegroups_details[$groupname][] = $service;\t\t\t\n\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\n\treturn $servicegroups_details; \n}", "function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++) { //for each group\n if (isset($groups[$i])) { // Patched by SysCo/al\n $line=trim($groups[$i]);\n \n if (strlen($line)>0){ \n //more presumptions, they're all prefixed with CN= (but no more yet, patched by SysCo/al\n //so we ditch the first three characters and the group\n //name goes up to the first comma\n $bits=explode(\",\",$line);\n if (1== count($bits)) {\n $group_array[]=$bits[0]; // Patched by SysCo/al\n } else {\n $prefix_len=strpos($bits[0], \"=\"); // Patched by SysCo/al to allow also various length (not only 3)\n if (FALSE === $prefix_len) {\n $group_array[]=$bits[0];\n } else {\n $group_array[]=substr($bits[0],$prefix_len+1); // Patched by SysCo/al\n }\n }\n }\n }\n }\n return ($group_array);\t\n }", "protected function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++){ // For each group\n \t\n \tif (isset($groups[$i])) {\n \t$line=$groups[$i];\n \t} else {\n \t\t$line = '';\n \t}\n \n if (strlen($line)>0){ \n // More presumptions, they're all prefixed with CN=\n // so we ditch the first three characters and the group\n // name goes up to the first comma\n $bits=explode(\",\",$line);\n $group_array[]=substr($bits[0],3,(strlen($bits[0])-3));\n }\n }\n return ($group_array); \n }", "protected function getGroupList() {}", "protected function getGroupList() {}", "public function getGroups();", "public function getGroups();", "public function groups();", "public function groups();", "public function getGroupsList(){\n return $this->_get(3);\n }", "public function getGroupsList(){\n return $this->_get(4);\n }", "public function getGroupsList(){\n return $this->_get(4);\n }", "public function findGroups() {\n\t\t\n\t}", "public function getGroupsList(){\n return $this->_get(1);\n }", "public function findServiceGroups(): array;", "abstract protected function getGroupList() ;", "public function listAddressGroupings();", "public static function getGroups()\n{\n $regexes = array(\"/\\d\\d\\d\\d\\_\\d/\", '/.*\\d\\d/'); # ex. (1) 2007_1\n\n $ldapconn = ldap_connect(self::LDAP_HOST, self::LDAP_PORT) or die(\"Could not connect to \".self::LDAP_HOST);\n @ldap_bind($ldapconn);\n $filter = \"(objectClass=posixGroup)\";\n $justthese = array('cn', 'gidnumber');\n $result = ldap_search($ldapconn, self::LDAP_DN_GROUPS, $filter, $justthese);\n $data = ldap_get_entries($ldapconn, $result);\n $groups = array();\n for ($i = 0; $i < $data['count']; $i++) {\n foreach ($regexes as $regex) {\n if (preg_match($regex, $data[$i]['cn'][0])) {\n $groups[$data[$i]['gidnumber'][0]] = $data[$i]['cn'][0];\n break;\n }\n }\n }\n asort($groups,SORT_STRING);\n return $groups;\n}", "static function getUserGroups(){\n \n }", "public function getGroups() {\n\t\t$groups = array(\n\t\t\t'get_posts' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use WP_Query instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'get_posts',\n\t\t\t\t\t'wp_get_recent_posts',\n\t\t\t\t\t'get_children',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_get_post_terms' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use get_the_terms() instead. Use wp_list_pluck() to get the IDs.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_get_post_terms',\n\t\t\t\t\t'wp_get_object_terms',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_get_post_categories' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use the equivalent get_the_* version instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_get_post_categories',\n\t\t\t\t\t'wp_get_post_tags',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_old_slug_redirect' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use wpcom_vip_old_slug_redirect() instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_old_slug_redirect',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'get_term_by' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => \"%s() is an uncached function; use wpcom_vip_get_term_by() instead.\",\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'get_term_by',\n\t\t\t\t\t'get_cat_ID',\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\n\t\t$wpcom_vip_fns = array(\n\t\t\t'get_category_by_slug',\n\t\t\t'get_term_link',\n\t\t\t'get_page_by_title',\n\t\t\t'get_page_by_path',\n\t\t\t'url_to_postid',\n\t\t);\n\t\tforeach ( $wpcom_vip_fns as $function ) {\n\t\t\t$groups[ $function ] = array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => \"%s() is an uncached function; use wpcom_vip_$function() instead.\",\n\t\t\t\t'functions' => array(\n\t\t\t\t\t$function\n\t\t\t\t),\n\t\t\t);\n\t\t}\n\n\t\treturn $groups;\n\t}", "public function ListGroups(){\n\t\t$query = \"SELECT groupTitle FROM [PUBLISH GROUPS TABLE] ORDER BY groupTitle ASC\";\n\t\treturn array(\"results\" => $this->SelectQueryHelper());\n\t}", "public static abstract function getGroupList();", "function _get_user_groups(){\r\n $groups = array();\r\n for($i=0; $i<get_sso_option('rules_number'); $i++){\r\n $rule = _get_rule($i);\r\n if($rule != FALSE){\r\n\t $is_group = _run_rule($rule['var'], $rule['regexp'], $rule['group']);\r\n\t if($is_group === TRUE) $groups[] = $rule['group'];\r\n }\r\n }\r\n return $groups;\r\n}", "public static function getGroupList() {\n $params = $_GET;\n if (isset($params['parent_id'])) {\n // requesting child groups for a given parent\n $params['page'] = 1;\n $params['rp'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n else {\n $requiredParams = [];\n $optionalParams = [\n 'title' => 'String',\n 'created_by' => 'String',\n 'group_type' => 'String',\n 'visibility' => 'String',\n 'component_mode' => 'String',\n 'status' => 'Integer',\n 'parentsOnly' => 'Integer',\n 'showOrgInfo' => 'Boolean',\n 'savedSearch' => 'Integer',\n // Ignore 'parent_id' as that case is handled above\n ];\n $params = CRM_Core_Page_AJAX::defaultSortAndPagerParams();\n $params += CRM_Core_Page_AJAX::validateParams($requiredParams, $optionalParams);\n\n // get group list\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n\n // if no groups found with parent-child hierarchy and logged in user say can view child groups only (an ACL case),\n // go ahead with flat hierarchy, CRM-12225\n if (empty($groups)) {\n $groupsAccessible = CRM_Core_PseudoConstant::group();\n $parentsOnly = $params['parentsOnly'] ?? NULL;\n if (!empty($groupsAccessible) && $parentsOnly) {\n // recompute group list with flat hierarchy\n $params['parentsOnly'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n }\n\n //NYSS 5259 convert line breaks to html\n foreach ( $groups['data'] as &$group ) {\n $group['description'] = str_replace('\\r\\n', '\\n', $group['description']);\n $group['description'] = str_replace('\\r', '\\n', $group['description']);\n $group['description'] = str_replace('\\n', '<br />', $group['description']);\n } \n }\n\n CRM_Utils_JSON::output($groups);\n }", "public function getGroups(): array;", "public function getGroupsDescription()\n {\n if (class_exists(Subsite::class)) {\n Subsite::disable_subsite_filter(true);\n }\n\n // Get the member's groups, if any\n $groups = $this->owner->Groups();\n if ($groups->Count()) {\n // Collect the group names\n $groupNames = array();\n foreach ($groups as $group) {\n /** @var Group $group */\n $groupNames[] = html_entity_decode($group->getTreeTitle() ?? '');\n }\n // return a csv string of the group names, sans-markup\n $result = preg_replace(\"#</?[^>]>#\", '', implode(', ', $groupNames));\n } else {\n // If no groups then return a status label\n $result = _t(__CLASS__ . '.NOGROUPS', 'Not in a Security Group');\n }\n\n if (class_exists(Subsite::class)) {\n Subsite::disable_subsite_filter(false);\n }\n return $result;\n }", "public static function get_group_info($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false, $service_props=false, $host_props=false, $limit=false, $sort_field=false, $sort_order='DESC')\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\t\t$filter_sql = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t}\n\n\t\t$limit_str = !empty($limit) ? trim($limit) : '';\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"AND sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\t$sort_string = \"\";\n\t\tif (empty($sort_field)) {\n\t\t\t$sort_string = \"h.host_name,s.current_state, s.service_description \".$sort_order;\n\t\t} else {\n\t\t\t$sort_string = $sort_field.' '.$sort_order;\n\t\t}\n\n\t\t$service_props_sql = Host_Model::build_service_props_query($service_props, 's.', 'h.');\n\t\t$host_props_sql = Host_Model::build_host_props_query($host_props, 'h.');\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_str = '';\n\t\tif ($auth->view_hosts_root || ($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$auth_str = \"\";\n\t\t} else {\n\t\t\t$auth_str = \" INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id).\" \";\n\t\t}\n\t\t$sql = \"SELECT\n\t\t\t\th.host_name,\n\t\t\t\th.address,\n\t\t\t\th.alias,\n\t\t\t\th.current_state AS host_state,\n\t\t\t\t(UNIX_TIMESTAMP() - \".($grouptype == 'service' ? 's' : 'h').\".last_state_change) AS duration,\n\t\t\t\tUNIX_TIMESTAMP() AS cur_time,\n\t\t\t\th.output AS host_output,\n\t\t\t\th.long_output AS host_long_output,\n\t\t\t\th.problem_has_been_acknowledged AS hostproblem_is_acknowledged,\n\t\t\t\th.scheduled_downtime_depth AS hostscheduled_downtime_depth,\n\t\t\t\th.notifications_enabled AS host_notifications_enabled,\n\t\t\t\th.active_checks_enabled AS host_active_checks_enabled,\n\t\t\t\th.action_url AS host_action_url,\n\t\t\t\th.icon_image AS host_icon_image,\n\t\t\t\th.icon_image_alt AS host_icon_image_alt,\n\t\t\t\th.is_flapping AS host_is_flapping,\n\t\t\t\th.notes_url AS host_notes_url,\n\t\t\t\th.display_name AS host_display_name,\n\t\t\t\ts.id AS service_id,\n\t\t\t\ts.current_state AS service_state,\n\t\t\t\t(UNIX_TIMESTAMP() - s.last_state_change) AS service_duration,\n\t\t\t\tUNIX_TIMESTAMP() AS service_cur_time,\n\t\t\t\ts.active_checks_enabled,\n\t\t\t\ts.current_state,\n\t\t\t\ts.problem_has_been_acknowledged,\n\t\t\t\t(s.scheduled_downtime_depth + h.scheduled_downtime_depth) AS scheduled_downtime_depth,\n\t\t\t\ts.last_check,\n\t\t\t\ts.output,\n\t\t\t\ts.long_output,\n\t\t\t\ts.notes_url,\n\t\t\t\ts.action_url,\n\t\t\t\ts.current_attempt,\n\t\t\t\ts.max_check_attempts,\n\t\t\t\ts.should_be_scheduled,\n\t\t\t\ts.next_check,\n\t\t\t\ts.notifications_enabled,\n\t\t\t\ts.service_description,\n\t\t\t\ts.display_name AS display_name\n\t\t\tFROM host h\n\t\t\tLEFT JOIN service s ON h.host_name=s.host_name\n\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.{$grouptype}group\n\t\t\t$auth_str\n\t\t\tWHERE 1 = 1\n\t\t\t\t{$all_sql} {$filter_sql} {$service_props_sql}\n\t\t\t\t{$host_props_sql}\n\t\t\tORDER BY \".$sort_string.\" \".$limit_str;\n\t\treturn $db->query($sql);\n\t}", "public function groupList(){\n\t\techo json_encode($this->read_database->get_groups());\n\t}", "public function adminHasRetrievedGroupListUsingTheGraphApi(): array {\n\t\t$response = GraphHelper::getGroups(\n\t\t\t$this->featureContext->getBaseUrl(),\n\t\t\t$this->featureContext->getStepLineRef(),\n\t\t\t$this->featureContext->getAdminUsername(),\n\t\t\t$this->featureContext->getAdminPassword()\n\t\t);\n\t\tif ($response->getStatusCode() === 200) {\n\t\t\t$jsonResponseBody = $this->featureContext->getJsonDecodedResponse($response);\n\t\t\treturn $jsonResponseBody[\"value\"];\n\t\t} else {\n\t\t\t$this->throwHttpException($response, \"Could not retrieve groups list.\");\n\t\t}\n\t}", "private function _get_groups() {\n\n\t\t$request = new Gitlab();\n\t\t$gitlab = $request->init_request();\n\n\t\t$groups = [];\n\t\t$page_index = 1;\n\n\t\tdo {\n\n\t\t\t$response = $gitlab->get( \"groups?per_page=100&page=$page_index\" );\n\t\t\t$response_arr = json_decode( $response->body, true );\n\n\t\t\t$groups = array_merge( $groups, $response_arr );\n\n\t\t\t$page_index = get_next_page( $response );\n\n\t\t} while ( ! empty( $page_index ) );\n\n\t\treturn $groups;\n\n\t}", "function get_nntp_groups($server)\r\n {\r\n $fp = fsockopen($server, $port=\"119\", $errno, $errstr, 30);\r\n if (!$fp)\r\n {\r\n # If socket error, issue error\r\n $return_array['ERROR'] = \"ERROR: $errstr ($errno)\";\r\n }\r\n else\r\n {\r\n # Else tell server to return a list of hosted newsgroups\r\n $out = \"LIST\\r\\n\";\r\n fputs($fp, $out);\r\n $groups = read_nntp_buffer($fp);\r\n\r\n $groups_array = explode(\"\\r\\n\", $groups); // Convert to an array\r\n }\r\n fputs($fp, \"QUIT \\r\\n\"); // Log out\r\n fclose($fp); // Close socket\r\n\r\n return $groups_array;\r\n }", "public function getUserGroups()\n\t{\n\t\tself::authenticate();\n\n\t\t$uname = FormUtil::getPassedValue('user', null);\n\t\tif($uname == null) {\n\t\t\treturn self::retError('ERROR: No user name passed!');\n\t\t}\n\n\t\t$uid = UserUtil::getIdFromName($uname);\n\t\tif($uid == false) {\n\t\t\treturn self::ret(false);\n\t\t}\n\n\t\t$groups = UserUtil::getGroupsForUser($uid);\n\t\t$return = array();\n\t\tforeach($groups as $item) {\n\t\t\t$group = UserUtil::getGroup($item);\n\t\t\t$return[] = $group['name'];\n\t\t}\n\t\tif(SecurityUtil::checkPermission('Owncloud::Admin', '::', ACCESS_MODERATE, $uid)) {\n\t\t\t$return[] = 'admin';\n\t\t}\n\t\treturn self::ret($return);\n\t}", "function get_groups() {\n\t\tif (!isset($_SESSION['groups']))\n\t\t\tlgi_mysql_fetch_session(\"SELECT GROUP_CONCAT(`name`) AS `groups` FROM %t(usergroups) AS p, %t(usercerts) AS c WHERE p.`usercertid`=c.`id` AND c.`user`='%%'\", $this->userid);\n\t\treturn explode(',', $_SESSION['groups']);\n\t}", "public function ADStaff_Get_Group_List(){\n\t \n\t $result_key = parent::Initial_Result('groups');\n\t $result = &$this->ModelResult[$result_key];\n\t \n\t try{\n\t\t// 查詢資料庫\n\t\t$DB_OBJ = $this->DBLink->prepare(parent::SQL_Permission_Filter(SQL_AdStaff::SELECT_GROUP_LIST()));\n\t\tif(!$DB_OBJ->execute()){\n\t\t throw new Exception('_SYSTEM_ERROR_DB_ACCESS_FAIL'); \n\t\t}\n\t\t$groups = $DB_OBJ->fetchAll(PDO::FETCH_ASSOC);\n\t\t$result['action'] = true;\t\t\n\t\t$result['data'] = $groups;\t\t\n\t } catch (Exception $e) {\n $result['message'][] = $e->getMessage();\n }\n\t return $result;\n\t}", "public function getGroupNames()\n {\n $result = array();\n if (isset($this->configHandle->gateways)) {\n foreach ($this->configHandle->gateways->children() as $tag => $gw_group) {\n if ($tag == \"gateway_group\") {\n $result[] = (string)$gw_group->name;\n }\n }\n }\n return $result;\n }", "function getGroups() {\n $groups = $this->groups;\n if (is_string($groups)) {\n $groups = explode(',', $groups);\n }\n return $groups;\n }", "function listGroups($refresh = false)\n {\n return array();\n }", "function &group_list($start=NULL, $limit=NULL, $direction=0, $where=NULL)\n\n {\n\n global $database, $user;\n\n \n\n\t $message_array = array();\n\n \n\n\t // MAKE SURE MESSAGES ARE ALLOWED\n\n\t \n\n \n\n // BEGIN MESSAGE QUERY\n\n $sql = \"\n\n SELECT\n\n *\n\n FROM\n\n se_groups\n\n WHERE\n\n owner='{$user->user_info['user_username']}'\n\n \";\n\n // EXECUTE QUERY\n\n $resource = $database->database_query($sql);\n\n \n\n // GET MESSAGES\n\n\t while( $message_info=$database->database_fetch_assoc($resource) )\n\n {\n\n // CREATE AN OBJECT FOR MESSAGE AUTHOR/RECIPIENT\n\n $pm_user = new SEUser();\n\n $pm_user->user_info['id'] = $message_info['id'];\n\n $pm_user->user_info['grup'] = $message_info['grup'];\n\n $pm_user->user_info['owner'] = $message_info['owner'];\n\n $pm_user->user_displayname();\n\n \n\n // Remove breaks for preview\n\n $message_info['pm_body'] = str_replace(\"<br>\", \"\", $message_info['pm_body']);\n\n \n\n // SET MESSAGE ARRAY\n\n $message_array[] = array(\n\n 'pmconvo_id' => $message_info['id'],\n\n 'pmconvo_grup' => $message_info['grup'],\n\n 'pm_owner' => $message_info['owner'],\n\t\t'pm_body' => $message_info['pm_body']\n\t\t\n\n );\n\n \n\n unset($pm_user);\n\n }\n\n \n\n return $message_array;\n\n }", "public function retrieveGroups()\n {\n return $this->start()->uri(\"/api/group\")\n ->get()\n ->go();\n }", "function getMySqlServerGroups() {\n if ($this->connectToMySqlWithParams('localhost:3307', 'root', 'myzconun')) {\n $query = sprintf(\"SELECT * FROM scuola.mysql_servers_groups\");\n\n // Perform Query\n $result = mysql_query($query);\n }\n $this->closeConnection();\n return $result;\n }", "public function getGroups()\n\t{\n\t\tself::authenticate();\n\n\t\t$search = FormUtil::getPassedValue('search', null, 'GETPOST');\n\t\tif($search == 'admin') {\n\t\t\t$return = array('admin');\n\t\t} else {\n\t\t\t$return = array();\n\t\t}\n\n\t\tif($search != '') {\n\t\t\t$where = 'name LIKE \\'' . mysql_escape_string($search) . '%\\'';\n\t\t} else {\n\t\t\t$where = '';\n\t\t}\n\t\t$offset = (integer)FormUtil::getPassedValue('offset', -1);\n\t\tif($offset == null) {\n\t\t\t$offset = -1;\n\t\t}\n\t\t$limit = (integer)FormUtil::getPassedValue('limit', -1);\n\t\tif($limit == null) {\n\t\t\t$limit = -1;\n\t\t}\n\n\t\t$groups = UserUtil::getGroups($where, 'name', $offset, $limit);\n\n\t\t$return = array();\n\t\tforeach($groups as $item) {\n\t\t\t$return[] = $item['name'];\n\t\t}\n\n\t\treturn self::ret($return);\n\t}", "public static function get_group_hoststatus($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false)\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$filter_sql = '';\n\t\t$extra_join = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\t#$svc_field = '';\n\t\t#$svc_groupby = ' GROUP BY myhost';\n\t\t#$svc_where = '';\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t\t#$svc_groupby = \" GROUP BY \".$grouptype.\"group_name, host.host_name\";\n\t\t\t#$svc_where = \" AND service.host_name=host.host_name \";\n\t\t}\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '1=1 ';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\tif (!$auth->view_hosts_root && !($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$extra_join = \"INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id);\n\t\t}\n\n\t\t$fields = 'h.host_name, h.current_state, h.address, h.action_url, h.notes_url, h.icon_image, h.icon_image_alt,';\n\t\tif ($auth->view_hosts_root) {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON ssg.{$grouptype}group = sg.id\n\t\t\t\tWHERE\n\t\t\t\t\t{$all_sql} {$filter_sql}\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t} elseif (!$auth->view_services_root && $grouptype == 'service') {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON ssg.{$grouptype}group = sg.id\n\t\t\t\t$extra_join\n\t\t\t\tWHERE\n\t\t\t\t\t{$all_sql}\n\t\t\t\t\t{$filter_sql}\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t} else {\n\t\t\t$sql = \"\n\t\t\t\tSELECT $fields\n\t\t\t\t\ts.current_state AS service_state,\n\t\t\t\t\ts.state_count AS state_count\n\t\t\t\tFROM\n\t\t\t\t\thost h\n\t\t\t\tINNER JOIN (SELECT current_state, COUNT(current_state) AS state_count, MAX(id) AS id, host_name FROM service GROUP BY host_name, current_state) s ON s.host_name = h.host_name\n\t\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.\".$grouptype.\"group\n\t\t\t\t$extra_join\n\t\t\t\tWHERE\n\t\t\t\t\t\".$all_sql.\"\n\t\t\t\t\t\".$filter_sql.\"\n\t\t\t\tORDER BY\n\t\t\t\t\th.host_name\";\n\t\t}\n\t\t$result = $db->query($sql);\n\t\t#echo $sql.\"<hr />\";\n\t\treturn $result;\n\t}", "public function listGroups()\n {\n\t\t$data = $this->call(array(), \"GET\", \"groups.json\");\n\t\t$data = $data->{'groups'};\n\t\t$groupArray = new ArrayObject();\n\t\tfor($i = 0; $i<count($data);$i++){\n\t\t\t$groupArray->append(new Group($data[$i], $this));\n\t\t}\n\t\treturn $groupArray;\n }", "public static function getGroups(): array\n {\n return [\"group2\"];\n }", "protected function getRegisteredTaskGroups() {}", "function all_groups($include_desc = false,\n $search = \"*\",\n $sorted = true,\n $local_group = FALSE // $local_group switch added by SysCo/al\n )\n {\n $this->_warning_message = \"\";\n if (!$this->_bind){ return (false); }\n\n if (2 == $this->_ldap_server_type) { // Generic LDAP\n $filter=\"(|(objectClass=posixGroup)(objectClass=groupofNames))\";\n $fields=array($this->_group_cn_identifier,\"description\");\n } else { // Active Directory\n //perform the search and grab all their details\n if ($local_group) {\n $group_account_type = \"(|(samaccounttype=\".ADLDAP_SECURITY_LOCAL_GROUP.\")(samaccounttype=\". ADLDAP_SECURITY_GLOBAL_GROUP.\"))\";\n } else {\n $group_account_type = \"(samaccounttype=\".ADLDAP_SECURITY_GLOBAL_GROUP.\")\";\n }\n $filter = \"(&(objectCategory=group)\".$group_account_type.\"(cn=\".$search.\"))\";\n $fields = array($this->_group_cn_identifier,\"description\");\n }\n\n $groups_array = array();\n\n $pageSize = 1000;\n $page_cookie = '';\n do {\n if (function_exists('ldap_control_paged_result')) {\n ldap_control_paged_result($this->_conn, $pageSize, false, $page_cookie);\n }\n $sr = @ldap_search($this->_conn,$this->_base_dn,$filter,$fields);\n \n if ((!function_exists('ldap_control_paged_result')) && (4 == ldap_errno($this->_conn))) {\n $cr = @ldap_count_entries($this->_conn,$sr);\n $this->_warning_message = \"LDAP server cannot return more than $cr records.\";\n }\n \n $entries = $this->ldap_get_entries_raw($sr);\n\n for ($i=0; $i<$entries[\"count\"]; $i++){\n if ($include_desc && strlen($entries[$i][\"description\"][0]) > 0 ){\n $groups_array[ $entries[$i][$this->_group_cn_identifier][0] ] = $entries[$i][\"description\"][0];\n } elseif ($include_desc){\n $groups_array[ $entries[$i][$this->_group_cn_identifier][0] ] = $entries[$i][$this->_group_cn_identifier][0];\n } else {\n array_push($groups_array, $entries[$i][$this->_group_cn_identifier][0]);\n }\n }\n if (function_exists('ldap_control_paged_result_response')) {\n ldap_control_paged_result_response($this->_conn, $sr, $page_cookie);\n }\n }\n while($page_cookie !== null && $page_cookie != '');\n \n if (function_exists('ldap_control_paged_result')) {\n // Reset LDAP paged result\n ldap_control_paged_result($this->_conn, $pageSize, false);\n }\n \n if( $sorted ){\n asort($groups_array);\n }\n \n return ($groups_array);\n \n }", "public function getGroups() {\n\t\treturn array(\n\t\t\t'user_meta' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => 'Usage of users/usermeta tables is highly discouraged in VIP context, For storing user additional user metadata, you should look at User Attributes.',\n\t\t\t\t'object_vars' => array(\n\t\t\t\t\t'$wpdb->users',\n\t\t\t\t\t'$wpdb->usermeta',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'cache_constraints' => array(\n\t\t\t\t'type' => 'warning',\n\t\t\t\t'message' => 'Due to using Batcache, server side based client related logic will not work, use JS instead.',\n\t\t\t\t'variables' => array(\n\t\t\t\t\t'$_COOKIE',\n\t\t\t\t\t),\n\t\t\t\t'array_members' => array(\n\t\t\t\t\t'$_SERVER[\\'HTTP_USER_AGENT\\']',\n\t\t\t\t\t'$_SERVER[\\'REMOTE_ADDR\\']',\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\t}", "protected function getGroups()\n\t{\n\t\tif (isset($this->element['groups']))\n\t\t{\n\t\t\treturn explode(',', $this->element['groups']);\n\t\t}\n\n\t\treturn;\n\t}", "public static function GetList()\n {\n $groups_directory = System::GetDataPath() . 'groups';\n \n $dir_handle = opendir($groups_directory);\n $groups = array();\n\n while (($group_directory = readdir($dir_handle)) !== false)\n {\n if(!is_dir($groups_directory . '/' . $group_directory))\n continue;\n\n //just check directories inside and skip the guest user group\n if (strcmp($group_directory, '.') != 0 && strcmp($group_directory, '..') != 0 && strcmp($group_directory, 'guest') != 0)\n {\n $group_data = self::GetData($group_directory);\n\n $groups[] = $group_data;\n }\n }\n\n return $groups;\n }", "function getGroups($uid, $asString = FALSE)\n {\n static $grouplist = NULL;\n\n $menber =& xoops_gethandler('member');\n\n if (is_null($grouplist)) {\n $grouplist = $menber->getGroupList();\n }\n foreach($menber->getGroupsByUser($uid) as $gid) {\n $ret[$gid] = $grouplist[$gid];\n }\n if ($asString) {\n $ret = join($asString, $ret);\n }\n\n return $ret;\n }", "public function groups() {\n\t\tif (empty($this->_compiledGroupNames)) {\n\t\t\tforeach ($this->settings['groups'] as $group) {\n\t\t\t\t$this->_compiledGroupNames[] = $this->settings['prefix'] . $group;\n\t\t\t}\n\t\t}\n\n\t\t$groups = $this->_Memcached->getMulti($this->_compiledGroupNames);\n\t\tif (count($groups) !== count($this->settings['groups'])) {\n\t\t\tforeach ($this->_compiledGroupNames as $group) {\n\t\t\t\tif (!isset($groups[$group])) {\n\t\t\t\t\t$this->_Memcached->set($group, 1, 0);\n\t\t\t\t\t$groups[$group] = 1;\n\t\t\t\t}\n\t\t\t}\n\t\t\tksort($groups);\n\t\t}\n\n\t\t$result = array();\n\t\t$groups = array_values($groups);\n\t\tforeach ($this->settings['groups'] as $i => $group) {\n\t\t\t$result[] = $group . $groups[$i];\n\t\t}\n\n\t\treturn $result;\n\t}", "public function getAllGroups();", "function getGroup() ;", "public function get_grouplist($inc_global = 0, $pattern = '', $num = 0, $start = 0)\n {\n $return = array();\n $q_r = '';\n $q_l = 'SELECT g.gid, g.name, COUNT(ag.aid) adrcount, g.owner FROM '.$this->Tbl['adb_group'].' g LEFT JOIN '.$this->Tbl['adb_adr_group'].' ag ON ag.gid = g.gid';\n $q_l .= ($inc_global) ? ' WHERE g.owner IN('.$this->uid.',0)' : ' WHERE g.owner='.$this->uid;\n if ($num != 0) {\n $q_r .= ' LIMIT ' . intval($start) . ',' . intval($num);\n }\n $qid = $this->query($q_l . ' GROUP BY g.gid ORDER BY IF(g.`owner`!= 0, 0, 1) ASC, g.`name`' . $q_r);\n while ($line = $this->assoc($qid)) {\n $line['is_shared'] = !empty($this->allShares[$line['gid']]) ? '1' : '0';\n $return[] = $line;\n }\n return $return;\n }", "private function getGroups()\n {\n $where = '';\n if ($this->userGroups)\n {\n $groups = explode(',', $this->userGroups);\n $where .= \" uid IN ('\" . implode(\"','\", $groups) . \"') \";\n }\n $result = $GLOBALS['TYPO3_DB']->exec_SELECTquery('*', 'fe_groups', $where);\n $res = array();\n while (($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($result)))\n {\n $res[$row['uid']] = $row;\n }\n\n $this->loadGroupIcons($res);\n\n return $res;\n }", "function timeconditions_timegroups_list_groups() {\n\tglobal $db;\n\t$tmparray = array();\n\n\t$sql = \"select id, description from timegroups_groups order by description\";\n\t$results = $db->getAll($sql);\n\tif(DB::IsError($results)) {\n\t\t$results = null;\n\t}\n\tforeach ($results as $val) {\n\t\t$tmparray[] = array($val[0], $val[1], \"value\" => $val[0], \"text\" => $val[1]);\n\t}\n\treturn $tmparray;\n}", "public function getGroups($username, $password) {\nglobal $_LW;\nif (!isset($this->client)) { // require the client\n\treturn false;\n};\n$this->client->getGroups($username, $password); // perform the API call\nreturn @$this->client->groups;\n}", "function give_get_settings_groups() {\n\n\t$current_section = give_get_current_setting_section();\n\n\treturn apply_filters( 'give_get_groups_' . $current_section, array() );\n}", "protected function readGroups() {\n\t\tif ($this->items) {\n\t\t\t$sql = \"SELECT\t\tuser_group.*, (SELECT COUNT(*) FROM wcf\".WCF_N.\"_user_to_groups WHERE groupID = user_group.groupID) AS members\n\t\t\t\tFROM\t\twcf\".WCF_N.\"_group user_group\n\t\t\t\tORDER BY\t\".($this->sortField != 'members' ? 'user_group.' : '').$this->sortField.\" \".$this->sortOrder;\n\t\t\t$result = WCF::getDB()->sendQuery($sql, $this->itemsPerPage, ($this->pageNo - 1) * $this->itemsPerPage);\n\t\t\twhile ($row = WCF::getDB()->fetchArray($result)) {\n\t\t\t\t$row['deletable'] = (!WCF::getUser()->getPermission('admin.user.canDeleteGroup') || Group::isMember($row['groupID']) || !Group::isAccessibleGroup($row['groupID']) || $row['groupType'] == Group::EVERYONE || $row['groupType'] == Group::GUESTS || $row['groupType'] == Group::USERS) ? 0 : 1;\n\t\t\t\t$row['editable'] = (WCF::getUser()->getPermission('admin.user.canEditGroup') && Group::isAccessibleGroup($row['groupID'])) ? 1 : 0;\n\t\t\t\t\n\t\t\t\t$this->groups[] = $row;\n\t\t\t}\n\t\t}\n\t}", "public function getUsergroup() {}", "public function get_property_groups(){\n\t\t$endpoint = 'groups';\n\t\ttry{\n\t\t\treturn json_decode($this->execute_get_request($this->get_request_url($endpoint,null)));\n\t\t}\n\t\tcatch(HubSpot_Exception $e){\n\t\t\tprint_r('Unable to retrieve property groups: '.$e);\n\t\t}\n\n\t}", "function getMemberGroupInfo1() {\n global $inputs;\n\n $res = getAll('SELECT mg.*,\n\t m.name\n FROM member_group mg\n JOIN member m\n ON m.id = mg.member_id\n WHERE group_id = ?' , [$inputs['id']]);\n formatOutput(true, 'success', $res);\n}", "public function getMembers($group_id);", "public function getGroupList()\n\t{\n\t\t$db = FabrikWorker::getDbo(true);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('DISTINCT(group_id)')->from('#__{package}_formgroup');\n\t\t$db->setQuery($query);\n\t\t$usedgroups = $db->loadResultArray();\n\t\tJArrayHelper::toInteger($usedgroups);\n\t\t$query = $db->getQuery(true);\n\t\t$query->select('id AS value, name AS text')->from('#__{package}_groups');\n\t\tif (!empty($usedgroups)) {\n\t\t\t$query->where('id NOT IN('.implode(\",\", $usedgroups) .')');\n\t\t}\n\t\t$query->where('published <> -2');\n\t\t$query->order(FabrikString::safeColName('text'));\n\t\t$db->setQuery($query);\n\t\t$groups = $db->loadObjectList();\n\t\t$list = JHTML::_('select.genericlist', $groups, 'jform[groups]', \"class=\\\"inputbox\\\" size=\\\"10\\\" style=\\\"width:100%;\\\" \", 'value', 'text', null, $this->id . '-from');\n\t\treturn array($groups, $list);\n\t}", "function ajax_get_all_groups() {\r\n global $wpdb;\r\n\r\n $groups = $this->get_groups();\r\n\r\n if ( is_array( $groups ) && 0 < count( $groups ) ) {\r\n\r\n $i = 0;\r\n $n = ceil( count( $groups ) / 5 );\r\n\r\n $html = '';\r\n $html .= '<ul class=\"clients_list\">';\r\n\r\n\r\n\r\n foreach ( $groups as $group ) {\r\n if ( $i%$n == 0 && 0 != $i )\r\n $html .= '</ul><ul class=\"clients_list\">';\r\n\r\n $html .= '<li><label>';\r\n $html .= '<input type=\"checkbox\" name=\"groups_id[]\" value=\"' . $group['group_id'] . '\" /> ';\r\n $html .= $group['group_id'] . ' - ' . $group['group_name'];\r\n $html .= '</label></li>';\r\n\r\n $i++;\r\n }\r\n\r\n $html .= '</ul>';\r\n } else {\r\n $html = 'false';\r\n }\r\n\r\n die( $html );\r\n\r\n }", "public function getGroupNames()\n {\n $groups = deserialize( $this->groups );\n if ( ! count( $groups ) )\n {\n return array();\n }\n\n $query = 'select name from ' . $this->group_table . ' where ';\n $params = array();\n foreach ( $groups as $group )\n {\n $query .= 'id = ? or ';\n $params[] = $group;\n }\n\n $query = substr( $query, 0, strlen( $query ) - 4 );\n\n $records = $this->Database->prepare( $query )\n ->execute( $params );\n\n $group_names = array();\n while ( $records->next() )\n {\n $group_names[] = $records->name;\n }\n\n return $group_names;\n }", "public function group_info($group_name,$fields=NULL){\n if ($group_name===NULL){ return (false); }\n if (!$this->_bind){ return (false); }\n \n if (stristr($group_name, '+')) {\n $group_name=stripslashes($group_name); \n }\n \n $filter=\"(&(objectCategory=group)(name=\".$this->ldap_slashes($group_name).\"))\";\n\n if ($fields===NULL){ $fields=array(\"member\",\"memberof\",\"cn\",\"description\",\"distinguishedname\",\"objectcategory\",\"samaccountname\"); }\n \n // Let's use paging if available\n\t\tif (function_exists('ldap_control_paged_result')) {\n \n \t$pageSize = 500;\n \t$cookie = '';\n \t$entries = array();\n \t$entries_page = array();\n \n \tdo {\n \t\tldap_control_paged_result($this->_conn, $pageSize, true, $cookie);\n \n \t\t$sr=ldap_search($this->_conn,$this->_base_dn,$filter,$fields);\n \t\t$entries_page = ldap_get_entries($this->_conn, $sr);\n \n \t\tif (!is_array($entries_page)) {\n \t\t\treturn (false);\n \t\t}\n \n \t\t$entries = array_merge($entries, $entries_page);\n \t\tldap_control_paged_result_response($this->_conn, $sr, $cookie);\n \n \t} while($cookie !== null && $cookie != '');\n\t\t\t\n\t\t\t$entries['count'] = count($entries) - 1; // Set a new count value !important!\n\t\t\t\n\t\t\tldap_control_paged_result($this->_conn, $pageSize, true, $cookie); // RESET is important\n \n } else {\n \n \t// Non-Paged version\n \t$sr=ldap_search($this->_conn,$this->_base_dn,$filter,$fields);\n \t$entries = ldap_get_entries($this->_conn, $sr);\n }\n \n //print_r($entries);\n return ($entries);\n }", "function build_group_array($objectarray, $type)\n{\n\t$membersArray = array(); \n\t$index = $type.'group_name';\n\n\tforeach ($objectarray as $object)\n\t{\n\t\t$group = $object[$index];\n\t\tif (isset($object['members']))\n\t\t{\n\t\t\t$members = $object['members'];\n\t\t\t$lineitems = explode(',', trim($members));\n\t\t\t\n\t\t\t//array_walk($lineitems, create_function('$v', '$v = trim($v);')); //XXX BAD to use create_function \n\t\t\tarray_walk($lineitems, 'trim'); \n\t\t\t\n\t\t\t$group_members = NULL;\n\t\t\tif ($type == 'host' || $type == 'contact')\n\t\t\t{\n\t\t\t\t$group_members = $lineitems;\n\t\t\t}\n\t\t\telseif ($type == 'service')\n\t\t\t{\n\t\t\t\tfor ($i = 0; $i < count($lineitems); $i+=2)\n\t\t\t\t{\n\t\t\t\t\t$host = $lineitems[$i];\n\t\t\t\t\t$service = $lineitems[$i+1];\n\t\t\t\t\t$group_members[$host][] = $service; \n\t\t\t\t\t/* (\n\t\t\t\t\t\t'host_name' => $host,\n\t\t\t\t\t\t'service_description' => $service); */\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$membersArray[$group] = $group_members;\n\t\t}\n\t}\n\n\treturn $membersArray;\n}", "function getGroups($username){\r\n\t\t//SELEZIONO DAL DATABASE L'ELENCO DEI GRUPPI AI QUALI L'UTENTE APPARTIENE\r\n\t\t$sql = \"SELECT groupname FROM \".$this->schema.\".user_group WHERE username='$username'\";\r\n\t\tprint_debug($sql,null,'tabella');\r\n\t\tif($this->db->sql_query($sql)){\t\t//STRUTTURA GRUPPI GISCLIENT\r\n\t\t\t$ris=$this->db->sql_fetchlist('groupname');\r\n\t\t\tif(!$ris) {\r\n\t\t\t\t$this->error->getError(\"C001\");\r\n\t\t\t\treturn false;\r\n\t\t\t}\r\n\t\t\tforeach($ris as $g){\r\n\t\t\t\t$this->groups[]=$g;\r\n\t\t\t}\r\n\t\t\treturn $this->groups;\r\n\t\t}\r\n\t\telse{\r\n\t\t\t$this->error->setNote($sql);\r\n\t\t\t$this->error->getError(\"1\");\t\r\n\t\t\treturn false;\r\n\t\t}\r\n\t}", "public function group_list()\n\t{\n\t\t$data = [\n\t\t\t'group' => $this->todo->get_group_list((int) $this->session->userdata('uid'))\n\t\t];\n\t\t$this->page->set_title(\"Group List\");\n\t\t$this->page->build('friend/group_list', $data);\n\t}", "function getGroupList() {\n return getAll(\"SELECT * FROM `group` WHERE admin_id = ?\", [getLogin()['uid']]);\n}", "function moduleExplodeGroup($group_id, $capability) {\n\tglobal $fmdb, $__FM_CONFIG;\n\t\n\t$return = false;\n\t\n\tif ($capability == 'access_specific_zones') {\n\t\t$group_id = substr($group_id, 2);\n\t\t$domain_sql = \"AND (domain_groups='$group_id' OR domain_groups LIKE '$group_id;%' OR domain_groups LIKE '%;$group_id;%' OR domain_groups LIKE '%;$group_id')\";\n\t\t$result = basicGetList('fm_' . $__FM_CONFIG['fmDNS']['prefix'] . 'domains', 'domain_id', 'domain_', $domain_sql);\n\t\tfor ($x=0; $x<$fmdb->num_rows; $x++) {\n\t\t\t$return[] = $fmdb->last_result[$x]->domain_id;\n\t\t}\n\t}\n\t\n\treturn $return;\n}", "function AnnouncementSelectMembergroup()\n{\n\tglobal $txt, $context, $topic;\n\n\t$groups = getAnnounceGroups();\n\n\t$context['groups'] = array();\n\tif (in_array(0, $groups))\n\t{\n\t\t$context['groups'][0] = array(\n\t\t\t'id' => 0,\n\t\t\t'name' => $txt['announce_regular_members'],\n\t\t\t'member_count' => 'n/a',\n\t\t);\n\t}\n\n\t// Get all membergroups that have access to the board the announcement was made on.\n\t$request = wesql::query('\n\t\tSELECT mg.id_group, COUNT(mem.id_member) AS num_members\n\t\tFROM {db_prefix}membergroups AS mg\n\t\t\tLEFT JOIN {db_prefix}members AS mem ON (mem.id_group = mg.id_group OR FIND_IN_SET(mg.id_group, mem.additional_groups) != 0 OR mg.id_group = mem.id_post_group)\n\t\tWHERE mg.id_group IN ({array_int:group_list})\n\t\tGROUP BY mg.id_group',\n\t\tarray(\n\t\t\t'group_list' => $groups,\n\t\t\t'newbie_id_group' => 4,\n\t\t)\n\t);\n\twhile ($row = wesql::fetch_assoc($request))\n\t{\n\t\t$context['groups'][$row['id_group']] = array(\n\t\t\t'id' => $row['id_group'],\n\t\t\t'name' => '',\n\t\t\t'member_count' => $row['num_members'],\n\t\t);\n\t}\n\twesql::free_result($request);\n\n\t// Now get the membergroup names.\n\t$request = wesql::query('\n\t\tSELECT id_group, group_name\n\t\tFROM {db_prefix}membergroups\n\t\tWHERE id_group IN ({array_int:group_list})',\n\t\tarray(\n\t\t\t'group_list' => $groups,\n\t\t)\n\t);\n\twhile ($row = wesql::fetch_assoc($request))\n\t\t$context['groups'][$row['id_group']]['name'] = $row['group_name'];\n\twesql::free_result($request);\n\n\t// Get the subject of the topic we're about to announce.\n\t$request = wesql::query('\n\t\tSELECT m.subject\n\t\tFROM {db_prefix}topics AS t\n\t\t\tINNER JOIN {db_prefix}messages AS m ON (m.id_msg = t.id_first_msg)\n\t\tWHERE t.id_topic = {int:current_topic}',\n\t\tarray(\n\t\t\t'current_topic' => $topic,\n\t\t)\n\t);\n\tlist ($context['topic_subject']) = wesql::fetch_row($request);\n\twesql::free_result($request);\n\n\tcensorText($context['announce_topic']['subject']);\n\n\t$context['move'] = isset($_REQUEST['move']) ? 1 : 0;\n\t$context['go_back'] = isset($_REQUEST['goback']) ? 1 : 0;\n\n\twetem::load('announce');\n}", "function secGroups($function, $group=NULL) {\n $g=array();\n $g['index']=array('ro','rw','rwv','admin');\n $g['clearStats']=array('admin');\n if(isset($g[$function])) {\n if(!empty($group)) return in_array($group, $g[$function]);\n return $g[$function];\n }\n return parent::secGroups($function,$group);\n }", "function getGroups()\n {\n//\t\t$this->_groups = array();\n if ( empty( $this->_groups ) ) {\n $member_handler = &zarilia_gethandler( 'member' );\n if ( $this->getVar( 'uid' ) ) {\n $this->_groups = $member_handler->getGroupsByUser( $this->getVar( 'uid' ) );\t\t\t\t\n } else {\n $this->_groups = array( 0 => ZAR_GROUP_ANONYMOUS );\n }\n }\t\t\n return $this->_groups;\n }", "function getGroups() {\n die ('unimplemented: '.__CLASS__.'::'.__FUNCTION__.' ('.__LINE__.':'.__FILE__.')');\n }", "public function getGroup();", "public function getGroup();", "public function getGroup();", "function automap_filter_by_group(&$obj, $params) {\n if(!isset($params['filter_group']) || $params['filter_group'] == '')\n return;\n\n global $_BACKEND;\n $_BACKEND->checkBackendExists($params['backend_id'][0], true);\n $_BACKEND->checkBackendFeature($params['backend_id'][0], 'getHostNamesInHostgroup', true);\n $hosts = $_BACKEND->getBackend($params['backend_id'][0])->getHostNamesInHostgroup($params['filter_group']);\n\n $allowed_ids = array_flip(automap_hostnames_to_object_ids($hosts));\n automap_filter_tree($allowed_ids, $obj);\n}", "function employee_bluegroups ($employee) {\n\tif (strpos($employee, '@') == true) {\n\t\t# lookup the DN from an email address\n\t\tif (! $record = bluepages_search(\"(mail=$employee)\") )\n\t\t\treturn(false);\n\t\t$user_dn = key($record);\n\t} elseif (strpos($employee, '=') == true) {\n\t\t# use the DN given\n\t\t$user_dn = $employee;\n\t} else {\n\t\t# passed something we don't know how to handle\n\t\treturn(false);\n\t}\n\n\t# setup ldap connection\n\tif ( ! $ds = _ldap_connect() ) return(false);\n\t$filter = \"(uniquemember=$user_dn)\";\n\t$basedn = 'ou=ibmgroups,o=ibm.com';\n\n\t# connect, bind, and search\n\tif (!$sr = @ldap_search($ds, $basedn, $filter, array('cn')))\n\t\treturn(false);\n\n\t# bail out if there aren't any groups (unlikely)\n\tif (@ldap_count_entries($ds, $sr) == 0)\n\t\treturn(false);\n\n\t# build an array of groups found\n\t$groups = array();\n\tfor ($entry = ldap_first_entry($ds, $sr); $entry != false; $entry = ldap_next_entry($ds, $entry)) {\n\t\t$val = ldap_get_values($ds, $entry, 'cn');\n\t\tarray_push($groups, $val[0]);\n\t}\nreturn($groups);\n}", "public function listaddressgroupings(){\n return $this->bitcoin->listaddressgroupings();\n }", "public static function group_overview($type='service', $group=false, $hostprops=false, $serviceprops=false, $hoststatustypes=false, $servicestatustypes=false)\n\t{\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_objects = array();\n\t\tif ($type == 'service') {\n\t\t\t$auth_objects = $auth->get_authorized_servicegroups();\n\t\t} elseif ($type == 'host') {\n\t\t\t$auth_objects = $auth->get_authorized_hostgroups();\n\t\t}\n\n\t\t$contact = $auth->id;\n\t\t$auth_ids = array_keys($auth_objects);\n\t\tif (empty($auth_ids) || empty($group)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$db = Database::instance();\n\n\t\tif (empty($group)) {\n\t\t\treturn false;\n\t\t}\n\n\t\t$host_match = $auth->view_hosts_root ? ''\n\t\t\t: \" AND h.id IN (SELECT host FROM contact_access WHERE contact=\".(int)$contact.\" AND service IS NULL) \";\n\t\tif (!empty($hostprops)) {\n\t\t\t$host_match .= Host_Model::build_host_props_query($hostprops, 'host.');\n\t\t}\n\n\t\t$service_match = $auth->view_hosts_root || $auth->view_services_root ? ''\n\t\t\t: \" AND service.id IN (SELECT service FROM contact_access WHERE contact=\".(int)$contact.\" AND service IS NOT NULL) \";\n\n\t\tif (!empty($serviceprops)) {\n\t\t\t$service_match .= Host_Model::build_service_props_query($serviceprops, 'service.', 'h.');\n\t\t}\n\n\t\t$filter_host_sql = false;\n\t\t$filter_service_sql = false;\n\t\tif (!empty($hoststatustypes)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatustypes);\n\t\t\t$filter_host_sql = \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\tif (!empty($servicestatustypes)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatustypes);\n\t\t\t$filter_service_sql = \" AND service.current_state IN ($bits) \";\n\t\t}\n\n\t\tswitch ($type) {\n\t\t\tcase 'host':\n\t\t\t\t# restrict host access for authorized contacts\n\t\t\t\tif (!$auth->view_hosts_root) {\n\t\t\t\t\t$hostgroups = $auth->hostgroups_r;\n\t\t\t\t\tif (!is_array($hostgroups) || !array_key_exists($group, $hostgroups)) {\n\t\t\t\t\t\t# user doesn't have access\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$svc_query = \"SELECT COUNT(*) FROM service WHERE service.host_name = h.host_name \".\n\t\t\t\t\t\"AND current_state = %s \".$service_match.$filter_service_sql;\n\n\t\t\t\t$sql = \"SELECT h.host_name, h.current_state, h.address, h.action_url, h.notes_url, h.icon_image,h.icon_image_alt,\".\n\t\t\t\t\t\"h.display_name, h.current_attempt, h.max_check_attempts, (\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_OK).\") AS services_ok,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_WARNING).\") AS services_warning,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_CRITICAL).\") AS services_critical,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_UNKNOWN).\") AS services_unknown,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_PENDING).\") AS services_pending \".\n\t\t\t\t\t\"FROM hostgroup hg, host h, host_hostgroup hhg \".\n\t\t\t\t\t\"WHERE hhg.hostgroup=hg.id AND h.id=hhg.host \".\n\t\t\t\t\t\"AND hg.hostgroup_name=\".$db->escape($group).$filter_host_sql.Host_Model::build_host_props_query($hostprops, 'h.');\n\t\t\t\tbreak;\n\t\t\tcase 'service':\n\t\t\t\tif (!$auth->view_hosts_root && !$auth->view_services_root) {\n\t\t\t\t\t$servicegroups = $auth->servicegroups_r;\n\t\t\t\t\tif (!is_array($servicegroups) || !array_key_exists($group, $servicegroups)) {\n\t\t\t\t\t\t# user doesn't have access\n\t\t\t\t\t\treturn false;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t$svc_query = \"SELECT COUNT(*) FROM service \".\n\t\t\t\t\t\"INNER JOIN service_servicegroup ON service.id = service_servicegroup.service \".\n\t\t\t\t\t\"WHERE service.host_name = h.host_name \".\n\t\t\t\t\t\"AND service_servicegroup.servicegroup = servicegroup.id \".\n\t\t\t\t\t\"AND current_state = %s \".$service_match.$filter_service_sql;\n\t\t\t\t$sql = \"SELECT DISTINCT h.host_name, h.current_state, h.address, h.action_url, \".\n\t\t\t\t\t\"h.notes_url, h.icon_image, h.icon_image_alt, h.display_name, \".\n\t\t\t\t\t\"h.current_attempt, h.max_check_attempts, (\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_OK).\") AS services_ok,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_WARNING).\") AS services_warning,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_CRITICAL).\") AS services_critical,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_UNKNOWN).\") AS services_unknown,(\".\n\t\t\t\t\tsprintf($svc_query, Current_status_Model::SERVICE_PENDING).\") AS services_pending \".\n\t\t\t\t\t\"FROM host h \".\n\t\t\t\t\t\"INNER JOIN service ON h.host_name = service.host_name \" .\n\t\t\t\t\t\"INNER JOIN service_servicegroup ON service_servicegroup.service = service.id \".\n\t\t\t\t\t\"INNER JOIN servicegroup ON servicegroup.id = service_servicegroup.servicegroup \".\n\t\t\t\t\t\"WHERE servicegroup.servicegroup_name = \".$db->escape($group).\n\t\t\t\t\t$host_match.$filter_host_sql;\n\t\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\treturn false;\n\t\t}\n\n\t\t$result = $db->query($sql);\n\t\treturn count($result)>0 ? $result : false;\n\t}", "static public function fetchFeGroups ()\n {\n $result = [];\n\n if (\n isset($GLOBALS['TSFE']->fe_user) &&\n isset($GLOBALS['TSFE']->fe_user->user) &&\n isset($GLOBALS['TSFE']->fe_user->user['usergroup'])\n ) {\n $result = explode(',', $GLOBALS['TSFE']->fe_user->user['usergroup']); \n }\n return $result;\n }", "function fetchAllGroups() {\n try {\n global $db_table_prefix;\n\n $results = array();\n\n $db = pdoConnect();\n\n $sqlVars = array();\n\n $query = \"SELECT\n id,\n name,\n is_default,\n can_delete,\n home_page_id\n FROM \".$db_table_prefix.\"groups\";\n\n $stmt = $db->prepare($query);\n\n if (!$stmt->execute($sqlVars)){\n // Error\n return false;\n }\n\n while ($r = $stmt->fetch(PDO::FETCH_ASSOC)) {\n $id = $r['id'];\n $results[$id] = $r;\n }\n $stmt = null;\n\n return $results;\n\n } catch (PDOException $e) {\n addAlert(\"danger\", \"Oops, looks like our database encountered an error.\");\n error_log(\"Error in \" . $e->getFile() . \" on line \" . $e->getLine() . \": \" . $e->getMessage());\n return false;\n } catch (ErrorException $e) {\n addAlert(\"danger\", \"Oops, looks like our server might have goofed. If you're an admin, please check the PHP error logs.\");\n return false;\n }\n}", "function get_groups() {\r\n global $wpdb;\r\n $groups = $wpdb->get_results( \"SELECT wcg.*, count(wcgc.client_id) as clients_count FROM {$wpdb->prefix}wpc_client_groups wcg LEFT JOIN {$wpdb->prefix}wpc_client_group_clients wcgc ON wcgc.group_id = wcg.group_id GROUP BY wcg.group_id\", \"ARRAY_A\");\r\n return $groups;\r\n }", "function getMemberGroupInfo() {\n global $inputs;\n\n if (empty($inputs)) {\n $mid = getLogin()['mid'];\n } else {\n $mid = $inputs['id'];\n }\n\n $res = getAll(\"SELECT b.*,a.id AS union_id \n FROM member_group a \n INNER JOIN `group` b \n ON a.group_id = b.id \n WHERE a.member_id = ?\", [$mid]);\n\n if (empty($inputs)) {\n return $res;\n } else {\n formatOutput(true, 'success', $res);\n }\n}", "function secGroups($function, $group=NULL) {\n $g=array();\n if (true || $_SERVER['REMOTE_ADDR'] == '80.13.99.120' || $_SERVER['REMOTE_ADDR'] == '78.231.77.57'){\n $g['tests'] = array('none');\n }\n $g['wtsCheckLine'] = array('none');\n $g['ajaxMotDePasse'] = array('none');\n $g['wtsLireOffres'] = array('none');\n $g['viewOffre'] = array('none');\n $g['wtscommande']=array('none');\n $g['wtssaisieforfaits']=array('none');\n $g['wtsCtrlSaisieForfaits'] = array('none');\n $g['wtsCaddieDisp']=array('none');\n $g['wtsAjaxCaddieDisp'] = array('none');\n $g['wtsadd2caddie']=array('none');\n $g['wtsCaddieSuppr']=array('none');\n $g['wtsCaddieToggleLine']=array('none');\n $g['wtsCaddieSupprPack']=array('none'); // a tester\n $g['wtsPreValidateOrder'] = array('none');\n $g['wtsDevis'] = array('none');\n $g['wtsCtrlValidateOrder'] = array('none');\n $g['wtsValidateOrder'] = array('none');\n $g['wtsCtrlValidateCustomerCreation'] = array('none');\n $g['wtsValidateCustomerCreation'] = array('none');\n $g['wtsPrePaiement'] = array('none');\n $g['wtsDisplayOrder'] = array('none');\n $g['wtsCheckWTP'] = array('none');\n $g['wtsAddCard'] = array('none');\n $g['wtsPaiementZero'] = array('none');\n $g['wtsPaiementCheque'] = array('none');\n $g['wtsAdhesion'] = array('none');\n $g['wtsUseReduction'] = array('none');\n \n $g['checkStructures'] = array('admin');\n $g['repairStructures'] = array('admin');\n $g['repairOneStructure'] = array('admin');\n $g['checkSets'] = array('admin');\n $g['verifgrps'] = array('admin');\n $g['verifVentePro'] = array('admin');\n $g['checkEPLProducts'] = array('admin');\n\n $g['getCaddie'] = array('none');\n \n $g['procAuthGroup'] = array('none');\n $g['closeAuthGroup'] = array('none');\n $g['ajaxProcAuthMembre'] = array('none'); // non ecrite\n $g['initCurrentUser'] = array('none');\n $g['closeAuthMembre'] = array('none');\n\n // fonctions de la vente pro\n $g['wtsprolistewtp'] = array('none'); // ro normalement\n $g['wtsproadd2caddie'] = array('none'); // ro normalement\n $g['wtsProPaiement'] = array('none');\n $g['wtsProCancelOrder'] = array('none');\n $g['proAccount'] = array('none');\n // fonctions de la gestion des comtpes clients\n $g['myAccount'] = array('none');\n $g['procCreateMyAccount'] = array('none');\n $g['procEditMyAccount'] = array('none');\n $g['procEditProAccount'] = array('none');\n\n if(isset($g[$function])) {\n if(!empty($group)) return in_array($group, $g[$function]);\n return $g[$function];\n }\n return parent::secGroups($function, $group);\n }", "public function sample()\n\t{\n\t\treturn array(\n\t\t\t'header' => 'groups',\n\t\t\t'content' => 'groupalias;groupalias;groupalias'\n\t\t);\n\t}", "public function getGroupNames()\r\n {\r\n return $this->getGuardUser() ? $this->getGuardUser()->getGroupNames() : array();\r\n }", "public function getSubGroups() {}", "function secGroups($function, $group=NULL) {\n $g=array();\n $g['preDel']=array('rw','rwv','admin');\n $g['dashboard']=array('ro','rw','rwv','admin');\n if(isset($g[$function])) {\n if(!empty($group)) return in_array($group, $g[$function]);\n return $g[$function];\n }\n return parent::secGroups($function,$group);\n }", "public function getNGroups() {}", "function group_info($group_name,$fields=NULL){\n if ($group_name==NULL){ return (false); }\n if (!$this->_bind){ return (false); }\n \n $filter=\"(&(objectCategory=group)(\".$this->_group_cn_identifier.\"=\".$this->ldap_search_encode($group_name).\"))\";\n\n if ($fields==NULL){ $fields=array(\"member\",$this->_group_attribute,\"cn\",\"description\",\"distinguishedname\",\"objectcategory\",$this->_group_cn_identifier); }\n \n $sr=@ldap_search($this->_conn,$this->_base_dn,$filter,$fields);\n if (FALSE === $sr) {\n $this->_warning_message = \"group_info: ldap_search error \".ldap_errno($this->_conn).\": \".ldap_error($this->_conn);\n echo \"DEBUG: \".$this->_warning_message.\"\\n\";\n }\n // Search: (&(objectCategory=group)(cn=gr10000))\n // (&(objectCategory=group)(cn=gr10))\n // PHP Warning: ldap_search(): Search: Critical extension is unavailable in // C:\\data\\projects\\multiotp\\core\\contrib\\MultiotpAdLdap.php on line 591\n // Search: (&(objectCategory=group)(cn=gr10))\n $entries = $this->ldap_get_entries_raw($sr);\n\n // DEBUG\n if (0 == count($entries)) {\n $this->_warning_message = \"group_info: No entry for the specified filter $filter\";\n echo \"DEBUG: \".$this->_warning_message.\"\\n\";\n }\n\n return ($entries);\n }", "static function get_apigroup();", "private function ldap_get_group_members_ad($groupfilter) {\n global $CFG;\n\n $ret = array();\n $ldapconnection = $this->ldap_connect();\n if (!$ldapconnection) {\n return $ret;\n }\n\n $queryg = \"(&({$this->config['syncgroupsgroupattribute']}=\" . $this->filter_addslashes(trim($groupfilter)) . \")(objectClass={$this->config['syncgroupsgroupclass']}))\";\n\n // The paging increment\n $size = 999;\n\n $contexts = $this->get_group_contexts();\n\n foreach ($contexts as $context) {\n $context = trim($context);\n if (empty ($context)) {\n continue;\n }\n $start = 0;\n $end = $size;\n $fini = false;\n\n while (!$fini) {\n //page the search by increments of $size\n $attribut = $this->config['syncgroupsmemberattribute'] . \";range=\" . $start . '-' . $end;\n\n if ($this->config[$this->config['syncgroupssearchsub']] == 'yes') {\n $resultg = ldap_search($ldapconnection, $context, $queryg, array($attribut));\n }\n else {\n $resultg = ldap_list($ldapconnection, $context, $queryg, array($attribut));\n }\n\n if ($resultg !== false && ldap_count_entries($ldapconnection, $resultg)) {\n $groupe = ldap_get_entries($ldapconnection, $resultg);\n\n // On the final page, AD returns \"member;range=number-*\" !!!\n if (empty($groupe[0][strtolower($attribut)])) {\n $attribut = $this->config['syncgroupsmemberattribute'] . \";range=\" . $start . '-*';\n $fini = true;\n }\n\n for ($g = 0; $g < (count($groupe[0][strtolower($attribut)]) - 1); $g++) {\n $membre = trim($groupe[0][strtolower($this->config['syncgroupsmemberattribute'])][$g]);\n if (empty($membre)) {\n continue;\n }\n if (!$this->config['syncgroupsmemberattributeisdn']) {\n $ret[] = $membre;\n }\n else {\n //rev 1.2 nested groups\n if ($this->config['syncgroupsnestedgroups'] && ($group_cn = $this->is_ldap_group($membre))) {\n // in case of funny directory where groups are member of groups\n if (array_key_exists($membre,$this->anti_recursion_array)) {\n unset($this->anti_recursion_array[$membre]);\n continue;\n }\n //recursive call\n $this->anti_recursion_array[$membre] = 1;\n $tmp = $this->ldap_get_group_members_ad ($group_cn);\n unset($this->anti_recursion_array[$membre]);\n $ret = array_merge($ret,$tmp);\n }\n else {\n $membre = $this->get_username_from_dn($membre);\n if ($membre) {\n $ret[] = $membre;\n }\n }\n }\n }\n }\n else {\n $fini = true;\n }\n $start = $start + $size;\n $end = $end + $size;\n }\n }\n $this->ldap_close($ldapconnection);\n return $ret;\n }" ]
[ "0.77412754", "0.72968704", "0.6887429", "0.6862146", "0.6729084", "0.6709216", "0.6693757", "0.6656371", "0.6656371", "0.6621481", "0.6621481", "0.6617949", "0.6617949", "0.6562275", "0.65350634", "0.65350634", "0.6515629", "0.65116817", "0.64962006", "0.64681923", "0.64253795", "0.6334499", "0.6319002", "0.63060296", "0.62942827", "0.62810457", "0.6275504", "0.6249386", "0.6233268", "0.6215102", "0.6210654", "0.61861134", "0.6185958", "0.60730976", "0.6071402", "0.6068203", "0.60441214", "0.6038892", "0.6037673", "0.6026146", "0.599529", "0.5994909", "0.59865624", "0.59495807", "0.5931642", "0.5902028", "0.5896311", "0.5895861", "0.5891402", "0.5890727", "0.5888186", "0.5884962", "0.5878576", "0.5871681", "0.5856286", "0.5836679", "0.5832787", "0.58240366", "0.5823707", "0.58236533", "0.5803846", "0.5801424", "0.57995754", "0.5797106", "0.5796827", "0.57895756", "0.5786095", "0.57670283", "0.5759448", "0.57573956", "0.5752488", "0.5747489", "0.5731487", "0.57233155", "0.57223064", "0.57157856", "0.57140595", "0.57080305", "0.5700328", "0.5697374", "0.5695894", "0.5695894", "0.5695894", "0.5695738", "0.5689484", "0.5682524", "0.56763184", "0.5673899", "0.5671572", "0.56680447", "0.5663341", "0.56443197", "0.5641929", "0.563306", "0.56284785", "0.5606782", "0.5602737", "0.56025386", "0.55997586", "0.5598994" ]
0.6825747
4
/ used on servicegroups page creates arrays of service details organized by groupnames
function build_servicegroups_array() { global $NagiosData; global $NagiosUser; $servicegroups = $NagiosData->getProperty('servicegroups'); $services = $NagiosData->getProperty('services'); $services = user_filtering($services,'services'); $servicegroups_details = array(); //multi-dim array to hold servicegroups foreach($servicegroups as $groupname => $members) { $servicegroups_details[$groupname] = array(); //array_dump($members); foreach($services as $service) { if(isset($members[$service['host_name']]) && in_array($service['service_description'],$members[$service['host_name']])) { process_service_status_keys($service); $servicegroups_details[$groupname][] = $service; } } } return $servicegroups_details; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function build_host_servicegroup_details($group_members) \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n\n\t$servicegroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t{\n\t\t\tif (isset($hosts[$member]['services']))\n\t\t\t\tforeach ($hosts[$member]['services'] as $service) \n\t\t\t\t{\n\t\t\t\t\tif($NagiosUser->is_authorized_for_service($member,$service)) //user-level filtering \n\t\t\t\t\t\t$servicegroup_details[] = $service;\t\n\t\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\treturn $servicegroup_details;\n}", "public function findServiceGroups(): array;", "function build_hostgroup_details($group_members) //make this return the totals array for hosts and services \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n//\t//add filter for user-level filtering \n//\tif(!$NagiosUser->is_admin()) {\n\t\t//print $type; \n//\t\t$hosts = user_filtering($hosts,'hosts'); \t\n//\t}\n\n\t$hostgroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t\t$hostgroup_details[] = $hosts[$member];\n\t}\n\n\treturn $hostgroup_details;\n}", "function get_hostgroup_data()\n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\n\t$hostgroups = $NagiosData->getProperty('hostgroups');\n\t$hosts = $NagiosData->getProperty('hosts');\n\n\t$hostgroup_data = array();\n\tforeach ($hostgroups as $group => $members) \n\t{\n\t\t\n\t\t\n\t\t$hostgroup_data[$group] = array(\n\t\t\t'member_data' => array(),\n\t\t\t'host_counts' => get_state_of('hosts', build_hostgroup_details($members)),\n\t\t\t'service_counts' => get_state_of('services', build_host_servicegroup_details($members))\n\t\t\t);\n\t\t\n\t\t//skip ahead if there are no authorized hosts\t\t\t\n\t\tif(array_sum($hostgroup_data[$group]['host_counts'])==0) continue; //skip empty groups \n\t\t\t\n\t\tforeach ($members as $member) \n\t\t{\n\t\t\n\t\t\tif(!$NagiosUser->is_authorized_for_host($member)) continue; //user-level filtering \t\t\n\t\t\n\t\t\t$host = $hosts[$member];\n\t\t\tprocess_host_status_keys($host); \n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_name'] = $host['host_name'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_state'] = $host['current_state'];\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['state_class'] = get_color_code($host);\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'] = array();\n\t\t\t$hostgroup_data[$group]['member_data'][$member]['host_url'] = \n\t\t\t\tBASEURL.'index.php?type=hostdetail&name_filter='.urlencode($host['host_name']);\n\n\t\t\t\n\t\t\tif (isset($host['services'])) {\n\t\t\t\tforeach($host['services'] as $service) {\n\t\t\t\t\n\t\t\t\t\tif(!$NagiosUser->is_authorized_for_service($member,$service['service_description'])) continue; //user-level filtering \t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\tprocess_service_status_keys($service);\n\t\t\t\t\t$service_data = array(\n\t\t\t\t\t\t'state_class' => get_color_code($service),\n\t\t\t\t\t\t'description' => $service['service_description'],\n\t\t\t\t\t\t'service_url' => htmlentities(BASEURL.'index.php?type=servicedetail&name_filter='.$service['service_id']),\n\t\t\t\t\t);\n\t\t\t\t\t$hostgroup_data[$group]['member_data'][$member]['services'][] = $service_data;\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\t\n\t}\n\treturn $hostgroup_data;\n}", "function build_group_array($objectarray, $type)\n{\n\t$membersArray = array(); \n\t$index = $type.'group_name';\n\n\tforeach ($objectarray as $object)\n\t{\n\t\t$group = $object[$index];\n\t\tif (isset($object['members']))\n\t\t{\n\t\t\t$members = $object['members'];\n\t\t\t$lineitems = explode(',', trim($members));\n\t\t\t\n\t\t\t//array_walk($lineitems, create_function('$v', '$v = trim($v);')); //XXX BAD to use create_function \n\t\t\tarray_walk($lineitems, 'trim'); \n\t\t\t\n\t\t\t$group_members = NULL;\n\t\t\tif ($type == 'host' || $type == 'contact')\n\t\t\t{\n\t\t\t\t$group_members = $lineitems;\n\t\t\t}\n\t\t\telseif ($type == 'service')\n\t\t\t{\n\t\t\t\tfor ($i = 0; $i < count($lineitems); $i+=2)\n\t\t\t\t{\n\t\t\t\t\t$host = $lineitems[$i];\n\t\t\t\t\t$service = $lineitems[$i+1];\n\t\t\t\t\t$group_members[$host][] = $service; \n\t\t\t\t\t/* (\n\t\t\t\t\t\t'host_name' => $host,\n\t\t\t\t\t\t'service_description' => $service); */\n\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$membersArray[$group] = $group_members;\n\t\t}\n\t}\n\n\treturn $membersArray;\n}", "public function getServices() {\n $serviceNames = $this->getServiceNames($this->serviceFolderPaths);\n $ret = $ret1 = array();\n// require_once AMFPHP_ROOTPATH.'Plugins/AmfphpDiscovery/CReflection.php';\n foreach ($serviceNames as $serviceName) {\n/* $methods = array();\n $objC = new CReflection(APP_PATH.'/app/controllers/'.$serviceName.'.php');\n $objComment = $objC->getDocComment();\n $arrMethod = $objC->getMethods();\n foreach ($arrMethod as $objMethods)\n {\n $methodComment = $objMethods->getDocComment();\n $parsedMethodComment = $this->parseMethodComment($methodComment);\n $arrParamenter = $objMethods->getParameters();\n foreach ($arrParamenter as $Paramenter)\n {\n $parameterInfo = new AmfphpDiscovery_ParameterDescriptor($Paramenter, '');\n $parameters[] = $parameterInfo;\n }\n $methods[$objMethods->_name] = new AmfphpDiscovery_MethodDescriptor($objMethods->_name, $parameters, $methodComment, $parsedMethodComment['return']);\n }\n\n $ret[$serviceName] = new AmfphpDiscovery_ServiceDescriptor($serviceName, $methods, $objComment); */\n $ret1[] = array('label'=>$serviceName,'date'=>'');\n }\n// var_dump($ret);exit();\n //note : filtering must be done at the end, as for example excluding a Vo class needed by another creates issues\n foreach ($ret as $serviceName => $serviceObj) {\n foreach (self::$excludePaths as $excludePath) {\n if (strpos($serviceName, $excludePath) !== false) {\n unset($ret[$serviceName]);\n break;\n }\n }\n }\n return $ret1;\n }", "public function getServices() {\n $services = Service::active()->get()->toArray();\n $outputArray = array();\n if ($services) {\n foreach ($services as $key => $value) {\n $begin = new DateTime($value['start_date']);\n $end = new DateTime($value['end_date']);\n if ($value['service_type'] == 'daily') {\n\n $interval = DateInterval::createFromDateString('1 day');\n $period = new DatePeriod($begin, $interval, $end);\n\n foreach ($period as $key => $dt) {\n $timestamp = strtotime($dt->format(\"Y-m-d\"));\n $myobj = new \\stdClass();\n $myobj->title = $value['title'];\n $myobj->start = $dt->format(\"Y-m-d\");\n \n $scheduleArray = $this->getScheduleService($value['id'], $timestamp);\n \n if (date(\"Y-m-d\") <= $dt->format(\"Y-m-d\") && !empty($scheduleArray['availability'])) {\n $myobj->color = \"#605ca8\";\n $myobj->url = url(\"/reservation/\" . $value['id'] . '/' . $timestamp);\n } else {\n $myobj->color = \"gray\";\n }\n array_push($outputArray, $myobj);\n }\n }\n if ($value['service_type'] == 'weekly') {\n\n $schedule = Schedule::where('service_id', $value['id'])->get()->toArray();\n\n $weekNumber = array();\n for ($i = 0; $i < count($schedule); $i++) {\n $weekNumber[] = $schedule[$i]['week_number'];\n }\n\n $interval = DateInterval::createFromDateString('1 day');\n $period = new DatePeriod($begin, $interval, $end);\n\n foreach ($period as $key => $dt) {\n $timestamp = strtotime($dt->format(\"Y-m-d\"));\n if (in_array($dt->format(\"w\"), $weekNumber)) {\n $myobj = new \\stdClass();\n $myobj->title = $value['title'];\n $myobj->start = $dt->format(\"Y-m-d\");\n \n $scheduleArray = $this->getScheduleService($value['id'], $timestamp);\n \n if (date(\"Y-m-d\") <= $dt->format(\"Y-m-d\") && !empty($scheduleArray['availability'])) {\n $myobj->color = \"#f012be\";\n $myobj->url = url(\"/reservation/\" . $value['id'] . '/' . $timestamp);\n } else {\n $myobj->color = \"gray\";\n }\n array_push($outputArray, $myobj);\n }\n }\n }\n\n if ($value['service_type'] == 'monthly') {\n $interval = DateInterval::createFromDateString('1 month');\n $period = new DatePeriod($begin, $interval, $end);\n\n foreach ($period as $key => $dt) {\n $timestamp = strtotime($dt->format(\"Y-m-d\"));\n $myobj = new \\stdClass();\n $myobj->title = $value['title'];\n $myobj->start = $dt->format(\"Y-m-d\");\n \n $scheduleArray = $this->getScheduleService($value['id'], $timestamp);\n \n if (date(\"Y-m-d\") <= $dt->format(\"Y-m-d\") && !empty($scheduleArray['availability'])) {\n $myobj->color = \"#00a65a\";\n $myobj->url = url(\"/reservation/\" . $value['id'] . '/' . $timestamp);\n } else {\n $myobj->color = \"gray\";\n }\n array_push($outputArray, $myobj);\n }\n }\n\n if ($value['service_type'] == 'yearly') {\n $interval = DateInterval::createFromDateString('1 year');\n $period = new DatePeriod($begin, $interval, $end);\n\n foreach ($period as $key => $dt) {\n $timestamp = strtotime($dt->format(\"Y-m-d\"));\n $myobj = new \\stdClass();\n $myobj->title = $value['title'];\n $myobj->start = $dt->format(\"Y-m-d\");\n \n $scheduleArray = $this->getScheduleService($value['id'], $timestamp);\n \n if (date(\"Y-m-d\") <= $dt->format(\"Y-m-d\") && !empty($scheduleArray['availability'])) {\n $myobj->color = \"orange\";\n $myobj->url = url(\"/reservation/\" . $value['id'] . '/' . $timestamp);\n } else {\n $myobj->color = \"gray\";\n }\n array_push($outputArray, $myobj);\n }\n }\n }\n }\n// echo \"<pre>\";\n// print_r($outputArray);\n// echo \"</pre>\";\n echo json_encode($outputArray);\n }", "protected function getGroupList() {}", "protected function getGroupList() {}", "public static function get_group_info($grouptype='service', $groupname=false, $hoststatus=false, $servicestatus=false, $service_props=false, $host_props=false, $limit=false, $sort_field=false, $sort_order='DESC')\n\t{\n\t\t$groupname = trim($groupname);\n\t\tif (empty($groupname)) {\n\t\t\treturn false;\n\t\t}\n\t\t$filter_sql = '';\n\t\t$state_filter = false;\n\t\tif (!empty($hoststatus)) {\n\t\t\t$bits = db::bitmask_to_string($hoststatus);\n\t\t\t$filter_sql .= \" AND h.current_state IN ($bits) \";\n\t\t}\n\t\t$service_filter = false;\n\t\t$servicestatus = trim($servicestatus);\n\t\tif ($servicestatus!==false && !empty($servicestatus)) {\n\t\t\t$bits = db::bitmask_to_string($servicestatus);\n\t\t\t$filter_sql .= \" AND s.current_state IN ($bits) \";\n\t\t}\n\n\t\t$limit_str = !empty($limit) ? trim($limit) : '';\n\n\t\t$db = Database::instance();\n\t\t$all_sql = $groupname != 'all' ? \"AND sg.\".$grouptype.\"group_name=\".$db->escape($groupname).\" \" : '';\n\n\t\t# we need to match against different field depending on if host- or servicegroup\n\t\t$member_match = $grouptype == 'service' ? \"s.id=ssg.\".$grouptype : \"h.id=ssg.\".$grouptype;\n\n\t\t$sort_string = \"\";\n\t\tif (empty($sort_field)) {\n\t\t\t$sort_string = \"h.host_name,s.current_state, s.service_description \".$sort_order;\n\t\t} else {\n\t\t\t$sort_string = $sort_field.' '.$sort_order;\n\t\t}\n\n\t\t$service_props_sql = Host_Model::build_service_props_query($service_props, 's.', 'h.');\n\t\t$host_props_sql = Host_Model::build_host_props_query($host_props, 'h.');\n\n\t\t$auth = Nagios_auth_Model::instance();\n\t\t$auth_str = '';\n\t\tif ($auth->view_hosts_root || ($auth->view_services_root && $grouptype == 'service')) {\n\t\t\t$auth_str = \"\";\n\t\t} else {\n\t\t\t$auth_str = \" INNER JOIN contact_access ca ON ca.host = h.id AND ca.contact = \".$db->escape($auth->id).\" \";\n\t\t}\n\t\t$sql = \"SELECT\n\t\t\t\th.host_name,\n\t\t\t\th.address,\n\t\t\t\th.alias,\n\t\t\t\th.current_state AS host_state,\n\t\t\t\t(UNIX_TIMESTAMP() - \".($grouptype == 'service' ? 's' : 'h').\".last_state_change) AS duration,\n\t\t\t\tUNIX_TIMESTAMP() AS cur_time,\n\t\t\t\th.output AS host_output,\n\t\t\t\th.long_output AS host_long_output,\n\t\t\t\th.problem_has_been_acknowledged AS hostproblem_is_acknowledged,\n\t\t\t\th.scheduled_downtime_depth AS hostscheduled_downtime_depth,\n\t\t\t\th.notifications_enabled AS host_notifications_enabled,\n\t\t\t\th.active_checks_enabled AS host_active_checks_enabled,\n\t\t\t\th.action_url AS host_action_url,\n\t\t\t\th.icon_image AS host_icon_image,\n\t\t\t\th.icon_image_alt AS host_icon_image_alt,\n\t\t\t\th.is_flapping AS host_is_flapping,\n\t\t\t\th.notes_url AS host_notes_url,\n\t\t\t\th.display_name AS host_display_name,\n\t\t\t\ts.id AS service_id,\n\t\t\t\ts.current_state AS service_state,\n\t\t\t\t(UNIX_TIMESTAMP() - s.last_state_change) AS service_duration,\n\t\t\t\tUNIX_TIMESTAMP() AS service_cur_time,\n\t\t\t\ts.active_checks_enabled,\n\t\t\t\ts.current_state,\n\t\t\t\ts.problem_has_been_acknowledged,\n\t\t\t\t(s.scheduled_downtime_depth + h.scheduled_downtime_depth) AS scheduled_downtime_depth,\n\t\t\t\ts.last_check,\n\t\t\t\ts.output,\n\t\t\t\ts.long_output,\n\t\t\t\ts.notes_url,\n\t\t\t\ts.action_url,\n\t\t\t\ts.current_attempt,\n\t\t\t\ts.max_check_attempts,\n\t\t\t\ts.should_be_scheduled,\n\t\t\t\ts.next_check,\n\t\t\t\ts.notifications_enabled,\n\t\t\t\ts.service_description,\n\t\t\t\ts.display_name AS display_name\n\t\t\tFROM host h\n\t\t\tLEFT JOIN service s ON h.host_name=s.host_name\n\t\t\tINNER JOIN {$grouptype}_{$grouptype}group ssg ON {$member_match}\n\t\t\tINNER JOIN {$grouptype}group sg ON sg.id = ssg.{$grouptype}group\n\t\t\t$auth_str\n\t\t\tWHERE 1 = 1\n\t\t\t\t{$all_sql} {$filter_sql} {$service_props_sql}\n\t\t\t\t{$host_props_sql}\n\t\t\tORDER BY \".$sort_string.\" \".$limit_str;\n\t\treturn $db->query($sql);\n\t}", "function getServicesList()\n {\n//JOIN sub_services_list ON services_categery.services_catagery_id=sub_services_list.services_catagery_id \";\n//\n// $query = $this->db->query($sql);\n// $result = $query->result_array();\n//\n// $serviceArray = [];\n// foreach ($result as $value) {\n// $serviceArray[$value['services_group']] [$value['services_categery_list']][] = [\n// $value['services_list'], $value['service_fee'], $value['convenience_fee']];\n// }\n\n $query = $this->db->get('services_group');\n $serviceArray ['servGroup'] = $query->result();\n\n//$query1 = $this->db->get('services_categery');\n//$serviceArray ['servCategory']= $query1->result() ;\n $this->db->select('*');\n $this->db->join('services_categery', 'sub_services_list.services_catagery_id=services_categery.services_catagery_id');\n $query2 = $this->db->get('sub_services_list');\n $serviceArray ['servList'] = $query2->result();\n\n// echo \"<pre>\";\n// print_r($serviceArray);die;\n return $serviceArray;\n }", "public function format()\n {\n $result = array();\n\n foreach ($this->groups as $group) {\n $result[] = array(\n 'id' => $group->getInternalId(),\n 'external_id' => $group->getExternalId(),\n 'value' => $group->getName(),\n 'label' => $group->getName(),\n );\n }\n\n return $result;\n }", "function makeServiceList() {\n\n\n $dbMain = $this->dbconnect();\n $stmt = $dbMain ->prepare(\"SELECT service_key, service_type, club_id FROM service_info WHERE service_key ='$this->serviceKey' AND group_type ='$this->groupType'\");\n\n $stmt->execute(); \n $stmt->store_result(); \n $stmt->bind_result($service_key, $service_type, $club_id); \n \n \n \n while ($stmt->fetch()) { \n \n // echo\"$service_key $service_type <br>\";\n \n $result = $dbMain -> query(\"SELECT club_name FROM club_info WHERE club_id = '$club_id'\");\n $row = mysqli_fetch_array($result, MYSQLI_NUM);\n $service_location = $row[0];\n \n\n \n if($club_id == \"0\") {\n $service_location = 'All Locations';\n }\n \n \n $this->serviceType = $service_type; \n \n /* \n //create color rows\n static $cell_count = 1;\n if($cell_count == 2) {\n $color = \"#D8D8D8\";\n $color2 = \"D8D8D8\";\n $cell_count = \"\";\n }else{\n $color = \"#FFFFFF\";\n $color2 = \"FFFFFF\";\n }\n $cell_count = $cell_count + 1;\n \n //$this->cellCount++;\n */\n \n$comp_type_a=\"comp_type$this->groupType$this->cellCount\";\n$comp_type_b ='[]';\n$comp_type =\"$comp_type_a$comp_type_b\";\n\n$comp_a =\"comp$this->groupType$this->cellCount\";\n$comp_b ='[]';\n$comp = \"$comp_a$comp_b\";\n\n\n$this->getTerms($service_key, $comp_type, $comp_a); \n\n//f the service month exiss in the available upgrades it allows it to print\nif($this->termsArray != null) {\n\n $terms = explode(\"|\", $this->termsArray);\n $term1 = $terms[0];\n $term2 = $terms[1]; \n $term3 = $terms[2];\n $term4 = $terms[3];\n\n$this->termsArray = null;\n\n//this sets up the renewal rate if it is a class or a date string \n$checkString = \"$term1 $term2 $term3 $term4\";\nif(preg_match(\"/Class\\(s\\)/\", $checkString)) {\n $disabled = 'disabled=\"disabled\"';\n $rate_value = 'NA';\n }else{\n $disabled = null;\n $rate_value = null;\n }\n\n //create color rows\n static $cell_count = 1;\n if($cell_count == 2) {\n $color = \"#D8D8D8\";\n $color2 = \"D8D8D8\";\n $cell_count = \"\";\n }else{\n $color = \"#FFFFFF\";\n $color2 = \"FFFFFF\";\n }\n $cell_count = $cell_count + 1;\n\n\n$records =\"<tr id=\\\"a$i\\\" style=\\\"background-color: $color\\\">\n<td align=\\\"left\\\" valign =\\\"top\\\"><font face=\\\"Arial\\\" size=\\\"1\\\" color=\\\"black\\\"><b>$this->cellCount.</b></font></td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><font face=\\\"Arial\\\" size=\\\"1\\\" color=\\\"black\\\"><b>$service_type<br><span class=\\\"locationColor\\\">$service_location</span></b></font></td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><font face=\\\"Arial\\\" size=\\\"1\\\" color=\\\"black\\\"><b>$term1</b></font></td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><font face=\\\"Arial\\\" size=\\\"1\\\" color=\\\"black\\\"><b>$term2</b></font></td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><font face=\\\"Arial\\\" size=\\\"1\\\" color=\\\"black\\\"><b>$term3</b></font></td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><font face=\\\"Arial\\\" size=\\\"1\\\" color=\\\"black\\\"><b>$term4</b></font></td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><input type=\\\"text\\\" name=\\\"$comp\\\" id=\\\"$comp_a\\\" value=\\\"\\\" size=\\\"8\\\" maxlength=\\\"8\\\" disabled=\\\"disabled\\\" onClick=\\\"return fieldChange(this.value, '$this->cellCount$this->groupType', this.name);\\\"/ >\n</td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><input type=\\\"text\\\" name=\\\"$comp\\\" id=\\\"$comp_a\\\" value=\\\"$rate_value\\\" size=\\\"8\\\" maxlength=\\\"8\\\" $disabled onClick=\\\"return fieldChange2(this.value, this.name)\\\"/ >\n</td>\n<td align=\\\"left\\\" valign =\\\"top\\\"><input type=\\\"text\\\" name=\\\"$comp\\\" id=\\\"$comp_a\\\" value=\\\"$rate_value\\\" size=\\\"8\\\" maxlength=\\\"8\\\" disabled=\\\"disabled\\\"/ >\n</td>\n\n<td align=\\\"left\\\" valign =\\\"top\\\"><input type=\\\"button\\\" name=\\\"save1\\\" value=\\\"Clear\\\" onClick=\\\"clearRowGroup('$comp_type','$comp','$this->cellCount$this->groupType')\\\"/>\n</td>\n</tr>\n\";\n\n$this->cellCount++;\n$this->cellRows++;\n}\n\n\n\n$checkString = null;\n}\n\n\n\n//this sets up the number of rows of a grouptype and creates the summary divs to delete in javascript\n switch($this->groupType) { \n case\"S\":\n $this->singleRows = $this->cellCount-1;\n $this->singleSummaryDivs= $this->createSummaryDivs($this->singleRows, $this->groupType);\n break;\n case\"F\":\n $this->familyRows = $this->cellRows-1;\n $this->familySummaryDivs= $this->createSummaryDivs($this->familyRows, $this->groupType);\n break;\n case\"B\":\n $this->businessRows = $this->cellRows-1;\n $this->businessSummaryDivs= $this->createSummaryDivs($this->businessRows, $this->groupType);\n break;\n case\"O\":\n $this->organizationRows = $this->cellRows-1;\n $this->organizationSummaryDivs= $this->createSummaryDivs($this->organizationRows, $this->groupType);\n break;\n }\n\nreturn \"$records\";\n\n\n\n}", "public function getServices(): array;", "public function getGroups() {}", "private function getServiceGroups(int $serviceId)\n {\n $host = Host::getInstance($this->dependencyInjector);\n $servicegroup = ServiceGroup::getInstance($this->dependencyInjector);\n $this->serviceCache[$serviceId]['sg'] = $servicegroup->getServiceGroupsForStpl($serviceId);\n foreach ($this->serviceCache[$serviceId]['sg'] as &$sg) {\n if ($host->isHostTemplate($this->currentHostId, $sg['host_host_id'])) {\n $servicegroup->addServiceInSg(\n $sg['servicegroup_sg_id'],\n $this->currentServiceId,\n $this->currentServiceDescription,\n $this->currentHostId,\n $this->currentHostName\n );\n Relations\\ServiceGroupRelation::getInstance($this->dependencyInjector)->addRelationHostService(\n $sg['servicegroup_sg_id'],\n $sg['host_host_id'],\n $serviceId\n );\n }\n }\n }", "function projectgroups_to_soap($pg_arr) {\n\t$return = array();\n\tfor ($i=0; $i<count($pg_arr); $i++) {\n\t\tif (!is_a($pg_arr[$i], 'ProjectGroup') || $pg_arr[$i]->isError()) {\n\t\t\t//skip if error\n\t\t} else {\n\t\t\t$return[]=array(\n\t\t\t\t'group_project_id'=>$pg_arr[$i]->data_array['group_project_id'],\n\t\t\t\t'group_id'=>$pg_arr[$i]->data_array['group_id'],\n\t\t\t\t'name'=>$pg_arr[$i]->data_array['project_name'],\n\t\t\t\t'description'=>$pg_arr[$i]->data_array['description'],\n\t\t\t\t'is_public'=>$pg_arr[$i]->data_array['is_public'],\n\t\t\t\t'send_all_posts_to'=>$pg_arr[$i]->data_array['send_all_posts_to']\n\t\t\t);\n\t\t}\n\t}\n\treturn $return;\n}", "public function getGroups(): array;", "public function postProcess(): void {\n $groupsToAddTo = (array) $this->getSubmittedValue('groups');\n $summaryInfo = ['groups' => [], 'tags' => []];\n foreach ($groupsToAddTo as $groupID) {\n // This is a convenience for now - really url & name should be determined at\n // presentation stage - ie the summary screen. The only info we are really\n // preserving is which groups were created vs already existed.\n $summaryInfo['groups'][$groupID] = [\n 'url' => CRM_Utils_System::url('civicrm/group/search', 'reset=1&force=1&context=smog&gid=' . $groupID),\n 'name' => Group::get(FALSE)\n ->addWhere('id', '=', $groupID)\n ->addSelect('name')\n ->execute()\n ->first()['name'],\n 'new' => FALSE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n\n if ($this->getSubmittedValue('newGroupName')) {\n /* Create a new group */\n $groupsToAddTo[] = $groupID = Group::create(FALSE)->setValues([\n 'title' => $this->getSubmittedValue('newGroupName'),\n 'description' => $this->getSubmittedValue('newGroupDesc'),\n 'group_type' => $this->getSubmittedValue('newGroupType') ?? [],\n 'is_active' => TRUE,\n ])->execute()->first()['id'];\n $summaryInfo['groups'][$groupID] = [\n 'url' => CRM_Utils_System::url('civicrm/group/search', 'reset=1&force=1&context=smog&gid=' . $groupID),\n 'name' => $this->getSubmittedValue('newGroupName'),\n 'new' => TRUE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n $tagsToAdd = (array) $this->getSubmittedValue('tag');\n foreach ($tagsToAdd as $tagID) {\n // This is a convenience for now - really url & name should be determined at\n // presentation stage - ie the summary screen. The only info we are really\n // preserving is which tags were created vs already existed.\n $summaryInfo['tags'][$tagID] = [\n 'url' => CRM_Utils_System::url('civicrm/contact/search', 'reset=1&force=1&context=smog&id=' . $tagID),\n 'name' => Tag::get(FALSE)\n ->addWhere('id', '=', $tagID)\n ->addSelect('name')\n ->execute()\n ->first()['name'],\n 'new' => TRUE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n if ($this->getSubmittedValue('newTagName')) {\n $tagsToAdd[] = $tagID = Tag::create(FALSE)->setValues([\n 'name' => $this->getSubmittedValue('newTagName'),\n 'description' => $this->getSubmittedValue('newTagDesc'),\n 'is_selectable' => TRUE,\n 'used_for' => 'civicrm_contact',\n //NYSS new tags during import should be imported as keywords\n 'parent_id'\t=> 296,\n ])->execute()->first()['id'];\n $summaryInfo['tags'][$tagID] = [\n 'url' => CRM_Utils_System::url('civicrm/contact/search', 'reset=1&force=1&context=smog&id=' . $tagID),\n 'name' => $this->getSubmittedValue('newTagName'),\n 'new' => FALSE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n // Store the actions to take on each row & the data to present at the end to the userJob.\n $this->updateUserJobMetadata('post_actions', [\n 'group' => $groupsToAddTo,\n 'tag' => $tagsToAdd,\n ]);\n $this->updateUserJobMetadata('summary_info', $summaryInfo);\n\n // If ACL applies to the current user, update cache before running the import.\n if (!CRM_Core_Permission::check('view all contacts')) {\n $userID = CRM_Core_Session::getLoggedInContactID();\n CRM_ACL_BAO_Cache::deleteEntry($userID);\n CRM_ACL_BAO_Cache::deleteContactCacheEntry($userID);\n }\n\n $this->runTheImport();\n }", "public function getServices()\n\t{\n\t\t$senddata= array();\n\t\t$finalsenddata= array();\n\t\t$services = Contactuspage::get()->toArray();\n\t\tforeach($services as $key=>$service)\n\t\t{\n\t\t\t$senddata['id'] \t\t\t= $service['id'];\n\t\t\t$senddata['title'] \t\t\t= $service['title'];\n\t\t\t$senddata['content'] \t\t= $service['content'];\n\t\t\tarray_push($finalsenddata,$senddata);\n\t\t}\n\t\t$siteSettings = SiteSettings::find(1)->toArray();\n\t\t$data['status'] = 1;\n\t\t$data['msg'] = 'Successfull.';\n\t\t$data['heading_text'] = $siteSettings['service_header'];\n\t\t$data['data'] = $finalsenddata;\n\t\techo json_encode($data);\n\t}", "function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++) { //for each group\n if (isset($groups[$i])) { // Patched by SysCo/al\n $line=trim($groups[$i]);\n \n if (strlen($line)>0){ \n //more presumptions, they're all prefixed with CN= (but no more yet, patched by SysCo/al\n //so we ditch the first three characters and the group\n //name goes up to the first comma\n $bits=explode(\",\",$line);\n if (1== count($bits)) {\n $group_array[]=$bits[0]; // Patched by SysCo/al\n } else {\n $prefix_len=strpos($bits[0], \"=\"); // Patched by SysCo/al to allow also various length (not only 3)\n if (FALSE === $prefix_len) {\n $group_array[]=$bits[0];\n } else {\n $group_array[]=substr($bits[0],$prefix_len+1); // Patched by SysCo/al\n }\n }\n }\n }\n }\n return ($group_array);\t\n }", "public function get_all_services_listing($data) {\n $this->db->select('*');\n $this->db->from('business_programs');\n $this->db->where('business_id', $data->business_id);\n $query = $this->db->get();\n $query_result = $query->result();\n $details = array();\n foreach ($query_result as $result) {\n $this->db->select('business_services.*,business_services_details.*');\n $this->db->from('business_services');\n $this->db->join('business_services_details', 'business_services.id = business_services_details.service_id');\n $this->db->where('business_services.program_id', $result->id);\n $query1 = $this->db->get();\n $query_result1 = $query1->result();\n array_push($details, $query_result1);\n }\n\n return $details;\n }", "public function getServices();", "protected function renderServicesList() {}", "function get_services($username) {\n\t\t$conn = db_connect();\n\t\t$result = $conn->query(\"select id,photo,service_name from services\");\n\t\tif (!$result)\n\t\t{\n\t\t\treturn false;\n\t\t}\n\t\t//create an array of the services\n\t\t$url_array = array();\n\t\tfor ($count = 1; $row = $result->fetch_row(); ++$count) {\n\t\t\t$url_array[$count][0] = $row[0];\n\t\t\t$url_array[$count][1] = $row[1];\n\t\t\t$url_array[$count][2] = $row[2];\t\n\t\t}\n\t\treturn $url_array;\n\t}", "private function createResourceGroups()\n {\n foreach ($this->api->getServices() as $service) {\n $this->resourceGroups[] = new ResourceGroup($service);\n }\n }", "public function groups();", "public function groups();", "function listServices()\n{\n global $LANG_ADMIN, $LANG_TRB, $_CONF, $_IMAGE_TYPE, $_TABLES;\n\n require_once $_CONF['path_system'] . 'lib-admin.php';\n\n $retval = '';\n\n $header_arr = array( # display 'text' and use table field 'field'\n array('text' => $LANG_ADMIN['edit'], 'field' => 'edit', 'sort' => false),\n array('text' => $LANG_TRB['service'], 'field' => 'name', 'sort' => true),\n array('text' => $LANG_TRB['ping_method'], 'field' => 'method', 'sort' => true),\n array('text' => $LANG_TRB['service_ping_url'], 'field' => 'ping_url', 'sort' => true),\n array('text' => $LANG_ADMIN['enabled'], 'field' => 'is_enabled', 'sort' => false)\n );\n\n $defsort_arr = array('field' => 'name', 'direction' => 'asc');\n\n $menu_arr = array (\n array('url' => $_CONF['site_admin_url'] . '/trackback.php?mode=editservice',\n 'text' => $LANG_ADMIN['create_new']),\n array('url' => $_CONF['site_admin_url'],\n 'text' => $LANG_ADMIN['admin_home']));\n\n $retval .= COM_startBlock($LANG_TRB['services_headline'], '',\n COM_getBlockTemplate('_admin_block', 'header'));\n\n $retval .= ADMIN_createMenu(\n $menu_arr,\n $LANG_TRB['service_explain'],\n $_CONF['layout_url'] . '/images/icons/trackback.' . $_IMAGE_TYPE\n );\n\n $text_arr = array(\n 'has_extras' => true,\n 'form_url' => $_CONF['site_admin_url'] . '/trackback.php',\n 'help_url' => getHelpUrl() . '#ping'\n );\n\n $query_arr = array(\n 'table' => 'pingservice',\n 'sql' => \"SELECT * FROM {$_TABLES['pingservice']} WHERE 1=1\",\n 'query_fields' => array('name', 'ping_url'),\n 'default_filter' => \"\",\n 'no_data' => $LANG_TRB['no_services']\n );\n\n // this is a dummy variable so we know the form has been used if all services\n // should be disabled in order to disable the last one.\n $form_arr = array('bottom' => '<input type=\"hidden\" name=\"serviceChanger\" value=\"true\"' . XHTML . '>');\n\n $retval .= ADMIN_list('pingservice', 'ADMIN_getListField_trackback',\n $header_arr, $text_arr, $query_arr, $defsort_arr,\n '', SEC_createToken(), '', $form_arr);\n $retval .= COM_endBlock(COM_getBlockTemplate('_admin_block', 'footer'));\n\n if ($_CONF['trackback_enabled']) {\n $retval .= freshTrackback ();\n }\n if ($_CONF['pingback_enabled']) {\n $retval .= freshPingback ();\n }\n\n return $retval;\n}", "private function _getServiceList()\n {\n Modules_CustomServices_DataLayer::init();\n $configs = Modules_CustomServices_DataLayer::loadServiceConfigurations();\n\n // Configs are objects, but the list view needs associative arrays.\n $config_to_array = function($config) {\n return [\n 'name' => '<a href=\"' . htmlspecialchars(pm_Context::getActionUrl('index', 'view') . '/id/' . urlencode($config->unique_id)) . '\">' . htmlspecialchars($config->display_name) . '</a>',\n 'type' => self::_configTypeName($config->config_type),\n 'plesk_service_id' => '<code>' . htmlspecialchars('ext-' . pm_Context::getModuleId() . '-' . $config->unique_id) . '</code>',\n 'run_as_user' => $config->run_as_user\n ];\n };\n $data = array_map($config_to_array, $configs);\n\n // Prepare the list for presentation.\n $list = new pm_View_List_Simple($this->view, $this->_request);\n $list->setData($data);\n $list->setColumns([\n 'name' => [\n 'title' => 'Name',\n 'noEscape' => TRUE,\n 'searchable' => TRUE,\n 'sortable' => TRUE\n ],\n 'type' => [\n 'title' => 'Type',\n 'noEscape' => FALSE,\n 'searchable' => FALSE,\n 'sortable' => FALSE\n ],\n 'plesk_service_id' => [\n 'title' => 'Service ID',\n 'noEscape' => TRUE,\n 'searchable' => TRUE,\n 'sortable' => FALSE\n ],\n 'run_as_user' => [\n 'title' => 'System user',\n 'noEscape' => FALSE,\n 'searchable' => TRUE,\n 'sortable' => TRUE\n ]\n ]);\n $list->setDataUrl(['action' => 'list-data']);\n $list->setTools([\n [\n 'title' => 'Add service (simple)',\n 'description' => 'Add a new service that wraps a process',\n 'class' => 'sb-add-new',\n 'link' => pm_Context::getActionUrl('index', 'add') . '/type/process'\n ],\n [\n 'title' => 'Add service (manual)',\n 'description' => 'Add a new manually controlled service',\n 'class' => 'sb-add-new',\n 'link' => pm_Context::getActionUrl('index', 'add') . '/type/manual'\n ]\n ]);\n return $list;\n }", "public function ListGroups(){\n\t\t$query = \"SELECT groupTitle FROM [PUBLISH GROUPS TABLE] ORDER BY groupTitle ASC\";\n\t\treturn array(\"results\" => $this->SelectQueryHelper());\n\t}", "function get_service_list() {\n\t\tglobal $wpdb;\n\t\t\n\t\t$services = $wpdb->get_results( \n\t\t\t\"\n\t\t\tSELECT ID, Title\n\t\t\tFROM cp_Categories\n\t\t\tWHERE 1\n\t\t\t\",\n\t\t\tARRAY_A\n\t\t);\n\t\t\n\t\treturn $services;\n\t}", "function groupListManage(&$array)\n{\n\tglobal $db;\n\n\t$res = $db->query('select group_def_id, group_def_name from group_def order by group_def_id');\n\n\tforeach($res as $row)\n\t{\n\t\tarray_push($array, array(\n\t\t\tdecode($row['group_def_name']),\n\t\t\tmakeLink('Manage', 'a=edit-group&g=' . $row['group_def_id'])\n\t\t));\n\t}\n}", "public function groupList(){\n\t\techo json_encode($this->read_database->get_groups());\n\t}", "public function findServices(): array;", "public function fetchGroupData() {}", "public function fetchGroupData() {}", "public static function get_services()\n {\n $ServicesObj = new Services();\n $Services = array();\n try {\n $stmt = $ServicesObj->read();\n $count = $stmt->rowCount();\n if ($count > 0) {\n while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {\n extract($row);\n $p = (object) array(\n \"ServiceID\" => (int) $ServiceID,\n \"ServiceName\" => $ServiceName,\n );\n\n array_push($Services, $p);\n }\n }\n return $Services;\n } catch (Exception $e) {\n throw $e;\n }\n }", "public function getServiceLevels()\n {\n $serviceLevels = unserialize(Mage::getStoreConfig('carriers/iparcel/name'));\n $formatted = array();\n foreach ($serviceLevels as $level) {\n $formatted[$level['service_id']] = $level['title'];\n }\n return $formatted;\n }", "abstract protected function getGroupList() ;", "protected function nice_names($groups){\n\n $group_array=array();\n for ($i=0; $i<$groups[\"count\"]; $i++){ // For each group\n \t\n \tif (isset($groups[$i])) {\n \t$line=$groups[$i];\n \t} else {\n \t\t$line = '';\n \t}\n \n if (strlen($line)>0){ \n // More presumptions, they're all prefixed with CN=\n // so we ditch the first three characters and the group\n // name goes up to the first comma\n $bits=explode(\",\",$line);\n $group_array[]=substr($bits[0],3,(strlen($bits[0])-3));\n }\n }\n return ($group_array); \n }", "public function getGroups();", "public function getGroups();", "function getService($service) {\n\t$i = 0;\n\t\tforeach ($this->services as $value) {\n\t\t\tif ($value == $service) {\n\t\t\t\treturn array(\n\t\t\t\t\"Keyword\" => $value,\n\t\t\t\t\"Description\" => $this->descriptions[$i],\n\t\t\t\t\"Information\" => $this->infos[$i]);\n\t\t\t}\n\t\t\t$i++;\n\t\t}\n\t}", "public function run()\n {\n $service = new Service;\n $service = [\n [\n 'name' => 'Building Construction',\n 'img' => 'img/service-1.jpg',\n 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec pretium mi. Curabitur facilisis \n ornare velit non vulputate. Aliquam metus tortor, auctor id gravida condimentum, viverra quis sem.',\n 'delay' => '0.1s'\n ],\n [\n 'name' => 'House Renovation',\n 'img' => 'img/service-2.jpg',\n 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec pretium mi. Curabitur facilisis \n ornare velit non vulputate. Aliquam metus tortor, auctor id gravida condimentum, viverra quis sem.',\n 'delay' => '0.2s'\n ],\n [\n 'name' => 'Architecture Design',\n 'img' => 'img/service-3.jpg',\n 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec pretium mi. Curabitur facilisis \n ornare velit non vulputate. Aliquam metus tortor, auctor id gravida condimentum, viverra quis sem.',\n 'delay' => '0.3s'\n ],\n [\n 'name' => 'Interior Design',\n 'img' => 'img/service-4.jpg',\n 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec pretium mi. Curabitur facilisis \n ornare velit non vulputate. Aliquam metus tortor, auctor id gravida condimentum, viverra quis sem.',\n 'delay' => '0.4s'\n ],\n [\n 'name' => 'Fixing & Support',\n 'img' => 'img/service-5.jpg',\n 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec pretium mi. Curabitur facilisis \n ornare velit non vulputate. Aliquam metus tortor, auctor id gravida condimentum, viverra quis sem.',\n 'delay' => '0.5s'\n ],\n [\n 'name' => 'Painting',\n 'img' => 'img/service-6.jpg',\n 'description' => 'Lorem ipsum dolor sit amet, consectetur adipiscing elit. Phasellus nec pretium mi. Curabitur facilisis \n ornare velit non vulputate. Aliquam metus tortor, auctor id gravida condimentum, viverra quis sem.',\n 'delay' => '0.6s'\n ],\n\n ];\n foreach ($service as $s) {\n Service::create($s);\n }\n }", "public function getDashboardGroups(): array;", "private function calculateService()\n {\n $service = new Service();\n $serviceList = array();\n foreach ($this->services as $value) {\n $result = $service->getById($value['name'])[0];\n $result['hours']= $service->calculateHours($value);\n $result['data'] = $value;\n $result['total'] = $result['hours'] * $result['price_per_hour'];\n $this->subtotal += $result['total'];\n $serviceList[] = $result;\n }\n $this->services = $serviceList;\n\n }", "public function servicesArray()\n {\n return [\n self::PAINTING,\n self::TIRE,\n self::BODY_WORK,\n self::TO,\n self::WASHING,\n ];\n }", "function &group_list($start=NULL, $limit=NULL, $direction=0, $where=NULL)\n\n {\n\n global $database, $user;\n\n \n\n\t $message_array = array();\n\n \n\n\t // MAKE SURE MESSAGES ARE ALLOWED\n\n\t \n\n \n\n // BEGIN MESSAGE QUERY\n\n $sql = \"\n\n SELECT\n\n *\n\n FROM\n\n se_groups\n\n WHERE\n\n owner='{$user->user_info['user_username']}'\n\n \";\n\n // EXECUTE QUERY\n\n $resource = $database->database_query($sql);\n\n \n\n // GET MESSAGES\n\n\t while( $message_info=$database->database_fetch_assoc($resource) )\n\n {\n\n // CREATE AN OBJECT FOR MESSAGE AUTHOR/RECIPIENT\n\n $pm_user = new SEUser();\n\n $pm_user->user_info['id'] = $message_info['id'];\n\n $pm_user->user_info['grup'] = $message_info['grup'];\n\n $pm_user->user_info['owner'] = $message_info['owner'];\n\n $pm_user->user_displayname();\n\n \n\n // Remove breaks for preview\n\n $message_info['pm_body'] = str_replace(\"<br>\", \"\", $message_info['pm_body']);\n\n \n\n // SET MESSAGE ARRAY\n\n $message_array[] = array(\n\n 'pmconvo_id' => $message_info['id'],\n\n 'pmconvo_grup' => $message_info['grup'],\n\n 'pm_owner' => $message_info['owner'],\n\t\t'pm_body' => $message_info['pm_body']\n\t\t\n\n );\n\n \n\n unset($pm_user);\n\n }\n\n \n\n return $message_array;\n\n }", "public function listAddressGroupings();", "function ajax_get_all_groups() {\r\n global $wpdb;\r\n\r\n $groups = $this->get_groups();\r\n\r\n if ( is_array( $groups ) && 0 < count( $groups ) ) {\r\n\r\n $i = 0;\r\n $n = ceil( count( $groups ) / 5 );\r\n\r\n $html = '';\r\n $html .= '<ul class=\"clients_list\">';\r\n\r\n\r\n\r\n foreach ( $groups as $group ) {\r\n if ( $i%$n == 0 && 0 != $i )\r\n $html .= '</ul><ul class=\"clients_list\">';\r\n\r\n $html .= '<li><label>';\r\n $html .= '<input type=\"checkbox\" name=\"groups_id[]\" value=\"' . $group['group_id'] . '\" /> ';\r\n $html .= $group['group_id'] . ' - ' . $group['group_name'];\r\n $html .= '</label></li>';\r\n\r\n $i++;\r\n }\r\n\r\n $html .= '</ul>';\r\n } else {\r\n $html = 'false';\r\n }\r\n\r\n die( $html );\r\n\r\n }", "public function getServiceName($serviceid) {\r\n \t\r\n \tif(is_array($serviceid) && !empty($serviceid)){\r\n \t\t$serviceid = @implode(\",\", $serviceid);\r\n \t}\r\n\r\n $serviceid = str_replace('P1188', 'PL', $serviceid);\r\n $serviceid = str_replace('C1188', 'CL', $serviceid);\r\n $serviceid = str_replace('A0.5', 'A2W', $serviceid);\r\n $serviceid = str_replace('B0.5', 'B2W', $serviceid);\r\n $serviceid = str_replace('P0.5', 'P2W', $serviceid);\r\n $serviceid = str_replace('C0.5', 'C2W', $serviceid);\r\n $serviceid = str_replace('P1.5', 'P6W', $serviceid);\r\n $serviceid = str_replace('C1.5', 'C6W', $serviceid);\r\n $serviceid = str_replace('P0.07', 'P1W', $serviceid);\r\n $serviceid = str_replace('C0.07', 'C1W', $serviceid);\r\n $serviceid_arr = @explode(\",\", $serviceid);\r\n $serviceid_str = \"'\".@implode(\"','\", $serviceid_arr).\"'\";\r\n \r\n $billingServicesObj = new billing_SERVICES('newjs_slave');\r\n $serviceDetails = $billingServicesObj->fetchAllServiceDetails($serviceid_str);\r\n foreach($serviceid_arr as $key=>$val){\r\n \tforeach($serviceDetails as $kk=>$vv){\r\n \t\tif($val == $vv['SERVICEID']){\r\n \t\t\t$id = $vv[\"SERVICEID\"];\t\t\r\n \t\t\t$service_name[$id][\"NAME\"] = $vv[\"NAME\"];\r\n \t\t}\r\n \t}\r\n }\r\n \r\n return $service_name;\r\n }", "private function _get_groups() {\n\n\t\t$request = new Gitlab();\n\t\t$gitlab = $request->init_request();\n\n\t\t$groups = [];\n\t\t$page_index = 1;\n\n\t\tdo {\n\n\t\t\t$response = $gitlab->get( \"groups?per_page=100&page=$page_index\" );\n\t\t\t$response_arr = json_decode( $response->body, true );\n\n\t\t\t$groups = array_merge( $groups, $response_arr );\n\n\t\t\t$page_index = get_next_page( $response );\n\n\t\t} while ( ! empty( $page_index ) );\n\n\t\treturn $groups;\n\n\t}", "function drush_test_list($groups) {\n foreach ($groups as $group_name => $group_tests) {\n foreach ($group_tests as $test_class => $test_info) {\n $rows[] = array('group' => $group_name, 'class' => $test_class, 'name' => $test_info['name']);\n }\n }\n return $rows;\n}", "public function getServiceGroupIDS($sorted = false): array\n {\n $serviceEntries = [];\n foreach ($this->serviceEntries as $serviceEntry) {\n $id = $serviceEntry->getID();\n $order = $serviceEntry->getSortKey();\n $serviceEntries[$id] = $order;\n }\n if ($sorted) {\n asort($serviceEntries);\n }\n return array_keys($serviceEntries);\n }", "public function &getGroupBy();", "public function sample()\n\t{\n\t\treturn array(\n\t\t\t'header' => 'groups',\n\t\t\t'content' => 'groupalias;groupalias;groupalias'\n\t\t);\n\t}", "public function findGroups() {\n\t\t\n\t}", "public function getGroupsList(){\n return $this->_get(1);\n }", "public function getAllServices_crm() {\r\n\t\t$billingServicesObj = new billing_SERVICES();\r\n $services = $billingServicesObj->getAllServiceDataForActiveServices();\r\n foreach ($services as $key=>$val) {\r\n if (strpos($val[\"SERVICEID\"], 'M') && $val[\"SERVICEID\"] != 'M3' && $val[\"SERVICEID\"] != 'M') {\r\n \tunset($services[$key]);\r\n }\r\n }\r\n return $services;\r\n }", "function recurringdowntime_get_servicegroup_cfg($servicegroup = false)\n{\n $cfg = recurringdowntime_get_cfg();\n $ret = array();\n foreach ($cfg as $sid => $schedule) {\n if (array_key_exists('schedule_type', $schedule)) {\n if ($schedule[\"schedule_type\"] != \"servicegroup\") {\n continue;\n }\n }\n if ($servicegroup && !(strtolower($schedule[\"servicegroup_name\"]) == strtolower($servicegroup))) {\n continue;\n }\n if (array_key_exists('servicegroup_name', $schedule)) {\n if (is_authorized_for_servicegroup(0, $schedule[\"servicegroup_name\"])) {\n $ret[$sid] = $schedule;\n }\n }\n }\n return $ret;\n}", "public function getServices()\n\t\t{\n\n\t\t\t$service_id = $this->input->get('service_id') ;\n\t\t\techo json_encode($this->mdl_services->all()->result() ) ;\n\t\t}", "function timeconditions_timegroups_list_groups() {\n\tglobal $db;\n\t$tmparray = array();\n\n\t$sql = \"select id, description from timegroups_groups order by description\";\n\t$results = $db->getAll($sql);\n\tif(DB::IsError($results)) {\n\t\t$results = null;\n\t}\n\tforeach ($results as $val) {\n\t\t$tmparray[] = array($val[0], $val[1], \"value\" => $val[0], \"text\" => $val[1]);\n\t}\n\treturn $tmparray;\n}", "function getAllUsedServices()\n {\n $ret = array();\n foreach ($this->plugins as $name => $obj) {\n if ($obj->is_account) {\n if (isset($obj->DisplayName)) {\n $ret[$name] = $obj->DisplayName;\n } else {\n $ret[$name] = $name;\n }\n }\n }\n return $ret;\n }", "public function getGroupsList(){\n return $this->_get(3);\n }", "function service_list_json(){\r\n\t\t\t$aColumns = array( 'sl','branch','invoice','date','type','customer','net_amount','action' );\r\n\t\t\t\r\n\t\t\t//Array of database search columns//\r\n\t\t\t$sColumns = array('customer','invoice','net_amount');\r\n\t\t\t\r\n\t\t\t//Indexed column (used for fast and accurate table attributes) //\r\n\t\t\t$sIndexColumn = \"service_id\";\r\n\t\t\t\r\n\t\t\t//DB tables to use//\r\n\t\t\t$sTable = \"tbl_service \r\n\t\t\t\t\t INNER JOIN tbl_branch ON service_branch=branch_id\r\n\t\t\t\t\t INNER JOIN tbl_payment_method ON service_type=payment_method_id\r\n\t\t\t\t\t INNER JOIN tbl_customer ON service_customer=customer_id\";\r\n\t\t\t\r\n\t\t\t//Paging//\r\n\t\t\t$sLimit = \"\";\r\n\t\t\tif ( isset( $_GET['iDisplayStart'] ) && $_GET['iDisplayLength'] != '-1' )\r\n\t\t\t{\r\n\t\t\t\t$sLimit = \"LIMIT \".( $_GET['iDisplayStart'] ).\", \".\r\n\t\t\t\t\t( $_GET['iDisplayLength'] );\r\n\t\t\t}\r\n\t\r\n\t\t\t//Ordering//\r\n\t\t\tif ( isset( $_GET['iSortCol_0'] ) )\r\n\t\t\t{\r\n\t\t\t\t$sOrder = \"ORDER BY \";\r\n\t\t\t\tfor ( $i=0 ; $i<intval( $_GET['iSortingCols'] ) ; $i++ )\r\n\t\t\t\t{\r\n\t\t\t\t\tif ( $_GET[ 'bSortable_'.intval($_GET['iSortCol_'.$i]) ] == \"true\" )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$sOrder .= $aColumns[ intval( $_GET['iSortCol_'.$i] ) ].\"\r\n\t\t\t\t\t\t\t\".( $_GET['sSortDir_'.$i] ) .\", \";\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$sOrder = substr_replace( $sOrder, \"\", -2 );\r\n\t\t\t\tif ( $sOrder == \"ORDER BY\" )\r\n\t\t\t\t{\r\n\t\t\t\t\t$sOrder = \"\";\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\t//Filtering//\r\n\t\t\t$sWhere = \"\";\r\n\t\t\tif ( $_GET['sSearch'] != \"\" )\r\n\t\t\t{\r\n\t\t\t\t$sWhere = \"WHERE (\";\r\n\t\t\t\tfor ( $i=0 ; $i<count($sColumns) ; $i++ )\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t\t\t$sWhere .= $sColumns[$i].\" LIKE '%\".( $_GET['sSearch'] ).\"%' OR \";\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t$sWhere = substr_replace( $sWhere, \"\", -3 );\r\n\t\t\t\t$sWhere .= ')';\r\n\t\t\t}\r\n\t\r\n\t\t\t//Individual column filtering//\r\n\t\t\tfor ( $i=0 ; $i<count($sColumns) ; $i++ )\r\n\t\t\t{\r\n\t\t\t\tif ( $_GET['bSearchable_'.$i] == \"true\" && $_GET['sSearch_'.$i] != '' )\r\n\t\t\t\t{\r\n\t\t\t\t\tif ( $sWhere == \"\" )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$sWhere = \"WHERE \";\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$sWhere .= \" AND \";\r\n\t\t\t\t\t}\r\n\t\t\t\t\t$sWhere .= $sColumns[$i].\" LIKE '%\".($_GET['sSearch_'.$i]).\"%' \";\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\r\n\t\t\t//SQL queries//\r\n\t\t\t$sQuery\t\t\t= \"SELECT SQL_CALC_FOUND_ROWS service_id as sl,branch_name as branch,service_invoice as invoice,\r\n\t\t\t\t\t\t\tDATE_FORMAT(service_date,'%d/%m/%Y') as date,payment_method_title as type,\r\n\t\t\t\t\t\t\tcustomer_name as customer,service_amount as amount,service_tax as tax,service_discount as discount,\r\n\t\t\t\t\t\t\tservice_total as total,service_net_amount as net_amount,service_id as id,\r\n\t\t\t\t\t\t\tservice_status as status\r\n\t\t\t\t\t\t\tFROM $sTable\r\n\t\t\t\t\t\t\t$sWhere\r\n\t\t\t\t\t\t\t$sOrder\r\n\t\t\t\t\t\t\t$sLimit\";\r\n\t\t\t$rResult \t\t= $this->db->query($sQuery);\r\n\t\r\n\t\t\t//Data set length after filtering//\r\n\t\t\t$fQuery\t\t\t= \"SELECT $sIndexColumn FROM $sTable $sWhere\";\r\n\t\t\t$fResult\t\t= $this->db->query($fQuery);\r\n\t\t\t$FilteredTotal\t= $fResult->num_rows();\r\n\t\r\n\t\t\t//Total data set length //\r\n\t\t\t$tQuery\t\t\t= \"SELECT $sIndexColumn FROM $sTable\";\r\n\t\t\t$tResult\t\t= $this->db->query($tQuery);\r\n\t\t\t$Total\t\t\t= $tResult->num_rows();\r\n\t\r\n\t\t\t//Output\r\n\t\t\t\r\n\t\t\tif($_GET['sEcho']==1){\r\n\t\t\t\t\r\n\t\t\t\t$cStart=0;\r\n\t\t\t\t$cEnd=$_GET['iDisplayLength'];\r\n\t\t\t\t$cLength=$_GET['iDisplayLength'];\r\n\t\t\t\t$cPage=0;\r\n\t\t\t\t$cTotalPage=ceil($FilteredTotal/$_GET['iDisplayLength']);\r\n\t\t\t}\r\n\t\t\telse{\r\n\t\t\t\t$cStart=$_GET['iDisplayStart'];\r\n\t\t\t\t$cEnd=$_GET['iDisplayStart']=$_GET['iDisplayLength'];\r\n\t\t\t\t$cLength=$_GET['iDisplayLength'];\r\n\t\t\t\t$cPage=intval($cStart/$cLength);\r\n\t\t\t\t$cTotalPage=ceil($FilteredTotal/$_GET['iDisplayLength']);\r\n\t\t\t}\r\n\t\t\t$output = array(\r\n\t\t\t\t\"cStart\"\t\t\t\t=> $cStart,\r\n\t\t\t\t\"cEnd\"\t\t\t\t\t=> $cEnd,\r\n\t\t\t\t\"cLength\"\t\t\t\t=> $cLength,\r\n\t\t\t\t\"cPage\"\t\t\t\t\t=> $cPage,\r\n\t\t\t\t\"cTotalPage\"\t\t\t=> $cTotalPage,\r\n\t\t\t\t\"sEcho\" \t\t\t\t=> intval($_GET['sEcho']),\r\n\t\t\t\t\"iTotalRecords\" \t\t=> $Total,\r\n\t\t\t\t\"iTotalDisplayRecords\" \t=> $FilteredTotal,\r\n\t\t\t\t\"aaData\" \t\t\t\t=> array()\r\n\t\t\t);\r\n\t\t\t$result\t= $rResult->result_array();\r\n\t\t\t$j=$cStart+1;\r\n\t\t\tforeach($result as $aRow){\r\n\t\t\t\t\r\n\t\t\t\t$row = array();\r\n\t\t\t\tfor ( $i=0 ; $i<count($aColumns) ; $i++ )\r\n\t\t\t\t{\r\n\t\t\t\t\t\r\n\t\t\t\t\tif ( $aColumns[$i] == \"sl\" )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$row[] = $j;\r\n\t\t\t\t\t}\r\n\t\t\t\t\t//else if($aColumns[$i] == \"amount\"){\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//if(PR_TAX_INCLUDE){\r\n\t\t\t\t\t\t\t//$row[]=$aRow[ $aColumns[$i] ];\r\n\t\t\t\t\t\t//}\r\n\t\t\t\t\t\t//else{\r\n\t\t\t\t\t\t\t//$row[]=number_format($aRow[ $aColumns[$i] ]+ $aRow['pr_tax_amount'],DECIMAL_DIGITS);\r\n\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\telse if( $aColumns[$i] == \"status\" ){\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//$row[] = \"<button type='button' style='margin-top:-5px; margin-bottom:-5px;' class='btn btn-xs btn-primary'>Extra Small Button</button>\";\r\n\t\t\t\t\t\t$row[] = $this->Common_model->status_template($aRow['status']);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t\telse if( $aColumns[$i] == \"action\" ){\r\n\t\t\t\t\t\t$id\t\t=$aRow['id'];\r\n\t\t\t\t\t\t//if($aRow['status']==2){\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t//$row[]\t= \"<a href='Purchase/purchase_confirm/$id/' class='on-default edit-row edit-icon'><button type='button' style='margin-top:-5px; margin-bottom:-5px;' class='btn btn-xs btn-primary'>Confirm</button></a>\";\r\n\t\t\t\t\t\t//}\r\n\t\t\t\t\t\t//if($aRow['status']==5){\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t$row[]\t= \"<a href='Service/service_details/$id/' class='on-default edit-row edit-icon'><button type='button' style='margin-top:-5px; margin-bottom:-5px;' class='btn btn-xs btn-primary'>Details</button></a>\";\r\n\r\n\t\t\t\t\t\t//}\r\n\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\telse if ( $aColumns[$i] != ' ' )\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t// General output \r\n\t\t\t\t\t\t$row[] = $aRow[ $aColumns[$i] ];\r\n\t\t\t\t\t}\r\n\t\t\t\t\t\r\n\t\t\t\t}\r\n\t\t\t\t$output['aaData'][] = $row;\r\n\t\t\t\t$j++;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\techo json_encode( $output );\r\n\t\t}", "public function getGroups() {\n\t\t$groups = array(\n\t\t\t'get_posts' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use WP_Query instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'get_posts',\n\t\t\t\t\t'wp_get_recent_posts',\n\t\t\t\t\t'get_children',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_get_post_terms' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use get_the_terms() instead. Use wp_list_pluck() to get the IDs.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_get_post_terms',\n\t\t\t\t\t'wp_get_object_terms',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_get_post_categories' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use the equivalent get_the_* version instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_get_post_categories',\n\t\t\t\t\t'wp_get_post_tags',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'wp_old_slug_redirect' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => '%s() is an uncached function; use wpcom_vip_old_slug_redirect() instead.',\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'wp_old_slug_redirect',\n\t\t\t\t),\n\t\t\t),\n\t\t\t'get_term_by' => array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => \"%s() is an uncached function; use wpcom_vip_get_term_by() instead.\",\n\t\t\t\t'functions' => array(\n\t\t\t\t\t'get_term_by',\n\t\t\t\t\t'get_cat_ID',\n\t\t\t\t),\n\t\t\t),\n\t\t);\n\n\t\t$wpcom_vip_fns = array(\n\t\t\t'get_category_by_slug',\n\t\t\t'get_term_link',\n\t\t\t'get_page_by_title',\n\t\t\t'get_page_by_path',\n\t\t\t'url_to_postid',\n\t\t);\n\t\tforeach ( $wpcom_vip_fns as $function ) {\n\t\t\t$groups[ $function ] = array(\n\t\t\t\t'type' => 'error',\n\t\t\t\t'message' => \"%s() is an uncached function; use wpcom_vip_$function() instead.\",\n\t\t\t\t'functions' => array(\n\t\t\t\t\t$function\n\t\t\t\t),\n\t\t\t);\n\t\t}\n\n\t\treturn $groups;\n\t}", "public function Detail_assigned_services($user_master_id,$service_order_id)\n\t{\n\t\t$sQuery = \"SELECT\n\t\t\t\t\tA.id,\n\t\t\t\t\tA.serv_pers_id,\n\t\t\t\t\tA.service_location,\n\t\t\t\t\tA.service_latlon,\n\t\t\t\t\tDATE_FORMAT(A.order_date, '%W %M %e %Y') as order_date,\n\t\t\t\t\tA.contact_person_name,\n\t\t\t\t\tA.contact_person_number,\n\t\t\t\t\tA.service_rate_card,\n\t\t\t\t\tB.main_cat_name,\n\t\t\t\t\tB.main_cat_ta_name,\n\t\t\t\t\tC.sub_cat_name,\n\t\t\t\t\tC.sub_cat_ta_name,\n\t\t\t\t\tD.service_name,\n\t\t\t\t\tD.service_ta_name,\n\t\t\t\t\tE.from_time,\n\t\t\t\t\tE.to_time,\n\t\t\t\t\tF.full_name AS service_person\n\t\t\t\tFROM\n\t\t\t\t\tservice_orders A,\n\t\t\t\t\tmain_category B,\n\t\t\t\t\tsub_category C,\n\t\t\t\t\tservices D,\n\t\t\t\t\tservice_timeslot E,\n\t\t\t\t\tservice_person_details F\n\t\t\t\tWHERE\n\t\t\t\t\t A.id = '\".$service_order_id.\"' AND A.serv_pers_id = '\".$user_master_id.\"' AND A.status = 'Assigned' AND A.`main_cat_id` = B.id AND A.`sub_cat_id` = C.id AND A.`service_id` = D.id\n AND A.`order_timeslot` = E.id AND A.serv_pers_id = F.user_master_id\";\n\t\t$serv_result = $this->db->query($sQuery);\n\t\t$service_result = $serv_result->result();\n\n\t\tif($serv_result->num_rows()>0) {\n\t\t\t$response = array(\"status\" => \"success\", \"msg\" => \"Service Order List\", \"detail_services_order\"=>$service_result);\n\t\t} else {\n\t\t\t$response = array(\"status\" => \"error\", \"msg\" => \"Service Order List Not found\");\n\t\t}\n\t\treturn $response;\n\t}", "public function getServiceDefinitions(): array;", "public function getServiceGroupsForStpl(int $serviceId)\n {\n // Get from the cache\n if (isset($this->sgRelationCache[$serviceId])) {\n return $this->sgRelationCache[$serviceId];\n }\n if ($this->doneCache == 1) {\n return [];\n }\n\n if (is_null($this->stmtStplSg)) {\n // Meaning, linked with the host or hostgroup (for the null expression)\n $this->stmtStplSg = $this->backendInstance->db->prepare(\n \"SELECT servicegroup_sg_id, host_host_id, service_service_id\n FROM servicegroup_relation\n WHERE service_service_id = :service_id\"\n );\n }\n $this->stmtStplSg->bindParam(':service_id', $serviceId, PDO::PARAM_INT);\n $this->stmtStplSg->execute();\n $this->sgRelationCache[$serviceId] = array_merge(\n $this->stmtStplSg->fetchAll(PDO::FETCH_ASSOC),\n $this->sgRelationCache[$serviceId]\n );\n return $this->sgRelationCache[$serviceId];\n }", "public function get_single_service_detail($service_id) {\n $this->db->select('business_services.*,business_services_details.description,business_services_details.duration,business_services_details.price,business_services_details.service_type,business_services_details.discount,business_services_details.discount_start_date,business_services_details.discount_end_date');\n $this->db->from('business_services');\n $this->db->join('business_services_details', 'business_services.id = business_services_details.service_id');\n $this->db->where('business_services.id', $service_id);\n $query = $this->db->get();\n $query_result = $query->result();\n $business_service_details = array();\n if (!empty($query_result)) {\n $business_service_details['details'] = $query_result[0];\n } else {\n $business_service_details['details'] = $query_result;\n }\n\n\n $gallery_query = $this->db->get_where('business_service_gallery', array('service_id' => $service_id));\n $gallery_query_result = $gallery_query->result();\n $business_service_details['gallery'] = $gallery_query_result;\n\n $membership_query = $this->db->get_where('memberships', array('business_service_id' => $service_id));\n $membership_query_result = $membership_query->result();\n $business_service_details['memberships'] = $membership_query_result;\n\n $slot_query = $this->db->get_where('services_slots', array('service_id' => $service_id));\n $slot_query_result = $slot_query->result();\n $slots = array();\n foreach ($slot_query_result as $key => $value) {\n $check_date = date('D', strtotime($value->date));\n if ($check_date == 'Mon') {\n $slots['1'][] = $value;\n } elseif ($check_date == 'Tue') {\n $slots['2'][] = $value;\n } elseif ($check_date == 'Wed') {\n $slots['3'][] = $value;\n } elseif ($check_date == 'Thu') {\n $slots['4'][] = $value;\n } elseif ($check_date == 'Fri') {\n $slots['5'][] = $value;\n } elseif ($check_date == 'Sat') {\n $slots['6'][] = $value;\n } elseif ($check_date == 'Sun') {\n $slots['7'][] = $value;\n }\n asort($slots);\n }\n $business_service_details['slots'] = $slots;\n\n return $business_service_details;\n }", "protected function collectDataGroup()\n {\n $url = $this->getGroupURI();\n $this->collectDeals($url);\n }", "public static abstract function getGroupList();", "public function buildDefaultCostTables() {\n\t\t// Get services table data\n\t\t$service_list = new ServicesInfo;\n\t\t$service_list = $service_list->getServicesTableData($id_list = NULL); // Note that the sizeof($service_data) == 8\n\t\t$cost_table_array = array();\n\t\tforeach ($service_list as $value) {\n\t\t\t$cost_table_array[$value['svc_name']][] = array('svc_id' => $value['svc_id'], 'svc_name' => '', 'cost_desc' => '', 'cost_code' => '', 'cost_ro_count' => '', 'cost_parts_sale' => '', 'cost_parts_cost' => '', 'cost_labor_sale' => '');\n\t\t}\n\t\treturn $cost_table_array;\n\t}", "public function getGroupsList(){\n return $this->_get(4);\n }", "public function getGroupsList(){\n return $this->_get(4);\n }", "function listGroups($refresh = false)\n {\n return array();\n }", "public function getList()\n {\n $query = (new Query());\n $query->select(['services.id as id, services.name as name, COUNT(orders.id) as count'])\n ->from('services')\n ->rightJoin('orders', '`orders`.`service_id` = `services`.`id`');\n\n $this->filter($query);\n\n return $query->groupBy('orders.service_id')\n ->all();\n }", "function create_Listgroup($name,$listGroups)\r\n{ \r\n //adding the header line\r\n $contenue=get_string('group','local_course_group').\"; \".get_string('subGroup','local_course_group').\"; \".get_string('nameStudents','local_course_group'); \r\n foreach ($listGroups as $mainGroup => $groups) {\r\n foreach ($groups as $group => $member) {\r\n $contenue=$contenue.\"\\n\".\"$mainGroup; \"; //adding the groups of the student\r\n if($group!=$mainGroup) //if there is a sub-group\r\n $contenue=$contenue.\"$group; \";\r\n else\r\n $contenue=$contenue.get_string('none','local_course_group').\"; \";\r\n for($i=0;$i<count($member);$i++) \r\n $contenue=$contenue.\"$member[$i] \"; //adding all the student of the groups\r\n }\r\n }\r\n\r\n header('Content-Type: application/csv'); //force download of the file\r\n header('Content-Disposition: attachment; filename='. $name);\r\n header('Pragma: no-cache');\r\n header('Cache-Control: no-cache, must-revalidate');\r\n header('Expires: 0');\r\n echo $contenue;\r\n\r\n exit;\r\n}", "public function list_get(){\n $data['list'] = $this->group->list();\n $this->response($data);\n }", "public function property_services_ancillary() {\n\n\t\t\tif ( $this->add_package !== 3 ) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t$out = '';\n\t\t\t$ancillary_service_field = get_field( 'ancillary_services' );\n\t\t\t$ancillary_services = get_field_object( 'ancillary_services' );\n\t\t\t$ancillary_services_value = $ancillary_services['value'];\n\t\t\t$other_ancillary_services = get_field( 'other_ancillary_services' );\n\n\t\t\tif ( $ancillary_services_value ) {\n\t\t\t\t$out .= '<h4>Ancillary Services</h4>';\n\t\t\t\t$out .= '<ul>';\n\n\t\t\t\tforeach ( $ancillary_services_value as $ancillary_service ) {\n\t\t\t\t\t$out .= '<li>' . $ancillary_service . '</li>';\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif ( $other_ancillary_services ) {\n\t\t\t\t$out .= '<li>' . $other_ancillary_services . '</li>';\n\t\t\t}\n\t\t\t$out .= '</ul>';\n\n\t\t\treturn $out;\n\t\t}", "function get_groups() {\r\n global $wpdb;\r\n $groups = $wpdb->get_results( \"SELECT wcg.*, count(wcgc.client_id) as clients_count FROM {$wpdb->prefix}wpc_client_groups wcg LEFT JOIN {$wpdb->prefix}wpc_client_group_clients wcgc ON wcgc.group_id = wcg.group_id GROUP BY wcg.group_id\", \"ARRAY_A\");\r\n return $groups;\r\n }", "public function getSystemUserGroups()\n {\n $system_user_groups = array();\n \n // load the related System_user_group objects\n //Busca grupo para professor\n $system_user_system_user_groups = SystemGroup::where('name','like','%- Professor%')->load();\n if (isset($system_user_system_user_groups[0]))\n {\n $group_id = $system_user_system_user_groups[0];\n }\n $system_user_groups[] = new SystemGroup( $group_id->id );\n //var_dump($system_user_groups);\n return $system_user_groups;\n \n }", "public function getListEntry()\n {\n $fields = goService::getListEntry();\n $fields['Message'] = _(\"Kopano service\");\n #$fields['AllowEdit'] = false;\n return($fields);\n }", "function serviceDetail(&$smartyService,$searchBox=false,$topList=false, $continueAbcBarFromServiceList=false) {\n\n\t\t// first the basics:\n\t\t// service_pidlist is needed for identifying the Employees: in case of an external service the employes have\n\t\t// to be retrieved from the pidlist of the community providing the service.\n\t\t// that is an excemption to the rule that all data is fetched from within $this->community_pidlist\n\t\t$service_pidlist=\"\";\n\n\t\t//test bk: repeat the heading from the list:\n\t\t$smartyService->assign('heading',$this->pi_getLL('tx_civserv_pi1_service_list.overview','Overview' ));\n\t\tif($continueAbcBarFromServiceList){\n\t\t\t$query = $this->makeServiceListQuery(all,false);\n\t\t\t$smartyService->assign('abcbarServiceList_continued', $this->makeAbcBar($query, 'service_list'));\n\t\t}\n\n\t\t$uid = intval($this->piVars['id']);\t//SQL-Injection!!!\n\t\t$community_id = $this->community['id'];\n\n\t\t//search Employee Details\n\t\t$smartyService->assign('employee_search', $this->community['employee_search']);\n\n\t\t//Set path to forms of services\n\t\t$folder_forms = $this->conf['folder_services'];\n\t\t$folder_forms .= $this->community['id'] . '/forms/';\n\n\t\t//Query for standard service details\n\t\t$res_common = $this->queryService(intval($uid));\n\t\t$service_common = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_common);\n\t\t#$service_common['typ']='i';\n\n\n\n\t\tif ($this->versioningEnabled) {\n\t\t\t// get workspaces Overlay\n\t\t\t// versionOL can't handle marker-field 'typ'\n\t\t\t$GLOBALS['TSFE']->sys_page->versionOL('tx_civserv_service',$service_common);\n\t\t\t// fix pid for record from workspace\n\t\t\t$GLOBALS['TSFE']->sys_page->fixVersioningPid('tx_civserv_service',$service_common);\n\t\t}\n\n\t\t// versioning:\n\t\tif($service_common['_ORIG_pid']== -1 && $service_common['_ORIG_uid']>0){ // this means we are looking at the details of a version-record!!!\n\t\t\t// for the display of associated emplopyee-, organisation-, etc. records we need the\n\t\t\t// uid of the record in the version-workspace !!!\n\t\t\t$uid=$service_common['_ORIG_uid'];\n\t\t\t$smartyService->assign('preview',1); //through this flag we can identification of workspace-records in preview\n\t\t}\n\n\n\t\t//Check if service is an external service and swap the pid_list if it is! so you can show the right contact persons!!\n\t\tif (!array_key_exists($service_common['pid'],array_flip(explode(',',$this->community['pidlist'])))) {\n\t\t\t$article='';\n\t\t\t$mandant = t3lib_div::makeInstanceClassName('tx_civserv_mandant');\n\t\t\t$mandantInst = new $mandant();\n\t\t\t$service_community = $mandantInst->get_mandant($service_common['pid']);\n\t\t\t$folder_forms = $this->conf['folder_services'];\n\t\t\t$folder_forms .= $service_community . '/forms/';\n\t\t\t$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t\t\t\t\t\t'cm_community_name,\n\t\t\t\t\t\t\t\t\t\t\t cm_uid',\n\t\t\t\t\t\t\t\t\t\t\t'tx_civserv_conf_mandant',\n\t\t\t\t\t\t\t\t\t\t\t'cm_community_id = ' . intval($service_community));//just in case\n\t\t\t$row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);\n\t\t\t//todo: get $article from locallang\n\t\t\t$town=explode(' ',$row['cm_community_name']);\n\t\t\tswitch($town[0]){\n\t\t\t\tcase 'Stadt':\n\t\t\t\t\t$article= 'die ';\n\t\t\t\tbreak;\n\t\t\t\tcase 'Gemeinde':\n\t\t\t\t\t$article= 'die ';\n\t\t\t\tbreak;\n\t\t\t\tcase 'Kreis':\n\t\t\t\t\t$article= 'den ';\n\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t$smartyService->assign('external_service_label',$this->pi_getLL('tx_civserv_pi1_service.external_service','This service is provided and advised by') . ' ' . $article . $row['cm_community_name']);\n\t\t\t$service_pidlist= $this->pi_getPidList($row['cm_uid'],$this->conf['recursive']);\n\t\t\t$service_common['typ']='e';\n\t\t} else {\n\t\t\t$service_community = $this->community['id'];\n\t\t\t$service_pidlist= $this->community['pidlist'];\n\t\t\t$service_common['typ']='i';\n\t\t}\n\n\n\t\t//Query for associated forms\n\t\t$res_forms = $GLOBALS['TYPO3_DB']->exec_SELECT_mm_query(\n\t\t\t\t\t\t'tx_civserv_form.uid as uid,\n\t\t\t\t\t\t fo_name as name,\n\t\t\t\t\t\t fo_url as url,\n\t\t\t\t\t\t fo_formular_file as file,\n\t\t\t\t\t\t fo_external_checkbox as checkbox,\n\t\t\t\t\t\t fo_target as target',\n\t\t\t\t\t\t'tx_civserv_service',\n\t\t\t\t\t\t'tx_civserv_service_sv_form_mm',\n\t\t\t\t\t\t'tx_civserv_form',\n\t\t\t\t\t\t' AND tx_civserv_service.uid = ' . intval($uid) .\n\t\t \t\t\t\t $this->cObj->enableFields('tx_civserv_form'),\n\t\t\t\t\t\t'', // GROUP BY\n\t\t\t\t\t\t'tx_civserv_service_sv_form_mm.sorting');\t//ORDER BY\n\t\t\t\t\t\t#'name');\t//ORDER BY\n\n\n\t\t//Query for associated organisation units\n\t\t$res_orga = $GLOBALS['TYPO3_DB']->exec_SELECT_mm_query(\n\t\t\t\t\t\t'tx_civserv_organisation.uid as uid, or_name as name',\n\t\t\t\t\t\t'tx_civserv_service',\n\t\t\t\t\t\t'tx_civserv_service_sv_organisation_mm',\n\t\t\t\t\t\t'tx_civserv_organisation',\n\t\t\t\t\t\t' AND tx_civserv_service.uid = ' . intval($uid) .\n \t\t\t\t\t\t$this->cObj->enableFields('tx_civserv_organisation'),\n\t\t\t\t\t\t'', // GROUP BY\n\t\t\t\t\t\t'tx_civserv_service_sv_organisation_mm.sorting');\t//ORDER BY\n\t\t\t\t\t\t#'name');\t//ORDER BY\n\n\n\n\t\t// change b.k.: for the display of contact persons also the field ep_datasac of the employee-position relation is relevant.\n\t\t// Query for associated employees\n\n\t\tif (!$this->conf['show_hidden_employees']){\n\t\t\t$strEnableField = $this->cObj->enableFields('tx_civserv_service');\n\t\t\t$strEnableField .= $this->cObj->enableFields('tx_civserv_position');\n\t\t\t$strEnableField .= $this->cObj->enableFields('tx_civserv_employee');\n\t\t\t$strEnableField .= $this->cObj->enableFields('tx_civserv_employee_em_position_mm');\n\t\t}\n\n\t\t$res_employees = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t'tx_civserv_employee.uid as emp_uid,\n\t\t\t\t\t\t tx_civserv_position.uid as pos_uid,\n\t\t\t\t\t\t tx_civserv_service.uid as sv_uid,\n\t\t\t\t\t\t tx_civserv_service_sv_position_mm.sp_descr as description,\n\t\t\t\t\t\t em_address as address,\n\t\t\t\t\t\t em_title as title,\n\t\t\t\t\t\t em_name as name,\n\t\t\t\t\t\t em_firstname as firstname,\n\t\t\t\t\t\t em_telephone,\n\t\t\t\t\t\t ep_telephone,\n\t\t\t\t\t\t em_email,\n\t\t\t\t\t\t ep_email,\n\t\t\t\t\t\t em_datasec as em_datasec,\n\t\t\t\t\t\t ep_datasec as ep_datasec', // additional\n\t\t\t\t\t\t'tx_civserv_service,\n\t\t\t\t\t\t tx_civserv_service_sv_position_mm,\n\t\t\t\t\t\t tx_civserv_position,\n\t\t\t\t\t\t tx_civserv_employee,\n\t\t\t\t\t\t tx_civserv_employee_em_position_mm',\n\t\t\t\t\t\t' tx_civserv_service.uid = ' . intval($uid) .\n\t\t\t\t\t\t $strEnableField.\n\t\t\t\t\t\t ' AND tx_civserv_service.uid = tx_civserv_service_sv_position_mm.uid_local\n\t\t\t\t\t\t AND tx_civserv_service_sv_position_mm.uid_foreign = tx_civserv_position.uid\n\t\t\t\t\t\t AND tx_civserv_employee.uid = tx_civserv_employee_em_position_mm.uid_local\n\t\t\t\t\t\t AND tx_civserv_employee_em_position_mm.uid_foreign = tx_civserv_position.uid\n\t\t\t\t\t\t AND tx_civserv_employee.pid IN (' . $service_pidlist . ')', // in case of external service this is the pidlist of the community providing the service!!\n\t\t\t\t\t\t'',\n\t\t\t\t\t\t'tx_civserv_service_sv_position_mm.sorting, tx_civserv_employee_em_position_mm.sorting'\n\t\t\t\t\t\t);\t//ORDER BY\n\n\t\t//Query for search words\n\t\t$res_search_word = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t'tx_civserv_service.uid as suid,\n\t\t\t\t\t\t tx_civserv_search_word.uid as wuid,\n\t\t\t\t\t\t tx_civserv_service.sv_name as sname,\n\t\t\t\t\t\t tx_civserv_search_word.sw_search_word as sword',\n\t\t\t\t\t\t'tx_civserv_service,\n\t\t\t\t\t\t tx_civserv_search_word,\n\t\t\t\t\t\t tx_civserv_service_sv_searchword_mm',\n\t\t\t\t\t\t' tx_civserv_service.uid = ' . intval($uid) .\n\t\t\t\t\t\t $this->cObj->enableFields('tx_civserv_service').\n\t\t\t\t\t\t $this->cObj->enableFields('tx_civserv_search_word').\n\t\t\t\t\t\t' AND tx_civserv_service.uid = tx_civserv_service_sv_searchword_mm.uid_local\n\t\t\t\t\t\t AND tx_civserv_search_word.uid = tx_civserv_service_sv_searchword_mm.uid_foreign',\n\t\t\t\t\t\t'',\n\t\t\t\t\t\t'tx_civserv_search_word.sw_search_word'); //ORDER BY\n\n\t\t//Query for similar services\n\t\t\t//service has been checked already\n\t\t\t$temp_enablefields1 = str_replace('tx_civserv_service', 'service', $this->cObj->enableFields('tx_civserv_service'));\n#\t\t\tdebug($temp_enablefields1, '$temp_enablefields1');\n\n\t\t\t$temp_enablefields2 = str_replace('tx_civserv_service', 'similar', $this->cObj->enableFields('tx_civserv_service'));\n#\t\t\tdebug($temp_enablefields2, '$temp_enablefields2');\n\n\t\t// in case this is an external service the query must be asked differently!!!\n\t\t// this is still a building site\n\t\t$from= 'tx_civserv_service AS service,\n\t\t\t\t\t\t tx_civserv_service_sv_similar_services_mm AS mm,\n\t\t\t\t\t\t tx_civserv_service AS similar';\n\t\t$where= 'service.uid = mm.uid_local\n\t\t\t\t\t\t AND mm.uid_foreign = similar.uid\n\t\t\t\t\t\t AND service.uid = ' . intval($uid) . '\n\t\t\t\t\t\t AND service.uid != similar.uid '.\n\t\t\t\t\t\t $temp_enablefields1.\n\t\t\t\t\t $temp_enablefields2;\n\n\n\t\tif($service_common['typ'] == 'e'){\n\t\t\t$from .= ', tx_civserv_external_service';\n\t\t\t$where .= ' AND tx_civserv_external_service.es_external_service = similar.uid '.\n\t\t\t\t\t $this->cObj->enableFields('tx_civserv_external_service');\n\t\t}\n\n\n\t\t$res_similar = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t'DISTINCT similar.uid AS uid,\n\t\t\t\t\t\t similar.sv_name AS name,\n\t\t\t\t\t\t similar.fe_group',\n\t\t\t\t\t\t$from,\n\t\t\t\t\t\t$where,\n\t\t\t\t\t\t'',\t\t\t\t\t\t// GROUP BY\n\t\t\t\t\t\t'mm.sorting');\t\t\t// ORDER BY\n\t\t\t\t\t\t#'similar.sv_name');\t// ORDER BY\n\n\t\t//Retrieve all uid's of transaction forms from transaction configuration table\n\t\t$res_transactions = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t'ct_transaction_uid as uid',\n\t\t\t\t\t\t'tx_civserv_conf_transaction',\n\t\t\t\t\t\t'tx_civserv_conf_transaction.ct_community_id = ' . intval($community_id));\n\n\t\tif ($GLOBALS['TYPO3_DB']->sql_num_rows($res_common) == 0) {\n\t\t\t$GLOBALS['error_message'] = $this->pi_getLL('tx_civserv_pi1_service.error_valid','Service does not exist or is not available.');\n\t\t\treturn false;\n\t\t}\n\n\t\t$service_employees = $this->sql_fetch_array_r($res_employees);\n\n\t\t$row_counter = 0;\n\t\t$similar = array();\n\t\twhile ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_similar))\t{\n\t\t\t$similar[$row_counter]['link'] = htmlspecialchars($this->pi_linkTP_keepPIvars_url(array(mode => 'service',id => $row['uid']),$this->conf['cache_services'],1));\n\t\t\t$similar[$row_counter]['name'] = $row['name'];\n\t\t\t$similar[$row_counter]['fe_group'] = $row['fe_group'];\n\t\t\tif($GLOBALS['TSFE']->fe_user->user['uid'] > 0){\n\t\t\t\t$similar[$row_counter]['logged_in'] = 1;\n\t\t\t}\n\t\t\t$row_counter++;\n\t\t}\n\n\t\t//Add coloumns with url for email form and employee page to array $service_employees and format position description string\n\t\tfor ($i = 0; $i < count($service_employees); $i++) {\n\t\t\tif($service_employees[$i]['address']==2){\n\t\t\t\t$service_employees[$i]['address_long'] = $this->pi_getLL('tx_civserv_pi1_organisation.address_female', 'Ms.');\n\t\t\t}elseif($service_employees[$i]['address']==1){\n\t\t\t\t$service_employees[$i]['address_long'] = $this->pi_getLL('tx_civserv_pi1_organisation.address_male', 'Mr.');\n\t\t\t}\n\n\t\t\t// use typolink, because of the possibility to use encrypted email-adresses for spam-protection\n\t\t\t$service_employees[$i]['email_code'] = $this->cObj->typoLink($service_employees[$i]['ep_email']?$service_employees[$i]['ep_email']:$service_employees[$i]['em_email'],array(parameter => $service_employees[$i]['ep_email']?$service_employees[$i]['ep_email']:$service_employees[$i]['em_email'],ATagParams => 'class=\"email\"'));\t// use typolink, because of the possibility to use encrypted email-adresses for spam-protection\n\t\t\t$service_employees[$i]['email_form_url'] = htmlspecialchars($this->pi_linkTP_keepPIvars_url(array(mode => 'set_email_form',id => $service_employees[$i]['emp_uid'],sv_id => $service_employees[$i]['sv_uid'],pos_id => $service_employees[$i]['pos_uid']),1,1));\n\t\t\t$service_employees[$i]['employee_url'] = htmlspecialchars($this->pi_linkTP_keepPIvars_url(array(mode => 'employee',id => $service_employees[$i]['emp_uid'],pos_id => $service_employees[$i]['pos_uid']),1,1));\n\t\t\t// Disabled by design issues\n\t\t\t//$service_employees[$i]['description'] = $this->formatStr($this->local_cObj->stdWrap($service_employees[$i]['description'],$this->conf['ep_sv_description_stdWrap.']));\n\t\t\t$service_employees[$i]['description'] = nl2br($service_employees[$i]['description']);\n\t\t}\n\t\t$smartyService->assign('employees',$service_employees);\n\n\t\tif ($GLOBALS['TYPO3_DB']->sql_num_rows($res_transactions) > 0) {\n\t\t\t$service_transactions = $this->sql_fetch_array_r($res_transactions);\n\t\t} else {\n\t\t\t$service_transactions[0] = ''; //Create empty array for 'in_array'-function\n\t\t}\n\n\t\t$row_counter = 0;\n\t\twhile ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_forms) ) {\n\t\t\t$service_forms[$row_counter]['name'] = $row['name'];\n\t\t\t//Set correct url depending on type of associated form (transaction form, external form oder form file)\n\t\t\tif ($row['checkbox'] == 1 && in_array(array('uid' => intval($row['uid'])),$service_transactions)) {\n\t\t\t\t$service_forms[$row_counter]['url'] = $this->cObj->typoLink_URL(array(parameter => $row['url'])) . '&tx_civserv_pi1[id]=' . $uid;\n\t\t\t} elseif ($row['checkbox'] == 1) {\n\t\t\t\t$service_forms[$row_counter]['url'] = $this->cObj->typoLink_URL(array(parameter => $row['url']));\n\t\t\t} else {\n\t\t\t\t$service_forms[$row_counter]['url'] = $folder_forms.$row['file'];\n\t\t\t}\n\t\t\t$service_forms[$row_counter]['target'] = $row['target'];\n\t\t\t$row_counter++;\n\t\t}\n\t\t$smartyService->assign('forms',$service_forms);\n\n\t\t$row_counter = 0;\n\t\twhile ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_orga) ) {\n\t\t\t$service_organisations[$row_counter]['name'] = $row['name'];\n\t\t\t$service_organisations[$row_counter]['url'] = htmlspecialchars($this->pi_linkTP_keepPIvars_url(array(mode => 'organisation',id => $row['uid']),1,1));\n\t\t\t$row_counter++;\n\t\t}\n\t\t$smartyService->assign('organisations', $service_organisations);\n\n\t\twhile ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_search_word) ) {\n\t\t\t$search_words[] = $row['sword'];\n\t\t}\n\t\tif ($search_words > 0){\n\t\t\t$search_words = implode(\", \", $search_words);\n\t\t\t$smartyService->assign('searchwords',$search_words);\n\t\t}\n\n\t\t//Query for model service\n\t\tif ($service_common['sv_model_service'] > 0) {\n\t\t\t$res_model_service = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t'tx_civserv_model_service.ms_name,\n\t\t\t\t\t\t tx_civserv_model_service.ms_descr_short,\n\t\t\t\t\t\t tx_civserv_model_service.ms_descr_long,\n\t\t\t\t\t\t tx_civserv_model_service.ms_image,\n\t\t\t\t\t\t tx_civserv_model_service.ms_image_text,\n\t\t\t\t\t\t tx_civserv_model_service.ms_fees,\n\t\t\t\t\t\t tx_civserv_model_service.ms_documents,\n\t\t\t\t\t\t tx_civserv_model_service.ms_legal_global',\n\t\t\t\t\t\t'tx_civserv_model_service',\n\t\t\t\t\t\t'1 '.\n\t\t\t\t\t\t$this->cObj->enableFields('tx_civserv_model_service').\n\t\t\t\t\t\t' AND uid = ' . intval($service_common['sv_model_service']),\n\t\t\t\t\t\t'',\n\t\t\t\t\t\t'');\n\n\t\t\t$model_service = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res_model_service);\n\t\t}\n\n\t\t//Check for external service flag\n\t\tif ($service_common['sv_3rdparty_checkbox'] > 0) {\n\t\t\t$smartyService->assign('ext_link', $service_common['sv_3rdparty_link']);\n\t\t\t$smartyService->assign('ext_name', $service_common['sv_3rdparty_name']);\n\t\t}\n\n\t\t//Service name\n\t\tif ($service_common['sv_name'] != \"\") {\n\t\t\t$name = trim($service_common['sv_name']);\n\t\t\t// ATTENTION: Field-list is hardcoded, because there are problems with the image because of the upload folder\n\t\t\t$name = $this->pi_getEditIcon($name,\t'fe_admin_fieldList\" => \"hidden,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t starttime,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t endtime,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t fe_group,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_name,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_synonym1,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_synonym2,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_synonym3,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_descr_short,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_descr_long,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_fees,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_documents,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_legal_local,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_legal_global,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_model_service,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_similar_services,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_service_version,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_form,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_searchword,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_position,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_organisation,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_navigation,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_3rdparty_checkbox,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_3rdparty_link,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t sv_3rdparty_name',\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $this->pi_getLL('tx_civserv_pi1_service.name','Service name'),\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t $service_common,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t 'tx_civserv_service'\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t);\n\t\t} else {\n\t\t\t$name = trim($model_service['ms_name']);\n\t\t}\n\t\t$smartyService->assign('name',$name);\n\n\t\t//Short description\n\t\tif ($service_common['sv_descr_short'] != \"\") {\n\t\t\t$descr_short = trim($service_common['sv_descr_short']);\n\t\t\t$descr_short = $this->pi_getEditIcon($descr_short,'sv_descr_short',$this->pi_getLL('tx_civserv_pi1_service.description_short','short description'),$service_common,'tx_civserv_service');\n\t\t} else {\n\t\t\t$descr_short = trim($model_service['ms_descr_short']);\n\t\t}\n\t\t$smartyService->assign('descr_short',$this->formatStr($this->local_cObj->stdWrap($descr_short,$this->conf['sv_descr_short_stdWrap.'])));\n\n\t\t//Long description\n\t\t$descr_long_ms = '';\n\t\tif ($model_service['ms_descr_long'] != \"\") {\n\t\t\t$descr_long_ms = trim($model_service['ms_descr_long']) . '<br />';\n\t\t}\n\t\t$descr_long = trim($service_common['sv_descr_long']);\n\t\t$descr_long = $this->pi_getEditIcon($descr_long,'sv_descr_long',$this->pi_getLL('tx_civserv_pi1_service.description_long','Long description'),$service_common,'tx_civserv_service');\n\t\t$descr_long = $descr_long_ms . $descr_long;\n\t\t$smartyService->assign('descr_long',$this->formatStr($this->local_cObj->stdWrap($descr_long,$this->conf['sv_descr_long_stdWrap.'])));\n\n\t\t//Image text\n\t\tif ($service_common['sv_image_text'] != \"\") {\n\t\t\t$image_text = trim($service_common['sv_image_text']);\n\t\t} else {\n\t\t\t$image_text = trim($model_service['ms_image_text']);\n\t\t}\n\t\t$image_descr = $this->pi_getEditIcon($image_text,'image_text',$this->pi_getLL('tx_civserv_pi1_service.image_text','Image description'),$service_common,'tx_civserv_service');\n\t\t$smartyService->assign('image_text',$image_descr);\n\n\t\t//Image\n\t\tif ($service_common['sv_image'] != \"\") {\n\t\t\t$image = $service_common['sv_image'];\n\t\t\t$imagepath = $this->conf['folder_organisations'] . $service_community . '/images/';\n\t\t} else {\n\t\t\t$image = $model_service['ms_image'];\n\t\t\t$imagepath = $this->conf['folder_organisations'] . 'model_services/images/';\n\t\t}\n\t\tif ($image) {\n\t\t\t$imageCode = $this->getImageCode($image,$imagepath,$this->conf['service-image.'],$image_text);\n\t\t}\n\t\t$smartyService->assign('image',$imageCode);\n\n\t\t//Fees\n\t\tif ($service_common['sv_fees'] != \"\") {\n\t\t\t$fees = trim($service_common['sv_fees']);\n\t\t\t$fees = $this->pi_getEditIcon($fees,'sv_fees',$this->pi_getLL('tx_civserv_pi1_service.description_fees','Fees'),$service_common,'tx_civserv_service');\n\t\t} else {\n\t\t\t$fees = trim($model_service['ms_fees']);\n\t\t}\n\t\t//test bk: support htmlarea in not desplaying empty labels; todo: transmit this to other sections!!!\n\t\tif(strip_tags($fees) > '' && strip_tags($documents) != '&nbsp;'){\n\t\t\t$smartyService->assign('fees',$this->formatStr($this->local_cObj->stdWrap($fees,$this->conf['sv_fees_stdWrap.'])));\n\t\t}\n\n\t\t//Documents\n\t\tif ($service_common['sv_documents'] != \"\") {\n\t\t\t$documents = trim($service_common['sv_documents']);\n\t\t\t$documents = $this->pi_getEditIcon($documents,'sv_documents',$this->pi_getLL('tx_civserv_pi1_service.description_documents','Necessary Documents'),$service_common,'tx_civserv_service');\n\t\t} else {\n\t\t\t$documents = trim($model_service['ms_documents']);\n\t\t}\n\t\tif(strip_tags($documents) > '' && strip_tags($documents) != '&nbsp;'){\n\t\t\t$smartyService->assign('documents',$this->formatStr($this->local_cObj->stdWrap($documents,$this->conf['sv_documents_general_stdWrap.'])));\n\t\t}\n\n\t\t//Legal local\n\t\t$legal_local = $this->pi_getEditIcon($service_common['sv_legal_local'],'sv_legal_local',$this->pi_getLL('tx_civserv_pi1_service.legal_local','Legal foundation (local)'),$service_common,'tx_civserv_service');\n\t\t$smartyService->assign('legal_local',$this->formatStr($this->local_cObj->stdWrap($legal_local,$this->conf['sv_legel_local_general_stdWrap.'])));\n\n\t\t//Legal global\n\t\tif ($service_common['sv_legal_global'] != \"\") {\n\t\t\t$legal_global = trim($service_common['sv_legal_global']);\n\t\t\t$legal_global = $this->pi_getEditIcon($legal_global,'sv_legal_global',$this->pi_getLL('tx_civserv_pi1_service.legal_global','Legal foundation (global)'),$service_common,'tx_civserv_service');\n\t\t} else {\n\t\t\t$legal_global = trim($model_service['ms_legal_global']);\n\t\t}\n\t\t$smartyService->assign('legal_global',$this->formatStr($this->local_cObj->stdWrap($legal_global,$this->conf['sv_legal_global_general_stdWrap.'])));\n\n\t\t//Similar services\n\t\tif ($this->conf['relatedTopics']) {\n\t\t\t$smartyService->assign('related_topics', $similar);\n\t\t} else {\n\t\t\t$smartyService->assign('similar_services', $similar);\n\t\t}\n\n\n\t\t// Check if this service is subject to restricted fe_user access\n\t\t$smartyService->assign('fe_group', $service_common['fe_group']);\n\n\n\t\t//Assign template labels\n\t\t$smartyService->assign('service_label',$this->pi_getLL('tx_civserv_pi1_service.service','Service'));\n\t\t$smartyService->assign('ext_service_label',$this->pi_getLL('tx_civserv_pi1_service.ext_service','This is an external service offered by'));\n\t\t$smartyService->assign('description_label',$this->pi_getLL('tx_civserv_pi1_service.description','Description'));\n\t\t$smartyService->assign('fees_label',$this->pi_getLL('tx_civserv_pi1_service.fees','Fees'));\n\t\t$smartyService->assign('documents_label',$this->pi_getLL('tx_civserv_pi1_service.documents','Necessary documents'));\n\t\t$smartyService->assign('forms_label',$this->pi_getLL('tx_civserv_pi1_service.forms','Forms'));\n\t\t$smartyService->assign('legal_label',$this->pi_getLL('tx_civserv_pi1_service.legal','Legal foundation'));\n\t\t$smartyService->assign('legal_local_label',$this->pi_getLL('tx_civserv_pi1_service.legal_local','Legal foundation (local)'));\n\t\t$smartyService->assign('legal_global_label',$this->pi_getLL('tx_civserv_pi1_service.legal_global','Legal foundation (general)'));\n\t\t$smartyService->assign('organisation_label',$this->pi_getLL('tx_civserv_pi1_service.organisation','Responsible organisational unit(s)'));\n\t\tif(count($service_employees)==1){\n\t\t\tif($service_employees[0]['address']==2){\n\t\t\t\t$smartyService->assign('contact_label',$this->pi_getLL('tx_civserv_pi1_service.contact_female','Contact person'));\n\t\t\t}else{\n\t\t\t\t$smartyService->assign('contact_label',$this->pi_getLL('tx_civserv_pi1_service.contact_male','Contact person'));\n\t\t\t}\n\t\t}else{\n\t\t\t$smartyService->assign('contact_label',$this->pi_getLL('tx_civserv_pi1_service.contact_plural','Contact persons'));\n\t\t}\n\t\t$smartyService->assign('employee_details',$this->pi_getLL('tx_civserv_pi1_organisation.employee_details','Jumps to a page with details of this employee'));\n\t\t$smartyService->assign('similar_services_label',$this->pi_getLL('tx_civserv_pi1_service.similar_services','Similar services'));\n\t\t$smartyService->assign('phone_label',$this->pi_getLL('tx_civserv_pi1_organisation.phone','Phone'));\n\t\t$smartyService->assign('email_label',$this->pi_getLL('tx_civserv_pi1_organisation.email','E-Mail'));\n\t\t$smartyService->assign('web_email_label',$this->pi_getLL('tx_civserv_pi1_organisation.web_email','E-Mail-Form'));\n\t\t$smartyService->assign('subnavigation_label',$this->pi_getLL('tx_civserv_pi1_service.subnavigation','Sub-navigation'));\n\t\t$smartyService->assign('link_to_section',$this->pi_getLL('tx_civserv_pi1_service.link_to_section','Jump label to section'));\n\t\t$smartyService->assign('serviceinformation_label',$this->pi_getLL('tx_civserv_pi1_common.serviceinformation','Service information'));\n\t\t$smartyService->assign('pages_related_topics_label',$this->pi_getLL('tx_civserv_pi1_service.pages_related_topics','Pages with related topics'));\n\t\t$smartyService->assign('top',$this->pi_getLL('tx_civserv_pi1_service.top','Top of page'));\n\t\t$smartyService->assign('link_to_top',$this->pi_getLL('tx_civserv_pi1_service.link_to_top','Jump label to the beginning of this page'));\n\n\t\tif ($searchBox) {\n\t\t\t//$_SERVER['REQUEST_URI'] = $this->pi_linkTP_keepPIvars_url(array(mode => 'search_result'),0,1); //dropped this according to instructions from security review\n\t\t\t$smartyService->assign('searchbox', $this->pi_list_searchBox('',true));\n\t\t}\n\n\t\tif ($topList) {\n\t\t\tif (!$this->calculate_top15($smartyService,false,$this->conf['topCount'])) {\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}\n\n\t\t//Access log for most frequently requested services\n\t\t//Get logging interval from configuration table\n\t\t$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery(\n\t\t\t\t\t\t'cf_value',\n\t\t\t\t\t\t'tx_civserv_configuration',\n\t\t\t\t\t\t'cf_module = \"accesslog\" AND cf_key = \"log_interval\"',\n\t\t\t\t\t\t'',\n\t\t\t\t\t\t'',\n\t\t\t\t\t\t'');\n\t\t$row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res);\n\t\t$log_interval = intval($row['cf_value']);\n\t\t$accesslog = t3lib_div::makeInstance('tx_civserv_accesslog');\n\t\t$accesslog->update_log($uid,$log_interval, long2ip(ip2long($_SERVER['REMOTE_ADDR'])));\n\n\t\t//Title for the Indexed Search Engine\n\t\t$GLOBALS['TSFE']->indexedDocTitle = $service_common['sv_name'];\n\t\t$GLOBALS['TSFE']->page['title']=$this->pi_getLL('tx_civserv_pi1_service.service','Service').\": \".$name;\n\t\treturn true;\n\t}", "public function listGroups()\n {\n\t\t$data = $this->call(array(), \"GET\", \"groups.json\");\n\t\t$data = $data->{'groups'};\n\t\t$groupArray = new ArrayObject();\n\t\tfor($i = 0; $i<count($data);$i++){\n\t\t\t$groupArray->append(new Group($data[$i], $this));\n\t\t}\n\t\treturn $groupArray;\n }", "function create_todos_groups(){\t\t\n\t\t$groups = array( 'master' => array() );\n\t\t$groups_str = array();\n\n\t\t//creating grounps or master group\n\t\tforeach ($this->get_bvars() as $key => $value) {\n\t\t\t$match = array();\n\t\t\tif( preg_match( '/group_(.*)/', $key, $match ) ){\n\t\t\t\t$groups[$match[1]] = array();\n\t\t\t\t$groups_str[] = $match[1];\n\t\t\t\tforeach ($this->bvars as $key2 => $value2) {\n\t\t\t\t\t$match2 = array();\n\t\t\t\t\tif ( preg_match( '/pa_' . $match[1] . '_(.*)/', $key2, $match2 ) ) {\n\n\t\t\t\t\t\t/*\n\t\t\t\t\t\t* 1st level \n\t\t\t\t\t\t* Checking if exact attr name class exists\n\t\t\t\t\t\t */\t\t\t\t\t\t\n\t\t\t\t\t\t\n\t\t\t\t\t\tif ( class_exists( '\\gcalc\\pa\\\\' . $match2[0] ) ) {\n\t\t\t\t\t\t\t$class_name = $match2[0];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t/*\n\t\t\t\t\t\t\t* 2nd level\n\t\t\t\t\t\t\t* master process class\n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\t$class_name = str_replace( $match[1] . '_', '', $match2[0] );\n\t\t\t\t\t\t\t$pa_class_name = '\\gcalc\\pa\\\\' . $class_name;\n\t\t\t\t\t\t\tif ( !class_exists( $pa_class_name ) ) {\n\t\t\t\t\t\t\t\tif ( class_exists( '\\gcalc\\pa\\\\' . $key2 ) ) {\n\t\t\t\t\t\t\t\t\t$class_name = $key2;\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\t\n\t\t\t\t\t\t$groups[ $match[ 1 ] ][ $key2 ]['class_name'] = $class_name;\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t}\t\t\t\t\n\t\t\t} \n\t\t}\n\n\t\t/*\n\t\t* Master group\n\t\t*/\n\t\t$groups_str = implode( '|', $groups_str );\n\t\tforeach ($this->bvars as $key => $value){\n\t\t\tif( ! preg_match( '/pa_['. $groups_str .')]{2,}(.*)/', $key) \n\t\t\t\t&& ! preg_match('/group_|apikey|apisecret|Authorization/', $key) \n\n\t\t\t){\n\t\t\t\t$class_name = $key;\n\t\t\t\t$groups[ 'master' ][$key]['class_name'] = $class_name;\t\t\t\t\n\t\t\t} \n\t\t}\n\n\n\n\t\t$this->todo_groups = $groups;\t\t\n\t}", "function getSiteList($service)\n{\n\t$siteList = $service->webResource->listWebResource();\n\t\n\t$siteArray = array();\n\t\n\tforeach ($siteList->getItems() as $siteItem)\n\t{\n\t\t#array_push($siteArray, $siteItem->id);\n\t\tarray_push($siteArray, $siteItem);\n\t}\n\t\t\n\t#print_r($siteArray)\t;\n\treturn($siteArray);\n}", "function check_membership($hostname='', $servicename='', $servicegroup_name='')\n{\n\tglobal $NagiosData;\n\t$hostgroups_objs = $NagiosData->getProperty('hostgroups_objs');\n\t$servicegroups_objs = $NagiosData->getProperty('servicegroups_objs');\n\n\t$hostname = trim($hostname);\n\t$servicename = trim($servicename);\n\t$servicegroup_name = trim($servicegroup_name);\n\n\t$memberships = array();\n\tif($hostname!='' && $servicename!='')\n\t{\n\t\t//search servicegroups array \n\t\t\n\t\t//create regexp string for 'host,service'\n\t\t$hostservice = \"$hostname,$servicename\";\n\t\t$hostservice_regex = preg_quote($hostservice, '/');\n\n\t\t//check regex against servicegroup 'members' index \n\t\tif ($servicegroup_name!='' && isset($servicegroups_objs[$servicegroup_name])) {\n\t\t\t$group = $servicegroups_objs[$servicegroup_name];\n\t\t\tif (preg_match(\"/$hostservice_regex/\", $group['members'])) {\n\t\t\t\t$str = isset($group['alias']) ? $group['alias'] : $group['servicegroup_name']; \n\t\t\t\t$memberships[] = $str;\n\t\t\t}\n\n\t\t} else {\n\t\t\tforeach($servicegroups_objs as $group)\n\t\t\t{\n\t\t\t\tif(isset($group['members']) && preg_match(\"/$hostservice_regex/\", $group['members']))\n\t\t\t\t{\n\t\t\t\t\t//use alias as default display name, else use groupname \n\t\t\t\t\t$str = isset($group['alias']) ? $group['alias'] : $group['servicegroup_name']; \n\t\t\t\t\t$memberships[] = $str;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\t\n\t//check for host membership \n\telseif($hostname!='' && $servicename=='')\n\t{\n\t\n\t\t$hostname_regex = preg_quote($hostname, '/');\n\t\tforeach($hostgroups_objs as $group)\n\t\t{\n\t\t\tif(isset($group['members']) && preg_match(\"/$hostname_regex/\", $group['members']))\n\t\t\t{\n\t\t\t\t//use alias as default display name, else use groupname \n\t\t\t\t$str = isset($group['alias']) ? $group['alias'] : $group['hostgroup_name'];\n\t\t\t\t$memberships[] = $str;\n\t\t\t}\n\t\t}\n\t}\n\t \n return empty($memberships) ? NULL : join(' ', $memberships);\n}", "function draw_servicestatus_table()\n{ $meta_pref_option = 'servicestatus_table_options';\n\n // defaults\n //$sortby=\"host_name:a,service_description\";\n $sortby = \"\";\n $sortorder = \"asc\";\n $page = 1;\n $records = 15;\n $search = \"\";\n\n // default to use saved options\n $s = get_user_meta(0, $meta_pref_option);\n $saved_options = unserialize($s);\n if (is_array($saved_options)) {\n if (isset($saved_options[\"sortby\"]))\n $sortby = $saved_options[\"sortby\"];\n if (isset($saved_options[\"sortorder\"]))\n $sortorder = $saved_options[\"sortorder\"];\n if (isset($saved_options[\"records\"]))\n $records = $saved_options[\"records\"];\n //if(array_key_exists(\"search\",$saved_options))\n //$search=$saved_options[\"search\"];\n }\n //echo \"SAVED OPTIONS: \";\n //print_r($saved_options);\n\n // grab request variables\n $show = grab_request_var(\"show\", \"services\");\n $host = grab_request_var(\"host\", \"\");\n $hostgroup = grab_request_var(\"hostgroup\", \"\");\n $servicegroup = grab_request_var(\"servicegroup\", \"\");\n $hostattr = grab_request_var(\"hostattr\", 0);\n $serviceattr = grab_request_var(\"serviceattr\", 0);\n $hoststatustypes = grab_request_var(\"hoststatustypes\", 0);\n $servicestatustypes = grab_request_var(\"servicestatustypes\", 0);\n\n // fix for \"all\" options\n if ($hostgroup == \"all\")\n $hostgroup = \"\";\n if ($servicegroup == \"all\")\n $servicegroup = \"\";\n if ($host == \"all\")\n $host = \"\";\n\n $sortby = grab_request_var(\"sortby\", $sortby);\n $sortorder = grab_request_var(\"sortorder\", $sortorder);\n $records = grab_request_var(\"records\", $records);\n $page = grab_request_var(\"page\", $page);\n $search = trim(grab_request_var(\"search\", $search));\n if ($search == _(\"Search...\"))\n $search = \"\";\n\n // save options for later\n $saved_options = array(\n \"sortby\" => $sortby,\n \"sortorder\" => $sortorder,\n \"records\" => $records,\n //\"search\" => $search\n );\n $s = serialize($saved_options);\n set_user_meta(0, $meta_pref_option, $s, false);\n\n\n $output = '';\n\n $output .= \"<form action='\" . get_base_url() . \"includes/components/xicore/status.php'>\";\n $output .= \"<input type='hidden' name='show' value=\\\"\" . encode_form_val($show) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='sortby' value=\\\"\" . encode_form_val($sortby) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='sortorder' value=\\\"\" . encode_form_val($sortorder) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='host' value=\\\"\" . encode_form_val($host) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='hostgroup' value=\\\"\" . encode_form_val($hostgroup) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='servicegroup' value=\\\"\" . encode_form_val($servicegroup) . \"\\\">\\n\";\n\n $output .= '<div class=\"servicestatustablesearch\">';\n\n $output .= '\n <input type=\"text\" size=\"15\" name=\"search\" id=\"hostsearchBox\" value=\"\" class=\"form-control condensed\" placeholder=\"'._('Search').'...\">\n <button type=\"submit\" class=\"btn btn-xs btn-default\" name=\"searchButton\" id=\"searchButton\"><i class=\"fa fa-search\"></i></button>\n </div>\n </form>';\n\n // ajax updater args\n $ajaxargs = array();\n $ajaxargs[\"host\"] = $host;\n $ajaxargs[\"hostgroup\"] = $hostgroup;\n $ajaxargs[\"servicegroup\"] = $servicegroup;\n $ajaxargs[\"sortby\"] = $sortby;\n $ajaxargs[\"sortorder\"] = $sortorder;\n $ajaxargs[\"records\"] = $records;\n $ajaxargs[\"page\"] = $page;\n $ajaxargs[\"search\"] = $search;\n $ajaxargs[\"hostattr\"] = $hostattr;\n $ajaxargs[\"serviceattr\"] = $serviceattr;\n $ajaxargs[\"hoststatustypes\"] = $hoststatustypes;\n $ajaxargs[\"servicestatustypes\"] = $servicestatustypes;\n\n $id = \"servicestatustable_\" . random_string(6);\n\n $output .= \"<div class='servicestatustable' id='\" . $id . \"'>\\n\";\n $output .= get_throbber_html();\n $output .= \"</div>\";\n\n // build args for javascript\n $n = 0;\n $jargs = \"{\";\n foreach ($ajaxargs as $var => $val) {\n if ($n > 0)\n $jargs .= \", \";\n $jargs .= \"\\\"\" . encode_form_val($var) . \"\\\" : \\\"\" . encode_form_val($val) . \"\\\"\";\n $n++;\n }\n $jargs .= \"}\";\n\n // ajax updater\n $output .= '\n <script type=\"text/javascript\">\n $(document).ready(function(){\n \n get_' . $id . '_content();\n \n $(\"#' . $id . '\").everyTime(30*1000, \"timer-' . $id . '\", function(i) {\n get_' . $id . '_content();\n });\n \n function get_' . $id . '_content(){\n $(\"#' . $id . '\").each(function(){\n var optsarr = {\n \"func\": \"get_servicestatus_table\",\n \"args\": ' . $jargs . '\n }\n var opts=array2json(optsarr);\n get_ajax_data_innerHTML(\"getxicoreajax\",opts,true,this);\n });\n }\n\n });\n </script>\n ';\n\n //return $output;\n echo $output;\n}", "public function getAllServiceItems()\n {\n $qbo = $this->container->get(\"numa.quickbooks\")->init();\n\n $ItemService = new \\QuickBooks_IPP_Service_Item();\n\n $qbItems = $ItemService->query($qbo->getContext(), $qbo->getRealm(), \"SELECT * FROM Item WHERE type='service' ORDER BY name \");\n $r = array();\n foreach ($qbItems as $item) {\n $r[$item->getName()] = $item->getName();\n }\n\n return $r;\n }", "public function retrieveGroups()\n {\n return $this->start()->uri(\"/api/group\")\n ->get()\n ->go();\n }", "function get_group_array()\n{\n\tglobal $db_raid, $table_prefix, $db_raid;\n\tglobal $db_allgroups_id, $db_allgroups_name, $db_table_allgroups ;\n\n\t$group = array();\n\t\n\t$sql = sprintf(\"SELECT \" . $db_allgroups_id . \" , \". $db_allgroups_name .\n\t\t\t\" FROM \" . $table_prefix . $db_table_allgroups .\n\t\t\t\" ORDER BY \". $db_allgroups_id);\n\t\n\t$result_group = $db_raid->sql_query($sql) or print_error($sql, $db_raid->sql_error(), 1);\n\twhile ($data_wrm = $db_raid->sql_fetchrow($result_group,true))\n\t{\n\t\t$group[$data_wrm[$db_allgroups_id]] = $data_wrm[$db_allgroups_name];\n\t}\n\n\treturn $group;\n}", "public function ADStaff_Get_Group_List(){\n\t \n\t $result_key = parent::Initial_Result('groups');\n\t $result = &$this->ModelResult[$result_key];\n\t \n\t try{\n\t\t// 查詢資料庫\n\t\t$DB_OBJ = $this->DBLink->prepare(parent::SQL_Permission_Filter(SQL_AdStaff::SELECT_GROUP_LIST()));\n\t\tif(!$DB_OBJ->execute()){\n\t\t throw new Exception('_SYSTEM_ERROR_DB_ACCESS_FAIL'); \n\t\t}\n\t\t$groups = $DB_OBJ->fetchAll(PDO::FETCH_ASSOC);\n\t\t$result['action'] = true;\t\t\n\t\t$result['data'] = $groups;\t\t\n\t } catch (Exception $e) {\n $result['message'][] = $e->getMessage();\n }\n\t return $result;\n\t}", "public function index()\n\t{\n\n//\t\t$selected = $this->getSelectedServices();\n//\n//\t\t$services = [];\n//\t\t$service_cats = ServiceCategories::where('parent_id', 0)->with('childs.services')->get();\n//\n//\t\t$service_cats->each(function ($categoryData) use (&$services, $selected) {\n//\t\t\t$sub_result = [];\n//\t\t\t$categoryData->childs()->each(function ($subCatData) use (&$sub_result, $selected) {\n//\t\t\t\t$sub_result[$subCatData->name] = [\n//\t\t\t\t\t'is_extra' => !!$subCatData->is_extra,\n//\t\t\t\t\t'name' => $subCatData->name,\n//\t\t\t\t\t'data' => []\n//\t\t\t\t];\n//\n//\t\t\t\t$t = [];\n//\t\t\t\t$subCatData->services()->each(function ($serviceData) use ($subCatData, &$sub_result, $selected) {\n//\t\t\t\t\t$sub_result[$subCatData->name]['data'][] = [\n//\t\t\t\t\t\t'id' => (string)$serviceData->id,\n//\t\t\t\t\t\t'name' => $serviceData->name,\n//\t\t\t\t\t\t'limit' => $serviceData->limit,\n//\t\t\t\t\t\t'prices_number' => $serviceData->prices_number,\n//\t\t\t\t\t\t'sub' => $serviceData->subs()->get(),\n//\t\t\t\t\t\t'my_price' => collect($selected->where('id', $serviceData->id)->first())->only(['pivot'])->first()\n//\t\t\t\t\t];\n//\t\t\t\t});\n//\n//\t\t\t});\n//\t\t\t$services[] = [\n//\t\t\t\t'id' => (string)$categoryData->id,\n//\t\t\t\t'text' => $categoryData->name,\n//\t\t\t\t'additional' => $sub_result\n//\t\t\t];\n//\t\t});\n\n\t\t$services = $this->loadServicesData();\n\n\t\treturn view('admin.services.index', compact('services'));\n\n\t}", "public function viewservice(){\n\t\t\tif(isset($this->service_id)){\n\t\t\t\t $this->sql=\"SELECT * FROM tbl_service WHERE service_id='$this->service_id'\";\n\t\t\t\t\n\t\t\t}else{\n\t\t\t$this->sql=\"SELECT * FROM tbl_service ORDER BY service_id DESC\";\n\t\t\t\n\t\t\t}\n\t\t\t$this->res=mysqli_query($this->conxn,$this->sql) or trigger_error($this->err=mysqli_error($this->conxn));\n\t\t\t$this->numRows=mysqli_num_rows($this->res);// or trigger_error($this->err=mysqli_error($this->conxn));\n\t\t\t$this->data=array();\n\t\t\t\n\t\t\tif($this->numRows>0){\n\t\t\t\twhile($this->row=mysqli_fetch_assoc($this->res)){\n\t\t\t\t\tarray_push($this->data,$this->row);\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t}\n\t\treturn $this->data;\n\t\t\n}", "public static function getGroupList() {\n $params = $_GET;\n if (isset($params['parent_id'])) {\n // requesting child groups for a given parent\n $params['page'] = 1;\n $params['rp'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n else {\n $requiredParams = [];\n $optionalParams = [\n 'title' => 'String',\n 'created_by' => 'String',\n 'group_type' => 'String',\n 'visibility' => 'String',\n 'component_mode' => 'String',\n 'status' => 'Integer',\n 'parentsOnly' => 'Integer',\n 'showOrgInfo' => 'Boolean',\n 'savedSearch' => 'Integer',\n // Ignore 'parent_id' as that case is handled above\n ];\n $params = CRM_Core_Page_AJAX::defaultSortAndPagerParams();\n $params += CRM_Core_Page_AJAX::validateParams($requiredParams, $optionalParams);\n\n // get group list\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n\n // if no groups found with parent-child hierarchy and logged in user say can view child groups only (an ACL case),\n // go ahead with flat hierarchy, CRM-12225\n if (empty($groups)) {\n $groupsAccessible = CRM_Core_PseudoConstant::group();\n $parentsOnly = $params['parentsOnly'] ?? NULL;\n if (!empty($groupsAccessible) && $parentsOnly) {\n // recompute group list with flat hierarchy\n $params['parentsOnly'] = 0;\n $groups = CRM_Contact_BAO_Group::getGroupListSelector($params);\n }\n }\n\n //NYSS 5259 convert line breaks to html\n foreach ( $groups['data'] as &$group ) {\n $group['description'] = str_replace('\\r\\n', '\\n', $group['description']);\n $group['description'] = str_replace('\\r', '\\n', $group['description']);\n $group['description'] = str_replace('\\n', '<br />', $group['description']);\n } \n }\n\n CRM_Utils_JSON::output($groups);\n }", "public function getCustomerGroups();", "public function parseService( $service_package );", "public function getServiceIDSOfGroup($serviceGroupID, $sorted = false): array\n {\n $services = [];\n foreach ($this->serviceEntries as $serviceEntry) {\n if ($serviceEntry->getServiceGroupID() == $serviceGroupID) {\n $id = $serviceEntry->getID();\n $order = $serviceEntry->getSortKey();\n $services[$id] = $order;\n }\n }\n if ($sorted) {\n asort($services);\n }\n return array_keys($services);\n }" ]
[ "0.7273374", "0.6778936", "0.6749087", "0.6406331", "0.62079006", "0.6124561", "0.59665525", "0.59389305", "0.59389305", "0.5936661", "0.5882174", "0.5875401", "0.58657116", "0.5856064", "0.58487016", "0.58009297", "0.5778471", "0.5732113", "0.5716035", "0.5713535", "0.56948304", "0.5686499", "0.56815195", "0.56740105", "0.56707895", "0.5668116", "0.56383055", "0.56383055", "0.5621682", "0.56177944", "0.5590399", "0.55601966", "0.55559945", "0.5545303", "0.55323535", "0.55197805", "0.55197805", "0.5519641", "0.5517772", "0.5514625", "0.55137277", "0.54953694", "0.54953694", "0.54918146", "0.54839635", "0.5478538", "0.54747087", "0.54680246", "0.5463152", "0.54520965", "0.5450972", "0.54478", "0.54370046", "0.5429664", "0.5425725", "0.5395286", "0.5394717", "0.5390444", "0.5384841", "0.5382843", "0.5381239", "0.53782696", "0.5377386", "0.5365556", "0.5360182", "0.5356309", "0.53556067", "0.53518313", "0.53463316", "0.5345971", "0.5343622", "0.53422195", "0.53380114", "0.5329745", "0.53266996", "0.53266996", "0.53258854", "0.5325318", "0.53180844", "0.5306988", "0.5299227", "0.5290797", "0.52907604", "0.5290739", "0.5286411", "0.5283777", "0.52765113", "0.52721715", "0.5265612", "0.5257231", "0.52545124", "0.52409834", "0.52384096", "0.5232036", "0.5231565", "0.52214104", "0.52188843", "0.52164763", "0.52054113", "0.52052295" ]
0.802006
0
/ Preprocess all of the data for hostgroups display/output
function get_hostgroup_data() { global $NagiosData; global $NagiosUser; $hostgroups = $NagiosData->getProperty('hostgroups'); $hosts = $NagiosData->getProperty('hosts'); $hostgroup_data = array(); foreach ($hostgroups as $group => $members) { $hostgroup_data[$group] = array( 'member_data' => array(), 'host_counts' => get_state_of('hosts', build_hostgroup_details($members)), 'service_counts' => get_state_of('services', build_host_servicegroup_details($members)) ); //skip ahead if there are no authorized hosts if(array_sum($hostgroup_data[$group]['host_counts'])==0) continue; //skip empty groups foreach ($members as $member) { if(!$NagiosUser->is_authorized_for_host($member)) continue; //user-level filtering $host = $hosts[$member]; process_host_status_keys($host); $hostgroup_data[$group]['member_data'][$member]['host_name'] = $host['host_name']; $hostgroup_data[$group]['member_data'][$member]['host_state'] = $host['current_state']; $hostgroup_data[$group]['member_data'][$member]['state_class'] = get_color_code($host); $hostgroup_data[$group]['member_data'][$member]['services'] = array(); $hostgroup_data[$group]['member_data'][$member]['host_url'] = BASEURL.'index.php?type=hostdetail&name_filter='.urlencode($host['host_name']); if (isset($host['services'])) { foreach($host['services'] as $service) { if(!$NagiosUser->is_authorized_for_service($member,$service['service_description'])) continue; //user-level filtering process_service_status_keys($service); $service_data = array( 'state_class' => get_color_code($service), 'description' => $service['service_description'], 'service_url' => htmlentities(BASEURL.'index.php?type=servicedetail&name_filter='.$service['service_id']), ); $hostgroup_data[$group]['member_data'][$member]['services'][] = $service_data; } } } } return $hostgroup_data; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function preprocessData() {}", "function build_hostgroup_details($group_members) //make this return the totals array for hosts and services \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t\n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n//\t//add filter for user-level filtering \n//\tif(!$NagiosUser->is_admin()) {\n\t\t//print $type; \n//\t\t$hosts = user_filtering($hosts,'hosts'); \t\n//\t}\n\n\t$hostgroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t\t$hostgroup_details[] = $hosts[$member];\n\t}\n\n\treturn $hostgroup_details;\n}", "private function organize_data(){\n\t\t$this->grab_data();\n\t\t$this->adjust_graph_dimensions();\n\t\t$this->draw_graphs();\n\t\t$this->draw_axes();\n\t\treturn;\n\t}", "function process_host_disp($desmhash, $summary_data_array, $dev_data_array)\n{\n global $data_totals;\n global $config;\n\n $devs = $activedevs = $max_temp = $fivesmhash = $fivesmhashper = $avgmhper = 0;\n $fivesmhashcol = $avgmhpercol = $rejectscol = $discardscol = $stalescol = $getfailscol = $remfailscol = \"\";\n $rejects = $discards = $stales = $getfails = $remfails = '---';\n $row = \"\";\n\n if ($summary_data_array != null)\n {\n if ($dev_data_array != null)\n $devs = process_host_devs($dev_data_array, $activedevs, $fivesmhash, $max_temp);\n\n $thisstatus = $summary_data_array['STATUS'][0]['STATUS'];\n $avgmhash = $summary_data_array['SUMMARY'][0]['MHS av'];\n $accepted = $summary_data_array['SUMMARY'][0]['Accepted'];\n $rejected = $summary_data_array['SUMMARY'][0]['Rejected'];\n $discarded = $summary_data_array['SUMMARY'][0]['Discarded'];\n $stale = $summary_data_array['SUMMARY'][0]['Stale'];\n $getfail = $summary_data_array['SUMMARY'][0]['Get Failures'];\n $remfail = $summary_data_array['SUMMARY'][0]['Remote Failures'];\n $utility = $summary_data_array['SUMMARY'][0]['Utility'];\n\n if (isset($accepted) && $accepted !== 0)\n {\n $rejects = round(100 / $accepted * $rejected, 1) . \" %\";\n $discards = round(100 / $accepted * $discarded,1) . \" %\";\n $stales = round(100 / $accepted * $stale, 1) . \" %\";\n $getfails = round(100 / $accepted * $getfail, 1) . \" %\";\n $remfails = round(100 / $accepted * $remfail, 1) . \" %\";\n \n $rejectscol = set_color_high($rejects, $config->yellowrejects, $config->maxrejects); // Rejects\n $discardscol = set_color_high($discards, $config->yellowdiscards, $config->maxdiscards); // Discards\n $stalescol = set_color_high($stales, $config->yellowstales, $config->maxstales); // Stales\n $getfailscol = set_color_high($getfails, $config->yellowgetfails, $config->maxgetfails); // Get fails\n $remfailscol = set_color_high($remfails, $config->yellowremfails, $config->maxremfails); // Rem fails\n }\n\n if ($desmhash > 0)\n {\n // Desired Mhash vs. 5s mhash\n $fivesmhashper = round(100 / $desmhash * $fivesmhash, 1);\n $fivesmhashcol = set_color_low($fivesmhashper, $config->yellowgessper, $config->maxgessper);\n\n // Desired Mhash vs. avg mhash\n $avgmhper = round(100 / $desmhash * $avgmhash, 1);\n $avgmhpercol = set_color_low($avgmhper, $config->yellowavgmhper, $config->maxavgmhper);\n }\n\n $tempcol = set_color_high($max_temp, $config->yellowtemp, $config->maxtemp); // Temperature\n $thisstatuscol = ($thisstatus == \"S\") ? \"class=green\" : \"class=yellow\"; // host status\n $thisdevcol = ($activedevs == $devs) ? \"class=green\" : \"class=red\"; // active devs\n\n\t$row = \"\n <td $thisstatuscol>$thisstatus</td>\n <td $thisdevcol>$activedevs/$devs</td>\n <td $tempcol>$max_temp</td>\n <td>$desmhash</td>\n <td>$utility</td>\n <td $fivesmhashcol>$fivesmhash<BR>$fivesmhashper %</td>\n <td $avgmhpercol>$avgmhash<BR>$avgmhper %</td>\n <td $rejectscol>$rejected<BR>$rejects</td>\n <td $discardscol>$discarded<BR>$discards</td>\n <td $stalescol>$stale<BR>$stales</td>\n <td $getfailscol>$getfail<BR>$getfails</td>\n <td $remfailscol>$remfail<BR>$remfails</td>\";\n\n // Sum Stuff\n $data_totals['hosts']++;\n $data_totals['devs'] += $devs;\n $data_totals['activedevs'] += $activedevs;\n $data_totals['maxtemp'] = ($data_totals['maxtemp'] > $max_temp) ? $data_totals['maxtemp'] : $max_temp;\n $data_totals['desmhash'] += $desmhash;\n $data_totals['utility'] += $utility;\n $data_totals['fivesmhash'] += $fivesmhash;\n $data_totals['avemhash'] += $avgmhash;\n $data_totals['accepts'] += $accepted;\n $data_totals['rejects'] += $rejects;\n $data_totals['discards'] += $discards;\n $data_totals['stales'] += $stales;\n $data_totals['getfails'] += $getfails;\n $data_totals['remfails'] += $remfails;\n }\n\n return $row;\n}", "protected function collectDataGroup()\n {\n $url = $this->getGroupURI();\n $this->collectDeals($url);\n }", "function get_host_summary($host_data)\n{\n $hostid = $host_data['id'];\n $name = $host_data['name'];\n $host = $host_data['address'];\n $hostport = $host_data['port'];\n $desmhash = $host_data['mhash_desired'];\n $host_row = \"\";\n\n $arr = array ('command'=>'summary','parameter'=>'');\n $summary_arr = send_request_to_host($arr, $host_data);\n\n if ($summary_arr != null)\n {\n $arr = array ('command'=>'devs','parameter'=>'');\n $dev_arr = send_request_to_host($arr, $host_data);\n\n $host_row = process_host_disp($desmhash, $summary_arr, $dev_arr);\n }\n else\n {\n // No data from host\n $error = socket_strerror(socket_last_error());\n $msg = \"Connection to $host:$hostport failed: \";\n $host_row = \"<td colspan='12'>$msg '$error'</td>\";\n }\n\n $host_row = \"<tbody><tr>\n <td><table border=0><tr>\n <td><a href=\\\"edithost.php?id=$hostid\\\"><img src=\\\"images/edit.png\\\" border=0></a></td>\n <td><a href=\\\"edithost.php?id=$hostid\\\">$name</a></td></td>\n </tr></table></td>\"\n . $host_row .\n \"</tr></tbody>\";\n\n return $host_row;\n}", "private function collectAllData()\n {\n $this->getParsedHeader();\n $this->getServerConfig();\n $this->getPageTitle();\n $this->getLanguage();\n $this->getCharset();\n $this->getHeadingsCount();\n $this->getCanonicalLINKS();\n $this->getAllLinksData();\n }", "function process_devs_disp($host_data)\n{\n global $id;\n\n $i = 0;\n $table = \"\";\n\n $arr = array ('command'=>'devs','parameter'=>'');\n $devs_arr = send_request_to_host($arr, $host_data);\n\n if ($devs_arr != null)\n {\n $id = $host_data['id'];\n while (isset($devs_arr['DEVS'][$i]))\n {\n $table .= process_dev_disp($devs_arr['DEVS'][$i]);\n $i++;\n }\n }\n\n return $table;\n}", "private function parse()\n\t{\n\t\t// parse datagrids\n\t\tif(!empty($this->datagrids)) $this->tpl->assign('datagrids', $this->datagrids);\n\t}", "function process_pools_disp($host_data, $edit=false)\n{\n $i = 0;\n $table = \"\";\n\n\n $arr = array ('command'=>'pools','parameter'=>'');\n $pool_arr = send_request_to_host($arr, $host_data);\n\n if ($pool_arr != null)\n {\n while (isset($pool_arr['POOLS'][$i]))\n {\n $table .= process_pool_disp($pool_arr['POOLS'][$i], $edit);\n $i++;\n }\n }\n return $table;\n}", "public function postProcess(): void {\n $groupsToAddTo = (array) $this->getSubmittedValue('groups');\n $summaryInfo = ['groups' => [], 'tags' => []];\n foreach ($groupsToAddTo as $groupID) {\n // This is a convenience for now - really url & name should be determined at\n // presentation stage - ie the summary screen. The only info we are really\n // preserving is which groups were created vs already existed.\n $summaryInfo['groups'][$groupID] = [\n 'url' => CRM_Utils_System::url('civicrm/group/search', 'reset=1&force=1&context=smog&gid=' . $groupID),\n 'name' => Group::get(FALSE)\n ->addWhere('id', '=', $groupID)\n ->addSelect('name')\n ->execute()\n ->first()['name'],\n 'new' => FALSE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n\n if ($this->getSubmittedValue('newGroupName')) {\n /* Create a new group */\n $groupsToAddTo[] = $groupID = Group::create(FALSE)->setValues([\n 'title' => $this->getSubmittedValue('newGroupName'),\n 'description' => $this->getSubmittedValue('newGroupDesc'),\n 'group_type' => $this->getSubmittedValue('newGroupType') ?? [],\n 'is_active' => TRUE,\n ])->execute()->first()['id'];\n $summaryInfo['groups'][$groupID] = [\n 'url' => CRM_Utils_System::url('civicrm/group/search', 'reset=1&force=1&context=smog&gid=' . $groupID),\n 'name' => $this->getSubmittedValue('newGroupName'),\n 'new' => TRUE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n $tagsToAdd = (array) $this->getSubmittedValue('tag');\n foreach ($tagsToAdd as $tagID) {\n // This is a convenience for now - really url & name should be determined at\n // presentation stage - ie the summary screen. The only info we are really\n // preserving is which tags were created vs already existed.\n $summaryInfo['tags'][$tagID] = [\n 'url' => CRM_Utils_System::url('civicrm/contact/search', 'reset=1&force=1&context=smog&id=' . $tagID),\n 'name' => Tag::get(FALSE)\n ->addWhere('id', '=', $tagID)\n ->addSelect('name')\n ->execute()\n ->first()['name'],\n 'new' => TRUE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n if ($this->getSubmittedValue('newTagName')) {\n $tagsToAdd[] = $tagID = Tag::create(FALSE)->setValues([\n 'name' => $this->getSubmittedValue('newTagName'),\n 'description' => $this->getSubmittedValue('newTagDesc'),\n 'is_selectable' => TRUE,\n 'used_for' => 'civicrm_contact',\n //NYSS new tags during import should be imported as keywords\n 'parent_id'\t=> 296,\n ])->execute()->first()['id'];\n $summaryInfo['tags'][$tagID] = [\n 'url' => CRM_Utils_System::url('civicrm/contact/search', 'reset=1&force=1&context=smog&id=' . $tagID),\n 'name' => $this->getSubmittedValue('newTagName'),\n 'new' => FALSE,\n 'added' => 0,\n 'notAdded' => 0,\n ];\n }\n // Store the actions to take on each row & the data to present at the end to the userJob.\n $this->updateUserJobMetadata('post_actions', [\n 'group' => $groupsToAddTo,\n 'tag' => $tagsToAdd,\n ]);\n $this->updateUserJobMetadata('summary_info', $summaryInfo);\n\n // If ACL applies to the current user, update cache before running the import.\n if (!CRM_Core_Permission::check('view all contacts')) {\n $userID = CRM_Core_Session::getLoggedInContactID();\n CRM_ACL_BAO_Cache::deleteEntry($userID);\n CRM_ACL_BAO_Cache::deleteContactCacheEntry($userID);\n }\n\n $this->runTheImport();\n }", "function PreProcessItemDataGroups()\n {\n $this->Import_Datas=array(\"Name\",\"Email\");\n array_unshift($this->ItemDataGroupPaths,\"../EventApp/System/Inscriptions\");\n }", "public function doProcessData() {}", "public function process()\n\t{\t\t\n\t\t$sImage = Phpfox::getLib('image.helper')->display(array_merge(array('user' => Phpfox::getService('user')->getUserFields(true)), array(\t\t\t\t\n\t\t\t\t\t'path' => 'core.url_user',\n\t\t\t\t\t'file' => Phpfox::getUserBy('user_image'),\n\t\t\t\t\t'suffix' => '_120',\n\t\t\t\t\t'max_width' => 100,\n\t\t\t\t\t'max_height' => 100\n\t\t\t\t)\n\t\t\t)\n\t\t);\n\t\t\n\t\t$aGroup = Phpfox::getService('user.group')->getGroup(Phpfox::getUserBy('user_group_id'));\n\t\t\n\t\t$this->template()->assign(array(\n\t\t\t\t'aUserGroup' => $aGroup,\n\t\t\t\t'sImage' => $sImage,\t\t\t\t\n\t\t\t\t'aDashboards' => Phpfox::getService('core')->getDashboardLinks(),\n\t\t\t\t'sBlockLocation' => Phpfox::getLib('module')->getBlockLocation('core.dashboard'),\n\t\t\t\t'sTotalUserViews' => Phpfox::getUserBy('total_view'),\n\t\t\t\t'sLastLogin' => Phpfox::getLib('date')->convertTime(Phpfox::getUserBy('last_login'), 'core.profile_time_stamps')\n\t\t\t)\n\t\t);\t\t\n\t\t\n\t\tif (!PHPFOX_IS_AJAX)\n\t\t{\n\t\t\t$aMenus = array();\n\t\t\tforeach (Phpfox::getService('core')->getDashboardMenus() as $sPhrase => $sLink)\n\t\t\t{\n\t\t\t\t$aMenus[Phpfox::getPhrase($sPhrase)] = $sLink;\n\t\t\t}\n\t\t\t\n\t\t\t$this->template()->assign(array(\n\t\t\t\t\t'sHeader' => Phpfox::getPhrase('core.dashboard'),\t\t\t\t\t\n\t\t\t\t\t'aMenu' => $aMenus\n\t\t\t\t)\n\t\t\t);\t\t\t\n\t\t\t\n\t\t\treturn 'block';\n\t\t}\n\t}", "public function fetchGroupData() {}", "public function fetchGroupData() {}", "function process_host_info($host_data)\n{\n global $API_version;\n global $CGM_version;\n\n $arr = array ('command'=>'config','parameter'=>'');\n $config_arr = send_request_to_host($arr, $host_data);\n \n $arr = array ('command'=>'summary','parameter'=>'');\n $summary_arr = send_request_to_host($arr, $host_data);\n \n $up_time = $summary_arr['SUMMARY']['0']['Elapsed'];\n $days = floor($up_time / 86400);\n $up_time -= $days * 86400;\n $hours = floor($up_time / 3600);\n $up_time -= $hours * 3600;\n $mins = floor($up_time / 60);\n $seconds = $up_time - ($mins * 60);\n \n $output = \"\n <tr>\n <th>CGminer version</th>\n <th>API version</th>\n <th>Up time</th>\n <th>Found H/W</th>\n <th>Using ADL</th>\n <th>Pools and Strategy</th>\n </tr>\n <tr>\n <td>\".$CGM_version.\"</td>\n <td>\".$API_version.\"</td>\n <td>\".$days.\"d \".$hours.\"h \".$mins.\"m \".$seconds.\"s</td>\n <td>\".$config_arr['CONFIG']['0']['CPU Count'].\" CPUs, \".$config_arr['CONFIG']['0']['GPU Count'].\" GPUs, \".$config_arr['CONFIG']['0']['BFL Count'].\" BFLs</td>\n <td>\".$config_arr['CONFIG']['0']['ADL in use'].\"</td>\n <td>\".$config_arr['CONFIG']['0']['Pool Count'].\" pools, using \".$config_arr['CONFIG']['0']['Strategy'].\"</td>\n </tr>\";\n\n return $output;\n}", "function _hosts()\n{\n $c = \"# Generated with beatnik on \" . date('Y-m-d h:i:s') . \" by \" . $GLOBALS['username'] . \"\\n\\n\";\n foreach ($GLOBALS['domains'] as $domain) {\n\n $zonename = $domain['zonename'];\n $tld = substr($zonename, strrpos($zonename, '.')+1);\n $domain = substr($zonename, 0, strrpos($zonename, '.'));\n\n foreach ($zonedata['cname'] as $id => $values) {\n extract($values);\n if (!empty($hostname)) {\n $hostname .= '.';\n }\n $c .= \"$pointer $hostname.$domain.$tld\\n\";\n }\n }\n\n return $c;\n}", "private function parseGroups()\n\t{\n\t\t/**\n\t\t * Grupos\n\t\t */\n\t\t$groups = $this->habbo->groups;\n\n\t\t/**\n\t\t * Convertirlos a Entity\n\t\t */\n\t\tforeach( $groups as $group )\n\t\t\t$this->addGroup( new Group( $group ) );\n\t}", "private function processExtraData() {\n $benchsDatasize = $this->dbConnection->get_rows(\"SELECT DISTINCT bench_type,bench,datasize FROM aloja2.execs e WHERE 1 AND valid = 1 AND filter = 0 \".DBUtils::getFilterExecs().\" GROUP BY bench_type,bench,datasize ORDER BY bench ASC \");\n $dataBenchs = array();\n $availDatasizes = array();\n foreach($benchsDatasize as $row) {\n $datasize = $this->roundDatasize($row['datasize']);\n if(!isset($availDatasizes[$row['bench_type']]) ||\n !isset($availDatasizes[$row['bench_type']][$row['bench']]) ||\n !in_array($datasize, $availDatasizes[$row['bench_type']][$row['bench']])) {\n $dataBenchs[$row['bench_type']][$row['bench']][] = $row['datasize'];\n $availDatasizes[$row['bench_type']][$row['bench']][] = $datasize;\n }\n }\n\n $this->additionalFilters['datasizesInfo'] = json_encode($dataBenchs);\n\n //Getting scale factors per bench\n $scaleFactors = array();\n $benchsScaleFactors = $this->dbConnection->get_rows(\"SELECT DISTINCT bench_type,bench,scale_factor FROM aloja2.execs e WHERE 1 AND valid = 1 AND filter = 0 \".DBUtils::getFilterExecs().\" GROUP BY bench_type,bench,scale_factor ORDER BY bench ASC \");\n foreach($benchsScaleFactors as $row) {\n $scaleFactor = $row['scale_factor'];\n $scaleFactors[$row['bench_type']][$row['bench']][] = $scaleFactor;\n }\n\n $this->additionalFilters['scaleFactorsInfo'] = json_encode($scaleFactors);\n\n //Getting providers / clusters\n $providerClusters = array();\n $clusters = $this->dbConnection->get_rows(\"SELECT provider,id_cluster FROM aloja2.clusters ORDER BY provider DESC \");\n foreach($clusters as $row) {\n $providerClusters[$row['provider']][] = $row['id_cluster'];\n }\n\n $this->additionalFilters['providerClusters'] = json_encode($providerClusters);\n }", "function processData() ;", "function build_host_servicegroup_details($group_members) \n{\n\tglobal $NagiosData;\n\tglobal $NagiosUser; \n\t$hosts = $NagiosData->getProperty('hosts');\n\t\n\n\t$servicegroup_details = array();\n\tforeach($group_members as $member)\n\t{\n\t\tif($NagiosUser->is_authorized_for_host($member)) //user-level filtering \n\t\t{\n\t\t\tif (isset($hosts[$member]['services']))\n\t\t\t\tforeach ($hosts[$member]['services'] as $service) \n\t\t\t\t{\n\t\t\t\t\tif($NagiosUser->is_authorized_for_service($member,$service)) //user-level filtering \n\t\t\t\t\t\t$servicegroup_details[] = $service;\t\n\t\t\t\t}\t\t\t\t\t\t\n\t\t}\n\t}\n\treturn $servicegroup_details;\n}", "public function processData() {}", "function PostProcessItemDataGroups()\n {\n $this->AddEventQuestDataGroups();\n }", "protected function parse()\n\t{\n\t\tparent::parse();\n\n\t\t// assign the datagrid\n\t\t$this->tpl->assign('dataGrid', ($this->dataGrid->getNumResults() != 0) ? $this->dataGrid->getContent() : false);\n\t}", "function fillGroups() \n\t{\n\t\t$this->groups[] = array(-1,\"<\".\"Admin\".\">\");\n\t\t$this->groupFullChecked[] = true;\n\t\t\n\t\t$trs = db_query(\"select , from `uggroups` order by \",$this->conn);\n\t\twhile($tdata = db_fetch_numarray($trs))\n\t\t{\n\t\t\t$this->groups[] = array($tdata[0],$tdata[1]);\n\t\t\t$this->groupFullChecked[] = true;\n\t\t}\n\t}", "private function normalize()\n {\n $field_id = isset($this->columns[0]) ? $this->columns[0] : 'id';\n\n $field_text = isset($this->columns[1]) ? $this->columns[1] : $field_id;\n\n $groups = [];\n\n $has_empty_groups = false;\n\n foreach ($this->data as $key => $datum) {\n $has_empty_groups = !is_numeric($key);\n }\n\n foreach ($this->data as $key => $datum) {\n if (is_array($datum) && isset($datum['id']) && isset($datum['text'])) {\n $this->push($datum);\n\n continue;\n }\n\n if (is_numeric($key)) {\n if (is_string($datum)) {\n $datum = [$datum];\n }\n\n $id = multi_dot_call($datum, $field_id);\n $id = $id === null ? (string) multi_dot_call($datum, '0') : (string) $id;\n\n $text = multi_dot_call($datum, $field_text);\n if (is_array($text)) {\n $lang = App::getLocale();\n $text = $text[$lang] ?? implode($this->separator, $text);\n }\n $text = $text === null ? (string) multi_dot_call($datum, '0') : (string) $text;\n\n if ($id && $text) {\n $text = $id . \") \" . $text;\n }\n\n foreach (array_slice($this->columns, 2) as $part) {\n $t = multi_dot_call($datum, $part);\n if ($t) {\n $text .= $this->separator.$t;\n }\n }\n\n $item = ['id' => $id, 'text' => $text];\n\n if ($id == $this->value) {\n $item['selected'] = true;\n }\n\n if (!$has_empty_groups) {\n $this->push($item);\n } else {\n $groups['Other'][] = $item;\n }\n } else {\n $groups[ucfirst($key)] = $datum;\n }\n }\n\n foreach ($groups as $group_name => $group) {\n $this->push([\n 'text' => $group_name,\n 'children' => collect($group)->map(function ($datum) use ($field_id, $field_text) {\n if (is_string($datum)) {\n $datum = [$field_id => $datum, $field_text => $datum];\n }\n\n $id = (string) multi_dot_call($datum, $field_id);\n\n $text = (string) multi_dot_call($datum, $field_text);\n\n foreach (array_slice($this->columns, 2) as $part) {\n $t = multi_dot_call($datum, $part);\n\n if ($t) {\n $text .= ' '.$t;\n }\n }\n\n $item = ['id' => $id, 'text' => $text];\n\n if ($id == $this->value) {\n $item['selected'] = true;\n }\n\n return $item;\n })->toArray()\n ]);\n }\n }", "function setupNewsgroups() {\n\t\t$this->setIfNot('hdr_group', 'free.pt');\n\t\t$this->setIfNot('nzb_group', 'alt.binaries.ftd');\n\t\t$this->setIfNot('comment_group', 'free.usenet');\n\t\t$this->setIfNot('report_group', 'free.willey');\n\t\t$this->setIfNot('report_group', 'free.willey');\n\t}", "function automap_filter_by_group(&$obj, $params) {\n if(!isset($params['filter_group']) || $params['filter_group'] == '')\n return;\n\n global $_BACKEND;\n $_BACKEND->checkBackendExists($params['backend_id'][0], true);\n $_BACKEND->checkBackendFeature($params['backend_id'][0], 'getHostNamesInHostgroup', true);\n $hosts = $_BACKEND->getBackend($params['backend_id'][0])->getHostNamesInHostgroup($params['filter_group']);\n\n $allowed_ids = array_flip(automap_hostnames_to_object_ids($hosts));\n automap_filter_tree($allowed_ids, $obj);\n}", "protected function preProcess() {}", "public function processData() {\n\t\t$GLOBALS['TCA'] = \\BusyNoggin\\BnBackend\\BackendLibrary::removeExcludeFields($GLOBALS['TCA']);\n\t}", "function group_prepare_usergroups_for_display($groups, $returnto='mygroups') {\n if (!$groups) {\n return;\n }\n\n // Retrieve a list of all the group admins, for placing in each $group object\n $groupadmins = array();\n $groupids = array_map(create_function('$a', 'return $a->id;'), $groups);\n if ($groupids) {\n $groupadmins = get_records_sql_array('SELECT \"group\", member\n FROM {group_member}\n WHERE \"group\" IN (' . implode(',', db_array_to_ph($groupids)) . \")\n AND role = 'admin'\", $groupids);\n\t\t\t\n if (!$groupadmins) {\n $groupadmins = array();\n }\n }\n\n $i = 0;\n foreach ($groups as $group) {\n $group->admins = array();\n foreach ($groupadmins as $admin) {\n if ($admin->group == $group->id) {\n $group->admins[] = $admin->member;\n }\n }\n $group->description = str_shorten_html($group->description, 100, true);\n if ($group->membershiptype == 'member') {\n $group->canleave = group_user_can_leave($group->id);\n }\n else if ($group->jointype == 'open') {\n $group->groupjoin = group_get_join_form('joingroup' . $i++, $group->id);\n }\n else if ($group->membershiptype == 'invite') {\n $group->invite = group_get_accept_form('invite' . $i++, $group->id, $returnto);\n }\n }\n}", "function outputformat_drush_engine_outputformat() {\n $common_topic_example = array(\n \"a\" => array(\"b\" => 2, \"c\" => 3),\n \"d\" => array(\"e\" => 5, \"f\" => 6)\n );\n\n $engines = array();\n $engines['table'] = array(\n 'description' => 'A formatted, word-wrapped table.',\n 'engine-capabilities' => array('format-table'),\n );\n $engines['key-value'] = array(\n 'description' => 'A formatted list of key-value pairs.',\n 'engine-capabilities' => array('format-single', 'format-list', 'format-table'),\n 'hidden' => TRUE,\n );\n $engines['key-value-list'] = array(\n 'engine-class' => 'list',\n 'list-item-type' => 'key-value',\n 'description' => 'A list of formatted lists of key-value pairs.',\n 'list-field-selection-control' => 1,\n 'engine-capabilities' => array('format-table'),\n 'hidden' => TRUE,\n );\n $engines['json'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'Javascript Object Notation.',\n 'topic-example' => $common_topic_example,\n );\n $engines['string'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'A simple string.',\n 'engine-capabilities' => array('format-single'),\n );\n $engines['message'] = array(\n 'machine-parsable' => FALSE, // depends on the label....\n 'hidden' => TRUE,\n );\n $engines['print-r'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'Output via php print_r function.',\n 'verbose-only' => TRUE,\n 'topic-example' => $common_topic_example,\n );\n $engines['var_export'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'An array in executable php format.',\n 'topic-example' => $common_topic_example,\n );\n $engines['yaml'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'Yaml output format.',\n 'topic-example' => $common_topic_example,\n );\n $engines['php'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'A serialized php string.',\n 'verbose-only' => TRUE,\n 'topic-example' => $common_topic_example,\n );\n $engines['config'] = array(\n 'machine-parsable' => TRUE,\n 'engine-class' => 'list',\n 'list-item-type' => 'var_export',\n 'description' => \"A configuration file in executable php format. The variable name is \\\"config\\\", and the variable keys are taken from the output data array's keys.\",\n 'metadata' => array(\n 'variable-name' => 'config',\n ),\n 'list-field-selection-control' => -1,\n 'engine-capabilities' => array('format-list','format-table'),\n 'verbose-only' => TRUE,\n );\n $engines['list'] = array(\n 'machine-parsable' => TRUE,\n 'list-item-type' => 'string',\n 'description' => 'A simple list of values.',\n // When a table is printed as a list, only the array keys of the rows will print.\n 'engine-capabilities' => array('format-list', 'format-table'),\n 'topic-example' => array('a', 'b', 'c'),\n );\n $engines['nested-csv'] = array(\n 'machine-parsable' => TRUE,\n 'engine-class' => 'list',\n 'list-separator' => ',',\n 'list-item-type' => 'csv-or-string',\n 'hidden' => TRUE,\n );\n $engines['csv-or-string'] = array(\n 'machine-parsable' => TRUE,\n 'hidden' => TRUE,\n );\n $engines['csv'] = array(\n 'machine-parsable' => TRUE,\n 'engine-class' => 'list',\n 'list-item-type' => 'nested-csv',\n 'labeled-list' => TRUE,\n 'description' => 'A list of values, one per row, each of which is a comma-separated list of values.',\n 'engine-capabilities' => array('format-table'),\n 'topic-example' => array(array('a', 12, '[email protected]'),array('b', 17, '[email protected]')),\n );\n $engines['variables'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'A list of php variable assignments.',\n 'engine-capabilities' => array('format-table'),\n 'verbose-only' => TRUE,\n 'list-field-selection-control' => -1,\n 'topic-example' => $common_topic_example,\n );\n $engines['labeled-export'] = array(\n 'machine-parsable' => TRUE,\n 'description' => 'A list of php exports, labeled with a name.',\n 'engine-capabilities' => array('format-table'),\n 'verbose-only' => TRUE,\n 'engine-class' => 'list',\n 'list-item-type' => 'var_export',\n 'metadata' => array(\n 'label-template' => '!label: !value',\n ),\n 'list-field-selection-control' => -1,\n 'topic-example' => $common_topic_example,\n );\n return $engines;\n}", "public function build_data() {\n $this->total_collection = (int)count($this->feeds);\n $redis_total_set = (int)$this->redis->hget($this->key_name, 'total:set'); \n \n $key = $this->redis->hgetall($this->key_name);\n $hosted_feeds = $this->group_and_build(); \n\n if(!$key || $redis_total_set !== $this->total_collection) {\n //echo \"Processing: Insert Data into Redis\";\n //insert data into redis\n $this->redis->hset($this->key_name, 'total:set', $this->total_collection);\n $page = 0;\n foreach($hosted_feeds as $feed_group => $feed_list) {\n $page_number = ++$page;\n $spring_data = Array($feed_group => $feed_list);\n $this->redis->hset($this->key_name, \"set:$page_number\", json_encode($spring_data));\n $spring_data = Null;\n }\n } \n \n }", "function processData($data) {\n\n // include states with list of population\n include 'state-popu.php';\n\n // assign $data in $row var\n $row = $data;\n\n // check each data if set and not null and assign to their variables\n $first = isset($row[0]) ? $row[0] : '';\n $last = isset($row[1]) ? $row[1] : '';\n $email = isset($row[2]) ? $row[2] : '';\n $state = isset($row[3]) ? $row[3] : '';\n\n // get the email domain base on the requirements\n $edomain = '';\n if($email) {\n $edomain = substr(strrchr($email, \"@\"), 1);\n }\n\n // changed the email for export base on the requirements\n // the given data only has a state and Jacksonville belongs to Florida, I just assumed that if state = Florida I will change the export data base on the requirement\n $exportedEmail = $email;\n if($state === 'Florida') {\n $exportedEmail = '[email protected]';\n }\n\n // add class to rows that will be excluded base on state population base on requirements\n $check_pop = '';\n if($state_popu_list[$state] > 10000000) {\n $check_pop = 'js-excluded';\n }\n\n // putting data as arrays for conversion\n $datas = array(\n $first,\n $last,\n $email,\n $state,\n $edomain,\n $exportedEmail,\n $check_pop\n );\n\n return $datas;\n}", "public function prepareDataSettings($inputData) {\n\t\t\t$data = array();\n\t\t\t$data['nodes:group'] = array();\n\n\t\t\tforeach($inputData as $group_name => $params) {\n\t\t\t\tif(!is_array($params)) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t$group = array();\n\t\t\t\t$group['attribute:name'] = $group_name;\n\t\t\t\t$group['attribute:label'] = getLabel(\"group-\" . $group_name);\n\n\t\t\t\t$options = array();\n\t\t\t\tforeach($params as $param_key => $param_value) {\n\t\t\t\t\t$param_name = def_module::getRealKey($param_key);\n\t\t\t\t\t$param_type = def_module::getRealKey($param_key, true);\n\n\t\t\t\t\t$option = array();\n\t\t\t\t\t$option['attribute:name'] = $param_name;\n\t\t\t\t\t$option['attribute:type'] = $param_type;\n\t\t\t\t\t$option['attribute:label'] = getLabel(\"option-\" . $param_name);\n\n\t\t\t\t\tswitch($param_type) {\n\t\t\t\t\t\tcase \"select\": {\n\t\t\t\t\t\t\t$items = array();\n\t\t\t\t\t\t\t$value = isset($param_value['value']) ? $param_value['value'] : false;\n\t\t\t\t\t\t\tforeach($param_value as $item_id => $item_name) {\n\t\t\t\t\t\t\t\tif($item_id === \"value\") continue;\n\n\t\t\t\t\t\t\t\t$item_arr = array();\n\t\t\t\t\t\t\t\t$item_arr['attribute:id'] = $item_id;\n\t\t\t\t\t\t\t\t$item_arr['node:name'] = $item_name;\n\t\t\t\t\t\t\t\t$items[] = $item_arr;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$option['value'] = array(\"nodes:item\" => $items);\n\n\t\t\t\t\t\t\tif($value !== false) {\n\t\t\t\t\t\t\t\t$option['value']['attribute:id'] = $value;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tcase \"password\": {\n\t\t\t\t\t\t\tif($param_value) {\n\t\t\t\t\t\t\t\t$param_value = \"********\";\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t$param_value = \"\";\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tcase \"symlink\": {\n\t\t\t\t\t\t\t$hierarchy = umiHierarchy::getInstance();\n\n\t\t\t\t\t\t\t$param_value = @unserialize($param_value);\n\t\t\t\t\t\t\tif(!is_array($param_value)) {\n\t\t\t\t\t\t\t\t$param_value = array();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$items = array();\n\t\t\t\t\t\t\tforeach($param_value as $item_id) {\n\t\t\t\t\t\t\t\t$item = $hierarchy->getElement($item_id);\n\t\t\t\t\t\t\t\tif($item instanceof umiHierarchyElement == false) {\n\t\t\t\t\t\t\t\t\tcontinue;\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t$item_arr = array();\n\t\t\t\t\t\t\t\t$item_arr['attribute:id'] = $item_id;\n\t\t\t\t\t\t\t\t$item_arr['node:name'] = $item->getName();\n\t\t\t\t\t\t\t\t$items[] = $item_arr;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t$option['value'] = array('nodes:item' => $items);\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdefault: {\n\t\t\t\t\t\t\t$option['value'] = $param_value;\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t$options[] = $option;\n\t\t\t\t}\n\n\t\t\t\t$group['nodes:option'] = $options;\n\t\t\t\t$data['nodes:group'][] = $group;\n\t\t\t}\n\t\t\treturn $data;\n\t\t}", "protected function _parse(){\n\t\tforeach ($this->dataArray['tables']['nat']['default-chains'] as $a => &$b){\n\t\t\t$b['iptables-rules'] = array();\n\t\t\t$this->transformToIPTables($b['rules'], $b['iptables-rules']);\n\t\t}\n\t\t\n\t\t// Now the IP chains...\n\t\tforeach ($this->dataArray['tables']['nat']['ip-chains'] as &$e){\n\t\t\t$e['iptables-rules'] = array();\n\t\t\t$this->transformToIPTables($e['rules'], $e['iptables-rules']);\n\t\t}\n\t\t\n\t\t// And finally, the others...\n\t\tforeach ($this->dataArray['tables']['nat']['other-chains'] as $h => &$i){\n\t\t\t$i['iptables-rules'] = array();\n\t\t\t$this->transformToIPTables($i['rules'], $i['iptables-rules']);\n\t\t}\n\t}", "public function printData()\n {\n pre($this->getData());\n }", "private function prepareData(){\n\t\t\t$this->text = trim($this->text);\n\t\t\t$this->user_id = intval($this->user_id);\n\t\t\t$this->parent_id = intval($this->parent_id);\n\t\t}", "function process_host_devs($dev_data_array, &$activedevs, &$host5shash, &$maxtemp)\n{\n global $pools_in_use;\n\n $devs = 0;\n $activedevs = 0;\n $host5shash = 0;\n $maxtemp = 0;\n $pools_in_use = array();\n\n while(isset($dev_data_array['DEVS'][$devs]))\n {\n /* Get 5 second has rate */\n $dev5shash = $dev_data_array['DEVS'][$devs]['MHS 5s'];\n $host5shash += $dev5shash;\n\n /* Is device operating */\n if ($dev_data_array['DEVS'][$devs]['Status'] == \"Alive\" && $dev_data_array['DEVS'][$devs]['Enabled'] == \"Y\")\n $activedevs++;\n\n /* Find higest temp */\n $temp = $dev_data_array['DEVS'][$devs]['Temperature'];\n if ($maxtemp < $temp)\n $maxtemp = $temp;\n \n /* Find which pools are in use */\n $pools_in_use[$dev_data_array['DEVS'][$devs]['Last Share Pool']] = true;\n \n $devs++;\n }\n\n return $devs;\n}", "protected function prepareForPresentation()\n {\n if ($this->prepared) {\n return;\n }\n\n $this->permissionGroups = new Collection;\n $this->ungroupedPermissions = [];\n $this->groupedPermissionIndex = [];\n\n $this->loadPermissionsFromModules()\n ->loadCustomPermissions()\n ->loadCustomPermissionGroups()\n ->addUngroupedPermissionGroup()\n ->filterEmptyGroups();\n }", "public function process(){\n \n // Grab config chunk name\n $chunkName =& $this->getProperty('chunk','');\n if(!strlen($chunkName)){\n return $this->failure('No config chunk specified');\n };\n\n // Load config\n if(!$conf = $this->modx->grideditor->loadConfigChunk($chunkName)){\n return $this->failure('Invalid config chunk');\n };\n \n // Grab all resources that match the template filters\n $c = $this->modx->grideditor->get_xPDOQuery($conf);\n $resources = $this->modx->getCollection('modResource',$c);\n $filterField = $conf->filter->field;\n\n\n // Grab the field info\n if(!$field = $conf->fields[$filterField]){\n\n // Try for tv thingy\n $safeName = str_replace(array('-','.'),'_',$filterField);\n if(!$field = $conf->fields[$safeName]){\n return $this->failure(\"Invalid filter field\");\n }\n }\n\n // Grab the filter field\n $isTV = ($field->type == 'tv');\n\n // Grab the field specified from each resource\n $values = array(array('name' => $conf->filter->label, 'value'=>''));\n foreach($resources as $res){\n if($isTV){\n $val = $res->getTVValue($field->field);\n } else {\n $val = $res->get($filterField);\n };\n if(! in_array_r($val,$values) && !empty($val)){\n $values[] = array(\n 'name' => $val,\n 'value'=> $val\n );\n };\n };\n \n return $this->outputArray($values); \n }", "function processData() \n {\n \n // store values in table manager object.\n $moduleID = $this->dataManager->getModuleID();\n $moduleCreator = new ModuleCreator( $moduleID, $this->pathModuleRoot);\n $moduleCreator->createModule();\n \n }", "function process_data($data) {\n // Implement in children classes\n }", "public function prepareDataTemplates($inputData) {\n\t\t\t$data = array();\n\t\t\t$domainsCollection = domainsCollection::getInstance();\n\n\t\t\t$domains = array();\n\t\t\tforeach($inputData as $host => $templates) {\n\t\t\t\t$domain = array();\n\t\t\t\t$domain['attribute:id'] = $domainsCollection->getDomainId($host);\n\t\t\t\t$domain['attribute:host'] = $host;\n\t\t\t\t$domain['nodes:template'] = $templates;\n\t\t\t\t$domains[] = $domain;\n\t\t\t}\n\t\t\t$data['nodes:domain'] = $domains;\n\t\t\treturn $data;\n\t\t}", "function renderOutput($data, $params, $exit_code) {\n\n // everything is fine\n if ($exit_code == 0){\n echo \"OK: Hypervisor \" . $data['host']['name'] . \" (\" . $data['host']['vendor'] . \" - \". $data['host']['model'] . \" - SN:\" . $data['host']['sn'] . \") is healthy.\\n\";\n }\n\n // houston, we have a problem..\n elseif ($exit_code == 1){\n echo \"WARNING: Hypervisor \" . $data['host']['name'] . \" (\" . $data['host']['vendor'] . \" - \". $data['host']['model'] . \" - SN:\" . $data['host']['sn'] . \") reported problems. please check details...\\n\";\n }\n \n // oooops, this should better not happen for this host..\n elseif ($exit_code == 2){\n echo \"CRITICAL: Hypervisor \" . $data['host']['name'] . \" (\" . $data['host']['vendor'] . \" - \". $data['host']['model'] . \" - SN:\" . $data['host']['sn'] . \") reported problems. please check details...\\n\";\n }\n\n // some basic system information like vendor, model & serial number..\n echo \"Hypervisor Version: \" . $data['host']['version'] . \"\\n\";\n echo \"Pool role: \" . ($data['is_poolmaster'] == true ? \"Master\" : \"Slave\") . \"\\n\";\n echo \"Vendor: \" . $data['host']['vendor'] . \"\\n\";\n echo \"Model: \" . $data['host']['model'] . \"\\n\";\n echo \"SN: \" . $data['host']['sn'] . \"\\n\";\n echo \"CPU: \" . $data['host']['cpu'] . \"\\n\\n\";\n\n // CPU usage\n echo \"Memory Usage: \" . formatStatus($data['memory']['usage'] . \"%\", $data['memory']['exit_code']) . \" (Free: \" . $data['memory']['free'] . \" GB - Used: \" . $data['memory']['used'] . \" GB - Total: \". $data['memory']['total'] . \" GB)\\n\";\n\n\n foreach ($data['storage'] as $storage)\n {\n // local storage\n if ($storage['type'] == 'ext' || $storage['type'] == 'lvm')\n echo $storage['label'] . \" - Usage: \" . formatStatus($storage['usage'] . \"%\", $storage['exit_code']) . \" (Free: \" . $storage['free'] . \" GB - Used: \" . $storage['used'] . \" GB - Total: \" .$storage['total'] . \" GB)\\n\";\n elseif ($data['is_poolmaster'] == true)\n echo $storage['label'] . \" - Usage: \" . formatStatus($storage['usage'] . \"%\", $storage['exit_code']) . \" (Free: \" . $storage['free'] . \" GB - Used: \" . $storage['used'] . \" GB - Total: \" .$storage['total'] . \" GB)\\n\";\n }\n\n // VMs\n if (!empty($data['guests'] ))\n {\n echo \"\\n<b>Guests on this host:</b>\\n\";\n\n foreach ($data['guests'] as $guest)\n {\n if ($guest['powerstate'] == 'Running')\n echo '<span style=\"color: #66bb6a;\">&#9679;</span> ' . $guest['name'] . \"\\n\";\n \n // VMs not running only for the poolmaster..\n if ($guest['powerstate'] != 'Running' && $data['is_poolmaster'] == true)\n echo '<span style=\"color: #f0666c;\">&#9679;</span> ' . $guest['name'] . \"\\n\";\n }\n }\n\n echo '| \\'memory usage\\'=' . $data['memory']['usage'] . ';' . $params['warning'] . ';' . $params['critical'] . ';0;100';\n\n foreach ($data['storage'] as $storage)\n {\n \n\n $w = round($storage['total'] * $params['warning'] / 100, 2);\n $c = round($storage['total'] * $params['critical'] / 100, 2);\n if ($storage['type'] == 'ext' || $storage['type'] == 'lvm')\n echo ' \\'' . $storage['label'] . '\\'=' . $storage['used'] . ';'. $w . ';' . $c .';0;' . $storage['total']. \"\\n\";\n elseif ($data['is_poolmaster'] == true)\n echo ' \\'' . $storage['label'] . '\\'=' . $storage['used'] . ';'. $w . ';' . $c .';0;' . $storage['total']. \"\\n\";\n }\n\n\n // Performance data\n // | 'CPU1'=16;0;0;; 'CPU2'=7;0;0;; 'CPU3'=6;0;0;;\n\n}", "abstract public function prepareData();", "function timeconditions_timegroups_configprocess() {\n\t$action= isset($_REQUEST['action'])?$_REQUEST['action']:null;\n\t$timegroup= isset($_REQUEST['extdisplay'])?$_REQUEST['extdisplay']:null;\n\t$description= isset($_REQUEST['description'])?$_REQUEST['description']:null;\n\t$times = isset($_REQUEST['times'])?$_REQUEST['times']:null;\n\n\tswitch ($action) {\n\t\tcase 'add':\n\t\t\ttimeconditions_timegroups_add_group($description,$times);\n\t\t\tbreak;\n\t\tcase 'edit':\n\t\t\ttimeconditions_timegroups_edit_group($timegroup,$description);\n\t\t\ttimeconditions_timegroups_edit_times($timegroup,$times);\n\t\t\tbreak;\n\t\tcase 'del':\n\t\t\ttimeconditions_timegroups_del_group($timegroup);\n\t\t\tbreak;\n\t}\n}", "function get_grouping_fields() {\n //field that is used to compare one record from the next\n $compare_field = sql_concat('user.lastname', \"'_'\", 'user.firstname', \"'_'\", 'user.id');\n\n //field used to order for groupings\n $order_field = sql_concat('lastname', \"'_'\", 'firstname', \"'_'\", 'userid');\n\n $cluster_label = get_string('grouping_cluster', 'rlreport_course_completion_by_cluster');\n $cluster_grouping = new table_report_grouping('cluster', 'cluster.id', $cluster_label, 'ASC',\n array('cluster.name'), 'above', 'path');\n \n $user_grouping_fields = array(\n 'user.idnumber AS useridnumber', 'user.firstname');\n $user_grouping = new table_report_grouping('groupuseridnumber', $compare_field, '', 'ASC', \n $user_grouping_fields, 'below', $order_field);\n\n //these groupings will always be used\n $result = array(\n $cluster_grouping, $user_grouping);\n\n //determine whether or not we should use the curriculum grouping\n $preferences = php_report_filtering_get_active_filter_values($this->get_report_shortname(),\n 'columns'.'_curriculum', $this->filter);\n\n $show_curriculum = true;\n if (isset($preferences['0']['value'])) {\n $show_curriculum = $preferences['0']['value'];\n }\n\n if ($show_curriculum) {\n $curriculum_label = get_string('grouping_curriculum', 'rlreport_course_completion_by_cluster');\n $result[] = new table_report_grouping('groupcurriculumid', 'curriculum.id', $curriculum_label, 'ASC', array(),\n 'below', 'curriculumname, curriculumid');\n }\n\n return $result;\n }", "public function onProcess($data)\n\t{\n\t\t//preg_match(\"~\\[([^]]*?)\\](.*?)-=([0-9]*)=-~i\", $data, $m);\n\n\t\t$temp = array();\n\t\t$temp = explode('\u0004', $data); \t\t\n\n\t\tif (!empty($temp)) \n\t\t{\n\t\t\t$this->str[] = array(\n\t\t\t\t'author'\t=>\t$temp[0],\n\t\t\t\t'title'\t\t=>\t$temp[2],\n\t\t\t\t'external_id'\t=> $temp[5],\n\t\t\t\t'format' => $temp[9],\n\t\t\t\t'date' => $temp[10],\n\t\t\t\t'lan' => $temp[11],\t\t\t\t\n\t\t\t);\n\t\t}\n\t}", "protected function loadData()\n\t{\n\t\t$delimiter = \"|||---|||---|||\";\n\t\t$command = 'show --pretty=format:\"%an'.$delimiter.'%ae'.$delimiter.'%cd'.$delimiter.'%s'.$delimiter.'%B'.$delimiter.'%N\" ' . $this->hash;\n\n\t\t$response = $this->repository->run($command);\n\n\t\t$parts = explode($delimiter,$response);\n\t\t$this->_authorName = array_shift($parts);\n\t\t$this->_authorEmail = array_shift($parts);\n\t\t$this->_time = array_shift($parts);\n\t\t$this->_subject = array_shift($parts);\n\t\t$this->_message = array_shift($parts);\n\t\t$this->_notes = array_shift($parts);\n\t}", "function postProcess() {\n $this->beginPostProcess();\n\n $this->buildACLClause( $this->_aliases['contact'] );\n // build query\n $sql = $this->buildQuery();\n //echo $sql;\n // build array of result based on column headers. This method also allows\n // modifying column headers before using it to build result set i.e $rows.\n $this->buildRows($sql, $rows);\n\n // format result set.\n $this->formatDisplay($rows);\n\n // assign variables to templates\n $this->doTemplateAssignment($rows);\n\n // do print / pdf / instance stuff if needed\n //$this->endPostProcess($rows);\n }", "public function _progressHostInfo($info){\n $i = 0;\n $k = 0;\n while($i < count($info)){\n foreach($info[$i] as $value){\n $hosts[] = $value;\n $k++;\n }\n $i++;\n }\n $tmp = array();\n $i = 0;\n\t\t\t$nOriginalHostsCount = count($hosts);\n while($i < $nOriginalHostsCount){\n \tif(!isset($hosts[$i])){\n\t\t\t\t\t$i++;\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n $hostid = $hosts[$i]['hostid'];\n if((int)$hostid==0){\n $i++;\n continue;\n }\n $tmp[$hostid]['hostid'] = $hosts[$i]['hostid'];\n $tmp[$hostid]['host'] = $hosts[$i]['host'];\n $tmp[$hostid]['ip'] = $hosts[$i]['ip'];\n $tmp[$hostid]['port'] = $hosts[$i]['port'];\n $tmp[$hostid]['status'] = $hosts[$i]['status'];\n $tmp[$hostid]['error'] = $hosts[$i]['error'];\n $tmp[$hostid]['maintenanceid'] = $hosts[$i]['maintenanceid'];\n $tmp[$hostid]['maintenance_status'] = $hosts[$i]['maintenance_status'];\n $tmp[$hostid]['maintenance_type'] = $hosts[$i]['maintenance_type'];\n $tmp[$hostid]['maintenance_from'] = $hosts[$i]['maintenance_from'];\n $triggers_in_host[] = $hosts[$i]['triggerid'];\n $j = $i+1;\n $total_host = count($hosts);\n while($j < $total_host){\n if(isset($hosts[$i]) && isset($hosts[$j]))\n {\n\t\t\t\t\t\tif($hosts[$i]['hostid'] == $hosts[$j]['hostid'] && $hosts[$j]['hostid']>0){\n\t\t\t\t\t\t\t$triggers_in_host[] = $hosts[$j]['triggerid'];\n\t\t\t\t\t\t\tunset($hosts[$j]);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n $j++;\n }\n $tmp[$hostid]['triggers'] = $triggers_in_host;\n unset($triggers_in_host);\n $i++;\n }\n return $tmp;\n }", "function draw_hoststatus_table()\n{ $meta_pref_option = 'hoststatus_table_options';\n\n // defaults\n //$sortby=\"host_name:a,service_description\";\n $sortby = \"\";\n $sortorder = \"asc\";\n $page = 1;\n $records = 15;\n $search = \"\";\n\n // default to use saved options\n $s = get_user_meta(0, $meta_pref_option);\n if ($s) {\n $saved_options = unserialize($s);\n if (is_array($saved_options)) {\n if (isset($saved_options[\"sortby\"]))\n $sortby = $saved_options[\"sortby\"];\n if (isset($saved_options[\"sortorder\"]))\n $sortorder = $saved_options[\"sortorder\"];\n if (isset($saved_options[\"records\"]))\n $records = $saved_options[\"records\"];\n //if(array_key_exists(\"search\",$saved_options))\n // $search=$saved_options[\"search\"];\n }\n //echo \"SAVED OPTIONS: \";\n //print_r($saved_options);\n }\n\n // grab request variables\n $show = grab_request_var(\"show\", \"services\");\n $host = grab_request_var(\"host\", \"\");\n $hostgroup = grab_request_var(\"hostgroup\", \"\");\n $servicegroup = grab_request_var(\"servicegroup\", \"\");\n $hostattr = grab_request_var(\"hostattr\", 0);\n $serviceattr = grab_request_var(\"serviceattr\", 0);\n $hoststatustypes = grab_request_var(\"hoststatustypes\", 0);\n $servicestatustypes = grab_request_var(\"servicestatustypes\", 0);\n\n // fix for \"all\" options\n if ($hostgroup == \"all\")\n $hostgroup = \"\";\n if ($servicegroup == \"all\")\n $servicegroup = \"\";\n if ($host == \"all\")\n $host = \"\";\n\n $sortby = grab_request_var(\"sortby\", $sortby);\n $sortorder = grab_request_var(\"sortorder\", $sortorder);\n $records = grab_request_var(\"records\", $records);\n $page = grab_request_var(\"page\", $page);\n $search = trim(grab_request_var(\"search\", $search));\n if ($search == _(\"Search...\"))\n $search = \"\";\n\n // save options for later\n $saved_options = array(\n \"sortby\" => $sortby,\n \"sortorder\" => $sortorder,\n \"records\" => $records,\n //\"search\" => $search\n );\n $s = serialize($saved_options);\n set_user_meta(0, $meta_pref_option, $s, false);\n\n\n $output = '';\n\n $output .= \"<form action='\" . get_base_url() . \"includes/components/xicore/status.php'>\";\n $output .= \"<input type='hidden' name='show' value='hosts'>\\n\";\n\n $output .= \"<input type='hidden' name='sortby' value=\\\"\" . encode_form_val($sortby) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='sortorder' value=\\\"\" . encode_form_val($sortorder) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='host' value=\\\"\" . encode_form_val($host) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='hostgroup' value=\\\"\" . encode_form_val($hostgroup) . \"\\\">\\n\";\n $output .= \"<input type='hidden' name='servicegroup' value=\\\"\" . encode_form_val($servicegroup) . \"\\\">\\n\";\n\n $output .= '<div class=\"servicestatustablesearch\">';\n $output .= '\n <input type=\"text\" size=\"15\" name=\"search\" id=\"hostsearchBox\" value=\"\" class=\"form-control condensed\" placeholder=\"'._('Search').'...\">\n <button type=\"submit\" class=\"btn btn-xs btn-default\" name=\"searchButton\" id=\"searchButton\"><i class=\"fa fa-search\"></i></button>\n </div>\n </form>';\n\n // ajax updater args\n $ajaxargs = array();\n $ajaxargs[\"host\"] = $host;\n $ajaxargs[\"hostgroup\"] = $hostgroup;\n $ajaxargs[\"servicegroup\"] = $servicegroup;\n $ajaxargs[\"sortby\"] = $sortby;\n $ajaxargs[\"sortorder\"] = $sortorder;\n $ajaxargs[\"records\"] = $records;\n $ajaxargs[\"page\"] = $page;\n $ajaxargs[\"search\"] = $search;\n $ajaxargs[\"hostattr\"] = $hostattr;\n $ajaxargs[\"serviceattr\"] = $serviceattr;\n $ajaxargs[\"hoststatustypes\"] = $hoststatustypes;\n $ajaxargs[\"servicestatustypes\"] = $servicestatustypes;\n\n $id = \"hoststatustable_\" . random_string(6);\n\n $output .= \"<div class='hoststatustable' id='\" . $id . \"'>\\n\";\n $output .= get_throbber_html();\n $output .= \"</div>\";\n\n // build args for javascript\n $n = 0;\n $jargs = \"{\";\n foreach ($ajaxargs as $var => $val) {\n if ($n > 0)\n $jargs .= \", \";\n $jargs .= \"\\\"\" . htmlentities($var) . \"\\\" : \\\"\" . htmlentities($val) . \"\\\"\";\n $n++;\n }\n $jargs .= \"}\";\n\n // ajax updater\n $output .= '\n <script type=\"text/javascript\">\n $(document).ready(function(){\n\n get_' . $id . '_content();\n \n $(\"#' . $id . '\").everyTime(30*1000, \"timer-' . $id . '\", function(i) {\n get_' . $id . '_content();\n });\n \n function get_' . $id . '_content(){\n $(\"#' . $id . '\").each(function(){\n var optsarr = {\n \"func\": \"get_hoststatus_table\",\n \"args\": ' . $jargs . '\n }\n var opts=array2json(optsarr);\n get_ajax_data_innerHTML(\"getxicoreajax\",opts,true,this);\n });\n }\n\n });\n </script>\n ';\n\n //return $output;\n echo $output;\n}", "public function pre_process($data)\n {\n $entrySiteId = (isset($this->row['entry_site_id']) ? $this->row['entry_site_id'] : null);\n\n // convert file tags to URLs\n RteHelper::replaceFileTags($data);\n\n // convert site page tags to URLs\n RteHelper::replacePageTags($data, $entrySiteId);\n\n // convert asset tags to URLs\n RteHelper::replaceExtraTags($data);\n\n ee()->load->library('typography');\n\n $tmp_encode_email = ee()->typography->encode_email;\n ee()->typography->encode_email = false;\n\n $tmp_convert_curly = ee()->typography->convert_curly;\n ee()->typography->convert_curly = false;\n\n $data = ee()->typography->parse_type($data, array(\n 'text_format' => 'none',\n 'html_format' => 'all',\n 'auto_links' => (isset($this->row['channel_auto_link_urls']) ? $this->row['channel_auto_link_urls'] : 'n'),\n 'allow_img_url' => (isset($this->row['channel_allow_img_urls']) ? $this->row['channel_allow_img_urls'] : 'y')\n ));\n\n ee()->typography->encode_email = $tmp_encode_email;\n ee()->typography->convert_curly = $tmp_convert_curly;\n\n // use normal quotes\n $data = str_replace('&quot;', '\"', $data);\n\n return $data;\n }", "public function groups();", "public function groups();", "function validate_group_with_host(&$PAGE_GROUPS, &$PAGE_HOSTS, $reset_host = true) {\n\tglobal $page;\n\n\t$config = select_config();\n\t$dd_first_entry = $config['dropdown_first_entry'];\n\n\t$group_var = 'web.latest.groupid';\n\t$host_var = 'web.latest.hostid';\n\n\t$_REQUEST['groupid'] = get_request('groupid', CProfile::get($group_var, -1));\n\t$_REQUEST['hostid'] = get_request('hostid', CProfile::get($host_var, -1));\n\n\tif ($_REQUEST['groupid'] > 0) {\n\t\tif ($_REQUEST['hostid'] > 0) {\n\t\t\tif (!DBfetch(DBselect('SELECT hg.groupid FROM hosts_groups hg WHERE hg.hostid='.$_REQUEST['hostid'].' AND hg.groupid='.$_REQUEST['groupid']))) {\n\t\t\t\t$_REQUEST['hostid'] = 0;\n\t\t\t}\n\t\t}\n\t\telseif ($reset_host) {\n\t\t\t$_REQUEST['hostid'] = 0;\n\t\t}\n\t}\n\telse {\n\t\t$_REQUEST['groupid'] = 0;\n\n\t\tif ($reset_host && $dd_first_entry == ZBX_DROPDOWN_FIRST_NONE) {\n\t\t\t$_REQUEST['hostid'] = 0;\n\t\t}\n\t}\n\n\t$PAGE_GROUPS['selected'] = $_REQUEST['groupid'];\n\t$PAGE_HOSTS['selected'] = $_REQUEST['hostid'];\n\n\tif ($PAGE_GROUPS['selected'] == 0 && $dd_first_entry == ZBX_DROPDOWN_FIRST_NONE && $reset_host) {\n\t\t$PAGE_GROUPS['groupids'] = array();\n\t}\n\tif ($PAGE_HOSTS['selected'] == 0 && $dd_first_entry == ZBX_DROPDOWN_FIRST_NONE && $reset_host) {\n\t\t$PAGE_HOSTS['hostids'] = array();\n\t}\n\tif ($PAGE_GROUPS['original'] > -1) {\n\t\tCProfile::update('web.'.$page['menu'].'.groupid', $_REQUEST['groupid'], PROFILE_TYPE_ID);\n\t}\n\tif ($PAGE_HOSTS['original'] > -1) {\n\t\tCProfile::update('web.'.$page['menu'].'.hostid', $_REQUEST['hostid'], PROFILE_TYPE_ID);\n\t}\n\tCProfile::update($group_var, $_REQUEST['groupid'], PROFILE_TYPE_ID);\n\tCProfile::update($host_var, $_REQUEST['hostid'], PROFILE_TYPE_ID);\n}", "protected function postImport(){\n foreach(MigrateDestinationFieldGroup::getFieldGroupModes() as $mode){\n $group = field_group_load_field_group('group_misc', 'taxonomy_term', $this->vocabulary->machine_name, $mode);\n if($group){\n $group->children = array_merge($group->children, $this->destination->getFieldsCreated());\n field_group_group_save($group);\n }\n }\n }", "public function format()\n {\n $result = array();\n\n foreach ($this->groups as $group) {\n $result[] = array(\n 'id' => $group->getInternalId(),\n 'external_id' => $group->getExternalId(),\n 'value' => $group->getName(),\n 'label' => $group->getName(),\n );\n }\n\n return $result;\n }", "public function prepareData()\r\n {\r\n $users_model = new UsersModel();\r\n $users_all = $users_model->getAll(true, false, 'C_FULLNAME');\r\n $users = Groups::getUsers($this->group_id, 'C_FULLNAME');\r\n $users_include = array();\r\n \tforeach ($users as $user_info) {\r\n \t\t$users_include[$user_info['U_ID']] = array(\r\n \t\t\t$user_info['U_ID'],\r\n \t\t\t$user_info['C_FULLNAME']\r\n \t\t);\r\n \t} \r\n \t$users_exclude = array();\r\n \tforeach ($users_all as $user_info) {\r\n \t\tif (!isset($users_include[$user_info['U_ID']])) {\r\n\t \t\t$users_exclude[] = array(\r\n\t \t\t\t$user_info['U_ID'],\r\n\t \t\t\t$user_info['C_FULLNAME']\r\n\t \t\t);\r\n \t\t}\r\n \t}\r\n \t$this->smarty->assign('group_id', $this->group_id);\r\n \t$this->smarty->assign('users_in', json_encode(array_values($users_include)));\r\n \t$this->smarty->assign('users_out', json_encode($users_exclude)); \r\n }", "public function parsePostData() {\n\t\t$dataset = DB::getInstance()->query('SELECT `id` FROM `'.PREFIX.'dataset` WHERE accountid = '.SessionAccountHandler::getId())->fetchAll();\n\n\t\tforeach ($dataset as $set) {\n\t\t\t$id = $set['id'];\n\t\t\t$modus = isset($_POST[$id.'_modus']) && $_POST[$id.'_modus'] == 'on' ? 2 : 1;\n\t\t\tif (isset($_POST[$id.'_modus_3']) && $_POST[$id.'_modus_3'] == 3)\n\t\t\t\t$modus = 3;\n\n\t\t\t$columns = array(\n\t\t\t\t'modus',\n\t\t\t\t'summary',\n\t\t\t\t'position',\n\t\t\t\t'style',\n\t\t\t\t'class'\n\t\t\t);\n\t\t\t$values = array(\n\t\t\t\t$modus,\n\t\t\t\t(isset($_POST[$id.'_summary']) && $_POST[$id.'_summary'] == 'on' ? 1 : 0),\n\t\t\t\tisset($_POST[$id.'_position']) ? (int)$_POST[$id.'_position'] : '',\n\t\t\t\tisset($_POST[$id.'_style']) ? htmlentities($_POST[$id.'_style']) : '',\n\t\t\t\tisset($_POST[$id.'_class']) ? htmlentities($_POST[$id.'_class']) : ''\n\t\t\t);\n\n\t\t\tDB::getInstance()->update('dataset', $id, $columns, $values);\n\t\t}\n\n\t\tCache::delete('Dataset');\n\t\tAjax::setReloadFlag(Ajax::$RELOAD_DATABROWSER);\n\t}", "public function prepareResults()\n {\n $final_imageset = $this->_imagesets;\n foreach ($this->_imagesets as $run_id => $imageset) {\n if (!$this->_validateOutFiles($imageset['out_images'])) {\n unset($final_imageset[$run_id]);\n break;\n }\n $final_imageset[$run_id]['recordtodb'] = isset($imageset['out_images']['main']);\n// unset ($final_imageset[$run_id]['out_images']);\n foreach ($this->_image->getColours() as $colour) {\n $tmp_colour = $imageset[$colour];\n $final_imageset[$run_id][$colour] = $tmp_colour['colour'];\n $final_imageset[$run_id]['imlev'] = $tmp_colour['levels']['imlev'];\n foreach (['r', 'v'] as $levtype) {\n foreach (['min', 'max'] as $minmax) {\n $minkey = sprintf(\"%s%s_%s\", $minmax, $colour, $levtype);\n $final_imageset[$run_id][$minkey] = $tmp_colour['levels'][$levtype][$minmax];\n }\n }\n }\n $final_imageset[$run_id] = array_merge($final_imageset[$run_id], $this->_commons);\n }\n return $final_imageset;\n }", "public function RunDataProcess()\n {\n // TODO: Implement RunDataProcess() method.\n }", "public function prepareData() {\r\n $sections = GearSection::getAll($this->id_shop);\r\n $this->smarty->assign('sections', $sections);\r\n $data = array();\r\n foreach($sections as $section) {\r\n $opts = GearOption::getBySection($section->id, $this->id_shop);\r\n $std = new stdClass();\r\n $std->id = $section->id;\r\n $std->name = $section->name;\r\n $std->label = $section->label;\r\n $std->options = $opts;\r\n array_push($data, $std);\r\n }\r\n \r\n if ($this->imported) { // generate css after import\r\n require_once 'classes/FrontStyle.php';\r\n FrontStyle::generateGearCss($data);\r\n }\r\n \r\n return $data;\r\n }", "private function getHosts()\n {\n foreach ($this->events as $event) {\n $this->hosts = array_unique(array_merge($this->hosts, array_map(function ($host) { return $host->host_name; }, $event->hosts)));\n }\n }", "protected function _process() {}", "protected function _process() {}", "protected function _process() {}", "protected function _process() {}", "public function parse()\n\t{\n\t\t$this->parseGroups();\n\t\t$this->parseBadges();\n\t}", "function SetUpDisplayGrps() {\n\t\tglobal $deals_details;\n\t\t$sWrk = @$_GET[EWRPT_TABLE_GROUP_PER_PAGE];\n\t\tif ($sWrk <> \"\") {\n\t\t\tif (is_numeric($sWrk)) {\n\t\t\t\t$this->DisplayGrps = intval($sWrk);\n\t\t\t} else {\n\t\t\t\tif (strtoupper($sWrk) == \"ALL\") { // display all groups\n\t\t\t\t\t$this->DisplayGrps = -1;\n\t\t\t\t} else {\n\t\t\t\t\t$this->DisplayGrps = 50; // Non-numeric, load default\n\t\t\t\t}\n\t\t\t}\n\t\t\t$deals_details->setGroupPerPage($this->DisplayGrps); // Save to session\n\n\t\t\t// Reset start position (reset command)\n\t\t\t$this->StartGrp = 1;\n\t\t\t$deals_details->setStartGroup($this->StartGrp);\n\t\t} else {\n\t\t\tif ($deals_details->getGroupPerPage() <> \"\") {\n\t\t\t\t$this->DisplayGrps = $deals_details->getGroupPerPage(); // Restore from session\n\t\t\t} else {\n\t\t\t\t$this->DisplayGrps = 50; // Load default\n\t\t\t}\n\t\t}\n\t}", "public function output_all()\n\t{\n\t\tFsb::$tpl->set_file('forum/forum_portail.html');\n\n\t\t// On affiche les modules\n\t\t$sql = 'SELECT pm_name, pm_position\n\t\t\t\tFROM ' . SQL_PREFIX . 'portail_module\n\t\t\t\tWHERE pm_activ = 1\n\t\t\t\tORDER BY pm_order';\n\t\t$result = Fsb::$db->query($sql, 'portail_module_');\n\t\twhile ($row = Fsb::$db->row($result))\n\t\t{\n\t\t\tif ($this->output_module($row['pm_name']))\n\t\t\t{\n\t\t\t\t// On affiche le template du block dynamiquement\n\t\t\t\tFsb::$tpl->set_blocks('portail_' . $row['pm_position'], array(\n\t\t\t\t\t'FILENAME' =>\t'portail_' . $row['pm_name'] . '.html',\n\t\t\t\t));\n\t\t\t}\n\t\t}\n\t\tFsb::$db->free($result);\n\t}", "function pi_authoring_render_group_tree($group_list, &$group_data)\n{\n\t$rows_to_return = array();\n\t// Check everything in the list and return either the name or the \n\t// expanded sub-list (if it's an array) \n\tforeach($group_list as $group_id => $group_items) \n\t{\n\t\t$item_name = theme('pi_group_title', l($group_data[$group_id]['title'], 'node/' . $group_id . '/edit', array('query' => drupal_get_destination()) ), $group_data[$group_id]['group_type']);\t\t\n\t\tif(is_array($group_items))\n\t\t{\n\t\t\t//pi_debug_message(\"expanding $group_id :\" . count($group_items));\n\t\t\t$expanded_group_list = pi_authoring_render_group_tree($group_items, $group_data);\n\t\t\t$rows_to_return[] = theme('item_list', $expanded_group_list, $item_name);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t//pi_debug_message(\"not expanding $group_id :\" . $item_name);\n\t\t\t$rows_to_return[] = $item_name;\n\t\t}\n\t}\n\treturn $rows_to_return;\n}", "public function prepareDetailedByGroup($group_id);", "function scan_field_groups()\n {\n }", "function SetUpDisplayGrps() {\n\t\tglobal $dealers_reports;\n\t\t$sWrk = @$_GET[EWRPT_TABLE_GROUP_PER_PAGE];\n\t\tif ($sWrk <> \"\") {\n\t\t\tif (is_numeric($sWrk)) {\n\t\t\t\t$this->DisplayGrps = intval($sWrk);\n\t\t\t} else {\n\t\t\t\tif (strtoupper($sWrk) == \"ALL\") { // display all groups\n\t\t\t\t\t$this->DisplayGrps = -1;\n\t\t\t\t} else {\n\t\t\t\t\t$this->DisplayGrps = 50; // Non-numeric, load default\n\t\t\t\t}\n\t\t\t}\n\t\t\t$dealers_reports->setGroupPerPage($this->DisplayGrps); // Save to session\n\n\t\t\t// Reset start position (reset command)\n\t\t\t$this->StartGrp = 1;\n\t\t\t$dealers_reports->setStartGroup($this->StartGrp);\n\t\t} else {\n\t\t\tif ($dealers_reports->getGroupPerPage() <> \"\") {\n\t\t\t\t$this->DisplayGrps = $dealers_reports->getGroupPerPage(); // Restore from session\n\t\t\t} else {\n\t\t\t\t$this->DisplayGrps = 50; // Load default\n\t\t\t}\n\t\t}\n\t}", "private function parse()\r\n\t{\r\n\t\t// Suppress annoying notices/warnings\r\n\t\tset_error_handler(function() { /* Nothing */ }, E_NOTICE|E_WARNING);\r\n\r\n\t\t$structure = mailparse_msg_get_structure($this->resource);\r\n\t\t$this->parts = array();\r\n\t\tforeach ($structure as $part_id) {\r\n\t\t\t$part = mailparse_msg_get_part($this->resource, $part_id);\r\n\t\t\t$this->parts[$part_id] = mailparse_msg_get_part_data($part);\r\n\t\t}\r\n\r\n\t\trestore_error_handler();\r\n\t}", "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 process()\n {\n $configurationDataSet = [\n 'database' => [\n 'server' => $this->getValue('db_server'),\n 'database' => $this->getValue('db_database'),\n 'username' => $this->getValue('db_username'),\n 'password' => $this->getValue('db_password'),\n 'prefix' => ''\n ]\n ];\n\n Modules_Pleskdockerusermanager_Configfile::setServiceConfigurationData($configurationDataSet);\n }", "protected function parse(): void\n {\n parent::parse();\n $this->template->assign('dataGrid', (string) $this->dataGrid->getContent());\n }", "public function collectData(){\n\t\t// Simple HTML Dom is not accurate enough for the job\n\t\t$content = getContents($this->getURI())\n\t\t\tor returnServerError('No results for LWNprev');\n\n\t\tlibxml_use_internal_errors(true);\n\t\t$html = new DOMDocument();\n\t\t$html->loadHTML($content);\n\t\tlibxml_clear_errors();\n\n\t\t$cat1 = '';\n\t\t$cat2 = '';\n\n\t\tforeach($html->getElementsByTagName('a') as $a){\n\t\t\tif($a->textContent === 'Multi-page format'){\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t$realURI = self::URI . $a->getAttribute('href');\n\t\t$URICounter = 0;\n\n\t\t$edition = $html->getElementsByTagName('h1')->item(0)->textContent;\n\t\t$editionTimeStamp = strtotime(\n\t\t\tsubstr($edition, strpos($edition, 'for ') + strlen('for '))\n\t\t);\n\n\t\tforeach($html->getElementsByTagName('h2') as $h2){\n\t\t\tif($h2->getAttribute('class') !== 'SummaryHL'){\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\t$item = array();\n\n\t\t\t$h2NextSibling = $h2->nextSibling;\n\t\t\t$this->jumpToNextTag($h2NextSibling);\n\n\t\t\tswitch($h2NextSibling->getAttribute('class')){\n\t\t\tcase 'FeatureByline':\n\t\t\t\t$item['author'] = $h2NextSibling->getElementsByTagName('b')->item(0)->textContent;\n\t\t\t\tbreak;\n\t\t\tcase 'GAByline':\n\t\t\t\t$text = $h2NextSibling->textContent;\n\t\t\t\t$item['author'] = substr($text, strpos($text, 'by '));\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$item['author'] = 'LWN';\n\t\t\t\tbreak;\n\t\t\t};\n\n\t\t\t$h2FirstChild = $h2->firstChild;\n\t\t\t$this->jumpToNextTag($h2FirstChild);\n\t\t\tif($h2FirstChild->nodeName === 'a'){\n\t\t\t\t$item['uri'] = self::URI . $h2FirstChild->getAttribute('href');\n\t\t\t}else{\n\t\t\t\t$item['uri'] = $realURI . '#' . $URICounter;\n\t\t\t}\n\t\t\t$URICounter++;\n\n\t\t\t$item['timestamp'] = $editionTimeStamp + $URICounter;\n\n\t\t\t$h2PrevSibling = $h2->previousSibling;\n\t\t\t$this->jumpToPreviousTag($h2PrevSibling);\n\t\t\tswitch($h2PrevSibling->getAttribute('class')){\n\t\t\tcase 'Cat2HL':\n\t\t\t\t$cat2 = $h2PrevSibling->textContent;\n\t\t\t\t$h2PrevSibling = $h2PrevSibling->previousSibling;\n\t\t\t\t$this->jumpToPreviousTag($h2PrevSibling);\n\t\t\t\tif($h2PrevSibling->getAttribute('class') !== 'Cat1HL'){\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t\t$cat1 = $h2PrevSibling->textContent;\n\t\t\t\tbreak;\n\t\t\tcase 'Cat1HL':\n\t\t\t\t$cat1 = $h2PrevSibling->textContent;\n\t\t\t\t$cat2 = '';\n\t\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\tbreak;\n\t\t\t}\n\t\t\t$h2PrevSibling = null;\n\n\t\t\t$item['title'] = '';\n\t\t\tif(!empty($cat1)){\n\t\t\t\t$item['title'] .= '[' . $cat1 . ($cat2 ? '/' . $cat2 : '') . '] ';\n\t\t\t}\n\t\t\t$item['title'] .= $h2->textContent;\n\n\t\t\t$node = $h2;\n\t\t\t$content = '';\n\t\t\t$contentEnd = false;\n\t\t\twhile(!$contentEnd){\n\t\t\t\t$node = $node->nextSibling;\n\t\t\t\tif(!$node || (\n\t\t\t\t\t\t$node->nodeType !== XML_TEXT_NODE && (\n\t\t\t\t\t\t\t$node->nodeName === 'h2' || (\n\t\t\t\t\t\t\t\t!is_null($node->attributes) &&\n\t\t\t\t\t\t\t\t!is_null($class = $node->attributes->getNamedItem('class')) &&\n\t\t\t\t\t\t\t\tin_array($class->nodeValue, array('Cat1HL', 'Cat2HL'))\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\t$contentEnd = true;\n\t\t\t\t}else{\n\t\t\t\t\t$content .= $node->C14N();\n\t\t\t\t}\n\t\t\t}\n\t\t\t$item['content'] = $content;\n\t\t\t$this->items[] = $item;\n\t\t}\n\t}", "function parseData(){\r\n\t\t$content = array();\r\n\t\t$this->page_id = $this->CFG->PostVars['pageid'];\r\n\t\tforeach($this->CFG->PostVars as $key=>$value){\r\n\t\t\tif(preg_match(\"/content_(.*)_(.*)/\", $key, $arr)){\r\n\t\t\t\t$field\t= $arr[1];\r\n\t\t\t\t$lang \t= $arr[2];\r\n\t\t\t\tif(is_array($content[$lang])){\r\n\t\t\t\t\t$content[$lang][$field] = $value;\r\n\t\t\t\t}\r\n\t\t\t\telse $content[$lang] = array($field => $value);\r\n\t\t\t}\r\n\t\t}\r\n\t\t\r\n\t\t$this->content = $content;\r\n\t}", "public static function pre_process() {}", "public function convertData()\n {\n foreach ($this->dataToConvert as $node) {\n $title = $node->xpath('title');\n $fileMeta = $this->retrieveFileInfo($title);\n if (empty($fileMeta) || 201 == ($fileMeta['type']) || ($fileMeta['type']) <= 0) {\n $this->message(\"ignore slash: \" . $title . \": \" . json_encode($fileMeta));\n continue;\n }\n \n $text = $node->xpath('revision/text')[0];\n if (empty($text)) {\n continue;\n }\n\n if ($fileMeta['type'] == 3 || $fileMeta['type'] == 4 || $fileMeta['type'] == 7) {\n if (strlen($text) > 1024) {\n $this->saveFile($fileMeta, $text, \".wikitext\");\n } else {\n $this->message(\"Template: \" . json_encode($fileMeta) . \" -> \" . $text);\n }\n continue;\n } else if ($fileMeta['type'] == 200) {\n $draftpath = $this->output . \"Draft/\" . $fileMeta['filename'] . \".md\";\n @unlink($draftpath);\n }\n \n $text = $this->cleanText($text, $fileMeta);\n if (empty($text)) {\n $this->message(\"cleanText empty: \" . json_encode($fileMeta));\n continue;\n }\n\n if ($this->format === \"mediawiki\") {\n $this->saveFile($fileMeta, $text, \".wikitext\");\n continue;\n }\n\n try {\n $lang = getenv(\"WIKILANG\");\n $this->message(\"pandoc: {$fileMeta['filename']}: \");\n $errpath=$this->output . \"Errors/\" . $fileMeta['filename'];\n $procOpt = [];\n $procOpt[\"stdout\"] = $errpath . \".log\";\n $procOpt[\"stderr\"] = $errpath . \".err.log\";\n $procOpt[\"timeout\"] = 3;\n if ($lang == \"en\" || mb_strlen($text) > 16*1024) {\n $procOpt[\"timeout\"] = 6;\n }\n $this->pandocOptions[\"variable\"] = [\n \"\\\"cfmtitle={$fileMeta['title']}\\\"\",\n \"\\\"cfmurl={$fileMeta['url']}\\\"\",\n \"\\\"WIKILANG={$lang}\\\"\",\n \"\\\"stdout={$errpath}.log\\\"\"\n ];\n \n file_put_contents($errpath . \".wikitext\", $text);\n $this->runPandoc($text, $procOpt);\n $text = file_get_contents($procOpt[\"stdout\"]);\n @unlink($procOpt[\"stdout\"]);\n $stderr = file_get_contents($procOpt[\"stderr\"]);\n if (mb_strlen($stderr) > 0) {\n $this->message(\"Caught stderr {$fileMeta['filename']}: \", $stderr);\n } else {\n @unlink($procOpt[\"stderr\"]);\n }\n if (empty($text)) {\n continue;\n }\n @unlink($errpath . \".wikitext\");\n } catch (\\Throwable $e) {\n $errmsg=$e->getMessage();\n $this->message(\"Caught exception {$fileMeta['filename']}: \", $errmsg);\n continue;\n }\n $text .= $this->getMetaData($fileMeta);\n $this->saveFile($fileMeta, $text);\n $this->counter++;\n }\n }", "public function fetchData() {\n \n $this->readMainDomain($this->base . \"/userdata/main\");\n $main[$this->mainDomain] = $this->mainDomain;\n\n $this->readAddOnDomains($this->base . \"/addons\");\n $this->readParkedDomains($this->base . \"/pds\");\n $this->readSubDomains($this->base . \"/sds2\");\n\n $this->allDomains = array_merge($this->addOnDomains, $this->subDomains);\n $this->allDomains = array_merge($this->allDomains, $this->parkedDomains);\n $this->allDomains = array_merge($this->allDomains, $main);\n\n $this->readMail($this->base . \"/homedir/.cpanel/email_accounts.yaml\");\n\n $this->readMySQL();\n $this->readUserConfig();\n $this->readHomeDir();\n }", "function process_data($data) {\n }", "function _addNodeToLayGrp($fqhostname)\n{\n\t// check to see if the layout group exists in every OV server, \n\t// add the layout group to OV servers that do not have it and \n\t// then add the server to the layout group in each OV server. \n\t//\n\t// Inputs:\n\t//\t$fqhostname\n\t// Output: none\n\t// Dependencies:\n\t//\t$domainsuffix - global variable\n\t//\t_getParentLayGrp - function\n\t//\t_getLayoutGroup - function\n\t//\t_checkForLayoutGroup - function\n\t//\t_addLayoutGroup - function\n\t//\n\t_log(\"addNodeToLayGrp: Starting.\",\"info\");\n\tglobal $domainsuffix;\n\t\n\t$parentLayGrp = _getParentLayGrp($domainsuffix);\n\t$custLayGrp = _getLayoutGroup($domainsuffix);\n\tif ($custLayGrp == '')\n\t{\n\t\t_log(\"addNodeToLayGrp: custLayGrp ($custLayGrp) is empty. Nothing to do.\",\"debug\");\n\t}\n\telse\n\t{\n\t\t$mlmsMissingLayGrp = _checkForLayoutGroup($parentLayGrp, $custLayGrp);\n\t\tforeach ($mlmsMissingLayGrp as $ovServer)\n\t\t{\n\t\t\t_log(\"addNodeToLayGrp: adding layout group to $ovServer. \",\"debug\");\n\t\t\t_addLayoutGroup($parentLayGrp, $custLayGrp, $ovServer);\n\t\t}\n\t$custLayoutGroup = $parentLayGrp . '/' . $custLayGrp;\n\t_assignLayoutGroup($fqhostname, $custLayoutGroup);\n\t}\t\n\t_log(\"addNodeToLayGrp: Exiting.\",\"info\");\n}", "public function prepare_items() {\n\n\t\t// Roll out each part.\n\t\t$columns = $this->get_columns();\n\t\t$hidden = $this->get_hidden_columns();\n\t\t$sortable = $this->get_sortable_columns();\n\t\t$dataset = $this->table_data();\n\n\t\t// Check for the action key value to filter.\n\t\tif ( ! empty( $_REQUEST['wbr-review-filter'] ) ) { // WPCS: CSRF ok.\n\t\t\t$dataset = $this->maybe_filter_dataset( $dataset );\n\t\t}\n\n\t\t// Handle our sorting.\n\t\tusort( $dataset, array( $this, 'sort_data' ) );\n\n\t\t// Load up the pagination settings.\n\t\t$paginate = 20;\n\t\t$item_count = count( $dataset );\n\t\t$current = $this->get_pagenum();\n\n\t\t// Set my pagination args.\n\t\t$this->set_pagination_args( array(\n\t\t\t'total_items' => $item_count,\n\t\t\t'per_page' => $paginate,\n\t\t\t'total_pages' => ceil( $item_count / $paginate ),\n\t\t));\n\n\t\t// Slice up our dataset.\n\t\t$dataset = array_slice( $dataset, ( ( $current - 1 ) * $paginate ), $paginate );\n\n\t\t// Do the column headers.\n\t\t$this->_column_headers = array( $columns, $hidden, $sortable );\n\n\t\t// Make sure we have the single action running.\n\t\t$this->process_single_action();\n\n\t\t// Make sure we have the bulk action running.\n\t\t$this->process_bulk_action();\n\n\t\t// Make sure we have the status change.\n\t\t$this->process_status_change();\n\n\t\t// And the result.\n\t\t$this->items = $dataset;\n\t}", "abstract function prepare_data(&$data_arr);", "function process($input, $metadata = array()) {\n $metadata = array_merge_recursive($metadata, $this->engine_config);\n if (isset($metadata['private-fields']) && is_array($input)) {\n if (!drush_get_option('show-passwords', FALSE)) {\n if (!is_array($metadata['private-fields'])) {\n $metadata['private-fields'] = array($metadata['private-fields']);\n }\n foreach ($metadata['private-fields'] as $private) {\n drush_unset_recursive($input, $private);\n }\n }\n }\n if (isset($metadata[$this->selected_engine . '-metadata'])) {\n $engine_specific_metadata = $metadata[$this->selected_engine . '-metadata'];\n unset($metadata[$this->selected_engine . '-metadata']);\n $metadata = array_merge($metadata, $engine_specific_metadata);\n }\n if ((drush_get_context('DRUSH_PIPE')) && (isset($metadata['pipe-metadata']))) {\n $pipe_specific_metadata = $metadata['pipe-metadata'];\n unset($metadata['pipe-metadata']);\n $metadata = array_merge($metadata, $pipe_specific_metadata);\n }\n $machine_parsable = $this->engine_config['engine-info']['machine-parsable'];\n $formatter_type = $machine_parsable ? 'parsable' : 'formatted';\n if ((!$machine_parsable) && is_bool($input)) {\n $input = $input ? 'TRUE' : 'FALSE';\n }\n\n // Run $input through any filters that are specified for this formatter.\n if (isset($metadata[$formatter_type . '-filter'])) {\n $filters = $metadata[$formatter_type . '-filter'];\n if (!is_array($filters)) {\n $filters = array($filters);\n }\n foreach ($filters as $filter) {\n if (function_exists($filter)) {\n $input = $filter($input, $metadata);\n }\n }\n }\n if (isset($metadata['field-labels'])) {\n foreach (drush_hide_output_fields() as $hidden_field) {\n unset($metadata['field-labels'][$hidden_field]);\n }\n }\n return $this->format($input, $metadata);\n }", "public function processData() {\r\r\n if ( is_array($this->data) && isset($this->data['args']) )\r\r\n $this->args = array_merge($this->args, $this->data['args']);\r\r\n\r\r\n if ( is_array($this->data) && isset($this->data['value']) ) {\r\r\n // If called from back-end non-post context\r\r\n $this->e_data = $this->decode_param($this->data['value']);\r\r\n $this->data = $this->encode_param($this->data['value']);\r\r\n } else {\r\r\n // POST method or something else\r\r\n $this->e_data = $this->decode_param($this->data);\r\r\n $this->data = $this->encode_param($this->data);\r\r\n }\r\r\n // All keys are srings in array, merge it with defaults to override\r\r\n $this->e_data = array_merge($this->default_options, $this->e_data);\r\r\n /**\r\r\n * At this point the this->data variable surely contains the encoded data, no matter what.\r\r\n */\r\r\n }", "function parse_user_access($data) {\r\n $rows = explode(\"\\n\",$data);\r\n $temp_arr = array();\r\n foreach ($rows as $row) {\r\n $row = explode(',',$row);\r\n $row = array_map('trim',$row); #make sure it's clean and dandy\r\n list($m,$label,$level,$groups) = $row;\r\n if ($groups) $groups = explode('^',$groups);\r\n $temp_arr[] = array('m'=>$m, 'label'=>$label, 'level'=>$level, 'groups'=>$groups);\r\n }\r\n return $temp_arr;\r\n}", "protected function processResults($output) {\n switch(strtolower($this->printFormat)) {\n case \"list\":\n $output = explode(\"\\n\",$output);\n if(strlen($output[count($output)-1])==0) {\n unset($output[count($output)-1]);\n }\n \n $html = [\"<ul class='list-group'>\"];\n foreach($output as $row) {\n $html[] = \"<li class='list-group-item'>{$row}</li>\";\n }\n $html[] =\"</ul>\";\n $output = implode(\"\",$html);\n break;\n case \"html\":\n $output = explode(\"\\n\",$output);\n if(strlen($output[count($output)-1])==0) {\n unset($output[count($output)-1]);\n }\n \n $html = [\"<table class='table table-bordered table-hover'>\"];\n foreach($output as $row) {\n $rowArr = explode(\":::\",$row);\n $tr = [\"<tr>\"];\n foreach($rowArr as $td) {\n $tr[] = \"<td>{$td}</td>\";\n }\n $tr[] = \"</tr>\";\n $html[] = implode(\"\",$tr);\n }\n $html[] = \"</table>\";\n $output = implode(\"\",$html);\n break;\n case \"raw\":\n $output = str_replace(':::',\", \",$output);\n $output = explode(\"\\n\",$output);\n if(strlen($output[count($output)-1])==0) {\n unset($output[count($output)-1]);\n }\n if(count($output)==1 && isset($output[0])) $output = $output[0];\n break;\n }\n return $output;\n }", "protected function getGroupList() {}", "protected function getGroupList() {}", "public function processAll();", "public function preDisplay()\n {\n if (!$GLOBALS['current_user']->isAdminForModule('Users') && !$GLOBALS['current_user']->isDeveloperForModule('Users'))\n dotb_die(\"Unauthorized access to administration.\");\n\n\n //Customize Team Management - By Lap Nguyen\n include_once(\"custom/modules/Teams/_helper.php\");\n $ss = new Dotb_Smarty();\n $region = $GLOBALS['app_list_strings']['region_list'];\n $nodes = getTeamNodes();\n $ss->assign(\"MOD\", $GLOBALS['mod_strings']);\n $ss->assign(\"NODES\", json_encode($nodes));\n $ss->assign(\"APPS\", $GLOBALS['app_strings']);\n $ss->assign(\"CURRENT_USER_ID\", $GLOBALS['current_user']->id);\n\n $detail = getTeamDetail('1');\n $ss->assign(\"team_name\", $detail['team']['team_name']);\n $ss->assign(\"legal_name\", $detail['team']['legal_name']);\n $ss->assign(\"short_name\", $detail['team']['short_name']);\n $ss->assign(\"prefix\", $detail['team']['prefix']);\n $ss->assign(\"phone_number\", $detail['team']['phone_number']);\n $ss->assign(\"team_id\", $detail['team']['team_id']);\n $ss->assign(\"parent_name\", $detail['team']['parent_name']);\n $ss->assign(\"parent_id\", $detail['team']['parent_id']);\n $ss->assign(\"manager_user_id\", $detail['team']['manager_user_id']);\n $ss->assign(\"manager_user_name\", $detail['team']['manager_user_name']);\n $ss->assign(\"description\", $detail['team']['description']);\n $ss->assign(\"count_user\", $detail['team']['count_user']);\n $ss->assign(\"region\", $detail['team']['region']);\n $ss->assign(\"select_region\", $region);\n\n echo $ss->fetch('custom/modules/Teams/tpls/TeamManagement.tpl');\n dotb_die();\n }", "function acf_prepare_field_group_for_export($field_group = array())\n{\n}", "private function parseOutput()\n {\n// $parsedOutput = explode(' ',$this->output);\n// $this->image = new Image($parsedOutput[0]);\n// $this->resolution = $parsedOutput[1];\n\n }" ]
[ "0.6212292", "0.5999573", "0.5980784", "0.59661335", "0.58540326", "0.57325333", "0.5715561", "0.570567", "0.55291766", "0.54855925", "0.54754", "0.54718333", "0.54636836", "0.54618704", "0.5395558", "0.5395558", "0.5338626", "0.53002626", "0.5298223", "0.5285552", "0.5221871", "0.52135575", "0.51702374", "0.5165483", "0.513577", "0.5111183", "0.5103645", "0.51015", "0.50697094", "0.5057907", "0.50525814", "0.503801", "0.5034305", "0.50296086", "0.5011952", "0.5009487", "0.50048363", "0.49983653", "0.4981458", "0.4980136", "0.49644172", "0.495881", "0.49126863", "0.49118108", "0.49102715", "0.49058294", "0.48973292", "0.48892003", "0.48800573", "0.48700586", "0.48673213", "0.48590288", "0.48554146", "0.48415393", "0.48136693", "0.48101884", "0.48101884", "0.4802158", "0.4792405", "0.47902656", "0.47842598", "0.4775657", "0.47737393", "0.47721505", "0.4770349", "0.47695", "0.47679684", "0.47679684", "0.47679684", "0.47679684", "0.47493097", "0.47487783", "0.47382608", "0.47374886", "0.47328338", "0.4729388", "0.47212622", "0.47192773", "0.47190812", "0.4717495", "0.4717456", "0.4716711", "0.47156453", "0.47120744", "0.47120193", "0.47115046", "0.47112346", "0.47092023", "0.46967694", "0.46897662", "0.46859676", "0.46822566", "0.468217", "0.4681304", "0.46806848", "0.46806848", "0.46784493", "0.46781582", "0.4677654", "0.46701646" ]
0.6840964
0
Display a listing of the resource.
public function index() { // }
{ "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() { return view('kontributor.signupkontributor'); }
{ "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,[ 'no_ktp' =>'required|min:5', 'foto_ktp' =>'required|max:2000|mimes:jpg,jpeg,png', 'subject' =>'required|min:10', 'kategori' =>'required', 'judul' =>'required|min:2', 'gambarpendaftar' => 'required|max:2000|mimes:jpg,jpeg,png', ]); $slug = str_slug($request->judul,'-').'-'.time(); //nama file gambar $filename1 = $request->no_ktp.time().'.png'; $filename2 = $slug.time().'.png'; $contents = content::create([ 'judul'=> $request->judul, 'slug'=> $slug, 'subject'=>$request->subject, 'kategori'=>$request->kategori, 'user_id'=>Auth::user()->id, 'gambar'=>$filename2, 'jenis'=> 'daftar', ]); $users = Auth::user()->where('id', Auth::user()->id )->update(['no_ktp' => $request->no_ktp]); $users1 = Auth::user()->where('id', Auth::user()->id )->update(['foto_ktp' => $filename1]); //upload file $request->file('foto_ktp')->storeAs('public/fotoktp',$filename1); $request->file('gambarpendaftar')->storeAs('public/gambarpendaftar',$filename2); return redirect('/daftarkontributor/'.$slug); }
{ "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 specontencified resource.
public function show($slug) { $content = content::where('slug',$slug)->first(); if (empty($content)) { die('hard'); abort(404); } return view('kontributor.kontenpendaftar',compact('content')); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function show(Resource $resource)\n {\n //\n }", "public function show(Resource $resource)\n {\n // not available for now\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()\n\t{\n\t\t\n\t}", "public function show()\n\t{\n\n\t}", "public function display()\n {\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display()\n {\n }", "public function display() {\n echo $this->render();\n }", "public function display(){}", "public function show(Dispenser $dispenser)\n {\n //\n }", "public function show() {\n \n }", "public function show() {\n\t}", "public function display() {\n\t}", "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 display() {}", "public function display() {}", "function display() {\n\t\t$view = &$this->getView();\n\t\t$view->display();\n\t}", "function Display($resource_name, $cache_id = null, $compile_id = null)\n {\n $this->_smarty->display($resource_name, $cache_id, $compile_id);\n }", "public function show()\n {\n //\n }", "public function show()\n {\n \n }", "public function show()\n {\n \n }", "public function display()\n\t{\n\t\tparent::display();\n\t}", "public function display()\n {\n echo $this->getDisplay();\n $this->isDisplayed(true);\n }", "public function show() {\n \n \n }", "public function show()\n {\n \n }", "public function show()\n {\n \n }", "public function display() {\r\n echo $this->template;\r\n }", "public function display ()\n {\n echo $this->as_text ();\n }", "public function show()\n {\n //\n return 'Rosie can i have a dance';\n }", "public function display() {\n $data = $this->container->get('data');\n $people = $data->load('people');\n $this->render('people', ['people' => $people]);\n }", "public function show(Resena $resena)\n {\n }", "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}", "function show() {\n echo $this->fetch();\n }", "public function display() {\n\t\t$this->init();\n\t\treturn $this->output();\n\t}", "public function info(){\n $this->display('Main/Person/info') ;\n }", "public function show(ResourceManagement $resourcesManagement)\n {\n //\n }", "public function show()\n { \n \n }", "public function show()\n {\n header('Content-Type: image/' . $this->config->mimeType);\n echo $this;\n }", "public function show()\n {\n }", "public function show()\n {\n }", "public function show()\n {\n }", "public function show()\n {\n }", "public function show()\n {\n }", "public function show()\n {\n }", "public function show()\n {\n }", "public function show(ResourceSubject $resourceSubject)\n {\n //\n }", "public function show()\n\t{\n\t\t$this->process_post();\n\t\t$this->output();\n\t}", "public function display() {\n\t\techo $this->data;\n\t\treturn;\n\t}", "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 show() {\n\t\t$variables = $this->sanitize($this->data);\n\t\tif (is_array($variables)) {\n\t\t\textract($variables);\n\t\t}\n\n\t\t$this->setHeaders();\n\n\t\tob_start();\n\t\tif ($this->isPartial) {\n\t\t\trequire_once $this->pathToPartial;\n\t\t} else {\n\t\t\trequire_once $this->pathToLayout;\n\t\t}\n\t\t$this->performReplacements();\n\t\tif (ob_get_length() !== false) {\n\t\t\tob_end_flush();\n\t\t}\n\t}", "abstract protected function show();", "public function show() {\n echo $this->mountElement();\n }", "public function show();", "public function show();", "public function show();", "public function show();", "public function show(Resolucion $resolucion)\n {\n //\n }", "public function show()\n {\n\n }", "public function display()\n {\n //If the page was cached\n if ($this->isCached)\n {\n //Nothing to do, we already showed the page\n return;\n }\n return $this->route->getView()->output();\n }", "public function showAction()\n {\n $this->setPageTitle(sprintf($this->_('Show %s'), $this->getTopic()));\n\n $model = $this->getModel();\n // NEAR FUTURE:\n // $this->addSnippet('ModelVerticalTableSnippet', 'model', $model, 'class', 'displayer');\n $repeater = $model->loadRepeatable();\n $table = $this->getShowTable();\n $table->setOnEmpty(sprintf($this->_('Unknown %s.'), $this->getTopic(1)));\n $table->setRepeater($repeater);\n $table->tfrow($this->createMenuLinks($this->menuShowIncludeLevel), array('class' => 'centerAlign'));\n\n if ($menuItem = $this->findAllowedMenuItem('edit')) {\n $table->tbody()->onclick = array('location.href=\\'', $menuItem->toHRefAttribute($this->getRequest()), '\\';');\n }\n\n $tableContainer = \\MUtil_Html::create('div', array('class' => 'table-container'), $table);\n $this->html[] = $tableContainer;\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 }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show()\n {\n //\n }", "public function show(Prosiding $prosiding)\n {\n //\n }", "public function display()\n \t{\n \t\t$this->assign(\"__view\", $this->_view);\n \t\tparent::display();\n \t}", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show()\n {\n\n }", "public function show() {\n $this->buildPage();\n echo $this->_page;\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 abstract function display();", "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 showAction() {\n $model = new Application_Model_Compromisso();\n //busco o id que eu quero ver\n $comp = $model->find($this->_getParam('id'));\n //crio uma view para o id referente;\n $this->view->assign(\"compromisso\", $comp);\n }", "public function display() {\n return $this->out(call_user_func_array([$this, 'render'], func_get_args()));\n }", "public function Display()\n {\n include($this->template);\n }", "public function displayComponent() {\n\t\t\n\t\t\t$this->outputLine($this->_content);\n\t\t\t\n\t\t}", "public function show()\n { \n }", "public function show()\r\n\t{\r\n\t\t\r\n\t\t$model = $this->getProfileView();\r\n\t\t$data = array('model'=> $model);\r\n\t\t\r\n\t\treturn $this->render($data);\r\n\t\t\r\n\t}", "protected function _show() {\n if ($this->_iId == '401')\n header('HTTP/1.0 401 Authorization Required');\n\n elseif ($this->_iId == '403')\n header('HTTP/1.0 403 Forbidden');\n\n elseif ($this->_iId == '404') {\n header('Status: 404 Not Found');\n header('HTTP/1.0 404 Not Found');\n }\n\n $oTemplate = $this->oSmarty->getTemplate($this->_sController, $this->_iId);\n $this->oSmarty->setTemplateDir($oTemplate);\n return $this->oSmarty->fetch($oTemplate, UNIQUE_ID);\n }", "public function show()\n {\n include $this->path . '.php';\n }", "public function showAction() {\n\t\t$contentObject = $this->configurationManager->getContentObject()->data;\n\t\t$config = $this->configurationManager->getConfiguration(Tx_Extbase_Configuration_ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK);\n\n\t\t/** @var $dce Tx_Dce_Domain_Model_Dce */\n\t\t$dce = $this->dceRepository->findAndBuildOneByUid(\n\t\t\t$this->dceRepository->extractUidFromCType($config['pluginName']),\n\t\t\t$this->settings,\n\t\t\t$contentObject\n\t\t);\n\n\t\tif ($dce->getEnableDetailpage() && intval($contentObject['uid']) === intval(t3lib_div::_GP($dce->getDetailpageIdentifier()))) {\n\t\t\treturn $dce->renderDetailpage();\n\t\t} else {\n\t\t\treturn $dce->render();\n\t\t}\n\t}" ]
[ "0.7539245", "0.75298524", "0.7020228", "0.7020228", "0.7020228", "0.68622804", "0.6779698", "0.67589164", "0.67589164", "0.6758088", "0.6758088", "0.6742549", "0.6709684", "0.66828084", "0.6674122", "0.6666822", "0.6623894", "0.66225785", "0.66156423", "0.66156423", "0.66119665", "0.66098005", "0.6602013", "0.6592016", "0.6592016", "0.6590638", "0.6570433", "0.65509623", "0.6544392", "0.6544392", "0.6527819", "0.65224814", "0.64983195", "0.6485537", "0.6484807", "0.64840335", "0.64835006", "0.6483289", "0.64737344", "0.6463162", "0.6454856", "0.64541906", "0.6450078", "0.6450078", "0.6450078", "0.6450078", "0.6450078", "0.6450078", "0.6450078", "0.64435154", "0.64403844", "0.6436021", "0.64283466", "0.642267", "0.64034337", "0.6395277", "0.63708746", "0.63708746", "0.63708746", "0.63708746", "0.63593584", "0.6359253", "0.6357805", "0.63389343", "0.6328503", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.6309927", "0.63079256", "0.628702", "0.62815684", "0.62815684", "0.62815684", "0.62815684", "0.62815684", "0.62815684", "0.62815684", "0.62815684", "0.62815684", "0.6278519", "0.6271986", "0.6261626", "0.6254859", "0.6252624", "0.62440616", "0.6241845", "0.62418413", "0.6233743", "0.6225021", "0.6222679", "0.62149084", "0.6206656" ]
0.0
-1
Show the form for editing the specified resource.
public function edit($slug) { }
{ "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) { // }
{ "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
Report or log an exception. This is a great spot to send exceptions to Sentry, Bugsnag, etc.
public function report(Exception $exception) { parent::report($exception); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function report(Throwable $exception)\n {\n\n if (env('APP_ENV') !== 'local') {\n if ($exception instanceof ErrorException) {\n // $this->sendEmailToSupport($exception);\n Log::error($exception->getMessage());\n abort(500, \"There was an error while processing your request. Admin has been notified\");\n }\n }\n parent::report($exception);\n }", "public function report(Exception $e) {\n }", "public function report(Exception $e) {\n Log::critical(\"The application could not process a request due to an error with the internal configuration\");\n Log::critical($e);\n }", "public function report()\n {\n Log::debug('Exotel Sms Exception');\n }", "public function report()\n {\n $this->logException();\n }", "public function report(Exception $exception)\n {\n\t\t\n\t\tif($this->shouldReport($exception)){\n\t\t\tif($exception instanceof ValidationException){\n\t\t\t\t$message = $exception->validator->errors()->first();\n\t\t\t}else{\n\t\t\t\t$message = $exception->getMessage();\n\t\t\t}\n\t\t\t// 有异常就发送邮件记录,不保险,可能会死循环,选择其他替代方案(存库)或第三方\n//\t\t\tbug_email($message,$exception->__toString());\n//\t\t\tbug_wechat($message,$exception->__toString());\n\t\t}\n\t\n\t\tif (app()->bound('sentry') && $this->shouldReport($exception)) {\n\t\t\tapp('sentry')->captureException($exception);\n\t\t}\n\t\t\n parent::report($exception);\n }", "public function report(Exception $e)\n {\n Log::error($e);\n\n parent::report($e);\n }", "public function report(Exception $e)\n {\n if ($this->shouldReport($e)) {\n $this->log->error($e);\n $this->dispatchSendMail($e);\n }\n }", "public function report(Exception $e)\n {\n $logger = Zilf::$container['log'];\n $logger->error($e);\n }", "public function report(Throwable $exception)\n {\n $eMessage = $exception->getMessage();\n $ignore = [\n \"Illuminate\\\\Auth\\\\AuthenticationException\",\n \"Symfony\\\\Component\\\\HttpKernel\\\\Exception\\\\NotFoundHttpException\",\n \"Symfony\\\\Component\\\\HttpKernel\\\\Exception\\\\HttpException\",\n \"Illuminate\\\\Session\\\\TokenMismatchException\",\n \"Illuminate\\\\Database\\\\Eloquent\\\\ModelNotFoundException\",\n \"Illuminate\\\\Validation\\\\ValidationException\",\n \"NotificationChannels\\\\Discord\\\\Exceptions\\\\CouldNotSendNotification\",\n \"Symfony\\Component\\HttpKernel\\Exception\\MethodNotAllowedHttpException\",\n \"Illuminate\\\\Http\\\\Exceptions\\\\ThrottleRequestsException\",\n ];\n\n try {\n if (!in_array(get_class($exception), $ignore) && $eMessage != '') {\n if (\n config('services.discord.active') === 'ignore' ||\n (config('services.discord.active') === true && config('app.debug') === false)\n ) {\n DiscordNotificationQueueElement::exception($exception);\n }\n }\n } catch (Exception $ex) {\n }\n parent::report($exception);\n }", "public function report(Exception $exception)\n {\n $this->sendException($exception, NULL);\n parent::report($exception);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n parent::report($e);\n }", "public function report(Exception $exception)\r\n {\r\n parent::report($exception);\r\n }", "public function report(Exception $exception)\n\t{\n\t\tparent::report($exception);\n\t}", "protected function reportException(Exception $e)\n {\n $this->app[ExceptionHandler::class]->report($e);\n }", "public function report(Exception $e){\n\n //send email exception\n $this->sendEmailException($e); \n return parent::report($e);\n \n }", "public function report(Exception $e)\n {\n if ($this->shouldntReport($e)) {\n return;\n }\n\n $this->log->error($e);\n }", "public function report(Exception $exception)\n {\n if (env(\"PRODUCTION\") == 1) {\n if ($this->shouldReport($exception)) { \n $this->sendEmail($exception); // sends an email\n }\n }\n\n parent::report($exception);\n }", "public function report(Exception $e) : void\n {\n parent::report($e);\n }", "public function report(Exception $e)\n {\n if (!config('span', null)) {\n LumenTracer::setSpan('report exception', LumenTracer::getJaegerHeaders());\n }\n $info = [\n 'error_file' => $e->getFile(),\n 'error_line' => $e->getLine(),\n 'error_message' => $e->getMessage(),\n 'error_code' => $e->getCode(),\n 'trace_string' => $e->getTraceAsString(),\n ];\n set_log($info);\n info('----error----', $info);\n LumenTracer::flush();\n parent::report($e);\n dieJson(20002, '系统出错');\n\n }", "public function report (Exception $exception) {\n parent::report ($exception);\n }", "public function report(Exception $exception)\n\n {\n\n parent::report($exception);\n\n }", "abstract protected function logException(\\Exception $ex);", "public function report(Throwable $exception)\n {\n if ($this->shouldReport($exception)) {\n $this->sendEmail($exception); // sends an email\n }\n }", "public function report(Exception $e)\n\t{\n \\Log::error($e);\n\n\t\treturn parent::report($e);\n\t}", "public function report(Exception $e)\n\t{\n \\Log::error($e);\n\n\t\treturn parent::report($e);\n\t}", "public function report(Exception $exception)\n {\n if (app()->bound('sentry') && $this->shouldReport($exception)) {\n app('sentry')->captureException($exception);\n }\n if($exception instanceof \\Illuminate\\Database\\QueryException){\n Log::critical(\"Database exception: \\n \".$exception->getMessage());\n return;\n }\n parent::report($exception);\n }", "protected function handleException(Exception $exception) {\n\n $client = $this->startClient();\n\n Yii::log('sending exception report to Airbrake');\n $client->notifyOnException($exception);\n \n parent::handleException($exception);\n }", "public function report(Throwable $e)\n {\n if (App::environment() != 'testing') {\n $this->incidentCode = Str::uuid()->toString();\n $exceptionClass = get_class($e);\n\n switch ($exceptionClass) {\n case AuthenticationException::class:\n case AuthorizationException::class:\n Log::warning($e->getMessage(), [\n 'incident_code' => $this->incidentCode,\n 'context' => ['url' => url()->current()]\n ]);\n break;\n case NotFoundHttpException::class:\n $message = 'HTTP 404 Not Found';\n\n Log::notice($message,[\n 'incident_code' => $this->incidentCode,\n 'context' => [ 'Request URI' => request()->getRequestUri()]\n ]);\n break;\n default:\n Log::emergency($e->getMessage(), [\n 'incident_code' => $this->incidentCode,\n 'context' => $e->getTrace()\n ]\n );\n break;\n }\n }\n }", "public function report(Exception $e)\n {\n if (App::environment('production') && $this->shouldReport($e)) {\n Mail::raw((string)$e, function ($message) use ($e) {\n $message->subject($e->getMessage());\n $message->from(config('mail.report_error_from.address'), config('mail.report_error_from.name'));\n $message->to(config('mail.report_error_to.address'), config('mail.report_error_to.name'));\n });\n }\n\n parent::report($e);\n }", "private function logException()\n {\n switch ($this->classShortName) {\n case 'IndexException':\n case 'CreateException':\n case 'ReadException':\n case 'UpdateException':\n case 'DeleteException':\n Log::error($this->message);\n Log::error(print_r($this->getExceptionData(), true));\n break;\n default:\n Log::error($this->message);\n }\n }", "public function reportException(Exception $e)\n {\n msg(hsc($e->getMessage()), -1, $e->getLine(), $e->getFile());\n global $conf;\n if ($conf['allowdebug']) {\n msg('<pre>' . hsc($e->getTraceAsString()) . '</pre>', -1);\n }\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "public function report(Throwable $exception)\n {\n parent::report($exception);\n }", "protected function reportException(\\Throwable $e)\n {\n $this->app[ExceptionHandler::class]->report($e);\n }", "public function report(Exception $e)\n {\n if ($this->shouldntReport($e)) {\n return;\n }\n\n try {\n $logger = $this->container->make(LoggerInterface::class);\n } catch (Exception $ex) {\n throw $e; // throw the original exception\n }\n\n $logger->error($e);\n }", "public function report(Throwable $exception)\n {\n if (!$this->shouldReport($exception)) { return; }\n \\Log::error( $exception->getMessage() . \"\\t\" . $exception->getMessage() . \"\\t\" . $exception->getFile() . \"\\t\" . $exception->getLine() . \"\\t\" . get_class($exception) );\n //parent::report($exception);\n }", "public function report(Exception $e)\n {\n// Mail::send('errors.tracker', ['e' => $e], function ($message) {\n// $message->from('[email protected]', 'Dream House International');\n// $message->to('[email protected]', 'soporte')->subject('Error Tracker');\n// });\n return parent::report($e);\n }", "public function report(\\Throwable $e): void\n {\n parent::report($e instanceof ApiException ? $e->toReport() : $e);\n }", "public function report(Throwable $exception): void\n {\n parent::report($exception);\n }", "public static function sendException(\\Throwable $exception): void\n {\n if (!static::hasNewRelic()) {\n return;\n }\n\n $exceptionClass = get_class($exception);\n if (in_array($exceptionClass, static::$ignoredExceptions)) {\n return;\n }\n\n newrelic_notice_error($exception);\n }", "protected function reportException(\\Throwable $e): void\n {\n $this->app[ExceptionHandler::class]->report($e);\n }", "public function report(Exception $exception)\n {\n if (app()->runningInConsole()) {\n $input = new ArgvInput();\n $botMessage = [\n 'type' => '[command]',\n 'time' => date('Y-m-d H:i:s'),\n 'command' => (string)$input,\n 'code' => $exception->getCode(),\n 'message' => $exception->getMessage(),\n 'trace' => $exception->getTrace()[0],\n ];\n $botMessage = json_encode($botMessage, JSON_UNESCAPED_SLASHES | JSON_UNESCAPED_UNICODE);\n Log::error($botMessage);\n dispatch(new AlarmbotJob('technical', $botMessage));\n\n }\n parent::report($exception);\n }", "public function report(Exception $e)\n\t{\n\t\t// Bugsnag support OOTB\n\t\tif (app()->bound('bugsnag') && $this->shouldReport($e) && empty($e->confidential))\n\t\t{\n\t\t\tapp('bugsnag')->notifyException($e, null, \"error\");\n\t\t}\n\n\t\t// Strip stack trace from VocalogicException\n\t\tif (($e instanceof VocalogicException) && $this->shouldReport($e)\n\t\t\t&& !config('vocalogic.logVocalogicExceptionStackTrace', false))\n\t\t{\n\t\t\t$message = head(explode(\"\\n\", (string) $e));\n\t\t\treturn $this->log->error($message);\n\t\t}\n\n\t\treturn parent::report($e);\n\t}", "public function failed(\\Exception $e)\n {\n report($e);\n }", "public function failed(Throwable $exception)\n {\n dispatch(new SendBySes($this->emailLog));\n }", "function exception_handler($ex) {\n // now let the plugin send the exception to client\n $this->send_error($ex);\n // not much else we can do now, add some logging later\n exit(1);\n }" ]
[ "0.7318765", "0.72908765", "0.71845585", "0.7105745", "0.7043648", "0.69846135", "0.6970913", "0.6940964", "0.687667", "0.6841767", "0.6790746", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6757035", "0.6730407", "0.6672915", "0.6672791", "0.66491616", "0.6642951", "0.6639349", "0.66352063", "0.661748", "0.66116536", "0.66079175", "0.6570163", "0.64714813", "0.64681274", "0.64681274", "0.646719", "0.6450352", "0.6447026", "0.6446607", "0.64393204", "0.63977975", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.6391505", "0.63674283", "0.63640505", "0.6348917", "0.633648", "0.632654", "0.62953717", "0.6266167", "0.6245788", "0.62435246", "0.6234818", "0.6196636", "0.6184543", "0.6184306" ]
0.66841614
45
Render an exception into an HTTP response.
public function render($request, Exception $exception) { return parent::render($request, $exception); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function render(ServerRequestInterface $request, Throwable $exception): ResponseInterface;", "public function render($request, Throwable $e): Response\r\n {\r\n if($this->app->isDebug()){\r\n return parent::render($request, $e);\r\n }else{\r\n $data = [\r\n 'code' => $e->getCode(),\r\n 'message' => $e->getMessage(),\r\n ];\r\n if(method_exists($e, \"getStatusCode\")){\r\n $this->httpStatus = $e->getStatusCode();\r\n }\r\n $this->httpHeaders = $e->getHeaders();\r\n return $request->isAjax() ? Response::create($data, 'json', $this->httpStatus)->header($this->httpHeaders) : Response::create(config('app.exception_tmpl'), 'view', $this->httpStatus)->header($this->httpHeaders)->assign($data);\r\n\r\n }\r\n \r\n }", "public function render($request, Exception $e)\n {\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n $rendered = parent::render($request, $e);\n\n // 拦截数据库异常\n if ($e instanceof QueryException)\n {\n \\Utils\\Log::danger('数据库异常', [\n 'Exception' => \\Utils\\Util::buildException($e)\n ]);\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::ERROR,\n '服务器异常',\n env('DEBUG') ? \\Utils\\Util::buildException($e) : []\n );\n }\n // 拦截Validator异常 \n elseif ($e instanceof ValidationException) {\n $errors = $e->errors();\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::VALIDATOR_ERROR,\n current($errors)[0],\n $e->errors()\n );\n }\n // 拦截Redis异常 \n elseif ($e instanceof ConnectionException) {\n \\Utils\\Log::danger('Redis数据库异常', [\n 'Exception' => \\Utils\\Util::buildException($e)\n ]);\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::ERROR,\n '服务器异常',\n env('DEBUG') ? \\Utils\\Util::buildException($e) : []\n );\n } elseif($e instanceof HttpException) {\n return $rendered;\n }\n // 其他异常\n else {\n try {\n if (property_exists($e, 'payload'))\n {\n $payload = $e->payload;\n } else {\n $payload = [];\n }\n switch ($rendered->getStatusCode()) {\n case 404:\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::NOT_FOUND,\n $e->getMessage(),\n $payload\n );\n break;\n case 405:\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::NOT_ALLOW_METHOD,\n '不支持该请求方式',\n $payload\n );\n break;\n case 500:\n if ($e->getCode())\n {\n return \\Utils\\Response::response(\n $e->getCode(), \n $e->getMessage(), \n $payload\n );\n } else {\n \\Utils\\Log::warning(\n $e->getMessage(), \n \\Utils\\Util::buildException($e)\n );\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::DEBUG_ERROR,\n $e->getMessage(),\n \\Utils\\Util::buildException($e)\n );\n }\n break;\n default:\n \\Utils\\Log::warning(\n $e->getMessage(), \n \\Utils\\Util::buildException($e)\n );\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::DEBUG_ERROR,\n $e->getMessage(),\n \\Utils\\Util::buildException($e)\n );\n break;\n }\n } catch(\\Exception $e)\n {\n return \\Utils\\Response::response(\\Utils\\ErrorCode::ERROR, $e->getMessage(), $payload);\n }\n }\n }", "public function render($request, Exception $e)\n {\n $e = $this->prepareException($e);\n\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n }\n\n return $this->prepareResponse($request, $e);\n }", "protected function renderHttpResponse(Exception $e)\n {\n $this->getExceptionHandler()->render($e);\n }", "public function render($request, Exception $e)\n {\n $e = $this->prepareException($e);\n return parent::render($request, $e);\n }", "public function render($request, Exception $exception) {\n // regular exception\n if ($this->handler->willHandle($exception)) {\n return parent::render($request, $exception);\n }\n\n // api exception\n if (!$message = $exception->getMessage()) {\n $message = sprintf('%d %s', $exception->getStatusCode(), Response::$statusTexts[$exception->getStatusCode()]);\n }\n\n $statusCode = $exception->getStatusCode();\n $headers = $exception->getHeaders();\n\n $response = ['message' => $message, 'status_code' => $statusCode];\n\n if ($exception instanceof ApiException && $exception->hasErrors()) {\n $response['errors'] = $exception->getErrors();\n }\n\n if ($code = $exception->getCode()) {\n $response['code'] = $code;\n }\n\n if ($this->debug) {\n $response['debug'] = [\n 'line' => $exception->getLine(),\n 'file' => $exception->getFile(),\n 'class' => get_class($exception),\n 'trace' => explode(\"\\n\", $exception->getTraceAsString())\n ];\n }\n\n return new Response($response, $statusCode, $headers);\n }", "public function render($request, Exception $e)\n\t{\n\t\tif (!config('app.debug') || ($request->ajax() && !config('app.ajax_debug'))) {\n\n\t\t\tif (!$this->isHttpException($e)) {\n\n\t\t\t\tif ($e instanceof TokenMismatchException) {\n\t\t\t\t\t$e = new HttpException(SymfonyResponse::HTTP_UNAUTHORIZED, \"TokenMismatch\");\n\n\t\t\t\t} else if ($e instanceof ModelNotFoundException) {\n\t\t\t\t\t// thrown when findOrFail is called on a model\n\t\t\t\t\t$e = new NotFoundHttpException();\n\n\t\t\t\t} else {\n\t\t\t\t\t$e = new HttpException(SymfonyResponse::HTTP_INTERNAL_SERVER_ERROR, 'Internal Server Error');\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn self::responseForHTTPException($request, $e);\n\t\t}\n\t\treturn parent::render($request, $e);\n\t}", "public function render($request, Exception $e)\n {\n if($this->isReadable($e)){\n if($e instanceof ValidationException){\n //校验异常,并且确保是ajax请求的才按照我们的格式输出,否则按照框架的规则输出页面\n if($e->getResponse() instanceof RedirectResponse){\n return parent::render($request, $e);\n }\n $errors = $this->getValidationError($e);\n return responseFailed(-1,$errors);\n }else{\n return responseError($e);\n }\n }\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof CustomException) {\n return response()->view('errors.custom', [], 500);\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n if (\\Config::get('app.debug') || Input::get('raw')) {\n // Log exception\n $this->report($e);\n\n return parent::render($request, $e);\n }\n\n $ec = get_class($e);\n\n if (array_key_exists($ec, $this->exceptionResponses)) {\n $data = $this->exceptionResponses[$ec];\n $code = isset($data['code']) ? $data['code'] : null;\n\n if (!$code) {\n if (method_exists($e, 'getStatusCode')) {\n $code = $e->getStatusCode();\n } else {\n $code = 400;\n }\n }\n\n return Controller::respondAPI('', Controller::ERROR, $data['message'], $code);\n }\n\n // We only want to send the actual exception message if debug mode is enabled\n $message = Controller::getExceptionMessage($e);\n $code = $e instanceof HttpException ? $e->getStatusCode() : 500;\n // Send standard error message\n return Controller::respondAPI('', Controller::ERROR, $message, $code);\n }", "public function render($request, Exception $e)\n\t{\n\t\tif ($this->isHttpException($e))\n\t\t{\n\t\t\treturn $this->renderHttpException($e);\n\t\t}\n\t\telse if ($e instanceof OAuthException)\n\t\t{\n\t\t\treturn $this->renderOAuthException($e);\n\t\t}\n\t\telse if ($e instanceof AuthException)\n\t\t{\n\t\t\treturn $this->notifyAuthException($e);\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn parent::render($request, $e);\n\t\t}\n\t}", "public function render($request, Exception $exception)\n {\n // dd($exception);\n $data = $this->getExceptionData($exception);\n if ($data !== false) {\n return $this->makeResponse($exception, $data[1], $data[0], $data[2]);\n }\n\n return $this->getResponse($exception);\n }", "public function render()\n {\n if(strstr($this->getMessage(), 'PDOException: SQLSTATE[')) {\n if(preg_match('/SQLSTATE\\[(\\w+)\\]:(.*):(\\s+\\d)(.*):(.*)/', $this->getMessage(), $matches) === false) {\n $this->message = 'Generic SQL exception unhandled';\n }\n else {\n $this->message = empty($matches[5]) ? 'Generic SQL exception unhandled' : trim($matches[5]);\n }\n }\n else {\n $this->message = 'Generic SQL exception unhandled';\n }\n\n return response()->json(['message' => $this->getMessage()], 409);\n }", "protected function renderHttpException(HttpException $e)\n {\n $status = $e->getStatusCode();\n\n /* view()->replaceNamespace('errors', [\n resource_path('views/errors'),\n __DIR__.'/views',\n ]);\n\n if (view()->exists(\"errors::{$status}\")) {\n return response()->view(\"errors::{$status}\", ['exception' => $e], $status, $e->getHeaders());\n } else {*/\n return $this->convertExceptionToResponse($e);\n// }\n }", "public function render($request, Exception $exception)\n {\n $status = Response::HTTP_INTERNAL_SERVER_ERROR;\n $message = $exception->getMessage();\n\n if ($exception->getCode()) {\n $status = $exception->getCode();\n }\n\n if (!Arr::get(Response::$statusTexts, $status))\n {\n if (app()->environment(['production', 'prod'])) {\n $message = 'Sorry! Looks like we have a problem on the server. Please try again later.';\n }\n $status = 500;\n }\n\n $response = [\n 'code' => $status,\n 'type' => 'error',\n 'message' => $message\n ];\n\n return response()->json($response, Response::HTTP_INTERNAL_SERVER_ERROR);\n }", "public function render($request, Exception $e)\n {\n ////////////////////////////////////////////////// starts: KHEENGZ CUSTOME CODE ///////////////////////////////////////\n //Invalid Record Request Exception\n if ($e instanceof ModelNotFoundException) {\n return response()->view('errors.custom', [\n 'code'=>'304.1',\n 'header'=>'Invalid Record Request',\n 'message'=>'The Record You Are Looking For Does Not Exist'\n ]);\n }\n //File For Download Not Found Exception\n if ($e instanceof FileNotFoundException){\n return response()->view('errors.custom', [\n 'code'=>'501.4',\n 'header'=>'File Not Found',\n 'message'=>'The File You Are Looking For Or Trying To Download Does Not Exist On Our Server'\n ]);\n }\n ////////////////////////////////////////////////// end: KHEENGZ CUSTOME CODE ///////////////////////////////////////\n\n return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n {\n // raises before render\n $this->beforeRender($request, $exception);\n // get exception response data\n list($status, $error) = $this->getExceptionError($exception);\n\n return $this->makeResponse($error, $status);\n }", "public function render($request, Exception $e)\n {\n //Validation\n if ($e instanceof ValidationException) {\n return $e->getResponse();\n }\n\n // AuthorizationException\n if ($e instanceof AuthorizationException) {\n return response()->json([\n 'errors' => [\n 'title' => 'Unauthorized'\n ]\n ], 401);\n }\n\n //Http Exceptions\n if ($e instanceof HttpException) {\n $response['message'] = $e->getMessage() ?: Response::$statusTexts[$e->getStatusCode()];\n $response['status'] = $e->getStatusCode();\n\n return response()->json($response, $response['status']);\n }\n\n //Default Exception Response\n $response = [\n 'message' => 'Whoops! Something went wrong.',\n 'status' => 500\n ];\n\n if ($this->isDebugMode()) {\n $response['debug'] = [\n 'message' => $e->getMessage(),\n 'exception' => get_class($e),\n 'code' => $e->getCode(),\n 'file' => $e->getFile(),\n 'line' => $e->getLine(),\n ];\n\n //clean trace\n foreach ($e->getTrace() as $item) {\n if (isset($item['args']) && is_array($item['args'])) {\n $item['args'] = $this->cleanTraceArgs($item['args']);\n }\n $response['debug']['trace'][] = $item;\n }\n }\n\n return response()->json($response, $response['status']);\n }", "public function render($request, Exception $e)\n {\n $code = 5000;\n /*逻辑代码异常*/\n if ($e instanceof LogicException) {\n $code = $e->getMessage();\n $message = config('apicode.' . $code);\n } elseif ($e instanceof ValidationException) { // 验证异常\n// $errors = $e->errors();\n// if (is_array($errors) && !empty($errors)) {\n// $code = 5001;\n// foreach ($errors as $k => $v) {\n// $data[] = $v[0];\n// }\n// }\n $errorinfo = array_slice($e->errors(), 0, 1, false);\n $msg = array_column($errorinfo, 0);\n $message = $msg[0];\n } else {\n //prod 环境,统一返回内部错误\n $errFile = $e->getFile();\n $errLine = $e->getLine();\n $errMsg = $e->getMessage();\n $data = [\n 'errorMsg' => $errMsg,\n 'errLine' => $errLine,\n 'errFile' => $errFile\n ];\n }\n\n return response()->json([\n 'code' => $code,\n 'message' => $message ?? '内部服务器错误',\n 'data' => $data ?? [],\n ], 200);\n\n return $this->responseMessage($code);\n }", "public function render($request)\r\n\t{\r\n\t\t// Create json response\r\n\t\treturn response()->json([\r\n\t\t\t'message' => $this->message ?? 'Unknown Exception.',\r\n\t\t], ($this->code >= 100 && $this->code < 600) ? $this->code : 422);\r\n\t}", "public function render($request, Throwable $exception)\n {\n\n if (env('APP_DEBUG') == true) {\n //return parent::render($request, $exception);\n }\n $rendered = parent::render($request, $exception);\n $this->convertDefaultException($exception);\n\n $this->convert($exception, [\n PageNotFoundException::class => ResourceNotFoundException::class,\n ]);\n\n if (!$exception instanceof HttpException) {\n $errorCode = 'internal_error';\n\n if ($exception instanceof OAuthServerException) {\n $errorCode = $exception->getPrevious() ? $exception->getPrevious()->getErrorType() : null;\n } else if ($exception instanceof ThrottleRequestsException) {\n $errorCode = 'too_many_request';\n }\n\n $exception = new ApiHttpException($rendered->getStatusCode(), $errorCode, $exception->getMessage(), $this->getHeaders($exception));\n\n }\n return $this->renderResponse($exception);\n }", "public function render($request, Throwable $e): Response\n {\n if ($e instanceof \\think\\Exception) {\n return show($e->getCode(), $e->getMessage());\n }\n if ($e instanceof \\think\\exception\\HttpResponseException) {\n return parent::render($request, $e);\n }\n if (method_exists($e, \"getStatusCode\")){\n $httpStatus = $e->getStatusCode();\n }else{\n $httpStatus = $this->httpStatus;\n }\n // 添加自定义异常处理机制\n return show(config(\"status.error\"), $e->getMessage(), [], $httpStatus);\n }", "protected function renderHttpException(HttpException $e)\n {\n $status = $e->getStatusCode();\n $errorMessages = $this->handleErrorMessages($status);\n\n return response()->view(get_the_view_path('errors.index'), ['errorMessages' => $errorMessages], $status);\n }", "public function render($request, Throwable $exception)\n {\n\n $error = new \\stdClass();\n $error->code = $status = 500;\n $error->message = 'Internal Server Error.';\n\n switch (true) {\n case $exception instanceof ModelNotFoundException:\n $model = str_replace('App\\\\', '', $exception->getModel());\n $status = $error->code = 404;\n $error->message = \"{$model} not found.\";\n break;\n\n case $exception instanceof NotFoundHttpException:\n $error->code = $exception->getStatusCode();\n $error->message = 'Page not found.';\n\n break;\n\n case $exception instanceof AuthenticationException:\n $status = $error->code = 401;\n $error->message = $exception->getMessage();\n break;\n\n case $exception instanceof CustomException:\n $status = $error->code = 400;\n $error->message = $exception->getMessage();\n break;\n\n default:\n $error->code = method_exists($exception,'getStatusCode') ? $exception->getStatusCode() : $status;\n $error->message = method_exists($exception,'getMessage') ? $exception->getMessage() : $error->message;\n break;\n }\n\n $response = ['success' => false, 'error' => $error ];\n Log::debug('Exception: '.json_encode($error, JSON_UNESCAPED_UNICODE));\n\n return response()->json($response, $status);\n }", "public function render($request, Exception $e)\n {\n /*if ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n return parent::render($request, $e);*/\n $debug = env('APP_DEBUG');\n if ($debug == 0) {\n if ($this->isHttpException($e)) {\n return $this->renderHttpException($e);\n } else if ($e instanceof NotFoundHttpException) {\n return response()->view('errors.404', [], 400);\n }elseif ($e instanceof FatalErrorException) {\n return response()->view('errors.500', [], 500);\n }elseif ($e instanceof handleError) {\n return response()->view('errors.500', [], 500);\n }elseif ($e instanceof ModelNotFoundException) {\n return response()->view('errors.500', [], 500);\n }else\n {\n return response()->view('errors.500', [], 500);\n }\n }else if($debug == 1) { //si es verdadero esta en modo debug y muestra el error\n if ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n return parent::render($request, $e);\n }\n }", "public function render($request, Exception $exception)\n {\n //HTTP Error Code 405\n if ($exception instanceof MethodNotAllowedHttpException) {\n $status = Response::HTTP_METHOD_NOT_ALLOWED;\n $exception = new MethodNotAllowedHttpException(\n [],\n 'HTTP_METHOD_NOT_ALLOWED',\n $exception\n );\n }\n //HTTP Error Code 404\n elseif ($exception instanceof NotFoundHttpException) {\n $status = Response::HTTP_NOT_FOUND;\n $exception = new NotFoundHttpException('HTTP_NOT_FOUND', $exception);\n }\n //HTTP Error Code 403\n elseif ($exception instanceof AuthorizationException) {\n $status = Response::HTTP_FORBIDDEN;\n $exception = new AuthorizationException('HTTP_FORBIDDEN', $status);\n } else {\n $status = $exception->getCode() ? $exception->getCode() : Response::HTTP_INTERNAL_SERVER_ERROR;\n }\n\n\n return response()->json(\n [\n \"error\" => 'ERROR',\n 'code' => $status,\n 'message' => $exception->getMessage()\n ],\n $status\n );\n }", "public function render($request, Exception $e)\n {\n if ($request->ajax() || $request->wantsJson()) {\n $message = null;\n\n if ($e instanceof HttpException) {\n $code = 404;\n $message = 'The requested resource could not be found.';\n } else {\n $code = 500;\n }\n\n return response()\n ->json([\n 'message' => in_array(app()->environment(), ['production']) ? 'Check error logs for detailed messages' : ($message ?: ($e->getMessage() ?: strval($e))),\n 'exception' => get_class($e),\n ], $code)\n ->header('Access-Control-Allow-Origin', '*')\n ->header('Access-Control-Allow-Methods', 'POST, GET, OPTIONS, PUT, DELETE')\n ->header('Access-Control-Allow-Headers', 'Content-Type, Accept, Authorization, X-Requested-With')\n ->header('Access-Control-Max-Age', '28800');\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n { \n if ($this->shouldReport($exception)){\n $this->sendException($exception, $request);\n }\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n if (\n !$request->expectsJson()\n || empty($this->formatApiResponse)\n || !$this->formatApiResponse\n ) {\n return parent::render($request, $exception);\n }\n\n return response()->error(\n $exception->getMessage(),\n $this->getStatus($exception),\n $this->getErrors($exception)\n );\n }", "protected function renderAsError() {}", "public static function exception_handler($exception) { \n ResponseFactory::send($exception->getMessage()); //Send exception message as response.\n }", "public function render($request, Exception $exception)\n {\n $errorCode = null;\n $httpResponseCode = null;\n $errorMsg = [];\n $errorArray = null;\n if ($exception instanceof AppException) {\n $errorCode = $exception->getCode();\n $errorMsg = $exception->getMessage();\n $httpResponseCode = $exception->getHttpResponseCode();\n $errorArray = $exception->getErrors();\n } else {\n return parent::render($request, $exception);\n }\n\n if (is_string($errorArray)) {\n $errorArray = null;\n }\n\n $httpResponseCode = (empty($httpResponseCode)) ? 404 : $httpResponseCode;\n $errorCode = (empty($httpResponseCode)) ? $errorCode : $httpResponseCode;\n $responseArray = $this->createErrorResponse($errorCode, $httpResponseCode, $errorMsg, $errorArray);\n\n return response($responseArray, $httpResponseCode);\n }", "public function actionException()\n {\n $this->render('exception');\n }", "public function render($request, Exception $e)\n {\n //如果$exception 是 ApiException的一个实例,则自定义返回的错误信息\n if($e instanceof ApiException){\n $result = [\n \"code\" => 9999,\n \"msg\" => $e -> getMessage(),\n \"data\" => \"\"\n ];\n return response() -> json($result);\n }\n //自定义错误页面\n if ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n\n if($e instanceof \\Symfony\\Component\\Debug\\Exception\\FatalErrorException\n && !config('app.debug')) {\n return response() -> view('errors.default', [], 500);\n }\n //如果不是,则使用 父类的处理方法\n return parent::render($request, $e);\n }", "protected function render(Throwable $e, Input $input) : Response\n {\n return call_user_func($this->getRenderer(), $e, $input);\n }", "public function render($request, Throwable $e)\n {\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n } elseif ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n } elseif ($e instanceof AuthorizationException) {\n $e = new HttpException(403, $e->getMessage());\n } elseif ($e instanceof ValidationException && $e->getResponse()) {\n return $e->getResponse();\n }\n\n if ($this->isHttpException($e)) {\n return $this->toIlluminateResponse($this->renderHttpException($e), $e);\n } else {\n return $this->toIlluminateResponse($this->convertExceptionToResponse($e), $e);\n }\n }", "private function renderOAuthException(OAuthException $e)\n\t{\n\t\tif (view()->exists('errors.403'))\n\t\t{\n\t\t\treturn response()->view('errors.403', ['message' => $e->getMessage()], 403);\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn (new SymfonyDisplayer(config('app.debug')))->createResponse($e);\n\t\t}\n\t}", "public function render($request, Throwable $e): Response\n {\n if($e instanceof \\think\\Exception){\n return json_response($e->getCode(),$e->getMessage());\n }\n if($e instanceof \\think\\exception\\HttpResponseException){\n return parent::render($request,$e);\n }\n // 添加自定义异常处理机制\n if(method_exists($e,'getStatusCode')){\n $this->httpStatusCode = $e->getStatusCode();\n }\n return json_response(config('status.error'),$e->getMessage(),[], $this->httpStatusCode);\n // 其他错误交给系统处理\n //return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n {\n\n $TraceException = [\n 'class' => get_class($exception),\n 'file' => $exception->getFile(),\n 'line_of_code' => $exception->getLine(),\n 'code' => $exception->getCode(),\n 'trace' => $exception->getTraceAsString()\n ];\n\n if ($exception instanceof ModelNotFoundException) {\n $arrModel = explode(\"\\\\\",$exception->getModel());\n $model = end($arrModel);\n return renderResponse([\n 'status' => FALSE, \n 'message' => ucfirst($model.' '.config('mamikos.message.data_not_found'))\n ],404);\n }\n\n if ($exception instanceof NotFoundHttpException) {\n return renderResponse([\n 'status' => FALSE, \n 'message' => config('mamikos.message.route_not_found'),\n // 'exception' => $TraceException\n ],404);\n }\n\n if($exception instanceof \\Illuminate\\Auth\\AuthenticationException ){\n return renderResponse([\n 'status' => FALSE, \n 'message' => $exception->getMessage()\n ],401);\n }\n\n if($exception instanceof ValidationException){\n $errors = [];\n foreach ($exception->errors() as $key => $value) {\n $errors[] = $value[0];\n\n if($key==0){break;} \n }\n return renderResponse([\n 'status' => FALSE, \n 'message' => $errors[0]\n ],400);\n }\n\n $response = [\n 'status' => FALSE,\n 'message' => $exception->getMessage(),\n 'exception' => $TraceException\n ];\n // return parent::render($request, $exception);\n return renderResponse($response, 404);\n }", "public function getResponseException(Exception $e)\n\t{\n\t\t$message = htmlentities($e->getMessage(), ENT_COMPAT, \"UTF-8\");\n\t\tswitch($this->outputFormat)\n\t\t{\n\t\t\tcase 'original':\n\t\t\t\tthrow $e;\n\t\t\tbreak;\n\t\t\tcase 'xml':\n\t\t\t\t@header(\"Content-Type: text/xml;charset=utf-8\");\n\t\t\t\t$return =\n\t\t\t\t\t\"<?xml version=\\\"1.0\\\" encoding=\\\"utf-8\\\" ?>\\n\" .\n\t\t\t\t\t\"<result>\\n\".\n\t\t\t\t\t\"\\t<error message=\\\"\".$message.\"\\\" />\\n\".\n\t\t\t\t\t\"</result>\";\n\t\t\tbreak;\n\t\t\tcase 'json':\n\t\t\t\t@header( \"Content-type: application/json\" );\n\t\t\t\t// we remove the \\n from the resulting string as this is not allowed in json\n\t\t\t\t$message = str_replace(\"\\n\",\"\",$message);\n\t\t\t\t$return = '{\"result\":\"error\", \"message\":\"'.$message.'\"}';\n\t\t\tbreak;\n\t\t\tcase 'php':\n\t\t\t\t$return = array('result' => 'error', 'message' => $message);\n\t\t\t\tif($this->caseRendererPHPSerialize())\n\t\t\t\t{\n\t\t\t\t\t$return = serialize($return);\n\t\t\t\t}\n\t\t\tbreak;\n\t\t\tdefault:\n\t\t\t\t$return = 'Error: '.$message;\n\t\t\tbreak;\n\t\t}\n\t\treturn $return;\n\t}", "public function render($request, Exception $exception)\n {\n $e = $this->prepareException($exception);\n\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n } elseif ($e instanceof AuthenticationException) {\n $status = Response::HTTP_UNAUTHORIZED;\n $message = '認証に失敗しました。ログインしてください。';\n $errors = [];\n $trace = [];\n } elseif ($e instanceof ValidationException) {\n $status = $e->status;\n $message = Response::$statusTexts[$status];\n $errors = $e->errors();\n $trace = [];\n } elseif ($this->isHttpException($e)) {\n $status = $e->getCode();\n if ($status == 0) {\n $status = 400;\n }\n $message = $e->getMessage();\n $errors = [];\n $trace = [];\n } else {\n $code = env('APP_DEBUG', true) ? $e->getCode() : Response::HTTP_INTERNAL_SERVER_ERROR;\n if (isset($code)) {\n $code = Response::HTTP_INTERNAL_SERVER_ERROR;\n }\n $status = $code;\n $message = env('APP_DEBUG', true) ? $e->getMessage() : 'サーバエラーが発生しました。管理者に連絡してください。';\n $errors = [];\n $trace = env('APP_DEBUG', true) ? $e->getTrace() : [];\n }\n\n // ResponseApiServiceProviderが実行される前にエラーが発生した場合の対応\n if (!method_exists(response(), 'error')) {\n $app = app();\n $provide = new ResponseApiServiceProvider($app);\n $provide->boot();\n }\n\n return response()->error($message, $errors, $trace, $status);\n }", "public function render($request, Throwable $e)\n {\n if ($e instanceof MethodNotAllowedHttpException) {\n return $this->methodNotAllowed(__('errors.method_not_allowed'));\n }\n\n if ($e instanceof NotFoundHttpException) {\n return $this->notFound(__('errors.not_found'));\n }\n\n if ($e instanceof ModelNotFoundException) {\n return $this->notFound(__('errors.not_found'));\n }\n\n if ($e instanceof ValidationException) {\n return $this->failedValidation(__('errors.validation_failed'), $e->errors());\n }\n\n if ($e instanceof AuthenticationException) {\n return $this->unauthorized($e->getMessage());\n }\n\n return $this->buildResponse($e->getMessage(), 'failed', config('errors.codes.server_error'));\n }", "public function render($request, Throwable $exception)\n {\n $codigo = 500;\n $message = 'Ocorreu algum problema.';\n\n if($exception instanceof ValidationException){\n $message = $exception->errors();\n } else {\n $message = $exception->getMessage();\n\n }\n\n $resposta = ['message' => $message];\n\n if (config('app.debug')) {\n $resposta['exception'] = get_class($exception);\n $resposta['message'] = $message;\n $resposta['trace'] = $exception->getTrace();\n $resposta['line'] = $exception->getLine();\n $resposta['file'] = $exception->getFile();\n }\n\n return response()->json($resposta, $codigo);\n }", "public function render(Throwable $e)\n {\n if ($e instanceof ResourceNotFoundException) {\n // 404\n $template = $this->app->make(ViewFactory::class);\n echo $template->make('vendor/404');\n exit();\n }\n throw $e;\n }", "public function render($request, Exception $ex)\n {\n if ($request->ajax()) {\n return $this->renderAsJson($request, $ex);\n }\n\n // render HttpException as request aware ones\n if ($this->isHttpException($ex)) {\n return $this->toIlluminateResponse($this->renderRequestAwareHttpException($request, $ex), $ex);\n }\n\n return parent::render($request, $ex);\n }", "public function render()\n {\n return $this->throw();\n }", "public function render($request, Throwable $exception)\n {\n // return parent::render($request, $exception);\n\n if ($exception instanceof ValidationException) {\n return $this->convertValidationExceptionToResponse($exception, $request);\n }\n\n if ($exception instanceof ModelNotFoundException) {\n $modelo = strtolower(class_basename($exception->getModel()));\n return $this->errorResponse(\"There is no instance of {$modelo} with the specified id\", 404);\n }\n\n if ($exception instanceof AuthorizationException) {\n return $this->errorResponse(\"You do not have authorization to execute this action\", 403);\n }\n\n if ($exception instanceof NotFoundHttpException) {\n return $this->errorResponse('The specified URL was not found', 404);\n }\n\n if ($exception instanceof MethodNotAllowedHttpException) {\n return $this->errorResponse('The method specified in the request is invalid', 405);\n }\n\n if ($exception instanceof HttpException) {\n return $this->errorResponse($exception->getMessage(), $exception->getStatusCode());\n }\n\n if ($exception instanceof QueryException) {\n $codigo = $exception->errorInfo[1];\n\n if ($codigo == 1451) {\n return $this->errorResponse('The resource cannot be permanently removed because it is related to some other.', 409);\n }\n }\n\n if (config('app.debug')) {\n return parent::render($request, $exception); \n }\n\n return $this->errorResponse('Unexpected failure. Try later', 500);\n }", "public function render($request, Exception $e)\n {\n if ($this->isResponseException($e)) {\n return parent::render($request, $e);\n }\n\n if ($this->isNotFountException($e)) {\n if ($request->ajax() || $request->wantsJson()) {\n return new JsonResponse(['404: ' . $e->getMessage()], 404);\n }\n\n return response()->view('errors.404', ['exception' => $e], 404);\n }\n\n if (config('app.debug')) {\n return $this->handleInDebugMode($request, $e);\n }\n\n return $this->handleInProductionMode($request, $e);\n }", "protected function webHandleException($request, Exception $exception)\n {\n return parent::render($request, $exception);\n }", "static public function responseForHTTPException($request, HttpException $exception) {\n\n \t\tif ($request->ajax()) {\n \t\t\t\t// error message and status code\n return response($exception->getMessage(), $exception->getStatusCode());\n } else {\n\t\t \t\t$data = [\n \"statusCode\" => $exception->getStatusCode(),\n \"statusText\" => SymfonyResponse::$statusTexts[$exception->getStatusCode()],\n \"errorMsg\" => $exception->getMessage()\n ];\n return response()->view('errors.error', $data, $exception->getStatusCode());\n }\n \t}", "public function render($request, Throwable $e)\n {\n if ($e instanceof MethodNotAllowedHttpException) {\n return $this->notAllowedResponse('The method you are calling is not allowed');\n }\n\n if ($e instanceof NotFoundHttpException) {\n return $this->notFoundResponse($e->getMessage() ? $e->getMessage() : 'we could not found what you are looking for');\n }\n\n if ($e instanceof ValidationException) {\n return $this->formValidationResponse('The validation has failed', $e->errors());\n }\n\n if ($e instanceof AuthenticationException) {\n return $this->notAllowedResponse($e->getMessage());\n }\n\n if ($e instanceof AuthorizationException) {\n return $this->notAllowedResponse($e->getMessage());\n }\n\n return $this->serverErrorResponse('Sorry an error occured, we are working on it', new Exception($e->getMessage()));\n }", "public function render($request, Throwable $e): Response\n {\n // 添加自定义异常处理机制\n $massageData = Env::get('app_debug', false) ? [\n 'message' => $e->getMessage(),\n 'file' => $e->getFile(),\n 'line' => $e->getLine(),\n 'trace' => $e->getTrace(),\n 'previous' => $e->getPrevious(),\n ] : [];\n\n // 添加自定义异常处理机制\n if ($e instanceof DbException) {\n return app('json')->fail('数据获取失败', $massageData);\n } elseif ($e instanceof AuthException ||\n $e instanceof ValidateException ||\n $e instanceof ApiException ||\n $e instanceof UploadException ||\n $e instanceof AdminException\n ) {\n return app('json')->make($e->getCode() ?: 400, $e->getMessage(), $massageData);\n }\n return app('json')->make($e->getCode() ?: 400, $e->getMessage(), $massageData);\n // 其他错误交给系统处理\n// return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n $url = $request->url();\n if(apiStrContains($url, '/api')) {\n $message = $e->getMessage();\n if($e instanceof MethodNotAllowedHttpException) {\n $header = $e->getHeaders()['Allow'];\n $header = explode(',', $header)[0];\n $message = 'Please send '.$header.' request.';\n }\n elseif(\n $e instanceof NotFoundHttpException ||\n $e instanceof InvalidArgumentException\n ) {\n $message = 'API not found';\n }\n else if($e instanceof UnauthorizedHttpException) {\n $message = 'Login authenication failed';\n }\n elseif (\n $e instanceof BadMethodCallException ||\n $e instanceof FatalThrowableError ||\n $e instanceof QueryException\n ) {\n $message = $e->getMessage();\n }\n return apiResponse(false, 403, $message);\n }\n return parent::render($request, $e);\n\n }", "public function render($request, Exception $exception)\n {\n // Json error exceptions\n if ($request->wantsJson())\n {\n // This will replace our 404 response with a JSON response.\n if ($exception instanceof ModelNotFoundException)\n {\n return response()->json([\n 'code' => 404,\n 'message' => 'Resource not found.'\n ], 404);\n }\n // This will replace our 404 response with a JSON response.\n if ($exception instanceof ValidationException)\n {\n //dd($exception);\n return response()->json([\n 'code' => $exception->status,\n 'message' => 'The given data was invalid.',\n 'errors' => $exception->errors(),\n ], $exception->status);\n }\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $exception)\n {\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $e): Response\n {\n // 添加自定义异常处理机制\n\n if ($e instanceof ValidateException) {\n return Response::create(['message' => $e->getMessage(), 'code' => 50015], 'json', 200);\n }\n\n if ($e instanceof SystemException) {\n return Response::create(['message' => $e->getMessage(), 'code' => $e->getCode()], 'json', 200);\n }\n\n // 其他错误交给系统处理\n return parent::render($request, $e);\n }", "public function apiException($request, $e)\n {\n if ($e instanceof ModelNotFoundException) {\n\n return $this->modelRes($e);\n } else if ($e instanceof NotFoundHttpException) {\n\n return $this->httpRes($e);\n } else if ($e instanceof AuthorizationException) {\n\n return $this->accessDeniedRes($e);\n } else {\n\n return parent::render($request, $e);\n }\n }", "public function render($request, Exception $exception)\n {\n // 参数验证错误的异常,我们需要返回 400 的 http code 和一句错误信息 1104\n if ($exception instanceof ValidationException) {\n // $code = 1104;\n // return response(['error' => array_first(array_collapse($exception->errors()))], 400);\n return $this->getResultByCode(1104, Arr::first(Arr::collapse($exception->errors())));\n }\n // 用户认证的异常,我们需要返回 401 的 http code 和错误信息\n if ($exception instanceof UnauthorizedHttpException) {\n // return response($exception->getMessage(), 401);\n $this->getResultByCode(401, $exception->getMessage());\n }\n\n if ($exception instanceof AuthenticationException) {\n return $this->getResultByCode(1200);\n }\n\n if ($exception instanceof ModelNotFoundException) {\n return $this->getResultByCode(404);\n }\n\n if ($exception instanceof QueryException) {\n // return response()->json(['code' => '500', 'reason' => 'Internal Server Error', 'data' => ''], 500);\n }\n\n // JWT exception\n if ($exception instanceof TokenBlacklistedException) {\n return $this->getResultByCode(5001);\n }\n\n // 2018-12-27 Missing404Exception 未生成全文索引的错误\n // if ($exception instanceof Missing404Exception) {\n // return $this->getResultByCode(5002);\n // }\n\n return parent::render($request, $exception);\n }", "public function render($request, \\Throwable $e)\n {\n $e = $this->resolveException($e);\n\n $response = response()->json($this->formatApiResponse($e), $e->getCode(), $e->getHeaders());\n\n return $response->withException($e);\n }", "public function render($request, Exception $e){\n\n if($e instanceof ModelNotFoundException){\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n \n if($e instanceof ForbiddenException){\n \n if($request->ajax()){\n return response()->json(['mensagem' => $e->getMessage()], 403);\n }\n \n return response()->view('errors.403', ['mensagem' => $e->getMessage()]);\n \n }\n \n if($e instanceof NotFoundException){ \n \n if($request->ajax()){\n return response()->json(['mensagem' => $e->getMessage()], 404);\n }\n \n return response()->view('errors.404', ['mensagem' => $e->getMessage()]);\n \n }\n \n return parent::render($request, $e);\n \n }", "public function render($request, Throwable $exception)\n {\n if ($exception instanceof \\Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException) {\n // return generated error response\n return response()->json([\n 'message' => 'Resources not found'\n ], 404);\n }\n\n // Store log to /storage/logs/api-[y-m-d].log\n Log::channel('api')->error(json_encode([\n 'id' => $request->id,\n 'exception' => [\n 'code' => $exception->getCode(),\n 'message' => $exception->getMessage(),\n 'file' => $exception->getFile(),\n 'line' => $exception->getLine(),\n // 'trace' => $exception->getTraceAsString(),\n ]\n ]));\n\n // return generated error response\n return response()->json([\n 'message' => 'There\\'s something wrong with the system. Please contact us for further information.'\n ], 500);\n }", "public function render($request, Exception $exception)\n {\n $route = $request->route();\n if (!$route || in_array('api', $route->middleware())) {\n $request->headers->set('Accept', 'application/json');\n }\n\n if ($exception instanceof ErrorHttp) {\n return $this->answerWith($exception);\n }\n\n if ($exception instanceof UnauthorizedHttpException) {\n $message = 'Unauthorized';\n $data = [];\n if ($exception->getMessage() === 'Token has expired') {\n $data['token'] = 'expired';\n }\n return $this->answerError($message, Status::CODE_401, $data);\n }\n\n if ($exception instanceof QueryException) {\n $bindings = $exception->getBindings();\n if (!is_array($bindings)) {\n $bindings = [$bindings];\n }\n foreach ($bindings as $key => $binding) {\n $bindings[$key] = Encoding::fixUTF8($binding);\n }\n $message = Encoding::fixUTF8($exception->getMessage());\n $data = [\n 'sql' => $exception->getSql(),\n 'bindings' => $bindings,\n ];\n return $this->answerError($message, Status::CODE_500, $data);\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n $handler = $this->findExceptionResponseHandler($exception);\n\n if (!is_null($handler)) {\n return $handler->render();\n }\n\n if (!method_exists($exception, 'getErrorTitle')) {\n $handler = new Response\\UnknownErrorHandler;\n\n return $handler->render();\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n /**\n * check if the request was an api request\n * this step just for returning json response\n * @author Amr\n */\n// dd($exception);\n if ($request->isJson() || $request->is('api/*')) {\n if ($exception instanceof RouteNotFoundException)\n return response()->api(ERROR_RESPONSE, trans('Auth::lang.not_authorized'), [], NOT_AUTHORIZED_ACCESS);\n else if ($exception instanceof ValidationException) {\n $errors = $exception->validator->errors();\n return response()->api(ERROR_RESPONSE, $errors->first(), prepare_error_attrs_keys($errors), VALIDATION_EXCEPTION);\n } else if ($exception instanceof ModelNotFoundException) {\n return response()->api(ERROR_RESPONSE, trans('lang.resource_not_found'), [], RESOURCE_NOT_FOUND);\n } else if ($exception instanceof AuthenticationException) {\n return response()->api(ERROR_RESPONSE, trans('Auth::lang.unauthenticated'), [], UNAUTHENTICATED_ERROR);\n }\n return response()->api(ERROR_RESPONSE, $exception->getMessage(), [], $exception->getCode());\n }\n\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n if ($request->wantsJson()) {\n return $this->handleApiException($request, $exception);\n } else {\n return parent::render($request, $exception);\n }\n }", "protected abstract function render(Response $response);", "public function render($request, Throwable $exception)\n {\n switch ($exception)\n {\n case $exception instanceof ModelNotFoundException && count($exception->getIds()) === 1:\n /* Handle model not found when querying a single entity */\n $id = array_first($exception->getIds());\n /*\n * IF $existed == true : the user has requested a url for a model that was deleted\n * IF $existed == false : the user has requested a url for a model that never existed (possible url manipulation)\n */\n $existed = $exception->getModel()::onlyTrashed()->where('id', $id)->count() > 0;\n $entity = last(explode('\\\\', $exception->getModel()));\n $entitiesToReport = ['Tender', 'Project', 'Asset'];\n $detailKey = null;\n if(in_array($entity, $entitiesToReport, true)) {\n $detailKey = $existed ? 'ENTITY_DELETED' : 'ENTITY_NOT_FOUND';\n }\n return response()->json([\n 'detailKey' => $detailKey,\n 'entity' => $entity\n ], 404);\n // TODO: log everything\n\n default:\n return parent::render($request, $exception);\n }\n\n }", "public function render($request, Exception $exception)\n {\n $response = [];\n $response['request_id'] = '';\n $response['success'] = false;\n\n if ($exception instanceof AuthServiceException) {\n $response['request_id'] = '';\n $response['success'] = false;\n $exception_code = $exception->getCode();\n $response['response_code'] = (!empty($exception_code)) ? $exception_code : 203;\n $response['message'] = $exception->getMessage();\n return response()->json($response, 401);\n } elseif ($exception instanceof ValidationException) {\n $response['response_code'] = 101;\n $response['message'] = $exception->getMessage();\n return response()->json($response, 400);\n } elseif ($exception instanceof BlogErrorException) {\n $exception_code = $exception->getCode();\n $response['response_code'] = (!empty($exception_code)) ? $exception_code : 102;\n\n $response['message'] = $exception->getMessage();\n if (App::environment('production')) {\n $response['message'] = 'Something went wrong!';\n }\n\n return response()->json($response, 500);\n } \n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $e)\n {\n\t\t//正式环境返回错误json\n\t\tif(env('APP_DEBUG')!='true'){\n\t\t\tif($e instanceof NotFoundHttpException){\n\t\t\t\treturn response(array('code'=>404,'message'=>'the api you request is not found!','content'=>'','contentEncrypt'=>''));\n\t\t\t}\n\t\t\telse if($e instanceof MethodNotAllowedHttpException){\n\t\t\t\treturn response(array('code'=>404,'message'=>'all request should be post!','content'=>'','contentEncrypt'=>''));\n\t\t\t}\n\n\t\t}\n return parent::render($request, $e);\n }", "public static function renderHtml(Exception $exception)\n {\n $whoops = new \\Whoops\\Run;\n $handler = new PrettyPageHandler;\n $response = app()->make(ExceptionHandler::class)->convertExceptionToResponse($exception);\n\n $whoops->pushHandler($handler);\n\n return response(\n $whoops->handleException($exception),\n $response->getStatusCode(),\n $response->headers->all()\n );\n }", "public function render($request, Exception $e)\n {\n app('translator')->setLocale('zh-CN');\n $errorCode = $e->getCode();\n $statusCode = $e->getStatusCode();\n\n if ($errorCode == 2002) {\n echo json_encode(error_response('0x000022', 'common'));\n } else if ($errorCode == 10061) {\n echo json_encode(error_response('0x000023', 'common'));\n } else {\n if ($statusCode == '404') {\n echo json_encode(error_response('0x000404', 'common'));\n } else if ($statusCode == '401') {\n echo json_encode(error_response('0x000401', 'common'));\n } else {\n echo json_encode(error_response('0x000013', '', json_encode([\"file\" => $e->getFile(), \"line\" => $e->getLine()])));\n }\n }\n exit;\n\n return parent::render($request, $e);\n }", "public function sendResponse()\n {\n $this->sendHeaders();\n\n if ($this->isException() && $this->renderExceptions()) {\n $exceptions = '';\n foreach ($this->getException() as $e) {\n $exceptions .= $e->__toString() . \"\\n\";\n }\n echo $exceptions;\n return;\n }\n\n $this->outputBody();\n }", "public function render($request, Exception $exception)\n {\n if ($exception instanceof ModelNotFoundException) {\n return response()->json([\n 'error' => 'model_not_found',\n 'message' => (new \\ReflectionClass($exception->getModel()))->getShortName() . ' with such parameters does not exists.'\n ], 404);\n } elseif ($exception instanceof UnauthorizedException) {\n return response()->json([\n 'error' => 'unauthorized',\n 'message' => $exception->getMessage()\n ], 403);\n } elseif ($exception instanceof ValidationException) {\n return response()->json([\n 'error' => 'validation_failed',\n 'messages' => $exception->validator->errors()->all()\n ], 400);\n } elseif ($exception instanceof HttpException) {\n return response()->json([\n 'error' => 'http_error',\n 'message' => $exception->getMessage()\n ], $exception->getStatusCode());\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $exception)\n {\n if ($exception instanceof AccessDeniedException) {\n return AccessDeniedException::getResponse();\n }\n if ($exception instanceof BadCredentialsException) {\n return BadCredentialsException::getResponse($exception->getMessage());\n }\n if ($exception instanceof DataNotFoundException) {\n return DataNotFoundException::getResponse($exception->getMessage());\n }\n if ($exception instanceof DuplicateDataException) {\n return DuplicateDataException::getResponse($exception->getMessage());\n }\n\n if ($exception instanceof \\Illuminate\\Database\\QueryException) {\n return QueryException::getResponse($exception->getMessage());\n } elseif ($exception instanceof \\PDOException) {\n return DatabaseConnectionException::getResponse();\n }\n\n if ($exception instanceof InvalidActionException) {\n return InvalidActionException::getResponse($exception->getMessage());\n }\n if ($exception instanceof UnauthorizeException) {\n return UnauthorizeException::getResponse($exception->getMessage());\n }\n if ($exception instanceof UsernameIsExistsException) {\n return UsernameIsExistsException::getResponse();\n }\n if ($exception instanceof ValidationException) {\n return ValidationErrorException::getResponse($exception);\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n if ($exception instanceof ValidationException) {\n $errors = $exception->errors();\n $first_error = collect($errors)->first();\n $message = ($first_error) ? $first_error[0] : $exception->getMessage();\n $code = 422;\n } elseif ($exception instanceof AuthenticationException) {\n $message = 'Unauthenticated';\n $code = 401;\n $errors = [\n 'token' => [$exception->getMessage()]\n ];\n } elseif ($exception instanceof ModelNotFoundException) {\n $message = 'Not Found';\n $code = 404;\n $errors = [\n 'route' => ['url is not found']\n ];\n } elseif ($exception instanceof NotFoundHttpException) {\n $message = 'Not Found';\n $code = 404;\n $errors = [\n 'route' => ['url is not found']\n ];\n }\n elseif ($exception instanceof UnauthorizedException) {\n $message = $exception->getMessage();\n $code = 403;\n $errors = [\n 'unauthorized' => [$exception->getMessage()]\n ];\n }\n else {\n $code = 400;\n $message = $exception->getMessage();\n $errors = [\n 'failed'=>['Something Went Wrong']\n\n ];\n }\n if (env('APP_DEBUG')) {\n if ($code == 404) {\n $errors = [\n 'route' => [$exception->getMessage()]\n ];\n }\n\n if ($code != 422){\n $errors['line'] = $exception->getLine();\n $errors['trace'] = $exception->getTrace();\n }\n }\n\n return response()->json([\n 'message' => $message,\n 'errors' => $errors,\n ], $code);\n }", "public function render($request, Throwable $exception)\n {\n /* only run if debug is turn off */\n if ( !env('APP_DEBUG', true) ) {\n\n $core = new Core;\n\n /* handling 404 exception */\n if($exception instanceof NotFoundHttpException){\n\n return response()->json([\n 'error' => 'Not Found',\n ])->setStatusCode(404);\n }\n\n /* handling 500 exception */\n $exception_name = get_class($exception);\n\n $error = $core->log('error', \"Exception ($exception_name) : \" . $exception->getTraceAsString() , true);\n\n return response()->json([\n 'error' => \"Server problem, code [$error]\",\n ])->setStatusCode(500);\n\n }\n\n return parent::render($request, $exception);\n }", "public function get_response() {\n $view = View::factory('Errors/default');\n\n // Remembering that `$this` is an instance of HTTP_Exception_404\n $view->message = $this->getMessage();\n\n $view->error_code = 500;\n $view->error_rant = \"something's wrong with our server\";\n $view->error_message = \"probably another rat ate our server cable. Please wait patiently :)\";\n\n $response = Response::factory()\n ->status(500)\n ->body($view->render());\n\n return $response;\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof \\Cms\\Modules\\Core\\Exceptions\\NotInstalledException) {\n return $this->renderNotInstalled($e);\n }\n\n if ($e instanceof \\Cms\\Modules\\Core\\Exceptions\\InMaintenanceException) {\n return $this->renderInMaintenance($e);\n }\n\n if (config('app.debug') && class_exists('\\Whoops\\Run')) {\n return $this->renderExceptionWithWhoops($e, $request);\n }\n\n if ($e instanceof \\PDOException) {\n return $this->renderPdoException($e);\n }\n\n return $this->renderErrorPage($e);\n //return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n {\n if (\n $exception instanceof ScheduleHasSessionException\n || $exception instanceof ScheduleNotHasSessionException\n || $exception instanceof ScheduleSessionIsClosedException\n || $exception instanceof UniqueVotePerSessionException\n || $exception instanceof UniqueDocumentAssociateException\n ) {\n return $this->renderCustom($request, $exception);\n }\n\n if ($exception instanceof ModelNotFoundException) {\n return $this->renderModelNotFoundException();\n }\n\n if ($exception instanceof ValidationException) {\n return $this->renderValidationException($exception->validator);\n }\n\n if ($exception instanceof NotFoundHttpException) {\n return $this->renderNotFoundHttpException();\n }\n\n if ($exception instanceof MethodNotAllowedHttpException) {\n return $this->renderMethodNotAllowedException();\n }\n\n return response()->json([\n 'message' => trans('exceptions.Unknown error')\n ], HttpStatusCodeEnum::INTERNAL_SERVER_ERROR);\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof SaleItemRegisterException) {\n return response()->view('errors.sale_item_register', [\"message\" => $e->getMessage()], 500);\n }\n if ($e instanceof NotFoundHttpException) {\n return response()->view('errors.404', [], 404);\n }\n if ($e instanceof NotFoundUserException) {\n return response()->view('errors.404', [\"message\" => $e->getMessage()], 404);\n }\n if ($e instanceof ItemRegisterException) {\n return response()->view('errors.item_register', [], 500);\n }\n if ($e instanceof ApiAuthException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($e instanceof ItemEditException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($e instanceof ArticleContainerException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($e instanceof UserSettingException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($request->ajax()) {\n if ($e instanceof Exception) {\n Log::info($e->getMessage());\n Log::info($e->getTraceAsString());\n return new JsonResponse([\"message\" => \"予期せぬエラーが発生しました\"]);\n }\n }\n // HTTPエラー\n if ($e instanceof HttpException) {\n if ($e->getStatusCode() === 404) {\n return response()->view('errors.404', [], 404);\n }\n // メンテナンスモード\n if ($e->getStatusCode() === 503) {\n return response()->view('errors.503', [\"message\" => $e->getMessage()], 503);\n }\n }\n \n // その他エラー\n if (!($e instanceof ValidationException) && !($e instanceof HttpResponseException) && $e instanceof Exception) {\n Log::info($e->getMessage());\n Log::info($e->getTraceAsString());\n return response()->view('errors.500', [\"message\" => $e->getMessage()], 500);\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Throwable $e)\n {\n // TODO: Implement render() method.\n }", "public function render($request, Exception $e)\n\t{\n\t\tif ($e instanceof VocalogicException)\n\t\t{\n\t\t\treturn $this->renderVocalogicException($e);\n\t\t}\n\n\t\tif (($e instanceof ModelNotFoundException) && !config('app.debug'))\n\t\t{\n\t\t\tabort(404);\n\t\t}\n\n\t\treturn parent::render($request, $e);\n\t}", "public function render($request, Exception $exception)\n {\n if (config('app.debug') && $request->wantsJson()) {\n return self::renderJson($exception);\n }\n\n if (config('app.debug')) {\n return self::renderHtml($exception);\n }\n\n return parent::render($request, $exception);\n }", "public function onException(Exception $err): Effect|Response;", "public function getHttpResponseBasedOnError(): HttpResponse\n {\n if ($this->exception instanceof ClientException) {\n $this->logger->addWarning($this->exception->getMessage(), [\n 'code' => $this->exception->getCode(),\n 'exception' => $this->exception\n ]);\n $response = new View('Error/error');\n $response->addVariable('error', $this->exception->getMesssage());\n $response->addVariable('statusCode', $this->exception->getCode());\n $response->setStatusCode($this->exception->getCode());\n return $response;\n } else {\n if ($this->exception instanceof PlatformException)\n $this->logger->addError($this->exception->getMessage(), [\n 'code' => $this->exception->getCode(),\n 'exception' => $this->exception\n ]);\n else if ($this->exception instanceof \\PDOException)\n $this->logger->addError($this->exception->getMessage(), [\n 'code' => PlatformException::ERROR_DB,\n 'exception' => $this->exception\n ]);\n else\n $this->logger->addEmergency($this->exception->getMessage(), [\n 'code' => PlatformException::ERROR_UNDEFINED,\n 'exception' => $this->exception\n ]);\n \n if ($this->environment == 'production') {\n $response = new View('Error/error');\n $response->addVariable('error', 'Something wrong happened. Please try again.');\n $response->addVariable('statusCode', 500);\n $response->setStatusCode(500);\n return $response;\n } else {\n throw $this->exception;\n }\n }\n }", "public function render($request, Exception $exception)\n {\n if ($exception instanceof ModelNotFoundException) {\n return response()->json(['error' => 'Resource was not found.'], 404);\n }\n\n if ($exception instanceof ValidationException) {\n return response()->json([\n 'error' => $exception->errors()\n ], 422);\n }\n\n if ($exception instanceof AuthenticationException\n || $exception instanceof AuthorizationException\n || $exception instanceof UnauthorizedHttpException) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return response()->json([\n 'error' => $exception->getMessage(),\n 'stack' => $exception->getTrace(),\n 'file' => $exception->getFile(),\n 'line' => $exception->getLine(),\n ], 500);\n\n return parent::render($request, $exception);\n }", "public static function handler(Exception $e)\n {\n try {\n\n if (Request::$current !== NULL\n && Request::current()->is_ajax() === TRUE\n && Kohana::$environment !== Kohana::PRODUCTION) {\n header('Content-Type: text/plain; charset='.Kohana::$charset, TRUE, 500);\n self::_print($e);\n }\n\n if (Kohana::$environment === Kohana::PRODUCTION && ! self::$custom_view_file)\n Kohana_Kohana_Exception::$error_view = self::get_view_file($e);\n elseif (self::$custom_view_file)\n Kohana_Kohana_Exception::$error_view = self::$custom_view_file;\n\n parent::handler($e);\n\n } catch(Exception $e) {\n /**\n * Things are going *really* badly for us, We now have no choice\n * but to bail. Hard.\n */\n // Clean the output buffer if one exists\n ob_get_level() AND ob_clean();\n\n // Set the Status code to 500, and Content-Type to text/plain.\n header('Content-Type: text/plain; charset='.Kohana::$charset, TRUE, 500);\n\n echo Kohana_Exception::text($e);\n\n exit(1);\n }\n }", "public function handleRequest()\n {\n try {\n $response = $this->handleRequestInner();\n } catch (HttpException $ex) {\n $this->config->set('page_title', 'Error');\n\n $view = new View('exception');\n $view->exception = $ex;\n\n $response = new Response();\n\n $response->setResponseCode($ex->getErrorCode());\n $response->setContent($view->render());\n } catch (\\Exception $ex) {\n $this->config->set('page_title', 'Error');\n\n $view = new View('exception');\n $view->exception = $ex;\n\n $response = new Response();\n\n $response->setResponseCode(500);\n $response->setContent($view->render());\n }\n\n return $response;\n }", "private function render() {\n header('Content-Type: text/html; charset=utf-8', TRUE);\n $view = \"{$this->method}_{$this->resource}\";\n if(file_exists(WEB.\"${view}.php\")) {\n ob_start();\n include ( WEB.\"${view}.php\");\n $response = ob_get_contents();\n ob_end_clean();\n } else {\n $status = HttpStatusCode::NOT_ACCEPTABLE;\n $content = 'No view found';\n $response = static::json();\n }\n\n return $response;\n }", "public function outputException(\\Throwable $e) : void\n {\n $response = new Response(500);\n $response = $response->withAddedHeader('Content-Type', 'text/plain');\n \n if ($e instanceof HttpException) {\n $response = $response->withStatus($e->getCode());\n }\n \n $result = $e->getMessage() . \"\\n\\r\";\n \n if (ErrorHandler::$showTrace === true) {\n $trace = explode(\"\\n\", $e->getTraceAsString());\n \n foreach ($trace as $step) {\n $result .= \"\\n\";\n $result .= $step;\n }\n }\n \n $content = new Stream(fopen('php://memory', 'r+'));\n $content->write($result);\n \n $response = $response->withBody($content);\n \n $this->output($response);\n }", "private function throwFriendlyErrors(\\Exception $e)\n {\n $errors = $e->errors();\n\n $response = response()->json([\n 'message' => 'Invalid data, please re-review the data you sent.',\n 'details' => $errors\n ], 422);\n\n throw new HttpResponseException($response);\n }", "public function render($request, Exception $exception)\n {\n\t // 调试模式返回原生异常调用栈\n//\t if (!config('app.debug')) {\n//\t\t return parent::render($request, $exception);\n//\t }\n\n\t // 如果定义了该异常处理,则自定义异常处理方法\n\t $renderMethod = $this->customRender[get_class($exception)]['render'] ?? '';\n\t if ($renderMethod && method_exists($this, $renderMethod)) {\n\t\t return $this->$renderMethod($request, $exception);\n\t }\n\n\t return parent::render($request, $exception);\n }", "public function exceptionAction(FlattenException $exception)\n {\n\t\t//\n // return new Response($msg, $exception->getStatusCode());\n\n\t\t$msg = 'Something went wrong!';\n\n return new Response($msg, $exception->getStatusCode());\n }", "public function render($request, Exception $e)\n {\n $redirect = $this->reportNotFound($e);\n\n if ($redirect && $redirect instanceof RedirectResponse) {\n return $redirect;\n }\n\n return parent::render($request, $e);\n }" ]
[ "0.73116726", "0.7122214", "0.7050922", "0.7050922", "0.704035", "0.6992839", "0.6990034", "0.6980675", "0.697365", "0.6950051", "0.69485855", "0.69412524", "0.69336146", "0.6920026", "0.6887852", "0.68392885", "0.68298024", "0.68196106", "0.681052", "0.6803951", "0.6795277", "0.6779122", "0.6774303", "0.67716074", "0.6753892", "0.67317593", "0.670746", "0.6705885", "0.66971046", "0.66953313", "0.669022", "0.66851664", "0.6680281", "0.6663982", "0.6662847", "0.6660546", "0.66480064", "0.6647299", "0.6644599", "0.6627376", "0.6626498", "0.66133827", "0.6609545", "0.6599049", "0.65928817", "0.6575709", "0.6550856", "0.6547668", "0.653514", "0.6529298", "0.6518081", "0.65012354", "0.64976424", "0.6491616", "0.64777887", "0.64771414", "0.6470872", "0.64677966", "0.6463605", "0.6446657", "0.6445654", "0.6443608", "0.6430121", "0.6430091", "0.64157295", "0.64120823", "0.6410421", "0.64092267", "0.6407834", "0.64055586", "0.6395041", "0.63826674", "0.63745856", "0.63707286", "0.63700855", "0.6360625", "0.63573146", "0.63546443", "0.6350278", "0.6346168", "0.6341646", "0.63391143", "0.6334965", "0.6325963", "0.6322274", "0.6320939", "0.6316641", "0.6316335", "0.6312784", "0.63034314", "0.6301164", "0.62994444", "0.62977517", "0.6296709", "0.6292592", "0.62821406", "0.6281566" ]
0.67439103
28
Convert an authentication exception into an unauthenticated response.
protected function unauthenticated($request, AuthenticationException $exception) { if ($request->expectsJson()) { return response()->json(['error' => 'Unauthenticated.'], Response::HTTP_UNAUTHORIZED); } return redirect()->guest('/'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if (\n !$request->expectsJson()\n || empty($this->formatApiResponse)\n || !$this->formatApiResponse\n ) {\n\n return parent::unauthenticated($request, $exception);\n }\n\n return response()->error(\n 'Unauthenticated.',\n 401,\n getenv('APP_DEBUG') == 'true' ? $exception : null\n );\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return $request->expectsJson()\n ? api_response()->fail()->message('Unauthenticated')->response(401)\n : redirect()->guest(route('login'));\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return $this->respondUnauthenticated();\n }", "protected function unauthenticated($request, AuthenticationException $e)\n {\n if ($request->ajax() || $request->wantsJson()) {\n return response('Unauthorized.', 401);\n } else {\n return redirect()->guest('login');\n }\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return $request->expectsJson() ? response()->json(['message' => $exception->getMessage()], 401) :\n redirect()->guest(route('login'));\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return $request->expectsJson()\n ? app(Response::class)->errorUnauthorized($exception->getMessage())\n : redirect()->guest($exception->redirectTo() ?? route('login'));\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n\t{\n\t\tif ($request->expectsJson()) {\n\t\t\treturn response()->json(['error' => 'Unauthenticated.'], 401);\n\t\t}\n\n\t\treturn redirect()->guest(route('login'));\n\t}", "protected function unauthenticatedJson(AuthenticationException $e): JsonResponse\n {\n return \\response()->json(['message' => 'unauthenticated'], 401);\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest('login');\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest('login');\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest('login');\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest('login');\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest('login');\n }", "protected function authenticationError(Exception $exception)\n {\n return $this->jsonResponse($exception->getMessage(), Response::HTTP_UNAUTHORIZED);\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest(route('login'));\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest(route('login'));\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest(route('login'));\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect('/login');\n }", "protected function notAuthenticated()\n {\n $this->response = $this->response->withStatus(401);\n $this->jsonBody($this->payload->getInput());\n }", "protected function getUnauthorizedResponse()\n {\n $authHeaderValue = $this->realm === null ? static::AUTHENTICATION_SCHEME :\n static::AUTHENTICATION_SCHEME . ' realm=\"' . $this->realm . '\"';\n\n return $this->integration->createResponse(\n null,\n Response::HTTP_UNAUTHORIZED,\n [self::HEADER_WWW_AUTHENTICATE => $authHeaderValue]\n );\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception): null|Response\n {\n $data = array(\n 'message' => strtr($exception->getMessageKey(), $exception->getMessageData())\n );\n\n return new JsonResponse($data, Response::HTTP_FORBIDDEN);\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n return $request->expectsJson()\n ? $this->unauthenticatedJson($exception)\n : redirect()->guest(route('login'));\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception)\n {\n $data = array(\n 'status' => Response::HTTP_FORBIDDEN,\n 'error' => 'Invalid token!', //strtr($exception->getMessageKey(), $exception->getMessageData()),\n 'data' => null\n );\n\n return new JsonResponse($data, Response::HTTP_FORBIDDEN);\n }", "public static function unauthorized($message = 'Unauthorized.')\n {\n throw new ResponseException($message, 401);\n }", "protected function unauthenticated($request, AuthenticationException $exception)\n {\n if ($request->expectsJson()) {\n return response()->json(['error' => 'Unauthenticated.'], 401);\n }\n\n return redirect()->guest(route('sessions.create'));\n }", "public function report(Exception $exception)\n {\n\t\t/*if ($exception instanceof \\League\\OAuth2\\Server\\Exception\\OAuthServerException && $exception->getCode() == 9) {\n\t\t\treturn response()->json(['message' => 'Unauthenticated'], 200);\n\t\t}*/\n parent::report($exception);\n }", "public function onAuthenticationFailure(\n Request $request,\n AuthenticationException $exception)\n {\n return new Response('Authentication Failed. ', 403);\n }", "public function getAuthenticationException();", "private function AuthenticationException(AuthenticationException $exception)\n\t{\n\t\treturn $this->CommonErrorExceptionResponse(\n\t\t\t'AuthenticationException',\n\t\t\t'Unauthenticated',\n\t\t\tarray('You are not authenticated',\n\t\t\t\t$exception->getMessage()\n\t\t\t),\n\t\t\tarray('Please login to the system', 'Check if your account is activated'),\n\t\t\t401\n\t\t);\n\n\t}", "protected function onAuthenticationException(Request $request, AuthenticationException $exception): Response\n {\n\n return $this->startAuthentication($request, $exception);\n }", "protected function unauthenticated($request, AuthenticationException $exception){\n\n $guard = array_get($exception->guards(), 0);\n\n switch ($guard){\n case 'teacher':\n #if using the teacher guard, go to the teacher login\n $login = 'teacher.login';\n break;\n\n default:\n #web guard response (for users, aka parents) - the default response\n $login = 'login';\n break;\n }\n\n //return redirect()->guest(route('login')); //original return statement before modification of this method\n return redirect()->guest(route($login));\n\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception): Response\n {\n if ($request->hasSession()) {\n $request->getSession()->set(Security::AUTHENTICATION_ERROR, $exception);\n }\n\n if ($exception instanceof BadCredentialsException) {\n $msg = 'Invalid credentials.';\n } else {\n $msg = $exception->getMessage();\n }\n return new JsonResponse(['error' => 1, 'message' => $msg]);\n }", "protected static function apiResponseUnauthorized($message){\n self::setStatusCode(Response::HTTP_UNAUTHORIZED);\n return self::apiResponse([\n 'status' => 'error',\n 'status_code' => self::getStatusCode(),\n 'message' => $message,\n ]);\n }", "public function testUnauthenticatedNoException()\n {\n $this->auth->setConfig('unauthenticatedException', false);\n $this->assertNull($this->auth->unauthenticated(new ServerRequest(), $this->response));\n }", "public function hydrate()\n {\n if (auth()->guest()) {\n throw new AuthenticationException();\n }\n }", "protected function authorizationError(Exception $exception)\n {\n return $this->jsonResponse($exception->getMessage(), Response::HTTP_FORBIDDEN);\n }", "public function respondUnauthorised($message = 'Unauthorised!')\n {\n return $this->setStatusCode(401)->respondWithError($message);\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception)\n {\n// $exception,\n// new JWTAuthenticationFailureResponse($exception->getMessage())\n// );\n\n $event = new AuthenticationFailureEvent(\n $exception,\n new JWTAuthenticationFailureResponse(\n $this->translator->trans('Invalid credentials.')\n )\n );\n if ($this->dispatcher instanceof ContractsEventDispatcherInterface) {\n $this->dispatcher->dispatch($event, Events::AUTHENTICATION_FAILURE);\n } else {\n $this->dispatcher->dispatch(Events::AUTHENTICATION_FAILURE, $event);\n }\n\n return $event->getResponse();\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception)\n {\n $datos = $request->request->all();\n $user = $datos[\"_username\"];\n $uri = $this->container->get('router')->generate('administrador_inicio_login_error', array('u'=> $user));\n $response = new RedirectResponse($uri);\n return $response;\n }", "public function respondUnauthorizedError($message = 'Unauthorized!')\n {\n return $this->setStatusCode(IlluminateResponse::HTTP_UNAUTHORIZED)->respondWithError($message);\n }", "public function start(Request $request, AuthenticationException $authException = null) : Response\n {\n return new Response(Constants::UNAUTHORIZED_MESSAGE, 401, [\"Content-Type\" => \"application/json\"]);\n }", "public function test_unauthenticated_error()\n {\n $response = $this->get($this->apiUrl('user'));\n\n $response->assertStatus(401);\n\n $response->assertJson([\n 'message' => 'Unauthenticated.'\n ]);\n }", "public static function buildUnauthorizedResponse(string $message = self::MESSAGE_UNAUTHORIZED): static\n {\n $dto = new static();\n $dto->setCode(Response::HTTP_UNAUTHORIZED);\n $dto->setSuccess(false);\n $dto->setMessage($message);\n return $dto;\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception)\n {\n return new RedirectResponse($request->getSession()->get('_security.jira_secured.login_path'));\n }", "protected function unauthorizedJson(AuthorizationException $e): JsonResponse\n {\n return \\response()->json(['message' => 'access_denied'], 403);\n }", "public static function error401() {\n header('Unauthorized', true, 401);\n $html401 = sprintf(\"<title>Error 401: Unauthorized</title>\\n\" .\n \"<main><div class=\\\"container\\\"><div class=\\\"row\\\"><div class=\\\"col-lg-10 offset-lg-1\\\">\" .\n \"<div class=\\\"row wow fadeIn\\\" data-wow-delay=\\\"0.4s\\\"><div class=\\\"col-lg-12\\\"><div class=\\\"divider-new\\\">\" .\n \"<h2 class=\\\"h2-responsive\\\">Error 401</h2>\" .\n \"</div></div>\" .\n \"<div class=\\\"col-lg-12 text-center\\\">\" .\n \"<p>You aren’t authenticated, please login and try again.</p>\" .\n \"</div></div></div></div></div></main>\", $_SERVER[\"REQUEST_URI\"]);\n echo $html401;\n }", "public static function sendUnauthorizedResponse(){\n http_response_code(401);\n die();\n }", "function unauthorized() {\n\treturn show_template('401');\n}", "public function notAuthenticated(ResponseInterface $response);", "public function unauthorized($message = \"You dont have permissions for this resource\",\n $errorCode = \"AuthException\")\n {\n $this->response = $this->laravelResponse->setContent(json_encode(['message' => $message,\n 'ErrorCode' => $errorCode]))->setStatusCode(401);\n return $this->respond();\n }", "public function unauthorized()\n {\n return view('exception.unauthorized');\n }", "public function respondUnauthorized($message = 'Not authorized!')\n {\n return $this->setStatusCode(401)->respondWithErrors($message);\n }", "public function start(Request $request, AuthenticationException $authException = null): Response\n {\n $data = ['status' => 'error', 'message' => 'UNAUTHORIZED'];\n \n return new JsonResponse($data, Response::HTTP_UNAUTHORIZED);\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception);", "public function get_response()\r\n {\r\n $response = Response::factory()\r\n ->status(401)\r\n ->headers('Location', URL::site('user/enter'));\r\n return $response;\r\n }", "public function s401($message = '') { self::respondWithJSON($message, 401); }", "public function getAssociatedStatusCode()\n {\n return AbstractResponse::RESPONSE_UNAUTHORIZED;\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception)\n {\n $request->getSession()->set(Security::AUTHENTICATION_ERROR, $exception);\n\n return new RedirectResponse($this->router->generate($this->parameters['route']['login']));\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(HttpResponse::HTTP_UNAUTHORIZED)\n ->respondWithError($message, self::CODE_UNAUTHORIZED);\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)->respondWithError($message);\n }", "public function testOnAuthenticationFailure(): void\n {\n $this->serverService->expects($this->once())\n ->method('getVariable')\n ->with('realm')\n ->will($this->returnValue('mock_realm'))\n ;\n\n $response = $this->authenticator->onAuthenticationFailure(\n new Request(),\n new AuthenticationException('Authentication failure message')\n );\n\n $this->assertSame(401, $response->getStatusCode());\n $this->assertSame('{\"error\":\"access_denied\",\"error_description\":\"Authentication failure message\"}', $response->getContent());\n }", "private function respondToUnauthorizedRequest($request)\n {\n if ($request->ajax() || $request->wantsJson()) {\n return response(trans('unauthorized'), 401);\n } else {\n return redirect()->guest(Route('home'));\n }\n }", "protected function respondUnauthorized($message)\n {\n return response()->json([\n 'success' => false,\n 'message' => $message\n ], 401);\n }", "private static function generateFailedAuthResponse(&$response) {\n $response->getHeaders()->addHeaders([\n 'Date' => gmdate('D, d M Y H:i:s T'),\n 'Content-Type' => 'application/json; charset=UTF-8'\n ]);\n $response->setContent(\\Zend\\Json\\Json::encode(['success' => false, 'data' => false, 'errors' => 'Request authorization failed, check keys/payload']));\n $response->getHeaders()->addHeaderLine('Content-Type', 'application/json');\n $response->setStatusCode(403);\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)\n ->respondWithError($message, self::CODE_UNAUTHORIZED);\n }", "protected function handleUnauthorizedCommand()\n\t{\n // si appel xmlhttp\n\t\tif ( (isset($_SERVER['HTTP_USER_AGENT']) && (strpos($_SERVER['HTTP_USER_AGENT'], 'XMLHTTP') === 0)) \n\t\t\t || (strpos($_SERVER['HTTP_ACCEPT'], 'application/json') === 0) )\n return new ReturnedValues\\Json(json_encode(array('statut'=>false, 'message'=>'Request is not authorized.')), false);\n else\n return new ReturnedValues\\PHP('Request is not authorized.', false);\n\t}", "public function getAuthenticationResponse() {\n }", "public function respondUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)->respondWithError($message);\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)\n ->respondWithError($message);\n }", "public function render($request, Throwable $exception)\n {\n if ($exception instanceof \\Symfony\\Component\\HttpKernel\\Exception\\UnauthorizedHttpException) {\n switch (get_class($exception->getPrevious())) {\n case \\Tymon\\JWTAuth\\Exceptions\\TokenExpiredException::class:\n return response()->json([\n 'error' => 'Su sesión ha expirado'\n ], $exception->getStatusCode());\n\n case \\Tymon\\JWTAuth\\Exceptions\\TokenInvalidException::class:\n case \\Tymon\\JWTAuth\\Exceptions\\TokenBlacklistedException::class:\n return response()->json([\n 'error' => 'La sesión no es valida'\n ], $exception->getStatusCode());\n default:\n break;\n }\n }\n\n return parent::render($request, $exception);\n }", "public function forbiddenResponse()\n {\n // (default is to just redirect to initial page with errors)\n //\n // Can return a response, a view, a redirect, or whatever else\n\n return Response::make('Permission denied foo!', 403);\n }", "public function authenticationFailure()\n {\n return $this->sendFailed(\"not authenticated\");\n }", "protected function sendFailedLoginResponse()\n {\n return response()->json([\n 'message' => $this->errorMessage,\n ], 401);\n }", "public function onAuthenticationFailure(Request $request, AuthenticationException $exception)\n {\n $error = $exception->getMessage();\n\n $request->getSession()->set('login_error', $error);\n\n return new \\Symfony\\Component\\HttpFoundation\\RedirectResponse($this->router->generate('fos_user_security_login'));\n }", "private function unauthorized($message = null){\n return response()->json([\n 'message' => $message ? $message : 'No estas autorizado para acceder a este recurso',\n 'success' => false\n ], 401);\n }", "public function render($request, Exception $exception)\n {\n $e = $this->prepareException($exception);\n\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n } elseif ($e instanceof AuthenticationException) {\n $status = Response::HTTP_UNAUTHORIZED;\n $message = '認証に失敗しました。ログインしてください。';\n $errors = [];\n $trace = [];\n } elseif ($e instanceof ValidationException) {\n $status = $e->status;\n $message = Response::$statusTexts[$status];\n $errors = $e->errors();\n $trace = [];\n } elseif ($this->isHttpException($e)) {\n $status = $e->getCode();\n if ($status == 0) {\n $status = 400;\n }\n $message = $e->getMessage();\n $errors = [];\n $trace = [];\n } else {\n $code = env('APP_DEBUG', true) ? $e->getCode() : Response::HTTP_INTERNAL_SERVER_ERROR;\n if (isset($code)) {\n $code = Response::HTTP_INTERNAL_SERVER_ERROR;\n }\n $status = $code;\n $message = env('APP_DEBUG', true) ? $e->getMessage() : 'サーバエラーが発生しました。管理者に連絡してください。';\n $errors = [];\n $trace = env('APP_DEBUG', true) ? $e->getTrace() : [];\n }\n\n // ResponseApiServiceProviderが実行される前にエラーが発生した場合の対応\n if (!method_exists(response(), 'error')) {\n $app = app();\n $provide = new ResponseApiServiceProvider($app);\n $provide->boot();\n }\n\n return response()->error($message, $errors, $trace, $status);\n }", "function auth_fail() {\n header('HTTP/1.1 401 Unauthorized');\n header('WWW-Authenticate: Digest realm=\"'.$realm.\n\t '\",qop=\"auth\",nonce=\"'.uniqid().'\",opaque=\"'.md5($realm).'\"');\n}", "function unauthorized($realm = 'PHPRestSQL') {\n header('WWW-Authenticate: Basic realm=\"'.$realm.'\"');\n header('HTTP/1.0 401 Unauthorized');\n }", "public function abortIfRequestUnauthorized(): void\n {\n if ($this->isUnauthorized()) {\n throw new UnauthorizedException($this);\n }\n }", "public function respondUnauthorized($message = 'Unauthorized!')\n {\n if (!!$this->customStatusCode) {\n return $this->setCustomStatusCode($this->customStatusCode)->respondWithError($message);\n }\n return $this->setCustomStatusCode(4001)->respondWithError($message);\n }", "protected function failedAuthorization()\n {\n throw new UnauthorizedException();\n }", "public function redirectUnauthenticatedUser(){\n if(!$this->isAuthenticated() )\n $this->logout();\n }", "public function getResponse()\n {\n // Validate the request\n if ($this->secure) {\n try {\n $this->validateRequest();\n } catch (VanillaException $e) {\n return $this->formatResponse([\n 'error' => $e->getType(),\n 'message' => $e->getMessage(),\n ]);\n }\n }\n\n return $this->formatResponse($this->getUser());\n }", "public function forbiddenResponse()\n {\n flash()->error(trans('defaults.auth.error'));\n\n return redirect()->back();\n }", "public static function unauthorized($message = '', \\Exception $previous = NULL)\n {\n return new self($message, 401, $previous);\n }", "public function start(Request $request, AuthenticationException $authException = null)\n {\n $response = [\n 'status' => Response::HTTP_UNAUTHORIZED,\n 'message' => 'You shall not pass!'\n ];\n\n return new JsonResponse($response, Response::HTTP_UNAUTHORIZED);\n }", "public function send401Unauthorized()\n {\n $this->sendHeader('HTTP/1.1 401 Unauthorized');\n }", "public static function errorUnauthorized($message = 'Unauthorized')\n {\n return static::error($message, 401);\n }", "public function unauthenticated(CakeRequest $request, CakeResponse $response) {\n }", "public function unauthorized()\n\t{\n\t\t$this->template->content = $this->add_view('extinfo/unauthorized');\n\t\t$this->template->content->error_description = _('If you believe this is an error, check the HTTP server authentication requirements for accessing this page and check the authorization options in your CGI configuration file.');\n\t}", "public function onException(GetResponseForExceptionEvent $event): void\n {\n $attributes = $event->getRequest()->attributes;\n if ($attributes->get(SetIsAdminRequestListener::ADMIN_FLAG_NAME) !== true) {\n return;\n }\n\n if (!$event->getRequest()->isXmlHttpRequest()) {\n return;\n }\n\n $exception = $event->getException();\n if (!$exception instanceof AuthenticationException && !$exception instanceof AccessDeniedException) {\n return;\n }\n\n $event->setException(new AccessDeniedHttpException());\n\n $event->stopPropagation();\n }", "public function render($request, Exception $exception)\n {\n if ($exception instanceof \\Illuminate\\Auth\\AuthenticationException) {\n\n if ($request->expectsJson()) {\n return response()->json(['status'=>'Failure','message' => 'Unauthenticated.'], 200);\n }\n return redirect('/');\n }else{\n if ($exception instanceof \\Illuminate\\Http\\Exceptions\\PostTooLargeException) {\n return response()->view('errors.posttoolarge', [], 500 );\n }\n $exception = \\Symfony\\Component\\Debug\\Exception\\FlattenException::create($exception);\n\t\t $status = $exception->getStatusCode();\n\n\t\t\t//if status code is 501 redirect to custom view\n\t\t\tif( $status == 501 || $status == 503 || $status == 500 || $status == 405 ){\n\t\t\t\t return response()->view('errors.500', [], 500 );\n\t\t\t}\n\t\t\tif( $status == 404 ){\n\t\t\t\t return response()->view('errors.404', [], 404 );\n\t\t\t}\n return parent::render($request, $exception);\n }\n\n // if ($exception instanceof \\Illuminate\\Auth\\AuthenticationException) {\n\n\t// \t\t//echo \"testset\";exit;\n\t// \t\t//$exception = $this->unauthenticated($request, $exception);\n\t// \t\tif ($request->expectsJson()) {\n\t// \t\t\treturn response()->json(['status'=>'Failure','message' => 'Unauthenticated.'], 200);\n\t// \t\t}\n\t// \t\treturn redirect('/');\n\t// \t}else{\n\n\t// \t\t$exception = \\Symfony\\Component\\Debug\\Exception\\FlattenException::create($exception);\n\t// \t $status = $exception->getStatusCode() ;\n\n\t// \t\t//if status code is 501 redirect to custom view\n\t// \t\tif( $status == 501 || $status == 503 || $status == 500 || $status == 405 ){\n\t// \t\t\t return response()->view('errors.500', [], 500 );\n\t// \t\t}\n\t// \t\tif( $status == 404 ){\n\t// \t\t\t return response()->view('errors.404', [], 404 );\n\t// \t\t}\n\t// \t\treturn parent::render($request, $exception);\n // \t}\n\n\n\n\n\n\n }", "public function forbiddenResponse( ) {\n if ( $this->ajax() || $this->wantsJson() ) {\n return (new ApiController())->setStatusCode(403)->respondWithError($this->ForbiddenMessage);\n }//if ( $this->ajax() || $this->wantsJson() )\n return parent::forbiddenResponse();\n }", "public function authenticationReqd(){\n\t\theader('HTTP/1.0 401 Unauthorized');\n\t\t$this['app']['hologram']->setModule(\"WWW\")->log(\\Bakery\\Utilities\\Hologram::NORMAL, \"Response: Page requires authentication\");\r\n\t\t\n\t\t$_SESSION['redirect_to'] = $this['request']['uri'];\n\t\t\n\t\tif($this->isJson()){\n\n\t\t\treturn array(\"response\" => \"authentication required\");\n\t\t\t\n\t\t}\n\t\t\n\t\theader(\"Location: {$this['app']['security.login']['handler']}\");\n\t\t\n\t}", "private function parseResponse(HttpResponse $response): string\n {\n $result = $response->getBody();\n\n if (stripos($result, 'Unauthorized:') !== false) {\n throw new Exception\\InvalidCredentialsException(\n 'Authentication error: missing or incorrect Elastic Email API key'\n );\n }\n\n return $result;\n }", "public function testAuthenticateTransformsAccountStatusException(): void\n {\n // flagging the authorization header to be removed at the same time\n $this->serverService->expects($this->once())\n ->method('getBearerToken')\n ->with(\n $this->isInstanceOf(Request::class),\n $this->equalTo(true)\n )\n ->will($this->returnValue('mock_token_string'))\n ;\n\n // expect the OAuth2 service to verify the token, returning an access token\n $accessToken = new AccessToken();\n $accessToken->setUser($this->user);\n $accessToken->setScope('scope_1 scope_2');\n $this->serverService->expects($this->once())\n ->method('verifyAccessToken')\n ->with('mock_token_string')\n ->will($this->returnValue($accessToken))\n ;\n\n // expect the user checker to not pass\n $this->userChecker->expects($this->once())\n ->method('checkPreAuth')\n ->with($this->user)\n ->willThrowException(new DisabledException('User account is disabled.'))\n ;\n\n $passport = $this->authenticator->authenticate(new Request());\n\n // confirm that the returned passport won't pass validation\n $this->assertFalse($passport->getBadge(OAuthCredentials::class)->isResolved());\n }", "public function unauthenticated(CakeRequest $request, CakeResponse $response) {\n $controller = $this->_Collection->getController();\n $url = '';\n\n if (isset($controller->request->url)) {\n $url = $controller->request->url;\n }\n\n $url = Router::normalize($url);\n $loginAction = Router::normalize($controller->Auth->loginAction);\n\n if ($url != $loginAction) {\n $controller->_falseJson(ApiResponseCode::UNAUTHORIZED);\n $controller->response->send();\n exit;\n }\n\n return false;\n }", "private function handleException($e)\n {\n // TODO: test coverage\n if ($e instanceof ClientException) {\n // will catch all 4xx errors\n if ($e->getResponse()->getStatusCode() == 403) {\n throw new AuthenticationException(\n $this->apiKey,\n $this->apiSecret,\n null,\n $e\n );\n } else {\n throw new DomainException(\n 'The OpenTok API request failed: ' . json_decode($e->getResponse()->getBody(true))->message,\n null,\n $e\n );\n }\n } else if ($e instanceof ServerException) {\n // will catch all 5xx errors\n throw new UnexpectedValueException(\n 'The OpenTok API server responded with an error: ' . json_decode($e->getResponse()->getBody(true))->message,\n null,\n $e\n );\n } else {\n // TODO: check if this works because Exception is an interface not a class\n throw new Exception('An unexpected error occurred');\n }\n }" ]
[ "0.72462296", "0.72462296", "0.7237182", "0.71802115", "0.7153523", "0.7131777", "0.71253836", "0.70805866", "0.7044714", "0.6928213", "0.68399024", "0.68399024", "0.68399024", "0.68399024", "0.68399024", "0.6801107", "0.6797086", "0.6797086", "0.6797086", "0.67951286", "0.6692273", "0.66762704", "0.66615266", "0.65927535", "0.6575697", "0.657172", "0.65651613", "0.65592605", "0.65561676", "0.65474343", "0.65456444", "0.64621174", "0.6449812", "0.6418659", "0.6368095", "0.6325493", "0.6315651", "0.619517", "0.61758846", "0.61474943", "0.6132035", "0.6115018", "0.60877025", "0.60406846", "0.60231787", "0.60017806", "0.5989365", "0.59561706", "0.59542197", "0.5951884", "0.5913911", "0.59054613", "0.59022427", "0.58936036", "0.5890028", "0.586228", "0.5816505", "0.58084416", "0.5798293", "0.5775827", "0.5765212", "0.5756567", "0.5748462", "0.57481897", "0.5736349", "0.5720096", "0.5710024", "0.5698599", "0.56899506", "0.5689086", "0.5678985", "0.5677279", "0.5670548", "0.56682247", "0.56546396", "0.56212157", "0.56041306", "0.555583", "0.5539595", "0.5519655", "0.55195737", "0.55165935", "0.5505888", "0.5496588", "0.5486352", "0.54606986", "0.545022", "0.5429932", "0.5427988", "0.5400584", "0.5395954", "0.5386388", "0.53843534", "0.5383478", "0.5371853", "0.5362611", "0.53582585", "0.5352634", "0.53490025", "0.53018844" ]
0.6773604
20
Override default method render the given HttpException.
protected function renderHttpException(HttpException $e) { $status = $e->getStatusCode(); $errorMessages = $this->handleErrorMessages($status); return response()->view(get_the_view_path('errors.index'), ['errorMessages' => $errorMessages], $status); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function render($request, Exception $e)\n\t{\n\t\tif (!config('app.debug') || ($request->ajax() && !config('app.ajax_debug'))) {\n\n\t\t\tif (!$this->isHttpException($e)) {\n\n\t\t\t\tif ($e instanceof TokenMismatchException) {\n\t\t\t\t\t$e = new HttpException(SymfonyResponse::HTTP_UNAUTHORIZED, \"TokenMismatch\");\n\n\t\t\t\t} else if ($e instanceof ModelNotFoundException) {\n\t\t\t\t\t// thrown when findOrFail is called on a model\n\t\t\t\t\t$e = new NotFoundHttpException();\n\n\t\t\t\t} else {\n\t\t\t\t\t$e = new HttpException(SymfonyResponse::HTTP_INTERNAL_SERVER_ERROR, 'Internal Server Error');\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn self::responseForHTTPException($request, $e);\n\t\t}\n\t\treturn parent::render($request, $e);\n\t}", "public function render($request, Exception $e)\n {\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n\t{\n\t\tif ($this->isHttpException($e))\n\t\t{\n\t\t\treturn $this->renderHttpException($e);\n\t\t}\n\t\telse if ($e instanceof OAuthException)\n\t\t{\n\t\t\treturn $this->renderOAuthException($e);\n\t\t}\n\t\telse if ($e instanceof AuthException)\n\t\t{\n\t\t\treturn $this->notifyAuthException($e);\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn parent::render($request, $e);\n\t\t}\n\t}", "public function render($request, Exception $e)\n {\n $e = $this->prepareException($e);\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n $rendered = parent::render($request, $e);\n\n // 拦截数据库异常\n if ($e instanceof QueryException)\n {\n \\Utils\\Log::danger('数据库异常', [\n 'Exception' => \\Utils\\Util::buildException($e)\n ]);\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::ERROR,\n '服务器异常',\n env('DEBUG') ? \\Utils\\Util::buildException($e) : []\n );\n }\n // 拦截Validator异常 \n elseif ($e instanceof ValidationException) {\n $errors = $e->errors();\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::VALIDATOR_ERROR,\n current($errors)[0],\n $e->errors()\n );\n }\n // 拦截Redis异常 \n elseif ($e instanceof ConnectionException) {\n \\Utils\\Log::danger('Redis数据库异常', [\n 'Exception' => \\Utils\\Util::buildException($e)\n ]);\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::ERROR,\n '服务器异常',\n env('DEBUG') ? \\Utils\\Util::buildException($e) : []\n );\n } elseif($e instanceof HttpException) {\n return $rendered;\n }\n // 其他异常\n else {\n try {\n if (property_exists($e, 'payload'))\n {\n $payload = $e->payload;\n } else {\n $payload = [];\n }\n switch ($rendered->getStatusCode()) {\n case 404:\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::NOT_FOUND,\n $e->getMessage(),\n $payload\n );\n break;\n case 405:\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::NOT_ALLOW_METHOD,\n '不支持该请求方式',\n $payload\n );\n break;\n case 500:\n if ($e->getCode())\n {\n return \\Utils\\Response::response(\n $e->getCode(), \n $e->getMessage(), \n $payload\n );\n } else {\n \\Utils\\Log::warning(\n $e->getMessage(), \n \\Utils\\Util::buildException($e)\n );\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::DEBUG_ERROR,\n $e->getMessage(),\n \\Utils\\Util::buildException($e)\n );\n }\n break;\n default:\n \\Utils\\Log::warning(\n $e->getMessage(), \n \\Utils\\Util::buildException($e)\n );\n return \\Utils\\Response::response(\n \\Utils\\ErrorCode::DEBUG_ERROR,\n $e->getMessage(),\n \\Utils\\Util::buildException($e)\n );\n break;\n }\n } catch(\\Exception $e)\n {\n return \\Utils\\Response::response(\\Utils\\ErrorCode::ERROR, $e->getMessage(), $payload);\n }\n }\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof CustomException) {\n return response()->view('errors.custom', [], 500);\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n $url = $request->url();\n if(apiStrContains($url, '/api')) {\n $message = $e->getMessage();\n if($e instanceof MethodNotAllowedHttpException) {\n $header = $e->getHeaders()['Allow'];\n $header = explode(',', $header)[0];\n $message = 'Please send '.$header.' request.';\n }\n elseif(\n $e instanceof NotFoundHttpException ||\n $e instanceof InvalidArgumentException\n ) {\n $message = 'API not found';\n }\n else if($e instanceof UnauthorizedHttpException) {\n $message = 'Login authenication failed';\n }\n elseif (\n $e instanceof BadMethodCallException ||\n $e instanceof FatalThrowableError ||\n $e instanceof QueryException\n ) {\n $message = $e->getMessage();\n }\n return apiResponse(false, 403, $message);\n }\n return parent::render($request, $e);\n\n }", "protected function renderAsError() {}", "public function render($request, Throwable $exception)\n {\n\n if (env('APP_DEBUG') == true) {\n //return parent::render($request, $exception);\n }\n $rendered = parent::render($request, $exception);\n $this->convertDefaultException($exception);\n\n $this->convert($exception, [\n PageNotFoundException::class => ResourceNotFoundException::class,\n ]);\n\n if (!$exception instanceof HttpException) {\n $errorCode = 'internal_error';\n\n if ($exception instanceof OAuthServerException) {\n $errorCode = $exception->getPrevious() ? $exception->getPrevious()->getErrorType() : null;\n } else if ($exception instanceof ThrottleRequestsException) {\n $errorCode = 'too_many_request';\n }\n\n $exception = new ApiHttpException($rendered->getStatusCode(), $errorCode, $exception->getMessage(), $this->getHeaders($exception));\n\n }\n return $this->renderResponse($exception);\n }", "public function render($request, Exception $e)\n {\n if (\\Config::get('app.debug') || Input::get('raw')) {\n // Log exception\n $this->report($e);\n\n return parent::render($request, $e);\n }\n\n $ec = get_class($e);\n\n if (array_key_exists($ec, $this->exceptionResponses)) {\n $data = $this->exceptionResponses[$ec];\n $code = isset($data['code']) ? $data['code'] : null;\n\n if (!$code) {\n if (method_exists($e, 'getStatusCode')) {\n $code = $e->getStatusCode();\n } else {\n $code = 400;\n }\n }\n\n return Controller::respondAPI('', Controller::ERROR, $data['message'], $code);\n }\n\n // We only want to send the actual exception message if debug mode is enabled\n $message = Controller::getExceptionMessage($e);\n $code = $e instanceof HttpException ? $e->getStatusCode() : 500;\n // Send standard error message\n return Controller::respondAPI('', Controller::ERROR, $message, $code);\n }", "public function render($request, Exception $exception)\n {\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n return parent::render($request, $exception);\n }", "public function apiException($request, $e)\n {\n if ($e instanceof ModelNotFoundException) {\n\n return $this->modelRes($e);\n } else if ($e instanceof NotFoundHttpException) {\n\n return $this->httpRes($e);\n } else if ($e instanceof AuthorizationException) {\n\n return $this->accessDeniedRes($e);\n } else {\n\n return parent::render($request, $e);\n }\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof ApiException) {\n return $this->customApiExceptionHandler($e);\n }\n\n if ($e instanceof OAuthException) {\n return $this->customOAuthExceptionHandler($e);\n }\n\n return parent::render($request, $e);\n }", "public function render(ServerRequestInterface $request, Throwable $exception): ResponseInterface;", "public function render($request, Throwable $e): Response\r\n {\r\n if($this->app->isDebug()){\r\n return parent::render($request, $e);\r\n }else{\r\n $data = [\r\n 'code' => $e->getCode(),\r\n 'message' => $e->getMessage(),\r\n ];\r\n if(method_exists($e, \"getStatusCode\")){\r\n $this->httpStatus = $e->getStatusCode();\r\n }\r\n $this->httpHeaders = $e->getHeaders();\r\n return $request->isAjax() ? Response::create($data, 'json', $this->httpStatus)->header($this->httpHeaders) : Response::create(config('app.exception_tmpl'), 'view', $this->httpStatus)->header($this->httpHeaders)->assign($data);\r\n\r\n }\r\n \r\n }", "public function render($request, Throwable $e)\n {\n if ($e instanceof MethodNotAllowedHttpException) {\n return $this->methodNotAllowed(__('errors.method_not_allowed'));\n }\n\n if ($e instanceof NotFoundHttpException) {\n return $this->notFound(__('errors.not_found'));\n }\n\n if ($e instanceof ModelNotFoundException) {\n return $this->notFound(__('errors.not_found'));\n }\n\n if ($e instanceof ValidationException) {\n return $this->failedValidation(__('errors.validation_failed'), $e->errors());\n }\n\n if ($e instanceof AuthenticationException) {\n return $this->unauthorized($e->getMessage());\n }\n\n return $this->buildResponse($e->getMessage(), 'failed', config('errors.codes.server_error'));\n }", "public function render($request, Throwable $e)\n {\n if ($e instanceof MethodNotAllowedHttpException) {\n return $this->notAllowedResponse('The method you are calling is not allowed');\n }\n\n if ($e instanceof NotFoundHttpException) {\n return $this->notFoundResponse($e->getMessage() ? $e->getMessage() : 'we could not found what you are looking for');\n }\n\n if ($e instanceof ValidationException) {\n return $this->formValidationResponse('The validation has failed', $e->errors());\n }\n\n if ($e instanceof AuthenticationException) {\n return $this->notAllowedResponse($e->getMessage());\n }\n\n if ($e instanceof AuthorizationException) {\n return $this->notAllowedResponse($e->getMessage());\n }\n\n return $this->serverErrorResponse('Sorry an error occured, we are working on it', new Exception($e->getMessage()));\n }", "public function render($request, Throwable $exception)\n {\n return parent::render($request, $exception);\n }", "public function render($request, Exception $e)\n {\n /*if ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n return parent::render($request, $e);*/\n $debug = env('APP_DEBUG');\n if ($debug == 0) {\n if ($this->isHttpException($e)) {\n return $this->renderHttpException($e);\n } else if ($e instanceof NotFoundHttpException) {\n return response()->view('errors.404', [], 400);\n }elseif ($e instanceof FatalErrorException) {\n return response()->view('errors.500', [], 500);\n }elseif ($e instanceof handleError) {\n return response()->view('errors.500', [], 500);\n }elseif ($e instanceof ModelNotFoundException) {\n return response()->view('errors.500', [], 500);\n }else\n {\n return response()->view('errors.500', [], 500);\n }\n }else if($debug == 1) { //si es verdadero esta en modo debug y muestra el error\n if ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n return parent::render($request, $e);\n }\n }", "protected function renderHttpException(HttpException $e)\n {\n $status = $e->getStatusCode();\n\n /* view()->replaceNamespace('errors', [\n resource_path('views/errors'),\n __DIR__.'/views',\n ]);\n\n if (view()->exists(\"errors::{$status}\")) {\n return response()->view(\"errors::{$status}\", ['exception' => $e], $status, $e->getHeaders());\n } else {*/\n return $this->convertExceptionToResponse($e);\n// }\n }", "public function render($request, Exception $e)\n {\n //如果$exception 是 ApiException的一个实例,则自定义返回的错误信息\n if($e instanceof ApiException){\n $result = [\n \"code\" => 9999,\n \"msg\" => $e -> getMessage(),\n \"data\" => \"\"\n ];\n return response() -> json($result);\n }\n //自定义错误页面\n if ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n\n if($e instanceof \\Symfony\\Component\\Debug\\Exception\\FatalErrorException\n && !config('app.debug')) {\n return response() -> view('errors.default', [], 500);\n }\n //如果不是,则使用 父类的处理方法\n return parent::render($request, $e);\n }", "public function render($request, Throwable $exception)\n {\n // return parent::render($request, $exception);\n\n if ($exception instanceof ValidationException) {\n return $this->convertValidationExceptionToResponse($exception, $request);\n }\n\n if ($exception instanceof ModelNotFoundException) {\n $modelo = strtolower(class_basename($exception->getModel()));\n return $this->errorResponse(\"There is no instance of {$modelo} with the specified id\", 404);\n }\n\n if ($exception instanceof AuthorizationException) {\n return $this->errorResponse(\"You do not have authorization to execute this action\", 403);\n }\n\n if ($exception instanceof NotFoundHttpException) {\n return $this->errorResponse('The specified URL was not found', 404);\n }\n\n if ($exception instanceof MethodNotAllowedHttpException) {\n return $this->errorResponse('The method specified in the request is invalid', 405);\n }\n\n if ($exception instanceof HttpException) {\n return $this->errorResponse($exception->getMessage(), $exception->getStatusCode());\n }\n\n if ($exception instanceof QueryException) {\n $codigo = $exception->errorInfo[1];\n\n if ($codigo == 1451) {\n return $this->errorResponse('The resource cannot be permanently removed because it is related to some other.', 409);\n }\n }\n\n if (config('app.debug')) {\n return parent::render($request, $exception); \n }\n\n return $this->errorResponse('Unexpected failure. Try later', 500);\n }", "public function render($request, Exception $e){\n\n if($e instanceof ModelNotFoundException){\n $e = new NotFoundHttpException($e->getMessage(), $e);\n }\n \n if($e instanceof ForbiddenException){\n \n if($request->ajax()){\n return response()->json(['mensagem' => $e->getMessage()], 403);\n }\n \n return response()->view('errors.403', ['mensagem' => $e->getMessage()]);\n \n }\n \n if($e instanceof NotFoundException){ \n \n if($request->ajax()){\n return response()->json(['mensagem' => $e->getMessage()], 404);\n }\n \n return response()->view('errors.404', ['mensagem' => $e->getMessage()]);\n \n }\n \n return parent::render($request, $e);\n \n }", "public function render($request, Throwable $e)\n {\n // TODO: Implement render() method.\n }", "public function render($request, Exception $ex)\n {\n if ($request->ajax()) {\n return $this->renderAsJson($request, $ex);\n }\n\n // render HttpException as request aware ones\n if ($this->isHttpException($ex)) {\n return $this->toIlluminateResponse($this->renderRequestAwareHttpException($request, $ex), $ex);\n }\n\n return parent::render($request, $ex);\n }", "public function render($request, Exception $e)\n\t{\n\t\tif ($e instanceof VocalogicException)\n\t\t{\n\t\t\treturn $this->renderVocalogicException($e);\n\t\t}\n\n\t\tif (($e instanceof ModelNotFoundException) && !config('app.debug'))\n\t\t{\n\t\t\tabort(404);\n\t\t}\n\n\t\treturn parent::render($request, $e);\n\t}", "protected function webHandleException($request, Exception $exception)\n {\n return parent::render($request, $exception);\n }", "public function render($request, Exception $e)\n {\n ////////////////////////////////////////////////// starts: KHEENGZ CUSTOME CODE ///////////////////////////////////////\n //Invalid Record Request Exception\n if ($e instanceof ModelNotFoundException) {\n return response()->view('errors.custom', [\n 'code'=>'304.1',\n 'header'=>'Invalid Record Request',\n 'message'=>'The Record You Are Looking For Does Not Exist'\n ]);\n }\n //File For Download Not Found Exception\n if ($e instanceof FileNotFoundException){\n return response()->view('errors.custom', [\n 'code'=>'501.4',\n 'header'=>'File Not Found',\n 'message'=>'The File You Are Looking For Or Trying To Download Does Not Exist On Our Server'\n ]);\n }\n ////////////////////////////////////////////////// end: KHEENGZ CUSTOME CODE ///////////////////////////////////////\n\n return parent::render($request, $e);\n }", "public static function handler(Exception $e)\n {\n try {\n\n if (Request::$current !== NULL\n && Request::current()->is_ajax() === TRUE\n && Kohana::$environment !== Kohana::PRODUCTION) {\n header('Content-Type: text/plain; charset='.Kohana::$charset, TRUE, 500);\n self::_print($e);\n }\n\n if (Kohana::$environment === Kohana::PRODUCTION && ! self::$custom_view_file)\n Kohana_Kohana_Exception::$error_view = self::get_view_file($e);\n elseif (self::$custom_view_file)\n Kohana_Kohana_Exception::$error_view = self::$custom_view_file;\n\n parent::handler($e);\n\n } catch(Exception $e) {\n /**\n * Things are going *really* badly for us, We now have no choice\n * but to bail. Hard.\n */\n // Clean the output buffer if one exists\n ob_get_level() AND ob_clean();\n\n // Set the Status code to 500, and Content-Type to text/plain.\n header('Content-Type: text/plain; charset='.Kohana::$charset, TRUE, 500);\n\n echo Kohana_Exception::text($e);\n\n exit(1);\n }\n }", "public function render($request, Exception $e)\n {\n if ($request->ajax() || $request->wantsJson()) {\n $message = null;\n\n if ($e instanceof HttpException) {\n $code = 404;\n $message = 'The requested resource could not be found.';\n } else {\n $code = 500;\n }\n\n return response()\n ->json([\n 'message' => in_array(app()->environment(), ['production']) ? 'Check error logs for detailed messages' : ($message ?: ($e->getMessage() ?: strval($e))),\n 'exception' => get_class($e),\n ], $code)\n ->header('Access-Control-Allow-Origin', '*')\n ->header('Access-Control-Allow-Methods', 'POST, GET, OPTIONS, PUT, DELETE')\n ->header('Access-Control-Allow-Headers', 'Content-Type, Accept, Authorization, X-Requested-With')\n ->header('Access-Control-Max-Age', '28800');\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Throwable $e)\n {\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n } elseif ($e instanceof ModelNotFoundException) {\n $e = new NotFoundHttpException($e->getMessage(), $e);\n } elseif ($e instanceof AuthorizationException) {\n $e = new HttpException(403, $e->getMessage());\n } elseif ($e instanceof ValidationException && $e->getResponse()) {\n return $e->getResponse();\n }\n\n if ($this->isHttpException($e)) {\n return $this->toIlluminateResponse($this->renderHttpException($e), $e);\n } else {\n return $this->toIlluminateResponse($this->convertExceptionToResponse($e), $e);\n }\n }", "public function render($request, Throwable $e)\n {\n if ($this->isApiRequest($request)) {\n return $this->renderApiException($e);\n }\n\n return parent::render($request, $e);\n }", "public function actionException()\n {\n $this->render('exception');\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof \\Cms\\Modules\\Core\\Exceptions\\NotInstalledException) {\n return $this->renderNotInstalled($e);\n }\n\n if ($e instanceof \\Cms\\Modules\\Core\\Exceptions\\InMaintenanceException) {\n return $this->renderInMaintenance($e);\n }\n\n if (config('app.debug') && class_exists('\\Whoops\\Run')) {\n return $this->renderExceptionWithWhoops($e, $request);\n }\n\n if ($e instanceof \\PDOException) {\n return $this->renderPdoException($e);\n }\n\n return $this->renderErrorPage($e);\n //return parent::render($request, $e);\n }", "public function render()\n {\n if(strstr($this->getMessage(), 'PDOException: SQLSTATE[')) {\n if(preg_match('/SQLSTATE\\[(\\w+)\\]:(.*):(\\s+\\d)(.*):(.*)/', $this->getMessage(), $matches) === false) {\n $this->message = 'Generic SQL exception unhandled';\n }\n else {\n $this->message = empty($matches[5]) ? 'Generic SQL exception unhandled' : trim($matches[5]);\n }\n }\n else {\n $this->message = 'Generic SQL exception unhandled';\n }\n\n return response()->json(['message' => $this->getMessage()], 409);\n }", "public function render($request, Exception $e)\n {\n if($this->isReadable($e)){\n if($e instanceof ValidationException){\n //校验异常,并且确保是ajax请求的才按照我们的格式输出,否则按照框架的规则输出页面\n if($e->getResponse() instanceof RedirectResponse){\n return parent::render($request, $e);\n }\n $errors = $this->getValidationError($e);\n return responseFailed(-1,$errors);\n }else{\n return responseError($e);\n }\n }\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n if ($e instanceof SaleItemRegisterException) {\n return response()->view('errors.sale_item_register', [\"message\" => $e->getMessage()], 500);\n }\n if ($e instanceof NotFoundHttpException) {\n return response()->view('errors.404', [], 404);\n }\n if ($e instanceof NotFoundUserException) {\n return response()->view('errors.404', [\"message\" => $e->getMessage()], 404);\n }\n if ($e instanceof ItemRegisterException) {\n return response()->view('errors.item_register', [], 500);\n }\n if ($e instanceof ApiAuthException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($e instanceof ItemEditException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($e instanceof ArticleContainerException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($e instanceof UserSettingException) {\n return new JsonResponse([\"message\" => $e->getMessage()]);\n }\n if ($request->ajax()) {\n if ($e instanceof Exception) {\n Log::info($e->getMessage());\n Log::info($e->getTraceAsString());\n return new JsonResponse([\"message\" => \"予期せぬエラーが発生しました\"]);\n }\n }\n // HTTPエラー\n if ($e instanceof HttpException) {\n if ($e->getStatusCode() === 404) {\n return response()->view('errors.404', [], 404);\n }\n // メンテナンスモード\n if ($e->getStatusCode() === 503) {\n return response()->view('errors.503', [\"message\" => $e->getMessage()], 503);\n }\n }\n \n // その他エラー\n if (!($e instanceof ValidationException) && !($e instanceof HttpResponseException) && $e instanceof Exception) {\n Log::info($e->getMessage());\n Log::info($e->getTraceAsString());\n return response()->view('errors.500', [\"message\" => $e->getMessage()], 500);\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n {\n $route = $request->route();\n if (!$route || in_array('api', $route->middleware())) {\n $request->headers->set('Accept', 'application/json');\n }\n\n if ($exception instanceof ErrorHttp) {\n return $this->answerWith($exception);\n }\n\n if ($exception instanceof UnauthorizedHttpException) {\n $message = 'Unauthorized';\n $data = [];\n if ($exception->getMessage() === 'Token has expired') {\n $data['token'] = 'expired';\n }\n return $this->answerError($message, Status::CODE_401, $data);\n }\n\n if ($exception instanceof QueryException) {\n $bindings = $exception->getBindings();\n if (!is_array($bindings)) {\n $bindings = [$bindings];\n }\n foreach ($bindings as $key => $binding) {\n $bindings[$key] = Encoding::fixUTF8($binding);\n }\n $message = Encoding::fixUTF8($exception->getMessage());\n $data = [\n 'sql' => $exception->getSql(),\n 'bindings' => $bindings,\n ];\n return $this->answerError($message, Status::CODE_500, $data);\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $e): Response\n {\n if ($e instanceof \\think\\Exception) {\n return show($e->getCode(), $e->getMessage());\n }\n if ($e instanceof \\think\\exception\\HttpResponseException) {\n return parent::render($request, $e);\n }\n if (method_exists($e, \"getStatusCode\")){\n $httpStatus = $e->getStatusCode();\n }else{\n $httpStatus = $this->httpStatus;\n }\n // 添加自定义异常处理机制\n return show(config(\"status.error\"), $e->getMessage(), [], $httpStatus);\n }", "public function render($request, Throwable $exception)\n {\n\n $error = new \\stdClass();\n $error->code = $status = 500;\n $error->message = 'Internal Server Error.';\n\n switch (true) {\n case $exception instanceof ModelNotFoundException:\n $model = str_replace('App\\\\', '', $exception->getModel());\n $status = $error->code = 404;\n $error->message = \"{$model} not found.\";\n break;\n\n case $exception instanceof NotFoundHttpException:\n $error->code = $exception->getStatusCode();\n $error->message = 'Page not found.';\n\n break;\n\n case $exception instanceof AuthenticationException:\n $status = $error->code = 401;\n $error->message = $exception->getMessage();\n break;\n\n case $exception instanceof CustomException:\n $status = $error->code = 400;\n $error->message = $exception->getMessage();\n break;\n\n default:\n $error->code = method_exists($exception,'getStatusCode') ? $exception->getStatusCode() : $status;\n $error->message = method_exists($exception,'getMessage') ? $exception->getMessage() : $error->message;\n break;\n }\n\n $response = ['success' => false, 'error' => $error ];\n Log::debug('Exception: '.json_encode($error, JSON_UNESCAPED_UNICODE));\n\n return response()->json($response, $status);\n }", "public function render($request, Throwable $exception)\n {\n if ($exception instanceof AccessDeniedException) {\n return AccessDeniedException::getResponse();\n }\n if ($exception instanceof BadCredentialsException) {\n return BadCredentialsException::getResponse($exception->getMessage());\n }\n if ($exception instanceof DataNotFoundException) {\n return DataNotFoundException::getResponse($exception->getMessage());\n }\n if ($exception instanceof DuplicateDataException) {\n return DuplicateDataException::getResponse($exception->getMessage());\n }\n\n if ($exception instanceof \\Illuminate\\Database\\QueryException) {\n return QueryException::getResponse($exception->getMessage());\n } elseif ($exception instanceof \\PDOException) {\n return DatabaseConnectionException::getResponse();\n }\n\n if ($exception instanceof InvalidActionException) {\n return InvalidActionException::getResponse($exception->getMessage());\n }\n if ($exception instanceof UnauthorizeException) {\n return UnauthorizeException::getResponse($exception->getMessage());\n }\n if ($exception instanceof UsernameIsExistsException) {\n return UsernameIsExistsException::getResponse();\n }\n if ($exception instanceof ValidationException) {\n return ValidationErrorException::getResponse($exception);\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n\t // 调试模式返回原生异常调用栈\n//\t if (!config('app.debug')) {\n//\t\t return parent::render($request, $exception);\n//\t }\n\n\t // 如果定义了该异常处理,则自定义异常处理方法\n\t $renderMethod = $this->customRender[get_class($exception)]['render'] ?? '';\n\t if ($renderMethod && method_exists($this, $renderMethod)) {\n\t\t return $this->$renderMethod($request, $exception);\n\t }\n\n\t return parent::render($request, $exception);\n }", "public function render($request, Throwable $e) /** @phpstan-ignore-line */\n {\n // TODO: Implement render() method.\n }", "public function render($request, Exception $e)\n {\n\t\t//正式环境返回错误json\n\t\tif(env('APP_DEBUG')!='true'){\n\t\t\tif($e instanceof NotFoundHttpException){\n\t\t\t\treturn response(array('code'=>404,'message'=>'the api you request is not found!','content'=>'','contentEncrypt'=>''));\n\t\t\t}\n\t\t\telse if($e instanceof MethodNotAllowedHttpException){\n\t\t\t\treturn response(array('code'=>404,'message'=>'all request should be post!','content'=>'','contentEncrypt'=>''));\n\t\t\t}\n\n\t\t}\n return parent::render($request, $e);\n }", "public function http(HttpResponseException $ex);", "abstract protected function echoExceptionWeb($exception);", "public function render($request, Exception $e)\n {\n //Validation\n if ($e instanceof ValidationException) {\n return $e->getResponse();\n }\n\n // AuthorizationException\n if ($e instanceof AuthorizationException) {\n return response()->json([\n 'errors' => [\n 'title' => 'Unauthorized'\n ]\n ], 401);\n }\n\n //Http Exceptions\n if ($e instanceof HttpException) {\n $response['message'] = $e->getMessage() ?: Response::$statusTexts[$e->getStatusCode()];\n $response['status'] = $e->getStatusCode();\n\n return response()->json($response, $response['status']);\n }\n\n //Default Exception Response\n $response = [\n 'message' => 'Whoops! Something went wrong.',\n 'status' => 500\n ];\n\n if ($this->isDebugMode()) {\n $response['debug'] = [\n 'message' => $e->getMessage(),\n 'exception' => get_class($e),\n 'code' => $e->getCode(),\n 'file' => $e->getFile(),\n 'line' => $e->getLine(),\n ];\n\n //clean trace\n foreach ($e->getTrace() as $item) {\n if (isset($item['args']) && is_array($item['args'])) {\n $item['args'] = $this->cleanTraceArgs($item['args']);\n }\n $response['debug']['trace'][] = $item;\n }\n }\n\n return response()->json($response, $response['status']);\n }", "public function render($request, Exception $exception)\r\n {\r\n $isApi = $request->expectsJson() || $request->wantsJson() || $request->ajax();\r\n \r\n if ($exception instanceof \\Symfony\\Component\\HttpKernel\\Exception\\NotFoundHttpException) {\r\n if($isApi){ \r\n return response()->json(['status'=>404,'message'=>__('alert.resource_not_found'),'data'=>null,'errors'=>[true]],404);\r\n }else{\r\n return response()->view('error.generic',['message'=>__('alert.resource_not_found'),'code'=>404]);\r\n }\r\n }else if($exception instanceof \\Illuminate\\Auth\\AuthenticationException){\r\n if($isApi){ \r\n return response()->json(['status'=>401,'message'=>__('alert.invalid_token'),'data'=>null,'errors'=>[true]],401);\r\n }else{\r\n // return response()->view('error.generic',['message'=>__('alert.invalid_token'),'code'=>401]);\r\n }\r\n }else if($exception instanceof \\Symfony\\Component\\HttpKernel\\Exception\\MethodNotAllowedHttpException){\r\n if($isApi){ \r\n return response()->json(['status'=>405,'message'=>__('alert.resource_not_found'),'data'=>null,'errors'=>[true]],405);\r\n }else{\r\n return response()->view('error.generic',['message'=>__('alert.resource_not_found'),'code'=>404]);\r\n }\r\n }\r\n \r\n\r\n return parent::render($request, $exception);\r\n }", "public function render($request, Exception $e)\n {\n app('translator')->setLocale('zh-CN');\n $errorCode = $e->getCode();\n $statusCode = $e->getStatusCode();\n\n if ($errorCode == 2002) {\n echo json_encode(error_response('0x000022', 'common'));\n } else if ($errorCode == 10061) {\n echo json_encode(error_response('0x000023', 'common'));\n } else {\n if ($statusCode == '404') {\n echo json_encode(error_response('0x000404', 'common'));\n } else if ($statusCode == '401') {\n echo json_encode(error_response('0x000401', 'common'));\n } else {\n echo json_encode(error_response('0x000013', '', json_encode([\"file\" => $e->getFile(), \"line\" => $e->getLine()])));\n }\n }\n exit;\n\n return parent::render($request, $e);\n }", "protected function renderHttpResponse(Exception $e)\n {\n $this->getExceptionHandler()->render($e);\n }", "public function render($request, Exception $exception)\n {\n $handler = $this->findExceptionResponseHandler($exception);\n\n if (!is_null($handler)) {\n return $handler->render();\n }\n\n if (!method_exists($exception, 'getErrorTitle')) {\n $handler = new Response\\UnknownErrorHandler;\n\n return $handler->render();\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $e): Response\n {\n if($e instanceof \\think\\Exception){\n return json_response($e->getCode(),$e->getMessage());\n }\n if($e instanceof \\think\\exception\\HttpResponseException){\n return parent::render($request,$e);\n }\n // 添加自定义异常处理机制\n if(method_exists($e,'getStatusCode')){\n $this->httpStatusCode = $e->getStatusCode();\n }\n return json_response(config('status.error'),$e->getMessage(),[], $this->httpStatusCode);\n // 其他错误交给系统处理\n //return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n {\n\n $TraceException = [\n 'class' => get_class($exception),\n 'file' => $exception->getFile(),\n 'line_of_code' => $exception->getLine(),\n 'code' => $exception->getCode(),\n 'trace' => $exception->getTraceAsString()\n ];\n\n if ($exception instanceof ModelNotFoundException) {\n $arrModel = explode(\"\\\\\",$exception->getModel());\n $model = end($arrModel);\n return renderResponse([\n 'status' => FALSE, \n 'message' => ucfirst($model.' '.config('mamikos.message.data_not_found'))\n ],404);\n }\n\n if ($exception instanceof NotFoundHttpException) {\n return renderResponse([\n 'status' => FALSE, \n 'message' => config('mamikos.message.route_not_found'),\n // 'exception' => $TraceException\n ],404);\n }\n\n if($exception instanceof \\Illuminate\\Auth\\AuthenticationException ){\n return renderResponse([\n 'status' => FALSE, \n 'message' => $exception->getMessage()\n ],401);\n }\n\n if($exception instanceof ValidationException){\n $errors = [];\n foreach ($exception->errors() as $key => $value) {\n $errors[] = $value[0];\n\n if($key==0){break;} \n }\n return renderResponse([\n 'status' => FALSE, \n 'message' => $errors[0]\n ],400);\n }\n\n $response = [\n 'status' => FALSE,\n 'message' => $exception->getMessage(),\n 'exception' => $TraceException\n ];\n // return parent::render($request, $exception);\n return renderResponse($response, 404);\n }", "public function render($request)\r\n\t{\r\n\t\t// Create json response\r\n\t\treturn response()->json([\r\n\t\t\t'message' => $this->message ?? 'Unknown Exception.',\r\n\t\t], ($this->code >= 100 && $this->code < 600) ? $this->code : 422);\r\n\t}", "public function render($request, Exception $exception)\n {\n if ($request->wantsJson()) {\n return $this->handleApiException($request, $exception);\n } else {\n return parent::render($request, $exception);\n }\n }", "public function render($request, Throwable $e)\n {\n switch (get_class($e)) {\n case $e instanceof AppValidationException:\n $renderer = new ValidationRenderer($e);\n return $renderer->render();\n case NotAuthenticatedException::class:\n $renderer = new NotAuthenticatedRenderer($e);\n return $renderer->render();\n break;\n default:\n return parent::render($request, $e);\n }\n }", "public function render(Throwable $e)\n {\n if ($e instanceof ResourceNotFoundException) {\n // 404\n $template = $this->app->make(ViewFactory::class);\n echo $template->make('vendor/404');\n exit();\n }\n throw $e;\n }", "protected function render(Throwable $e, Input $input) : Response\n {\n return call_user_func($this->getRenderer(), $e, $input);\n }", "public function render($request, Throwable $exception)\n {\n switch ($exception)\n {\n case $exception instanceof ModelNotFoundException && count($exception->getIds()) === 1:\n /* Handle model not found when querying a single entity */\n $id = array_first($exception->getIds());\n /*\n * IF $existed == true : the user has requested a url for a model that was deleted\n * IF $existed == false : the user has requested a url for a model that never existed (possible url manipulation)\n */\n $existed = $exception->getModel()::onlyTrashed()->where('id', $id)->count() > 0;\n $entity = last(explode('\\\\', $exception->getModel()));\n $entitiesToReport = ['Tender', 'Project', 'Asset'];\n $detailKey = null;\n if(in_array($entity, $entitiesToReport, true)) {\n $detailKey = $existed ? 'ENTITY_DELETED' : 'ENTITY_NOT_FOUND';\n }\n return response()->json([\n 'detailKey' => $detailKey,\n 'entity' => $entity\n ], 404);\n // TODO: log everything\n\n default:\n return parent::render($request, $exception);\n }\n\n }", "public function render($request, Exception $e)\n {\n if ($this->isResponseException($e)) {\n return parent::render($request, $e);\n }\n\n if ($this->isNotFountException($e)) {\n if ($request->ajax() || $request->wantsJson()) {\n return new JsonResponse(['404: ' . $e->getMessage()], 404);\n }\n\n return response()->view('errors.404', ['exception' => $e], 404);\n }\n\n if (config('app.debug')) {\n return $this->handleInDebugMode($request, $e);\n }\n\n return $this->handleInProductionMode($request, $e);\n }", "protected function renderRequestAwareHttpException($request, \\Symfony\\Component\\HttpKernel\\Exception\\HttpException $ex)\n {\n $status = $ex->getStatusCode();\n $sub = $this->findPathInfoFirstComponent($request->getPathInfo());\n\n if (view()->exists(\"errors.{$status}-{$sub}\")) {\n return response()->view(\"errors.{$status}-{$sub}\", ['exception' => $ex], $status);\n }\n\n return $this->renderHttpException($ex);\n }", "public function render($request, Throwable $exception)\n {\n if ($exception instanceof \\Symfony\\Component\\HttpKernel\\Exception\\UnauthorizedHttpException) {\n switch (get_class($exception->getPrevious())) {\n case \\Tymon\\JWTAuth\\Exceptions\\TokenExpiredException::class:\n return response()->json([\n 'error' => 'Su sesión ha expirado'\n ], $exception->getStatusCode());\n\n case \\Tymon\\JWTAuth\\Exceptions\\TokenInvalidException::class:\n case \\Tymon\\JWTAuth\\Exceptions\\TokenBlacklistedException::class:\n return response()->json([\n 'error' => 'La sesión no es valida'\n ], $exception->getStatusCode());\n default:\n break;\n }\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $exception)\n {\n switch (true) {\n case ($exception instanceof BaseException):\n return $this->renderException(['login' => [$exception->getMessage()]], $exception->getCode());\n case ($exception instanceof UnauthorizedHttpException):\n return $this->renderException(['user' => [$exception->getMessage()]], $exception->getCode());\n case ($exception instanceof JWTException):\n return $this->renderException(['token' => [$exception->getMessage()]], JsonResponse::HTTP_UNAUTHORIZED);\n case ($exception instanceof NotFoundHttpException):\n return $this->renderException(['not_found' => [self::ROUTE_NOT_FOUND]], JsonResponse::HTTP_NOT_FOUND);\n default:\n return $this->renderException(['error' => [$exception->getMessage()]], JsonResponse::HTTP_INTERNAL_SERVER_ERROR);\n }\n }", "public function render($request, Throwable $e): Response\n {\n // 添加自定义异常处理机制\n\n if ($e instanceof ValidateException) {\n return Response::create(['message' => $e->getMessage(), 'code' => 50015], 'json', 200);\n }\n\n if ($e instanceof SystemException) {\n return Response::create(['message' => $e->getMessage(), 'code' => $e->getCode()], 'json', 200);\n }\n\n // 其他错误交给系统处理\n return parent::render($request, $e);\n }", "public function render($request, Throwable $e): Response\n {\n // 添加自定义异常处理机制\n $massageData = Env::get('app_debug', false) ? [\n 'message' => $e->getMessage(),\n 'file' => $e->getFile(),\n 'line' => $e->getLine(),\n 'trace' => $e->getTrace(),\n 'previous' => $e->getPrevious(),\n ] : [];\n\n // 添加自定义异常处理机制\n if ($e instanceof DbException) {\n return app('json')->fail('数据获取失败', $massageData);\n } elseif ($e instanceof AuthException ||\n $e instanceof ValidateException ||\n $e instanceof ApiException ||\n $e instanceof UploadException ||\n $e instanceof AdminException\n ) {\n return app('json')->make($e->getCode() ?: 400, $e->getMessage(), $massageData);\n }\n return app('json')->make($e->getCode() ?: 400, $e->getMessage(), $massageData);\n // 其他错误交给系统处理\n// return parent::render($request, $e);\n }", "public function render($request, Exception $exception)\n {\n if (\n !$request->expectsJson()\n || empty($this->formatApiResponse)\n || !$this->formatApiResponse\n ) {\n return parent::render($request, $exception);\n }\n\n return response()->error(\n $exception->getMessage(),\n $this->getStatus($exception),\n $this->getErrors($exception)\n );\n }", "public function render($request, Exception $e)\n {\n //dd($e);\n //dd($request->wantsJson());\n //dd($request);\n if ($e instanceof ModelNotFoundException or \n $e instanceof NotFoundHttpException or \n $e instanceof HttpException)\n {\n //dd('entrou no if');\n $statusCode = $e->getStatusCode();\n\n // Verifica se requisição veio via AJAX\n if ($request->wantsJson()){\n switch ($statusCode) \n {\n case 401: return response()->json(['status' => false, 'errors' => ['errors' => [ 'Usuário não está logado' ] ] ], $statusCode);\n case 403: return response()->json(['errors' => ['errors' => ['Falha na autenticação'] ] ], $statusCode);\n case 404: return response()->json(['status' => false, 'errors' => ['errors' => [ 'A página solicitada não foi encontrada' ] ] ], $statusCode);\n //case 404: return redirect()->guest(route('login'));\n }\n \n } else {\n switch ($statusCode) \n {\n case 401: return response()->view('auth.login',[],$statusCode);\n case 403: return response()->view('erros.403', ['titulo' => 'Atenção', 'descricao' => 'Falha na autenticação'],$statusCode);\n case 404: return response()->view('erros.404',[],$statusCode);\n //case 404: return redirect()->guest(route('login'));\n }\n }\n }\n else if( $e instanceof QueryException )\n {\n if( !empty($e->errorInfo[2]) && isset($e->errorInfo[2]) && $e->errorInfo[2] != '' )\n {\n $mensagem[0] = $e->errorInfo[2];\n\n if( \\Config::get('app.debug') )\n {\n $mensagem[1] = $e->getSql();\n }\n }\n else\n {\n $mensagem[0] = $e->getMessage();\n }\n\n // Verifica se requisição veio via AJAX\n if ($request->wantsJson())\n return response()->json(['status' => false, 'errors' => ['errors' => [ 'Erro no comando SQL.' ] ] ], 200);\n else\n return response()->view('erros.query', ['mensagem' => $mensagem], 500);\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Throwable $exception)\n {\n if (ApiUtil::checkUrlIsApi($request)) {\n return $this->handleApiException($request, $exception);\n } else {\n return $this->handleWebException($request, $exception);\n }\n }", "public function render($request, Exception $exception) {\n // regular exception\n if ($this->handler->willHandle($exception)) {\n return parent::render($request, $exception);\n }\n\n // api exception\n if (!$message = $exception->getMessage()) {\n $message = sprintf('%d %s', $exception->getStatusCode(), Response::$statusTexts[$exception->getStatusCode()]);\n }\n\n $statusCode = $exception->getStatusCode();\n $headers = $exception->getHeaders();\n\n $response = ['message' => $message, 'status_code' => $statusCode];\n\n if ($exception instanceof ApiException && $exception->hasErrors()) {\n $response['errors'] = $exception->getErrors();\n }\n\n if ($code = $exception->getCode()) {\n $response['code'] = $code;\n }\n\n if ($this->debug) {\n $response['debug'] = [\n 'line' => $exception->getLine(),\n 'file' => $exception->getFile(),\n 'class' => get_class($exception),\n 'trace' => explode(\"\\n\", $exception->getTraceAsString())\n ];\n }\n\n return new Response($response, $statusCode, $headers);\n }", "public function render($request, Throwable $exception)\n {\n /* only run if debug is turn off */\n if ( !env('APP_DEBUG', true) ) {\n\n $core = new Core;\n\n /* handling 404 exception */\n if($exception instanceof NotFoundHttpException){\n\n return response()->json([\n 'error' => 'Not Found',\n ])->setStatusCode(404);\n }\n\n /* handling 500 exception */\n $exception_name = get_class($exception);\n\n $error = $core->log('error', \"Exception ($exception_name) : \" . $exception->getTraceAsString() , true);\n\n return response()->json([\n 'error' => \"Server problem, code [$error]\",\n ])->setStatusCode(500);\n\n }\n\n return parent::render($request, $exception);\n }", "public function RenderNotFound () {\n\t\tif ($this->application->IsNotFoundDispatched()) return;\n\t\tthrow new \\ErrorException(\n\t\t\t\"Page not found: `\" . htmlspecialchars($this->request->GetFullUrl()) . \"`.\", 404\n\t\t);\n\t}", "public function render($request, Throwable $exception)\n {\n #sentry\n if (app()->bound('sentry') && $this->shouldReport($exception)) {\n app('sentry')->captureException($exception);\n }\n\n if ($exception instanceof MethodNotAllowedException) {\n return $this->sendErrorResponse([], 'Method not allowed', 405);\n }\n\n if ($exception instanceof CustomValidatorException) {\n return $this->sendErrorResponse($exception->getErrors(), 'Required fields are missing', 422);\n }\n\n if ($request->wantsJson()) {\n //Unauthenticated\n if ($exception instanceof AuthenticationException) {\n return $this->sendErrorResponse(null, $exception->getMessage(), 401);\n }\n\n\n $code = $exception->getCode() ?: 500;\n\n\n if (config('app.debug')) {\n $response = $exception->getMessage();\n $debug = $exception->getTrace();\n $message = $exception->getMessage();\n\n if ($exception instanceof QueryException) {\n $code = 500;\n }\n\n return $this->sendErrorResponse(\n null,\n $response,\n $code,\n [],\n $message,\n $debug\n );\n } else {\n $message = \"Something went wrong, Please try again later.\";\n\n\n if ($exception instanceof DolphiqException) {\n return $this->sendErrorResponse([], $exception->getMessage(), $exception->getCode());\n }\n if ($exception instanceof NotFoundHttpException) {\n return $this->sendErrorResponse([], 'Resource not found', 404);\n }\n\n\n if ($exception instanceof QueryException) {\n $code = 500;\n $message = \"Server Error! Please Try Again.\";\n }\n\n //default\n return $this->sendErrorResponse(\n null,\n $message,\n $code,\n [],\n $exception->getMessage()\n );\n }\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n if (config('app.debug') && $request->wantsJson()) {\n return self::renderJson($exception);\n }\n\n if (config('app.debug')) {\n return self::renderHtml($exception);\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $e)\n {\n $code = 5000;\n /*逻辑代码异常*/\n if ($e instanceof LogicException) {\n $code = $e->getMessage();\n $message = config('apicode.' . $code);\n } elseif ($e instanceof ValidationException) { // 验证异常\n// $errors = $e->errors();\n// if (is_array($errors) && !empty($errors)) {\n// $code = 5001;\n// foreach ($errors as $k => $v) {\n// $data[] = $v[0];\n// }\n// }\n $errorinfo = array_slice($e->errors(), 0, 1, false);\n $msg = array_column($errorinfo, 0);\n $message = $msg[0];\n } else {\n //prod 环境,统一返回内部错误\n $errFile = $e->getFile();\n $errLine = $e->getLine();\n $errMsg = $e->getMessage();\n $data = [\n 'errorMsg' => $errMsg,\n 'errLine' => $errLine,\n 'errFile' => $errFile\n ];\n }\n\n return response()->json([\n 'code' => $code,\n 'message' => $message ?? '内部服务器错误',\n 'data' => $data ?? [],\n ], 200);\n\n return $this->responseMessage($code);\n }", "public function render($request, Throwable $exception)\n {\n\n // todo: refactor\n switch (get_class($exception)) {\n case AuthenticationException::class:\n if (in_array('api', request()->route()->middleware())) {\n return \\response()->json([\n 'status' => 'error',\n 'message' => $exception->getMessage()\n ]);\n }\n break;\n default:\n break;\n }\n\n return parent::render($request, $exception);\n }", "public function render()\r\n {\r\n $this->view->toView([\"subTitle\" => \"Error\"])->loadError($this->code);\r\n }", "public function render($request, Exception $exception)\n {\n //HTTP Error Code 405\n if ($exception instanceof MethodNotAllowedHttpException) {\n $status = Response::HTTP_METHOD_NOT_ALLOWED;\n $exception = new MethodNotAllowedHttpException(\n [],\n 'HTTP_METHOD_NOT_ALLOWED',\n $exception\n );\n }\n //HTTP Error Code 404\n elseif ($exception instanceof NotFoundHttpException) {\n $status = Response::HTTP_NOT_FOUND;\n $exception = new NotFoundHttpException('HTTP_NOT_FOUND', $exception);\n }\n //HTTP Error Code 403\n elseif ($exception instanceof AuthorizationException) {\n $status = Response::HTTP_FORBIDDEN;\n $exception = new AuthorizationException('HTTP_FORBIDDEN', $status);\n } else {\n $status = $exception->getCode() ? $exception->getCode() : Response::HTTP_INTERNAL_SERVER_ERROR;\n }\n\n\n return response()->json(\n [\n \"error\" => 'ERROR',\n 'code' => $status,\n 'message' => $exception->getMessage()\n ],\n $status\n );\n }", "public function render($request, Exception $e)\n {\n $redirect = $this->reportNotFound($e);\n\n if ($redirect && $redirect instanceof RedirectResponse) {\n return $redirect;\n }\n\n return parent::render($request, $e);\n }", "public function render($request, Exception $e)\n {\n $e = $this->prepareException($e);\n\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n }\n\n return $this->prepareResponse($request, $e);\n }", "public function render($request, Throwable $exception)\n {\n if(get_class($exception) === AuthorizationException::class) {\n return response()->json([\n 'error' => 'this action is not allowed by user'\n ], 403);\n }\n\n else if(get_class($exception) === ModelNotFoundException::class) {\n \n $model = strtolower(collect(explode('\\\\', $exception->getModel()))->last());\n\n return response()->json([\n 'error' => \"$model not found\"\n ], 404);\n }\n\n else if(get_class($exception) === NotFoundHttpException::class) {\n return response()->json([\n 'error' => 'route not found'\n ], 404);\n } elseif (get_class($exception) === UnableToVerifyPaymentException::class) {\n return response()->json([\n 'error' => $exception->getMessage()\n ], 400);\n }\n else {\n if(app()->environment('production')) {\n return response()->json([\n 'error' => 'something unexpected happened'\n ], 500);\n }\n }\n\n return parent::render($request, $exception);\n }", "static public function responseForHTTPException($request, HttpException $exception) {\n\n \t\tif ($request->ajax()) {\n \t\t\t\t// error message and status code\n return response($exception->getMessage(), $exception->getStatusCode());\n } else {\n\t\t \t\t$data = [\n \"statusCode\" => $exception->getStatusCode(),\n \"statusText\" => SymfonyResponse::$statusTexts[$exception->getStatusCode()],\n \"errorMsg\" => $exception->getMessage()\n ];\n return response()->view('errors.error', $data, $exception->getStatusCode());\n }\n \t}", "public function render($request, Exception $exception)\n {\n if ($exception instanceof \\Illuminate\\Validation\\ValidationException\n || $exception instanceof \\Illuminate\\Foundation\\Http\\Exceptions\\MaintenanceModeException){\n // 勝手に処理してくれるのでもともとのハンドラに丸投げする\n return parent::render($request, $exception);\n }\n\n if(config('app.debug')){\n return parent::render($request, $exception);\n }\n\n if($this->isHttpException($exception)){\n switch(true){\n case ($exception->getStatusCode() == 404):\n return response()->view('errors/404', [], 404);\n }\n }\n\n return response()->view('errors/500', [], 500);\n // return parent::render($request, $exception);\n }", "public function render()\n {\n return $this->throw();\n }", "public function actionError()\n {\n if (($exception = Yii::$app->getErrorHandler()->exception) === null) {\n // action has been invoked not from error handler, but by direct route, so we display '404 Not Found'\n $exception = new HttpException(404, Yii::t('yii', 'Page not found.'));\n }\n\n if ($exception instanceof HttpException) {\n $code = $exception->statusCode;\n } else {\n $code = $exception->getCode();\n }\n if ($exception instanceof Exception) {\n $name = $exception->getName();\n } else {\n $name = Yii::t('yii', 'Error');\n }\n if ($code) {\n $name .= \" (#$code)\";\n }\n\n if ($exception instanceof UserException) {\n $message = $exception->getMessage();\n } else {\n $message = Yii::t('yii', 'An internal server error occurred.');\n }\n $statusCode = $exception->statusCode ? $exception->statusCode : 500;\n if (Yii::$app->getRequest()->getIsAjax()) {\n return \"$name: $message\";\n } else {\n return $this->render('error', [\n 'code' => $statusCode,\n 'name' => $name,\n 'message' => $message\n ]);\n }\n }", "public function render($request, Exception $exception)\n { \n if ($this->shouldReport($exception)){\n $this->sendException($exception, $request);\n }\n return parent::render($request, $exception);\n }", "public function handleRequest()\n {\n try {\n $response = $this->handleRequestInner();\n } catch (HttpException $ex) {\n $this->config->set('page_title', 'Error');\n\n $view = new View('exception');\n $view->exception = $ex;\n\n $response = new Response();\n\n $response->setResponseCode($ex->getErrorCode());\n $response->setContent($view->render());\n } catch (\\Exception $ex) {\n $this->config->set('page_title', 'Error');\n\n $view = new View('exception');\n $view->exception = $ex;\n\n $response = new Response();\n\n $response->setResponseCode(500);\n $response->setContent($view->render());\n }\n\n return $response;\n }", "public function render($request, Exception $exception)\n {\n // 参数验证错误的异常,我们需要返回 400 的 http code 和一句错误信息 1104\n if ($exception instanceof ValidationException) {\n // $code = 1104;\n // return response(['error' => array_first(array_collapse($exception->errors()))], 400);\n return $this->getResultByCode(1104, Arr::first(Arr::collapse($exception->errors())));\n }\n // 用户认证的异常,我们需要返回 401 的 http code 和错误信息\n if ($exception instanceof UnauthorizedHttpException) {\n // return response($exception->getMessage(), 401);\n $this->getResultByCode(401, $exception->getMessage());\n }\n\n if ($exception instanceof AuthenticationException) {\n return $this->getResultByCode(1200);\n }\n\n if ($exception instanceof ModelNotFoundException) {\n return $this->getResultByCode(404);\n }\n\n if ($exception instanceof QueryException) {\n // return response()->json(['code' => '500', 'reason' => 'Internal Server Error', 'data' => ''], 500);\n }\n\n // JWT exception\n if ($exception instanceof TokenBlacklistedException) {\n return $this->getResultByCode(5001);\n }\n\n // 2018-12-27 Missing404Exception 未生成全文索引的错误\n // if ($exception instanceof Missing404Exception) {\n // return $this->getResultByCode(5002);\n // }\n\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n if (\n $exception instanceof ScheduleHasSessionException\n || $exception instanceof ScheduleNotHasSessionException\n || $exception instanceof ScheduleSessionIsClosedException\n || $exception instanceof UniqueVotePerSessionException\n || $exception instanceof UniqueDocumentAssociateException\n ) {\n return $this->renderCustom($request, $exception);\n }\n\n if ($exception instanceof ModelNotFoundException) {\n return $this->renderModelNotFoundException();\n }\n\n if ($exception instanceof ValidationException) {\n return $this->renderValidationException($exception->validator);\n }\n\n if ($exception instanceof NotFoundHttpException) {\n return $this->renderNotFoundHttpException();\n }\n\n if ($exception instanceof MethodNotAllowedHttpException) {\n return $this->renderMethodNotAllowedException();\n }\n\n return response()->json([\n 'message' => trans('exceptions.Unknown error')\n ], HttpStatusCodeEnum::INTERNAL_SERVER_ERROR);\n }", "public function render($request, Exception $exception)\n {\n $e = $this->prepareException($exception);\n\n if ($e instanceof HttpResponseException) {\n return $e->getResponse();\n } elseif ($e instanceof AuthenticationException) {\n $status = Response::HTTP_UNAUTHORIZED;\n $message = '認証に失敗しました。ログインしてください。';\n $errors = [];\n $trace = [];\n } elseif ($e instanceof ValidationException) {\n $status = $e->status;\n $message = Response::$statusTexts[$status];\n $errors = $e->errors();\n $trace = [];\n } elseif ($this->isHttpException($e)) {\n $status = $e->getCode();\n if ($status == 0) {\n $status = 400;\n }\n $message = $e->getMessage();\n $errors = [];\n $trace = [];\n } else {\n $code = env('APP_DEBUG', true) ? $e->getCode() : Response::HTTP_INTERNAL_SERVER_ERROR;\n if (isset($code)) {\n $code = Response::HTTP_INTERNAL_SERVER_ERROR;\n }\n $status = $code;\n $message = env('APP_DEBUG', true) ? $e->getMessage() : 'サーバエラーが発生しました。管理者に連絡してください。';\n $errors = [];\n $trace = env('APP_DEBUG', true) ? $e->getTrace() : [];\n }\n\n // ResponseApiServiceProviderが実行される前にエラーが発生した場合の対応\n if (!method_exists(response(), 'error')) {\n $app = app();\n $provide = new ResponseApiServiceProvider($app);\n $provide->boot();\n }\n\n return response()->error($message, $errors, $trace, $status);\n }", "public function render($request, Throwable $exception)\n {\n if ($exception instanceof NotImplementedException) {\n return response('Not implemented', 501);\n }\n\n if (!$request->expectsJson()) {\n if ($exception instanceof AuthorizationException) {\n Session::flash('error', 'Not authorized.');\n\n return redirect('/');\n }\n if ($exception instanceof UnauthorizedException) {\n Session::flash('error', 'Not authorized.');\n\n return redirect('/');\n }\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $exception)\n {\n $debug = env('APP_DEBUG');\n\n if (!$debug) {\n if ($exception instanceof ValidationException) {\n return new JsonResponse([\n 'error' => 'bad request'\n ], Response::HTTP_BAD_REQUEST);\n } elseif ($exception instanceof BadRequestHttpException) {\n $message = $exception->getMessage();\n\n if (substr($exception->getMessage(), 0, 4) == 'msg_') {\n// if ()\n $message = substr($message, 4);\n if ($message) {\n $msg = json_decode($message);\n if ($msg) {\n return new JsonResponse([\n 'error' => 'bad request',\n 'message' => $msg\n ], Response::HTTP_BAD_REQUEST);\n } else {\n return new JsonResponse([\n 'error' => 'bad request',\n 'message' => $message\n ], Response::HTTP_BAD_REQUEST);\n }\n }\n return new JsonResponse([\n 'error' => 'bad request'\n ], Response::HTTP_BAD_REQUEST);\n\n }\n } elseif ($exception instanceof ModelNotFoundException) {\n return new JsonResponse([\n 'error' => 'model not found'\n ], Response::HTTP_NOT_FOUND);\n } elseif ($exception instanceof UnauthorizedException) {\n return new JsonResponse([\n 'error' => 'unauthorized exception'\n ], Response::HTTP_UNAUTHORIZED);\n } else {\n return new JsonResponse([\n 'error' => $exception->getMessage()\n ]);\n }\n }\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n Log::error($exception);\n // 保存错误日志\n $error = new Error();\n $error->add($exception, $request);\n $className = explode('\\\\', get_class($exception));\n if ($request->is('api/*')) {\n // 处理错误日志\n switch (array_pop($className))\n {\n case 'ValidationException':\n return response()->json(['message' => $exception->validator->errors(), 'errNo' => StatusCodes::USER_PARAMETER_ERROR, 'result' => []],StatusCodes::STATUS_OK, [], JSON_FORCE_OBJECT);\n break;\n case 'InvalidArgumentException':\n return response()->json(['message' => $exception->getMessage(), 'errNo' => StatusCodes::USER_PARAMETER_ERROR, 'result' => []],StatusCodes::STATUS_OK, [], JSON_FORCE_OBJECT);\n break;\n case 'NotFoundHttpException':\n return response()->json(['message' => 'API Not Found', 'errNo' => 404, 'result' => []], 404, [], JSON_FORCE_OBJECT);\n break;\n case 'MethodNotAllowedHttpException':\n return response()->json(['message' => StatusCodes::getMessage(StatusCodes::REQUEST_METHOD_ERROR), 'errNo' => StatusCodes::REQUEST_METHOD_ERROR, 'result' => []], 404, [], JSON_FORCE_OBJECT);\n break;\n case 'ApiException':\n return response()->json(['message' => $exception->getMessage(), 'errNo' => $exception->getCode(), 'result' => []], StatusCodes::STATUS_OK, [], JSON_FORCE_OBJECT);\n break;\n case 'UnauthorizedHttpException':\n case 'JWTException':\n case 'TokenInvalidException':\n case 'InvalidClaimException':\n case 'PayloadValidator':\n case 'TokenBlacklistedException':\n case 'TokenExpiredException':\n case 'UserNotDefinedException':\n return response()->json([\"message\" => __('exception.'.$exception->getMessage()), \"errNo\" => StatusCodes::TOKEN_VALIDATE_FAIL, 'result'=>[]], StatusCodes::STATUS_OK, [], JSON_FORCE_OBJECT);\n break;\n default:\n return response()->json([\"message\" => $exception->getMessage(), \"errNo\" => StatusCodes::STATUS_ERROR, 'result'=>[]], StatusCodes::STATUS_ERROR, [], JSON_FORCE_OBJECT);\n }\n }\n return parent::render($request, $exception);\n }", "public function render($request, Exception $exception)\n {\n if ($exception instanceof \\Illuminate\\Auth\\AuthenticationException) {\n\n if ($request->expectsJson()) {\n return response()->json(['status'=>'Failure','message' => 'Unauthenticated.'], 200);\n }\n return redirect('/');\n }else{\n if ($exception instanceof \\Illuminate\\Http\\Exceptions\\PostTooLargeException) {\n return response()->view('errors.posttoolarge', [], 500 );\n }\n $exception = \\Symfony\\Component\\Debug\\Exception\\FlattenException::create($exception);\n\t\t $status = $exception->getStatusCode();\n\n\t\t\t//if status code is 501 redirect to custom view\n\t\t\tif( $status == 501 || $status == 503 || $status == 500 || $status == 405 ){\n\t\t\t\t return response()->view('errors.500', [], 500 );\n\t\t\t}\n\t\t\tif( $status == 404 ){\n\t\t\t\t return response()->view('errors.404', [], 404 );\n\t\t\t}\n return parent::render($request, $exception);\n }\n\n // if ($exception instanceof \\Illuminate\\Auth\\AuthenticationException) {\n\n\t// \t\t//echo \"testset\";exit;\n\t// \t\t//$exception = $this->unauthenticated($request, $exception);\n\t// \t\tif ($request->expectsJson()) {\n\t// \t\t\treturn response()->json(['status'=>'Failure','message' => 'Unauthenticated.'], 200);\n\t// \t\t}\n\t// \t\treturn redirect('/');\n\t// \t}else{\n\n\t// \t\t$exception = \\Symfony\\Component\\Debug\\Exception\\FlattenException::create($exception);\n\t// \t $status = $exception->getStatusCode() ;\n\n\t// \t\t//if status code is 501 redirect to custom view\n\t// \t\tif( $status == 501 || $status == 503 || $status == 500 || $status == 405 ){\n\t// \t\t\t return response()->view('errors.500', [], 500 );\n\t// \t\t}\n\t// \t\tif( $status == 404 ){\n\t// \t\t\t return response()->view('errors.404', [], 404 );\n\t// \t\t}\n\t// \t\treturn parent::render($request, $exception);\n // \t}\n\n\n\n\n\n\n }", "public function render($request, Exception $e)\n\t{\n if ($e instanceof \\App\\Exceptions\\CouponException)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\CardDeclined)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\OrderCreationException)\n return \\Redirect::to('checkout/confirm')->with(array('status' => 'danger' , 'message' => $e->getMessage()));\n\n if ($e instanceof \\App\\Exceptions\\RegisterException)\n return \\Redirect::back()->with(array('status' => 'warning' , 'message' => 'Vous êtes déjà inscrit à ce colloque'));\n\n if ($e instanceof \\App\\Exceptions\\CampagneCreationException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec la création de campagne sur mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\ContentCreationException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec la création du contenu pour la campagne'));\n\n if ($e instanceof \\App\\Exceptions\\FileUploadException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Problème avec l\\'upload '.$e->getMessage() ));\n\n if ($e instanceof \\App\\Exceptions\\SubscribeUserException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur synchronisation email vers mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\CampagneSendException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur avec l\\'envoi de la newsletter, mailjet à renvoyé une erreur'));\n\n if ($e instanceof \\App\\Exceptions\\DeleteUserException)\n return redirect('/')->with(array('status' => 'warning' , 'message' => 'Erreur avec la suppression de l\\'abonnés sur mailjet'));\n\n if ($e instanceof \\App\\Exceptions\\UserNotExistException)\n return redirect()->back()->with(array('status' => 'warning' , 'message' => 'Cet email n\\'existe pas'));\n\n if ($e instanceof \\Symfony\\Component\\HttpKernel\\Exception\\MethodNotAllowedHttpException)\n return redirect()->to('admin');\n\n\t\treturn parent::render($request, $e);\n\t}", "public function render($request, Exception $exception)\n {\n if ($exception instanceof ModelNotFoundException) {\n return response()->json([\n 'error' => 'model_not_found',\n 'message' => (new \\ReflectionClass($exception->getModel()))->getShortName() . ' with such parameters does not exists.'\n ], 404);\n } elseif ($exception instanceof UnauthorizedException) {\n return response()->json([\n 'error' => 'unauthorized',\n 'message' => $exception->getMessage()\n ], 403);\n } elseif ($exception instanceof ValidationException) {\n return response()->json([\n 'error' => 'validation_failed',\n 'messages' => $exception->validator->errors()->all()\n ], 400);\n } elseif ($exception instanceof HttpException) {\n return response()->json([\n 'error' => 'http_error',\n 'message' => $exception->getMessage()\n ], $exception->getStatusCode());\n }\n\n return parent::render($request, $exception);\n }", "public function render($request, Throwable $exception)\n {\n $status = 500;\n\n if(is_a($exception, BadRequestException::class)) {\n $error = $exception->getError();\n $status = 400;\n\n return response()->json($error, $status);\n }\n\n if($request->ajax()) {\n $error = [\n 'error' => $exception->getMessage(), \n ];\n\n return response()->json($error, $status);\n }\n \n // form not posted for a long time -> refresh\n if ($exception instanceof TokenMismatchException){\n return redirect($request->fullUrl());\n }\n\n return parent::render($request, $exception);\n }" ]
[ "0.74905413", "0.74413407", "0.74413407", "0.743258", "0.71576035", "0.70486176", "0.7045336", "0.70389163", "0.702387", "0.69490045", "0.6912601", "0.6888515", "0.6888515", "0.6888515", "0.6888515", "0.6887917", "0.6857658", "0.68551636", "0.68458927", "0.68458503", "0.6842009", "0.68245393", "0.6819667", "0.6797915", "0.6789225", "0.6767936", "0.67281675", "0.6726603", "0.67061615", "0.6701418", "0.6691253", "0.6666178", "0.66494054", "0.66395634", "0.663859", "0.66301006", "0.6627678", "0.6620723", "0.6619636", "0.66094285", "0.6561305", "0.65503526", "0.65489846", "0.65405625", "0.6523391", "0.6513137", "0.65121114", "0.6495242", "0.6483745", "0.64743626", "0.6467416", "0.6465409", "0.64598656", "0.6455702", "0.64536804", "0.64522755", "0.643821", "0.6410551", "0.6407895", "0.6403904", "0.6380879", "0.63678104", "0.63641155", "0.63621795", "0.634358", "0.63353914", "0.6335367", "0.6332933", "0.63320816", "0.63288105", "0.6320956", "0.63188386", "0.6310103", "0.63099355", "0.63088197", "0.6300041", "0.6295355", "0.6293074", "0.6286697", "0.62854135", "0.6282874", "0.6268728", "0.6263205", "0.62609243", "0.62580186", "0.62547225", "0.6253476", "0.62491375", "0.6239354", "0.62384826", "0.6213713", "0.61936903", "0.61923873", "0.6187404", "0.61836374", "0.6159394", "0.61478835", "0.6116467", "0.61161935", "0.6114119" ]
0.6550183
42
Construct default controller, create lang table
public function __construct(ServiceManager $serviceLocator) { $this->serviceLocator = $serviceLocator; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct()\n {\n parent::__construct(); \n $this->_ROUTE = \"languages\";\n $this->_TABLE = \"atlantotec_languages\";\n $this->_URL = route($this->_ROUTE_FIX.\".\".$this->_ROUTE); \n $this->_DATA[\"_PAGETILE\"] = \"Languages\"; \n $this->_DATA[\"_ROUTE_ADD\"] = route($this->_ROUTE_FIX.\".\".$this->_ROUTE . \".create\"); \n }", "public function create_new_lang()\n {\n $root_directory = FCPATH.\"application/language/\";\n $scan_root_directory = array_diff(scandir($root_directory),array('.','..'));\n $data['root_dir'] = $scan_root_directory;\n\n // Application Languages\n $directory = FCPATH.\"application/language/english\";\n $file_lists = scandir($directory,0);\n $total_file = count($file_lists);\n $language_Files = array();\n\n for($i = 2; $i< $total_file; $i++) \n {\n array_push($language_Files, $file_lists[$i]);\n }\n\n for ($i = 0; $i < count($language_Files); $i++) \n {\n $file_name = $language_Files[$i];\n include FCPATH.\"application/language/english/\".$file_name;\n $data['file_name'][$i] = $file_name;\n }\n\n // datatables plugins language\n $directory2 = FCPATH.\"assets/modules/datatables/language/english.json\";\n $plugin_file = file_get_contents($directory2);\n $plugin_file_contents = json_decode($plugin_file,TRUE);\n\n $lang = array();\n\n foreach ($plugin_file_contents as $key => $value) \n {\n if($key == \"oPaginate\")\n {\n foreach ($value as $key1 => $value1) \n {\n $lang[$key1] = $value1;\n }\n\n } else if ($key =='oAria') {\n\n foreach ($value as $key1 => $value1) \n {\n $lang[$key1] = $value1;\n }\n } else {\n $lang[$key] = $value;\n\n } \n }\n\n\n // Addon Language\n $addon_directory = FCPATH.\"application/modules/\";\n $scan_directory = scandir($addon_directory,0);\n $addon_files = array();\n\n for ($i = 2; $i < count($scan_directory) ; $i++) \n {\n array_push($addon_files, $scan_directory[$i]);\n }\n\n $addon_lang_folder = array();\n for ($i = 0; $i < count($addon_files); $i++) \n {\n $module_directory = FCPATH.\"application/modules/\".$addon_files[$i].\"/language\";\n if(file_exists($module_directory))\n {\n $scan_module_directories = array_diff(scandir($module_directory),array('.','..'));\n if(!empty($scan_module_directories))\n {\n $addon_name = $addon_directory.$addon_files[$i];\n array_push($addon_lang_folder,$addon_name);\n }\n }\n }\n\n\n $addon_dir_arr = array();\n for ($i = 0; $i < count($addon_lang_folder); $i++) \n {\n $addon_lang_file = $addon_lang_folder[$i];\n $addon_lang_file_dir = $addon_lang_file.\"/language/english/\";\n $addon_lang_file_dir_scan[] = scandir($addon_lang_file_dir,1);\n array_push($addon_dir_arr,$addon_lang_file_dir_scan[$i][0]);\n }\n $data['addons'] = $addon_dir_arr;\n\n $data['body'] = 'admin/multi_language/add_language';\n $data['page_title'] = $this->lang->line(\"New Language\");\n $this->_viewcontroller($data);\n }", "public function run()\n {\n Lang::create([\n 'key'=>'hire_link',\n 'en'=>'Hire Me Now',\n 'bn'=>'আমাকে ভাড়া করুন',\n 'pt'=>'contrate-me',\n 'hi'=>'मुझे चुनिएँ',\n 'ml'=>'എന്നെ നിയമിക്കൂ',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'i_am',\n 'en'=>'I Am',\n 'bn'=>'আমি',\n 'pt'=>'eu sou',\n 'hi'=>'मैं हूँ',\n 'ml'=>'ഞാൻ',\n 'custom'=>'',\n ]);\n Lang::create([\n 'key'=>'about_me',\n 'en'=>'ABOUT ME',\n 'bn'=>'আমার সম্পর্কে',\n 'pt'=>'SOBRE MIM',\n 'hi'=>'मेरे बारे में',\n 'ml'=>'എന്നെ പറ്റി',\n 'custom'=>'',\n ]);\n \n Lang::create([\n 'key'=>'skill',\n 'en'=>'My Skills.',\n 'bn'=>'আমার স্কিল',\n 'pt'=>'minhas habilidades',\n 'hi'=>'मेरे कौशल',\n 'ml'=>'എന്റെ കഴിവുകൾ.',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'experince',\n 'en'=>'My Experience',\n 'bn'=>'আমার অভিজ্ঞতা',\n 'pt'=>'Minha experiência',\n 'hi'=>'मेरा अनुभव',\n 'ml'=>'എന്റെ അനുഭവം',\n 'custom'=>'',\n ]);\n \n Lang::create([\n 'key'=>'service',\n 'en'=>'My Services',\n 'bn'=>'আমার সেবা',\n 'pt'=>'Meu serviço',\n 'hi'=>'मेरी सेवा',\n 'ml'=>'എന്റെ സേവനം',\n 'custom'=>'',\n ]);\n \n Lang::create([\n 'key'=>'work',\n 'en'=>'My Works',\n 'bn'=>'আমার কাজ',\n 'pt'=>'Meus trabalhos',\n 'hi'=>'मेरा काम',\n 'ml'=>'എന്റെ കൃതികൾ',\n 'custom'=>'',\n ]);\n \n Lang::create([\n 'key'=>'contact',\n 'en'=>'Contact Me',\n 'bn'=>'আমার সাথে যোগাযোগ করুন',\n 'pt'=>'Entre em contato comigo',\n 'hi'=>'मुझसे संपर्क करें',\n 'ml'=>'എന്നെ ബന്ധപ്പെടുക',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'subs_email',\n 'en'=>'Get The latest Update by Email',\n 'bn'=>'ইমেল দ্বারা সর্বশেষ আপডেট পান',\n 'pt'=>'Receba as atualizações mais recentes por email',\n 'hi'=>'ईमेल द्वारा नवीनतम अद्यतन प्राप्त करें',\n 'ml'=>'ഇമെയിൽ വഴി ഏറ്റവും പുതിയ അപ്‌ഡേറ്റുകൾ നേടുക',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'cv',\n 'en'=>'Download CV',\n 'bn'=>'সিভি ডাউনলোড করুন',\n 'pt'=>'Baixar CV',\n 'hi'=>'डाउनलोड सीवी',\n 'ml'=>'സിവി ഡൗൺലോഡുചെയ്യുക',\n 'custom'=>'',\n ]);\n \n Lang::create([\n 'key'=>'phone',\n 'en'=>'Call Me',\n 'bn'=>'আমাদের কল করুন',\n 'pt'=>'Ligue-nos',\n 'hi'=>'हमें फोन करें',\n 'ml'=>'ഞങ്ങളെ വിളിക്കുക',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'email',\n 'en'=>'Email Us At',\n 'bn'=>'আমাদের ইমেল করুন',\n 'pt'=>'Envie-nos um e-mail para',\n 'hi'=>'हमें ईमेल करें',\n 'ml'=>'ഞങ്ങൾക്ക് ഇമെയിൽ ചെയ്യുക',\n 'custom'=>'',\n ]);\n Lang::create([\n 'key'=>'office',\n 'en'=>'Visit Office',\n 'bn'=>'অফিস দেখুন',\n 'pt'=>'Visite o escritório',\n 'hi'=>'कार्यालय पर जाएँ',\n 'ml'=>'ഓഫീസ് സന്ദർശിക്കുക',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'sendmsg',\n 'en'=>'Send Message',\n 'bn'=>'বার্তা পাঠান',\n 'pt'=>'enviar mensagem',\n 'hi'=>'मेसेज भेजें',\n 'ml'=>'സന്ദേശം അയയ്ക്കുക',\n 'custom'=>'',\n ]);\n\n Lang::create([\n 'key'=>'subscibe',\n 'en'=>'Subscibe',\n 'bn'=>'সাবস্ক্রাইব',\n 'pt'=>'se inscrever',\n 'hi'=>'सदस्यता लेने के',\n 'ml'=>'സബ്‌സ്‌ക്രൈബുചെയ്യുക',\n 'custom'=>'',\n ]);\n \n\n }", "public function createLanguagesAction() {\n $em = $this->getDoctrine()->getManager();\n $list = array(\"zh\", \"en\", \"es\", \"hi\", \"bn\", \"pt\", \"ru\", \"fr\", \"ur\", \"ja\", \"de\", \"ko\", \"tr\", \"it\", \"ar\");\n\n foreach ($list as $key => $value) {\n $object = new \\Skaphandrus\\AppBundle\\Entity\\SkLanguage();\n $object->setName($value);\n $em->persist($object);\n }\n $em->flush();\n\n $entities = $em->getRepository('SkaphandrusAppBundle:SkLanguage')->findAll();\n\n return $this->render('SkaphandrusAppBundle:SkBusiness:createLanguage.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function actionCreate()\n {\n $model = new SiteLang();\n\n if ($model->load(Yii::$app->request->post()) && $model->save()) {\n return $this->redirect(['index', 'id' => $model->code]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n ]);\n }", "protected function initializeAction()\n {\n $this->extKey = GeneralUtility::camelCaseToLowerCaseUnderscored('BwrkOnepage');\n /** @var LanguageAspect $languageAspect */\n $languageAspect = GeneralUtility::makeInstance(Context::class)->getAspect('language');\n $this->languageUid = $languageAspect->getId();\n }", "public function run()\n {\n \\App\\Model\\Lang::create([\n 'lang' => 'hu',\n 'title' => 'Magyar',\n ]);\n \\App\\Model\\Lang::create([\n 'lang' => 'en',\n 'title' => 'Angol',\n ]);\n \\App\\Model\\Lang::create([\n 'lang' => 'de',\n 'title' => 'Német',\n ]);\n \\App\\Model\\Lang::create([\n 'lang' => 'jp',\n 'title' => 'Japán',\n 'body_class' => 'direction_rtl',\n ]);\n \\App\\Model\\Lang::create([\n 'lang' => 'ae',\n 'title' => 'Arab',\n 'body_class' => 'direction_rtl',\n ]);\n }", "function __construct() {\n\t //llamo al contructor de Controller.php\n\t parent::__construct();\n\n\t //instancio el modelo\n\t $this->Lenguajes = new Lenguajes();\n\t \n\n\t}", "public function create()\n\t{\n\t \n\t \n\t return view('admin.language.create');\n\t}", "public static function manage()\n {\n $table = Html::table();\n $table->addHeader()->addCol('Languages', array('colspan' => 2));\n\n $langs = Multilanguage::language()->orderBy('name')->all();\n\n if($langs)\n {\n foreach($langs as $lang)\n {\n $row = $table->addRow();\n $row->addCol(Html::a()->get($lang->name, 'admin/multilanguage/languages/edit/' . $lang->id));\n $row->addCol(\n Html::a('Delete', 'admin/multilanguage/languages/delete/' . $lang->id, array(\n 'onclick' => \"return confirm('Delete this language?')\"\n )),\n array('class' => 'right')\n );\n }\n }\n else\n $table->addRow()->addCol('<em>No languages</em>', array('colspan' => 2));\n\n return array(\n 'title' => 'Manage Languages',\n 'content' => $table->render()\n );\n }", "public function run()\n {\n $items = [\n [\n \t'title' => 'English',\n 'understanding' => 'C1',\n 'speach' => 'C1',\n 'writing' => 'C1'\n ],\n [\n 'title' => 'German',\n 'understanding' => 'A1',\n 'speach' => 'A1',\n 'writing' => 'A2'\n ]\n ];\n\n foreach($items as $item) \n {\n Language::create($item);\n }\n }", "public function create()\n {\n $data['record'] \t = FALSE;\n \t$data['active_class'] = 'languages';\n $data['title'] = LanguageHelper::getPhrase('add_language');\n $data['layout'] = 'layouts.admin.adminlayout';\n $data['module_helper'] = false;\n $data['admin'] = $this->admin;\n $data['breadcumbs'] = $this->breadcumbs;\n return view('lmanager::languages.add-edit', $data);\n }", "public function init() \n\t{\n\t\t$sLang = $this->getRequest()->getParam('lang');\n\t\t\n\t\tif(!empty($_SESSION['lang']) && !empty($sLang) && $_SESSION['lang'] != $sLang) {\n\t\t\tunset ($_SESSION['lang']);\n\t\t\tunset ($_SESSION['languages']);\n\t\t}\n\t\t\n\t\tif(!empty($sLang)) {\n\t\t\t$_SESSION['lang'] = $sLang;\n\t\t\tswitch ($sLang) {\n\t\t\t\tcase 'en':\n\t\t\t\t\t$_SESSION['languages'] = 'English';\n\t\t\t\tbreak;\n\t\t\t\tcase 'ru':\n\t\t\t\t\t$_SESSION['languages'] = 'Russian';\n\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t$_SESSION['languages'] = 'English';\n\t\t\t}\n\t\t}\t\n\t\tif(! array_key_exists($sLang, $this->_aLocales)) {\n\t\t\t$sLang = $this->_sDefaultLanguage;\n\t\t}\n\n\t\t// generate path to the gettext language file\n\t\t$sLanguageFilePath = $this->_sLanguagesDirectoryPath . '/'. $sLang . '.php';\n\t\tif(! file_exists($sLanguageFilePath)) {\n\t\t\t$sLanguageFilePath = $this->_sLanguagesDirectoryPath . '/' . $this->_sDefaultLanguage . '.php';\n\t\t\t$sLang = $this->_sDefaultLanguage;\n\t\t}\n\n\t\t// get current locale by current language\n\t\t$sLocale = $this->_aLocales[$sLang];\n\n\t\t// setup translate object\n\t\t$oTranslate = new Zend_Translate('array', $sLanguageFilePath, $sLang);\n\t\t\n\t\tZend_Registry::set('Zend_Translate', $oTranslate);\n\t\tZend_Validate_Abstract::setDefaultTranslator($oTranslate);\n\t\t\n\n\t\t$this->_actionController->_locale = $sLocale;\n\t\t$this->_actionController->_lang = $sLang;\n\t\t$this->_actionController->_translate = $oTranslate;\n\n\t\t$viewRenderer = Zend_Controller_Action_HelperBroker::getStaticHelper('viewRenderer');\n\t\t$viewRenderer->view->locale = $sLocale;\n\t\t$viewRenderer->view->lang = $sLang;\n\t\t$viewRenderer->view->translate = $oTranslate;\n\t}", "public function run()\n {\n $language=New Language();\n $language->name='español';\n $language->save();\n\n $language=New Language();\n $language->name='ingles';\n $language->save();\n\n $language=New Language();\n $language->name='tailandes';\n $language->save();\n }", "public function create()\n {\n return view('languages.create');\n }", "public function create()\n {\n return view('admin.pages.language.create');\n }", "public function create()\n {\n if (! Gate::allows('language_create')) {\n return abort(401);\n }\n return view('admin.languages.create');\n }", "public function initializeLanguages() {}", "public function index(){\n\n $data['active_class'] = 'languages';\n $data['title'] = getPhrase('languages');\n $data['layout'] = getLayout();\n $data['module_helper'] = getModuleHelper('languages-list');\n $data['languages'] = Language::all();\n $data['default_lang'] = $this->get_user_default_lang();\n return view('languages.change_lang', $data);\n\n }", "public function languages_create(Request $request) {\n\n $language_details = new Language;\n\n return view('admin.languages.create')\n ->withPage('languages')\n ->with('sub_page','languages-create')\n ->with('language_details', $language_details);\n }", "function __construct() {\n\t //llamo al contructor de Controller.php\n\t parent::__construct();\n\n\t //instancio el modelo\n $this->modelo(array('cortos','ediciones','categorias'));\n\n\n\t}", "public function __construct($lang = DEFAULT_LANGUAGE,$name = DEFAULT_SITE_NAME){\r\n \r\n $this->language = $lang;\r\n $this->name = $name;\r\n $this->database = new Database(DB_HOST,DB_USER,DB_PASSWORD,DB_NAME);\r\n $this->loadTemplate(DEFAULT_TEMPLATE);\r\n $this->setNavigator(new Navigator());\r\n \r\n \r\n\t\t}", "public function create() {\n $activeTab = 'Languages';\n return View('admin/languages/create', compact('activeTab'));\n }", "public function create()\n {\n return view('admin.languages.create');\n }", "public function getCreate()\n\t{\n // Show the page\n return view('admin/language/create_edit');\n\t}", "public function getLangWidgetAction()\n {\n $this->response['LANG'] = array(\n 'YOURCITY' => 'Ваш город',\n 'COURIER' => 'Курьер',\n 'PICKUP' => 'Самовывоз',\n 'TERM' => 'Срок',\n 'PRICE' => 'Стоимость',\n 'DAY' => 'дн.',\n 'RUB' => 'руб.',\n 'NODELIV' => 'Нет доставки',\n 'CITYSEATCH' => 'Поиск города',\n 'CITYSEARCH' => 'Поиск города',\n 'ALL' => 'Все',\n 'PVZ' => 'Пункты выдачи',\n 'MOSCOW' => 'Москва',\n 'RUSSIA' => 'Россия',\n 'COUNTING' => 'Идет расчет',\n\n 'NO_AVAIL' => 'Нет доступных способов доставки',\n 'CHOOSE_TYPE_AVAIL' => 'Выберите способ доставки',\n 'CHOOSE_OTHER_CITY' => 'Выберите другой населенный пункт',\n\n 'EST' => 'есть',\n\n 'L_ADDRESS' => 'Адрес пункта выдачи заказов',\n 'L_TIME' => 'Время работы',\n 'L_WAY' => 'Как к нам проехать',\n 'L_CHOOSE' => 'Выбрать',\n\n 'H_LIST' => 'Список пунктов выдачи заказов',\n 'H_PROFILE' => 'Способ доставки',\n 'H_CASH' => 'Расчет картой',\n 'H_DRESS' => 'С примеркой',\n 'H_SUPPORT' => 'Служба поддержки',\n );\n }", "public function create()\n {\n \n return view('admin.languages.create', compact(''));\n }", "public static function create()\n {\n if(isset($_POST['create_language']) && Html::form()->validate())\n {\n if(!Multilanguage::language()->where('code', 'LIKE', $_POST['code'])->first())\n {\n $id = Multilanguage::language()->insert(array(\n 'name' => $_POST['name'],\n 'code' => strtolower($_POST['code'])\n ));\n\n if($id)\n {\n Message::ok('Language created successfully.');\n $_POST = array(); // Clear form\n }\n else\n Message::error('Error creating language, please try again.');\n }\n else\n Message::error('A language with that code already exists.');\n }\n\n $form[] = array(\n 'fields' => array(\n 'name' => array(\n 'title' => 'Language Name <em>(Ex: Russian)</em>',\n 'type' => 'text',\n 'validate' => array('required')\n ),\n 'code' => array(\n 'title' => '2 Letter Language Code <em>(Ex: ru)<em>',\n 'type' => 'text',\n 'validate' => array('required', 'min:2'),\n 'attributes' => array(\n 'maxlength' => 2\n )\n ),\n 'create_language' => array(\n 'type' => 'submit',\n 'value' => 'Create Language'\n )\n )\n );\n\n return array(\n 'title' => 'Create Language',\n 'content' => Html::form()->build($form)\n );\n }", "public function index()\n {\n $languages = Language::orderBy('language_recordid')->paginate(20);\n $source_data = Source_data::find(1);\n\n return view('backEnd.tables.tb_language', compact('languages', 'source_data'));\n }", "public function create()\n {\n return view('languages/create');\n }", "public function run()\n {\n $this->verboseBarDumpString($this->language, 'Language on controller start');\n Assert::string($this->result['template']);\n $this->MyCMS->template = $this->result['template'];\n Assert::isArray($this->result['context']);\n $this->MyCMS->context = $this->result['context'];\n\n $options = ['REQUEST_URI' => $this->requestUri];\n\n // prepare variables and set templates for each kind of request\n if ($this->friendlyUrlInstantiated) {\n // Note: $this->MyCMS->template = 'home'; already set in MyControler\n $templateDetermined = $this->friendlyUrl->determineTemplate($options);\n // so that the FriendlyURL translation to parametric URL is taken into account\n $this->get = $this->friendlyUrl->getGet();\n // Note: $_SESSION['language'] je potřeba, protože to nastavuje stav jazyka pro browser\n // Note: $this->session je potřeba, protože je ekvivalentní proměnné $_SESSION,\n // která je vstupem MyCMS->getSessionLanguage\n // Note: $this->language je potřeba, protože nastavuje jazyk v rámci instance Controller\n $this->session['language'] = $this->language = $this->friendlyUrl->getLanguage();\n /**\n * @phpstan-ignore-next-line\n * Property WorkOfStan\\MyCMS\\MyController::$get (array) in isset() is not nullable.\n * But in PHPUnit call it is not even set\n */\n $tempGet = isset($this->get) ? $this->get : [];\n // Language is finally determined, therefore make the include creating TRANSLATION\n $_SESSION['language'] = $this->MyCMS->getSessionLanguage($tempGet, $this->session, true);\n $this->MyCMS->context['applicationDirLanguage'] = $this->MyCMS->context['applicationDir']\n . (($_SESSION['language'] === DEFAULT_LANGUAGE) ? '' : ($_SESSION['language'] . '/'));\n $this->MyCMS->logger->info(\"After determineTemplate: this->language={$this->language}, \"\n . \"this->session['language']={$this->session['language']}, _SESSION['language']={$_SESSION['language']} \"\n . \"this->get[language]=\" . (isset($this->get['language']) ? $this->get['language'] : 'n/a'));\n $this->verboseBarDump([\n 'get' => $this->get,\n 'templateDetermined' => $templateDetermined,\n 'friendlyUrl->get' => $this->friendlyUrl->getGet()\n ], 'get in controller after determineTemplate');\n if (is_string($templateDetermined)) {\n $this->MyCMS->template = $templateDetermined;\n } elseif (is_array($templateDetermined) && isset($templateDetermined['redir'])) {\n $this->redir((string) $templateDetermined['redir'], (int) $templateDetermined['httpCode']);\n }\n } else {\n /**\n * @phpstan-ignore-next-line\n * Property WorkOfStan\\MyCMS\\MyController::$get (array) in isset() is not nullable.\n * But in PHPUnit call it is not even set\n */\n $tempGet = isset($this->get) ? $this->get : [];\n /**\n * @phpstan-ignore-next-line\n * Property WorkOfStan\\MyCMS\\MyController::$session (array<array|string>) in isset() is not nullable.\n * But in PHPUnit call it is not even set\n */\n $tempSession = isset($this->session) ? $this->session : [];\n // Language is finally determined, therefore make the include creating TRANSLATION\n $this->language = $_SESSION['language'] = $this->MyCMS->getSessionLanguage($tempGet, $tempSession, true);\n }\n\n // PROJECT SPECIFIC CHANGE OF OPTIONS AFTER LANGUAGE IS DETERMINED\n $this->prepareTemplate($options);\n\n // TYPICAL CONTROLLER CODE\n $this->prepareAllTemplates($options);\n\n if ($this->MyCMS->template === self::TEMPLATE_NOT_FOUND) {\n http_response_code(404);\n }\n\n // Todo: deprecated >0.4.4 - should return void\n return [\n 'template' => $this->MyCMS->template,\n 'context' => $this->MyCMS->context,\n ];\n }", "function Menu() {\r\n parent::Controller();\r\n $this->load->helper('html');\r\n $this->lang->load('userauth', $this->session->userdata('ua_language'));\r\n $this->lang->load('validation', $this->session->userdata('ua_language'));\r\n }", "public function run()\n {\n App\\Models\\Language::truncate();\n\n $items = [\n ['name' => '繁體中文', 'code' => 'zh_tw'],\n ['name' => '简体中文', 'code' => 'zh_cn'],\n ['name' => 'English', 'code' => 'en'],\n ];\n\n foreach($items as $item){\n App\\Models\\Language::create($item);\n }\n }", "public function actionIndex()\n {\n $searchModel = new SiteLangSearch();\n $dataProvider = $searchModel->search(Yii::$app->request->queryParams);\n\n $this->updateAuthRecordsByController('index');\n\n return $this->render('index', [\n 'searchModel' => $searchModel,\n 'dataProvider' => $dataProvider,\n ]);\n }", "public function initBaseController();", "public function translate_create($id)\n {\n\n if (env('DEMO_MODE') === \"YES\") {\n Alert::warning('warning', 'This is demo purpose only');\n return back();\n }\n\n try {\n $lang = Language::findOrFail($id);\n return view('settings.application.language.translate',compact('lang'));\n } catch (\\Throwable $th) {\n Alert::error(translate('Whoops'), translate('Something went wrong'));\nreturn back();\n }\n \n }", "public function actionCreate()\n {\n $model = new Category();\n $lang = new Language;\n $lang->getNameLanguages();\n $category;\n $id;\n foreach ($lang->languages as $value) {\n if($value['shortname'] == 'en') {\n $id = $value['id'];\n }\n }\n\n if(isset($_POST['Language'])) {\n $category = $this->encode($_POST['Language']['names'], $lang->languages);\n }\n\n if ($model->load(Yii::$app->request->post())) {\n\n foreach ($category as $cat) {\n if($cat->language_id == $id) {\n $model->name = $cat->name;\n $model->save();\n }\n }\n\n foreach ($category as $cat) {\n $cat->category_id = $model->id;\n $cat->save();\n }\n return $this->redirect(['view', 'id' => $model->id]);\n }\n\n return $this->render('create', [\n 'model' => $model,\n 'lang' => $lang,\n ]);\n }", "public function run()\n {\n /*Add ru language supporting*/\n Language::create(['name' => Config::get('app.locale'), 'code' => Config::get('app.locale')]);\n\n /*Home page*/\n Page::create(['url' => '/', 'menu_id' => 1])\n ->translate()\n ->create(['name' => 'Главная страница', 'language_id' => 1]);\n /*Contacts*/\n Page::create(['url' => 'contacts', 'module' => 'feedback', 'menu_id' => 1])\n ->translate()\n ->create(['name' => 'Контакты', 'language_id' => 1]);\n /*Sitemap*/\n Page::create(['url' => 'sitemap', 'module' => 'sitemap', 'menu_id' => 1])\n ->translate()\n ->create(['name' => 'Карта сайта', 'language_id' => 1]);\n }", "public static function init(){\n self::$language = config::getMainIni('language');\n\n $system_lang = array();\n $db = new db();\n $system_language = $db->select(\n 'language',\n 'language',\n config::$vars['coscms_main']['language']\n );\n\n // create system lanugage for all modules\n if (!empty($system_language)){\n foreach($system_language as $key => $val){\n $module_lang = unserialize($val['translation']);\n $system_lang+= $module_lang;\n }\n } \n self::$dict = $system_lang;\n }", "public function index_get () {\n\t\tif ( ! $this->get('id') ) { \n \tself::error($this->config->item(\"api_bad_request_code\"));\n return; \n }\n\n $Language = new Language();\n\n if ( ! $Language->Load( $this->get(\"id\") ) ) {\n \tself::error($this->config->item(\"api_not_found_code\"));\n \treturn;\n }\n\n $this->response( $Language->Export() );\n\t}", "public function __construct() {\r\n parent::__construct();\r\n $this->load->database();\r\n $this->string_values = $this->lang->line('interface')['model']; //Cargar textos utilizados en vista\r\n }", "public function create()\n {\n\t\t //$languages = Language::all();\n return view('admin.banners.create');\n }", "public function __construct () {\n\t\tparent::__construct();\n\t\t$this->load->library(\"language\");\n\t}", "function index() {\n // add users.js file\n $this->addjs(theme_url(\"js/app/directives/modal-confirm.js\"), TRUE);\n $this->addjs(theme_url(\"js/app/languages.js\"), TRUE);\n\n // get all language \n $this->add_js_inline(array('user' => $this->current_user, 'settings' => $this->settings));\n\n //write code here to load view\n $this->bulid_layout(\"languages/list\");\n }", "public function languages_director()\r\n\t{\r\n\t\t$this->load->view('inc/header');\r\n $this->load->view('site/languages_department');\r\n $this->load->view('inc/footer');\r\n\t}", "public function translationManagement()\n {\n $langListFromDB = $this->service->getLanguageCodeList();\n $dataTransFromDB = $this->service->getTranslateList('', '');\n $langList = ($langListFromDB->status == SDBStatusCode::OK)?$langListFromDB->data:array();\n $dataTrans = ($dataTransFromDB->status == SDBStatusCode::OK)?$dataTransFromDB->data:array();\n $dataComboFilter = $this->service->getNewTransComboList();\n return view(\"dev/translation\", compact(['dataTrans', 'langList', 'dataComboFilter']));\n }", "public function initAction()\n\t{\n\t\t$preservemodels = array('category','Category','file','File','EmailMessage','emailmessage','tag','mgmt_entity','mgmt_lang');\n\t\t$preserve = array('emailmessage','user','tag','mgmtlang','category');\n\t\n\t\t//standard language module is also basis for the front end module\n\t\t$language = $this->language('NL');\n\n\t\t$this->view->disable();\n\t\t$status = array('status' => 'false');\t\n\t\tif ($this->request->isPost()) \n\t\t{\n\t\t\t$post = $this->request->getPost();\n\t\t\t$noincludes = array('file');\n\n\t\t\t$images = array();\n\t\t\t$functions = array();//array for new/edit extra functions information\n\t\t\t$widgets = array();\n\t\t\t$tables = array();\n\t\t\t$ctables = array();\n\t\t\t\n\t\t\t$postkeys = array_keys($post);\n\t\t\tforeach($postkeys as $var)\n\t\t\t{\n\t\t\t\t$v = explode('_',$var);\n\t\t\t\tif(isset($v[1]))\n\t\t\t\t{\n\t\t\t\t\tswitch($v[0])\n\t\t\t\t\t{\n\t\t\t\t\t\tcase 'file':\n\t\t\t\t\t\t\tif($post[$var] == 1){ array_push($images,$v[1]); }\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'functions':\n\t\t\t\t\t\t\tif(is_array($post[$var]))\n\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\tforeach($post[$var] as $function)\n\t\t\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\t\t\t$entity = $v[1];\n\t\t\t\t\t\t\t\t\t$value = explode('_',$function);\n\t\t\t\t\t\t\t\t\t$widgetentity = $value[0];\n\t\t\t\t\t\t\t\t\t$widgetentityid = $value[1];\n\t\t\t\t\t\t\t\t\t$table = array($entity,array('widgetentity' => $widgetentity,'widgetentityid' => $widgetentityid));\n\t\t\t\t\t\t\t\t\tarray_push($functions,$table);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t\tcase 'widget':\n\t\t\t\t\t\t\tarray_push($widgets,$v[1]);\n\t\t\t\t\t\tbreak;\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\tif($post[$var] == 1)\n\t\t\t\t\t{\n\t\t\t\t\t\tarray_push($tables,$var);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t//SETTINGS SLUG & ALIAS SAVE \t\tNEW/EDIT & VIEW WIDGETS ALSO\n\t\t\t\n\t\t\t//mgmtentities cant update for some reason\n\t\t\t\n\t\t\t\n\t\t\t$ent = MgmtEntity::find();\n\t\t\tforeach($ent as $e)\n\t\t\t{\n\t\t\t\t$e->delete();\n\t\t\t}\n\t\t\t\n\t\t\tforeach($tables as $table)\n\t\t\t{\t\t\t\n\t\t\t\tif(isset($post['clearance_'.$table]) && isset($post['alias_'.$table]))\n\t\t\t\t{\n\t\t\t\t\t$mgmt_entity = MgmtEntity::findFirst('titel = \"'.$table.'\"');\n\t\t\t\t\tif(!$mgmt_entity)\n\t\t\t\t\t{\t\n\t\t\t\t\t\t$mgmt_entity = new MgmtEntity();\t\n\t\t\t\t\t}\n\t\t\t\t\t$mgmt_entity->id = $this->uuid();\n\t\t\t\t\t$mgmt_entity->titel = $table;\n\t\t\t\t\t$mgmt_entity->slug = strtolower(preg_replace(\"/[^a-zA-Z]/\", \"\", $table));\n\t\t\t\t\t$mgmt_entity->clearance = $post['clearance_'.$table];\n\t\t\t\t\t$mgmt_entity->alias = $post['alias_'.$table];\t\t\n\t\t\t\t\t\n\t\t\t\t\t$mgmt_entity->newedit = serialize($post['functions_'.$table.'_new']);\n\t\t\t\t\t$mgmt_entity->view = serialize($post['functions_'.$table.'_view']);\n\t\t\t\t\t\n\t\t\t\t\tif($post[$table] == 1)\n\t\t\t\t\t{ $val = 1;\t}else{$val = 0;}\n\t\t\t\t\t\n\t\t\t\t\t$mgmt_entity->visible = $val;\n\t\t\n\t\t\t\t\tif($mgmt_entity->save())\n\t\t\t\t\t{ \n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tforeach ($mgmt_entity->getMessages() as $message)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\techo $message;\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\t//get all tables\n\t\t\t$tablesq = $this->db->fetchAll(\"SHOW TABLES\", Phalcon\\Db::FETCH_ASSOC);\n\t\t\t$linktables = array();\n\t\t\tforeach ($tablesq as $tableq) \n\t\t\t{\n\t\t\t\t$ext = explode('_',$tableq['Tables_in_'.DATABASENAME]);\n\t\t\t\tif(isset($ext[1]))\n\t\t\t\t{\tarray_push($linktables,$tableq['Tables_in_'.DATABASENAME]);\t}\n\t\t\t\t\n\t\t\t\tarray_push($ctables,$tableq['Tables_in_'.DATABASENAME]);\n\t\t\t}\n\n\t\t\t//tables with columns\n\t\t\t$tablesobject = array();\n\t\t\tforeach ($tablesq as $tableq) \n\t\t\t{\n\t\t\t\t$tablesobject[$tableq['Tables_in_'.DATABASENAME]] = array();\n\t\t\t\t$columns = $this->db->fetchAll(\"DESCRIBE `\".$tableq['Tables_in_'.DATABASENAME].\"`\", Phalcon\\Db::FETCH_ASSOC);\n\t\t\t\tforeach($columns as $column)\n\t\t\t\t{\n\t\t\t\t\tarray_push($tablesobject[$tableq['Tables_in_'.DATABASENAME]],$column['Field']);\t\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t$error =0;\n\t\t\t//create models for link tables\t\n\t\t\tforeach($linktables as $linktable)\n\t\t\t{\n\t\t\t\tif(!in_array($linktable,$preservemodels))\n\t\t\t\t{\n\t\t\t\t\t$model = new Modell();\n\t\t\t\t\t$model->name = $linktable;\n\t\t\t\t\t$columns = $this->db->fetchAll(\"DESCRIBE \".$linktable, Phalcon\\Db::FETCH_ASSOC);\n\t\t\t\t\t$model->columns = $columns;\n\t\t\t\t\t\n\t\t\t\t\t$model->tables = $tables;\n\t\t\t\t\t$model->tablesobject = $tablesobject;\n\t\t\t\t\tif(!$model->tofile()){ $error++; }\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t//create models\t\t\t\n\t\t\tforeach($tables as $table)\n\t\t\t{\n\t\t\t\tif(!in_array($table,$preserve))\n\t\t\t\t{\n\t\t\t\t\t$model = new Modell();\n\t\t\t\t\t$model->name = $table;\n\t\t\t\t\t$columns = $this->db->fetchAll(\"DESCRIBE \".$table, Phalcon\\Db::FETCH_ASSOC);\n\t\t\t\t\t$model->columns = $columns;\n\t\t\t\t\t$model->tables = $ctables;\n\t\t\t\t\t$model->tablesobject = $tablesobject;\n\t\t\t\t\tif(!$model->tofile()){ $error++; }\n\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t$relations = array();\n\t\t\t\t\tforeach($tables as $tablex)\n\t\t\t\t\t{\n\t\t\t\t\t\t$columnx = $this->db->fetchAll(\"DESCRIBE \".$tablex, Phalcon\\Db::FETCH_ASSOC);\n\t\t\t\t\t\tforeach($columnx as $column)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tif($column['Field'] == $tablex.'id')\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tarray_push($relations,$column['Field']);\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\t\n\t\t\t\t\t//generate view relations for detail view\n\t\t\t\t\t$linkentityrelations = array();\n\t\t\t\t\t$entityrelations = array();\n\t\t\t\t\tforeach($tablesq as $tablex)\n\t\t\t\t\t{\t\t\n\t\t\t\t\t\t$table3 = explode('_',$tablex['Tables_in_'.DATABASENAME]);\n\t\t\t\t\t\tif(!isset($table3[1]))\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t$columnx = $this->db->fetchAll(\"DESCRIBE `\".$tablex['Tables_in_'.DATABASENAME].\"`\", Phalcon\\Db::FETCH_ASSOC);\n\t\t\t\t\t\t\tforeach($columnx as $column)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tif($table.'id' == $column['Field'])\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tif($tablex['Tables_in_'.DATABASENAME] != 'acl')\n\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\tarray_push($entityrelations,$tablex['Tables_in_'.DATABASENAME]);\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}\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($table3[0] == $table || $table3[1] == $table)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tarray_push($linkentityrelations,$tablex['Tables_in_'.DATABASENAME]);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\t\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t\n\t\t\t\t\t$controller = new Controller();\n\t\t\t\t\t$controller->language = $language;\t\t\t\t\n\t\t\t\t\t$controller->entity = $table;\n\t\t\t\t\t$controller->columns = $columns;\n\t\t\t\t\t$controller->relations = $entityrelations;\n\t\t\t\t\t$controller->linkrelations = $linkentityrelations;\n\t\t\t\t\t$controller->tables = $tables;\t\t\n\t\t\t\t\t$controller->images = in_array($table,$images);\t\t\n\t\t\t\t\t\n\t\t\t\t\n\t\t\t\t\t$view = new View();\n\t\t\t\t\t$view->language = $language;\n\t\t\t\t\t$view->entity = $table;\n\t\t\t\t\t$view->columns = $columns;\n\t\t\t\t\t$view->relations = $entityrelations;\n\t\t\t\t\t$view->linkrelations = $linkentityrelations;\n\t\t\t\t\t$view->baseuri = $this->url->getBaseUri();\t\t\n\t\t\t\t\t$view->images = in_array($table,$images); \n\t\t\t\t\t$view->tablesobject = $tablesobject;\n\t\t\t\t\t\n\t\t\t\t\t$functions = array();\n\t\t\t\t\tif(isset($post['functions_'.$table.'_new']) && is_array($post['functions_'.$table.'_new']) )\n\t\t\t\t\t{\t\n\t\t\t\t\t\tforeach($post['functions_'.$table.'_new'] as $function)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tarray_push($functions,$function);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\n\t\t\t\t\tif(isset($post['functions_'.$table.'_view']) && is_array($post['functions_'.$table.'_view']) )\n\t\t\t\t\t{\t\n\t\t\t\t\t\tforeach($post['functions_'.$table.'_view'] as $function)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tarray_push($functions,$function);\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($functions) > 0)\n\t\t\t\t\t{ \n\t\t\t\t\t\t$view->functions = $functions; \n\t\t\t\t\t\t$controller->functions = $functions;\n\t\t\t\t\t}\n\n\t\t\t\t\tif(!$view->tofile()){ $error++; }\t\n\t\t\t\t\t\n\t\t\t\t\tif(!$controller->tofile()){ $error++; }\t\n\t\t\t\t}\n\t\t\t}\t\n\n\t\t\t$menu = new Menu();\n\t\t\t$menu->tables = MgmtEntity::find(array('order' => 'titel ASC'));\n\t\t\tif(!$menu->tofile()){ $error++; }\n\t\t\t\n\t\t\tif(!isset($error) || $error == 0)\n\t\t\t{\n\t\t\t\t$status['status'] = 'ok';\t\t\t\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$status['messages'] = 'Something went wrong!';\n\t\t\t}\n\t\t\t\n\t\t\t\n\t\t}\n\t\techo json_encode($status);\n\t}", "public function init(){\n\t\t$this->_arrParam = $this->_request->getParams();\n\t\t\n\t\t//Duong dan cua Controller\n\t\t$this->_currentController = '/' . $this->_arrParam['module'] \n\t\t\t\t\t\t\t\t\t . '/' . $this->_arrParam['controller'];\t\t\n\t\t//Duong dan cua Action chinh\t\t\n\t\t$this->_actionMain = '/' . $this->_arrParam['module'] \n\t\t\t\t\t\t\t . '/' . $this->_arrParam['controller']\t. '/index';\n\t\t\t\t\t\t\t \n\t\t$this->_paginator['currentPage'] = $this->_request->getParam('page',1);\n\t\t$this->_arrParam['paginator'] = $this->_paginator;\n\t\t\n\t\t//Luu cac du lieu filter vao SESSION\n\t\t//Dat ten SESSION\n\t\t$this->_namespace = $this->_arrParam['module'] . '-' . $this->_arrParam['controller'];\n\t\t$ssFilter = new Zend_Session_Namespace($this->_namespace);\n\t\t//$ssFilter->unsetAll();\n\t\tif(empty($ssFilter->col)){\n\t\t\t$ssFilter->lang \t\t= '';\n\t\t}\n\t\t$this->_arrParam['ssFilter']['lang'] \t\t= $this->_arrParam['lang'];\t\n\t\t\n\t\t/*====================================================\n\t\t * Load Zendvn Translate for Controller\n\t\t *====================================================*/\n\t\t/*$this->_langObj->setLangFile(array('default.language.tmx'));\t\t\n\t\tZend_Registry::set('Zend_Translate', $this->_langObj->generate());*/\n\t\t\n\t\t$info = new Zendvn_System_Info();\n\t\t$language = $info->getLanguage('admin');\n\t\tif(empty($language)){\n\t\t\t$language = 'vi';\n\t\t}\n\t\t$translate = array(\n\t\t\t\t\t\t\t'adapter' => 'tmx',\n\t\t\t\t\t\t\t'content' => LANG_PATH . '/' . $language . '/admin/default.language.tmx',\n\t\t\t\t\t\t\t'locale' => $language,\n\t\t\t\t\t\t\t);\n\t\t$translate = new Zend_Translate($translate);\n\t\tZend_Registry::set('Zend_Translate', $translate);\n\t\t\n\t\t//Truyen ra view\n\t\t$this->view->arrParam = $this->_arrParam;\n\t\t$this->view->currentController = $this->_currentController;\n\t\t$this->view->actionMain = $this->_actionMain;\t\t\n\t\t$template_path = TEMPLATE_PATH . \"/public/system\";\n\t\t$this->loadTemplate($template_path,'template.ini','template');\t\t\n\t}", "public function create()\n {\n return view('Backend.Contents.language.add');\n }", "public function initialize()\n { $model= new \\Yabasi\\ModelController();\n $this->setSchema($model->model());\n $this->setSource(\"notification\");\n }", "public function run()\n {\n $languages = [\n [\n 'language'=>'English',\n 'short_code'=>'en',\n 'country'=>'United Kingdom',\n ],\n [\n 'language'=>'Dansih',\n 'short_code'=>'da',\n 'country'=>'Denmark',\n ],\n ];\n\n foreach ($languages as $item) {\n $mLanguage = new Language();\n $mLanguage->language = $item['language'];\n $mLanguage->short_code = $item['short_code'];\n $mLanguage->countries = $item['country'];\n $mLanguage->save();\n }\n }", "public function __construct()\n {\n parent::__construct();\n $this->language->load('Home');\n $this->Database = new \\Models\\Db();\n }", "public function getLanguage($controller);", "function __contrruct(){ //construdor do controller, nele é possivel carregar as librari, helpers, models que serão utilizados nesse controller\n\t\tparent::__contrruct();//Chamando o construtor da classe pai\n\t}", "public function languages_index() {\n // Load Lanugages\n $languages = Language::paginate(10);\n\n return view('admin.languages.index')\n ->withPage('languages')\n ->with('sub_page','languages-view')\n ->with('languages', $languages);\n }", "function __construct($parms = null)\n {\n global $debug;\n global $warn;\n global $connection;\n\n if ($debug)\n {\n $warn .= '<p>Language::__construct(' .\n print_r($parms, true) . \")</p>\\n\";\n }\n\n if (is_null($connection))\n {\n throw new Exception('Language::constructor: \" .\n \"No connection to database server');\n }\n\n $needInsert = false;\n $this->table = 'Languages';\n $code = 'en';\n $cc = null;\n\n // validate parameters\n if (is_null($parms) ||\n (is_array($parms) && count($parms) == 0))\n { // create default entry from Cookie\n if (array_key_exists('lang', $_REQUEST))\n $code = strtolower($_REQUEST['lang']);\n $parms = array('code' => $code);\n } // create default entry\n\n // process parameters\n if (is_array($parms))\n { // an array with at least one entry\n if (count($parms) < count(self::$initRow))\n { // search parameters\n $where = '';\n $and = 'WHERE ';\n $sqlParms = array();\n foreach($parms as $key => $value)\n { // loop through parameters\n $fieldLc = strtolower($key);\n if (array_key_exists($fieldLc, self::$translate))\n $fieldLc = self::$translate[$fieldLc];\n switch($fieldLc)\n { // act on key fields\n case 'code639_1':\n { // language code\n if (strlen($value) > 2)\n {\n $code = substr($value, 0, 2);\n if (strlen($value) >= 5 && \n substr($value, 2, 1) == '-')\n $cc = strtoupper(substr($value, 3));\n }\n else\n $code = $value;\n $where .= $and . \"Code639_1=:code\";\n $sqlParms['code'] = $code;\n $and = ' AND ';\n break;\n } // language code\n\n } // act on key fields\n } // loop through parameters\n\n if (strlen($where) == 0)\n {\n $where .= \"WHERE Code639_1=:code\";\n $sqlParms['code'] = $code;\n }\n\n $query = \"SELECT * FROM Languages $where\";\n\n // query the database\n $stmt = $connection->prepare($query);\n $queryText = debugPrepQuery($query, $sqlParms);\n\n if ($stmt->execute($sqlParms))\n { // success\n if ($debug)\n $warn .= \"<p>Language::__construct: \" . __LINE__ . \n \" query='$queryText'</p>\\n\";\n\n $result = $stmt->fetchAll(PDO::FETCH_ASSOC);\n $count = count($result);\n if ($count == 1)\n { // existing record\n $dbrow = $result[0];\n $needInsert = false;\n } // existing record\n else\n if ($count == 0)\n { // create a new record\n // set defaults\n $dbrow = self::$initRow;\n $dbrow['code639_1'] = $code;\n $dbrow['name'] = \"Language: '$code'\";\n $needInsert = true;\n } // create new record\n else\n { // error performing query\n $this->msg .= \"Language::__construct: '$queryText' \" .\n \"returns $count records. \";\n } // error performing query\n } // success\n else\n { // error performing query\n $this->msg .=\"Language::__construct: '$queryText' \" .\n print_r($stmt->errorInfo(),true);\n } // error performing query\n } // search parameters\n else\n { // build from existing record\n $dbrow = $parms;\n $needInsert = false;\n } // build from existing record\n } // an array with at least one entry\n else\n { // unsupported parameter type\n throw new Exception(\"Language::__construct: \" .\n \"parameter must be an array: is \" .\n gettype($parms));\n } // unsupported parameter type\n\n\n // invoke constructor of base class\n parent::__construct($dbrow,\n 'Languages');\n $this->needInsert = $needInsert;\n\n if (!is_null($cc))\n {\n $this->extras['cc'] = $cc;\n }\n\n // diagnostic output if debug is set\n $this->dump('Language Record constructed:');\n }", "function __construct() {\r\r\n\t\tparent::__construct();\r\r\n\t\t$this->load->model(\"infraction_category_code_m\");\r\r\n\t\t$this->load->model(\"infraction_category_m\");\r\r\n\t\t$language = $this->session->userdata('lang');\r\r\n\t\t$this->lang->load('infraction_category_code', $language);\r\r\n\t}", "public function init() {\n parent::init();\n $this->controller = Tour::getTableSchema()->name;\n }", "protected function initializeAction() {\n\t\t$httpRequest = $this->request->getHttpRequest();\n\t\tif ($httpRequest->hasCookie('GIB_GradingTool_Language')) {\n\t\t\t$cookie = $httpRequest->getCookie('GIB_GradingTool_Language');\n\t\t\t$language = $cookie->getValue();\n\t\t\tif (array_key_exists($language, $this->settings['languages'])) {\n\t\t\t\t// requested language is valid, therefore we use it\n\t\t\t\t$locale = new \\TYPO3\\Flow\\I18n\\Locale($language);\n\t\t\t} else {\n\t\t\t\t// requested language is invalid, we fall back to default language\n\t\t\t\t$locale = new \\TYPO3\\Flow\\I18n\\Locale($this->settings['defaultLanguage']);\n\t\t\t}\n\t\t} else {\n\t\t\t$locale = new \\TYPO3\\Flow\\I18n\\Locale($this->settings['defaultLanguage']);\n\t\t}\n\n\t\t$this->i18nService->getConfiguration()->setCurrentLocale($locale);\n\n\n\t}", "public function __construct()\r\n {\r\n $this->template = new backend_model_template();\r\n $this->data = new backend_model_data($this);\r\n $this->plugins = new backend_model_plugins();\r\n $this->message = new component_core_message($this->template);\r\n $this->modelLanguage = new backend_model_language($this->template);\r\n $this->collectionLanguage = new component_collections_language();\r\n $this->settings = new backend_model_setting();\r\n $this->setting = $this->template->settings;\r\n\r\n // --- GET\r\n if (http_request::isGet('controller')) $this->controller = form_inputEscape::simpleClean($_GET['controller']);\r\n if (http_request::isGet('edit')) $this->edit = form_inputEscape::numeric($_GET['edit']);\r\n if (http_request::isGet('tabs')) $this->tabs = form_inputEscape::simpleClean($_GET['tabs']);\r\n if (http_request::isGet('page')) $this->page = intval(form_inputEscape::simpleClean($_GET['page']));\r\n $this->offset = (http_request::isGet('offset')) ? intval(form_inputEscape::simpleClean($_GET['offset'])) : 25;\r\n if (http_request::isRequest('action')) $this->action = form_inputEscape::simpleClean($_REQUEST['action']);\r\n\r\n if (http_request::isGet('tableaction')) {\r\n $this->tableaction = form_inputEscape::simpleClean($_GET['tableaction']);\r\n $this->tableform = new backend_controller_tableform($this, $this->template);\r\n }\r\n\r\n // --- Search\r\n if (http_request::isGet('search')) {\r\n $this->search = form_inputEscape::arrayClean($_GET['search']);\r\n $this->search = array_filter($this->search, function ($value) {\r\n return $value !== '';\r\n });\r\n }\r\n\r\n // --- ADD or EDIT\r\n if (http_request::isPost('cartpay')) $this->cartpay = form_inputEscape::arrayClean($_POST['cartpay']);\r\n elseif (http_request::isGet('cartpay')) $this->cartpay = form_inputEscape::arrayClean($_GET['cartpay']);\r\n if (http_request::isPost('address')) $this->address = form_inputEscape::arrayClean($_POST['address']);\r\n if (http_request::isPost('acConfig')) $this->config = (array)form_inputEscape::arrayClean($_POST['acConfig']);\r\n if (http_request::isPost('id')) $this->id = (int)form_inputEscape::simpleClean($_POST['id']);\r\n if (http_request::isPost('status_order')) $this->status_order = form_inputEscape::simpleClean($_POST['status_order']);\r\n //\r\n }", "public function create()\n {\n $language = new Language();\n return view('student::settings.languages.create', compact('language'));\n }", "public function init(): void {\n if (!isset($this->language)) {\n $this->language = $this->selectLang();\n $this->getTranslator()->setLang($this->language);\n }\n /*if ($redirect && $this->urlLang !== $this->language) {\n $this->getPresenter()->forward('this', ['lang' => $this->language]);\n }*/\n }", "public function create()\n {\n return view('sadmin.languageadd');\n }", "public function index()\n {\n if (request()->ajax()) {\n $data = LanguageOp::_fetchAll();\n return $this->dataTable($data);\n }\n return view('student::settings.languages.index');\n }", "public function __construct($default_lang){\n parent::__construct($default_lang);\n \n # Pour accéder à une page de configuration\n $this->setConfigProfil(PROFIL_ADMIN,PROFIL_MANAGER);\n # Déclaration des hooks\n\n $this->addHook('Events', 'Events');\n $this->addHook('ThemeEndHead', 'ThemeEndHead');\n $this->addHook('ThemeEndBody', 'ThemeEndBody');\n $this->addHook('AdminTopEndHead', 'AdminTopEndHead'); \n }", "function __construct() {\n\t\tparent::__construct();\n\t\t$this->load->model(\"routine_m\");\n\t\t$this->load->model(\"classes_m\");\n\t\t$this->load->model(\"student_info_m\");\n\t\t$this->load->model(\"parentes_info_m\");\n\t\t$this->load->model(\"section_m\");\n\t\t$this->load->model(\"subject_m\");\n\t\t$this->load->model('parentes_m');\n\t\t$this->load->model('student_m');\n\t\t$language = $this->session->userdata('lang');\n\t\t$this->lang->load('routine', $language);\n\t}", "function __construct() {\n\t\tparent::__construct();\n\t\t$this->load->model(\"lmember_m\");\n\t\t$this->load->model(\"book_m\");\n\t\t$this->load->model(\"section_m\");\n\t\t$this->load->model(\"libraryanalysis_m\");\n\t\t$this->load->model(\"data_books_statistics_m\");\n\t\t$this->load->model(\"student_m\");\n\t\t$this->load->model(\"parentes_m\");\n\t\t\n\t\t$language = $this->session->userdata('lang');\n\t\t$this->lang->load('libraryanalysis', $language);\t\n\t}", "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}", "public function create()\n {\n //get list all locales from config file\n $langs = \\Config::get('translatable.locales');\n //define field who was translated\n $trans_fields = ['name', 'description', 'meta_title', 'meta_description'];\n //define variable data\n $data = [];\n foreach($trans_fields as $field_name)\n {\n foreach($langs as $lang)\n {\n $data['trans_fields'][$field_name][$lang] = '';\n }\n }\n return view('admin.categories.categories_create', $data);\n }", "public function __construct()\n\t{\n\tparent:: __construct();\n\t$this->load->helper('url');\n\t$this->load->model('seo_model');\n\t$this->load->helper('language');\n\t$this->load->model('articles_en_model');\n\t$this->load->model('articles_ru_model');\n\t$this->load->model('articles_chi_model');\n\t$this->current_lang = $this->uri->segment(1);\n\t}", "public function create()\n {\n $langs=Lang::lists('language','id');\n return view('backend.countries.create')->with('langs',$langs);\n }", "public function __construct()\n\n\t{\n\t\t$this->model = new Crud;\n\t // $this->breadcrumbs = ['index' => ['hello' , 'name' , 'gue' , 'reza']]; // controh pembuatan breadcrumbs manual\n }", "public function index()\n {\n\n $column = \\request('column', 'id');\n $order = \\request('order', 'DESC');\n\n $query = Language::query();\n\n $query = $query->where($this->searchWhere());\n\n if (in_array($column, getFillable(new Language(), 'created_at')) and in_array($order, ['ASC', 'DESC'])) {\n $query = $query->orderBy($column, $order);\n }\n\n $query = $query->paginate(10);\n $languages = $query->appends(request()->query());\n return view('admin.pages.language.index', compact('languages'));\n }", "public function create()\n {\n return view('quizzes.type.translate_words.create', [\n 'languages' => Language::all()\n ]);\n }", "public function create()\n\t{\n\t\treturn view('languageKeys.create');\n\t}", "protected function initializeController() {}", "public function run()\n {\n \\App\\Models\\CategoryType::insert([\n [\n 'translation_lang' => 'id',\n 'translation_of' => '1',\n 'name'=> 'Pekerjaan',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'id',\n 'translation_of' => '2',\n 'name'=> 'Acara',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'id',\n 'translation_of' => '3',\n 'name'=> 'Artikel',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'id',\n 'translation_of' => '4',\n 'name'=> 'Forum',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'id',\n 'translation_of' => '5',\n 'name'=> 'Industri',\n 'active'=> '1'\n ],\t\t\t\n [//English\n 'translation_lang' => 'en',\n 'translation_of' => '1',\n 'name'=> 'Jobs',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'en',\n 'translation_of' => '2',\n 'name'=> 'Events',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'en',\n 'translation_of' => '3',\n 'name'=> 'Article',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'en',\n 'translation_of' => '4',\n 'name'=> 'Forum',\n 'active'=> '1'\n ],\n [\n 'translation_lang' => 'en',\n 'translation_of' => '5',\n 'name'=> 'Industry',\n 'active'=> '1'\n ],\t\t\t\n ]);\n }", "public function create()\r\n {\r\n $this->setTpl('create.htm');\r\n $this->setControllerTitle('Apollo');\r\n $this->setCurrentControllerName('Création d\\'une condition');\r\n\r\n //$oParam = new ParamsModel();\r\n\r\n $this->aVars['aDepartementsListe'] = $this->oEm->getRepository('Apollo\\Entity\\Departement')->findAll();\r\n $this->aVars['aTypeNego'] = $this->oEm->getRepository('Apollo\\Entity\\TypeNego')->findAll();\r\n\r\n //$oParam->close();\r\n }", "public function create()\n {\n //\n $languages = Language::where('status','=','1')->get();\n\n return view('admin.categories.create')->withLanguages($languages);\n\n }", "public function init()\n {\n \theader('content-type: text/html; charset=utf8');\n \tdefined('BASE_URL')\t|| define('BASE_URL', Zend_Controller_Front::getInstance()->getBaseUrl());\n \t$this->tr = Application_Form_FrmLanguages::getCurrentlanguage();\n\t}", "function __construct() {\n\t\tparent::__construct();\n\t\t$this->load->model(\"student_m\");\n\t\t$this->load->model(\"parentes_m\");\n\t\t$this->load->model(\"teacher_m\");\n\t\t$this->load->model(\"user_m\");\n\t\t$this->load->model(\"systemadmin_m\");\n\t\t$language = $this->session->userdata('lang');\n\t\t$this->lang->load('profile', $language);\n\t}", "private function _loadDefaultController(){\n\t\trequire $this->_controllerPath . $this->_defaultFile;\n\t\t$this->_controller = new Index();\n\t\t$this->_controller->index();\n\t}", "protected function generateLocalLang() {}", "public function carregar()\n {\n if (file_exists('app/sts/Controllers/' . $this->UrlController . '.php')) {\n $classe = \"\\\\Sts\\\\Controllers\\\\\" . $this->UrlController;\n } else {\n $classe = \"\\\\Sts\\\\Controllers\\\\Erro404\";\n }\n \n $classeCarregar = new $classe; \n $classeCarregar->index();\n }", "function __construct() {\r\n\t\t\t\tparent :: __construct();\r\n\t\t\t\t$this->langdef = DEFLANG;\r\n\t\t}", "function __construct() {\n\t\t//echo '__construc';\n\t\t//$this->getLang('article', 'article');\n\t\t//jieqi_loadlang('article', 'article');\n\t}", "public function run()\n {\n if (!empty(DB::table('language')->first())) {\n return;\n }\n\n $languagesJsonFile = __DIR__.'/resources/uis_core_languages.json';\n $languagesData = json_decode($this->files->get($languagesJsonFile));\n $insertLanguages = [];\n $lngIndex = 0;\n foreach ($languagesData as $lngData) {\n $code = isset($lngData->code) ? $lngData->code : '';\n $name = isset($lngData->name_native) ? $lngData->name_native : '';\n $enName = isset($lngData->name_en) ? $lngData->name_en : '';\n $isDefault = isset($lngData->is_default) && $lngData->is_default ? BaseModel::TRUE : BaseModel::FALSE;\n\n $insertLanguages[$lngIndex] = [\n 'code' => $code,\n 'name' => $name,\n 'en_name' => $enName,\n 'sort_order' => $lngIndex * 10,\n 'is_default' => $isDefault,\n 'show_status' => BaseModel::STATUS_ACTIVE,\n ];\n $lngIndex++;\n }\n DB::table('language')->insert($insertLanguages);\n }", "public function __construct() {\r\n\t\tparent::__construct($this->controllerName);\t\r\n\t\t$this->load->model('todo_model');\r\n\r\n\t\t$this->data = array(\r\n\t\t\t'title' => 'Orpheus.todo',\r\n\t\t\t'loadedControllers' => Registry::getLoadedLibs()\r\n\t\t\t);\r\n\t\t\r\n\t\t\r\n\t\t//$this->index();\r\n\t\t\r\n\t}", "public function index($param1 = 'list', $param2 = null, $param3 = null)\n {\n\n // foreach ($languages as $value) {\n // echo \"[<br>\n // 'phrase' => '\" . str_replace(\"'\",\"\\'\",$value['phrase']) . \"',<br>\n // 'en' => '\" . str_replace(\"'\",\"\\'\",$value['en']) . \"',<br>\n // 'km' => '\" . $value['km'] . \"'\n // <br>],\" . \"<br>\";\n // }\n // dd();\n\n // foreach ($languages as $value) {\n // echo \"'\".$value['phrase'].\"' => '\" . str_replace(\"'\",\"\\'\",$value['km']) .\"',<br>\";\n // }\n // dd();\n\n\n $data['formData'] = array(\n 'image' => asset('/assets/img/icons/image.jpg'),\n );\n $data['formName'] = AppModel::path('url') . '/' . Translates::path('url');\n $data['formAction'] = '/add';\n $data['listData'] = array();\n if ($param1 == 'list') {\n if (strtolower(request()->server('CONTENT_TYPE')) == 'application/json') {\n return Translates::getData(null, null, 10);\n } else {\n $data = $this->list($data);\n }\n } elseif (strtolower($param1) == 'list-datatable') {\n if (strtolower(request()->server('CONTENT_TYPE')) == 'application/json') {\n return Translates::getDataTable();\n } else {\n $data = $this->list($data, $param1);\n }\n } elseif ($param1 == 'add') {\n\n if (request()->ajax()) {\n if (request()->method() === 'POST') {\n return Translates::addToTable();\n }\n }\n\n $data = $this->add($data);\n } elseif ($param1 == 'edit') {\n $id = request('id', $param2);\n if (request()->ajax()) {\n if (request()->method() === 'POST') {\n return Translates::updateToTable($id);\n }\n }\n\n $data = $this->edit($data, $id);\n } elseif ($param1 == 'view') {\n $id = request('id', $param2);\n\n $data = $this->view($data, $id);\n } elseif ($param1 == 'delete') {\n $id = request('id', $param2);\n abort(404);\n }\n\n MetaHelper::setConfig([\n 'title' => $data['title'],\n 'author' => config('app.name'),\n 'keywords' => '',\n 'description' => '',\n 'link' => null,\n 'image' => null\n ]);\n $pages = array(\n 'host' => url('/'),\n 'path' => '/' . Users::role(),\n 'pathview' => '/' . $data['formName'] . '/',\n 'parameters' => array(\n 'param1' => $param1,\n 'param2' => $param2,\n 'param3' => $param3,\n ),\n 'search' => parse_url(request()->getUri(), PHP_URL_QUERY) ? '?' . parse_url(request()->getUri(), PHP_URL_QUERY) : '',\n 'form' => FormHelper::form($data['formData'], $data['formName'], $data['formAction']),\n 'parent' => Translates::path('view'),\n 'view' => $data['view'],\n );\n $pages['form']['validate'] = [\n 'rules' => FormTranslates::rules(),\n 'attributes' => FormTranslates::attributes(),\n 'messages' => FormTranslates::messages(),\n 'questions' => FormTranslates::questions(),\n ];\n\n config()->set('app.title', $data['title']);\n config()->set('pages', $pages);\n return view($pages['parent'] . '.index', $data);\n }", "public function create()\n {\n $locale = Lang::locale();\n $lang=[];\n if(Session::has('job_category_lang_id')){\n $lang = Session::get('job_category_lang_id');\n }\n $language = Language::whereNotIn('id',$lang)->where('active',1)->pluck('name','id');\n return view('admin.jobcategories.create',compact('language'));\n }", "public function run()\n {\n $data = [\n [\n 'flag' => '/uploads/languages/vi.png',\n 'name' => 'Tiếng Việt',\n 'short' => 'vi',\n 'status' => 1\n ],\n [\n 'flag' => '/uploads/languages/en.png',\n 'name' => 'English',\n 'short' => 'en',\n 'status' => 1\n ]\n ];\n \\App\\Models\\Language::insert($data);\n }", "function __construct() {\n\t\tparent::__construct();\n\t\t$this->load->model(\"setting_m\");\n\t\t$language = $this->session->userdata('lang');\n\t\t$this->lang->load('setting', $language);\n\t}", "public function init()\r\n {\r\n \t$this->tr=Application_Form_FrmLanguages::getCurrentlanguage();\r\n \theader('content-type: text/html; charset=utf8');\r\n \tdefined('BASE_URL')\t|| define('BASE_URL', Zend_Controller_Front::getInstance()->getBaseUrl());\r\n\t}", "public function create(){\n $quality = ['Average'=>'Average','Good'=>'Good','Very Good'=>'Very Good','Excellent'=>'Excellent'];\n $languages = Language::where('user_id',$this->user_id)->get();\n return view('jobseeker.language.create', compact('languages','quality'));\n }", "public function init()\r\n\t{\r\n\t\t$this->tr=Application_Form_FrmLanguages::getCurrentlanguage();\r\n\t\theader('content-type: text/html; charset=utf8');\r\n\t\tdefined('BASE_URL')\t|| define('BASE_URL', Zend_Controller_Front::getInstance()->getBaseUrl());\r\n\t}", "function __construct () {\r\n\r\n\t\tparent::__construct();\r\n\r\n\t\t$this->load->model(\"student_m\");\r\n\r\n\t\t$this->load->model(\"parentes_m\");\r\n\t\t\r\n\t\t$this->load->model(\"package_m\");\r\n\r\n\t\t$this->load->model(\"section_m\");\r\n\r\n\t\t$this->load->model(\"mark_m\");\r\n\r\n\t\t$this->load->model(\"grade_m\");\r\n\r\n\t\t$this->load->model(\"invoice_m\");\r\n\r\n\t\t$this->load->model(\"classes_m\");\r\n\r\n\t\t$this->load->model(\"exam_m\");\r\n\r\n\t\t$this->load->model(\"subject_m\");\r\n\r\n\t\t$this->load->model(\"user_m\");\r\n\r\n\t\t$this->load->model(\"tmember_m\");\r\n\r\n\t\t$language = $this->session->userdata('lang');\r\n\r\n\t\t$this->lang->load('student', $language);\r\n\r\n\t}", "public function create()\n {\n $this->validate();\n\n $this->language->default = (bool) $this->language->default;\n\n $this->language->save();\n\n $this->notify(\n 'Language successfully created.',\n 'hub.languages.index'\n );\n }", "public function __construct()\n\t{\n\t\tparent::__construct();\n\t\t$this->load->language('dashboard');\n\t}", "public static function make(){\n return new Language;\n }", "public function getCreate()\n {\n $languages = Language::all();\n $language = \"\";\n // Show the page\n return view('admin.objecttype.create_edit', compact('languages','language'));\n }", "public function __construct(){\n parent::__construct();\n $this->load->library('session');\n $this->load->model(\"Page_model\");\n $this->load->model(\"Book_model\");\n $this->load->model(\"./Lang_fc\");\n }" ]
[ "0.654467", "0.6494885", "0.64239866", "0.63991034", "0.62546206", "0.6155056", "0.61368436", "0.6117191", "0.6088474", "0.6082712", "0.605837", "0.5959908", "0.5918154", "0.5900087", "0.58981884", "0.5850066", "0.58416593", "0.5810439", "0.5807883", "0.5785673", "0.575996", "0.5748431", "0.5735129", "0.5725626", "0.57203627", "0.5718109", "0.5712985", "0.5704553", "0.5701448", "0.56972355", "0.5693496", "0.5685972", "0.5677314", "0.5674059", "0.56736535", "0.56730485", "0.5660176", "0.5654234", "0.56523925", "0.5644895", "0.5641134", "0.5633359", "0.5632553", "0.5622357", "0.5616436", "0.56113756", "0.5606905", "0.5598696", "0.55953145", "0.5577134", "0.5576482", "0.5573649", "0.55667275", "0.55650526", "0.55562615", "0.5554663", "0.55529857", "0.55529845", "0.55517817", "0.5551145", "0.5550674", "0.5546819", "0.5543651", "0.5543007", "0.55404305", "0.5538162", "0.55281204", "0.55238926", "0.55198306", "0.55185056", "0.5514253", "0.5512066", "0.55084944", "0.5502479", "0.54979974", "0.54889107", "0.548676", "0.54819703", "0.5480645", "0.54794717", "0.54675466", "0.546336", "0.54612094", "0.54579073", "0.54577553", "0.54566014", "0.54565394", "0.5456414", "0.5447464", "0.54464847", "0.5440352", "0.5435077", "0.5434221", "0.54332143", "0.5430419", "0.5426478", "0.54264015", "0.54248327", "0.5423898", "0.5420491", "0.5416079" ]
0.0
-1
Ready to process requests controller method
public function ready() { $this->isAjax = true; $origin = $this->request->getHeader('Origin'); if ($origin) { // allow API usage from any hosts $this->getResponse()->getHeaders()->addHeaderLine( 'Access-Control-Allow-Origin', $origin->getFieldValue() ); } $requestHeaders = $this->request->getHeader('Access-Control-Request-Headers'); if ($requestHeaders) { // allow any headers asked $this->getResponse()->getHeaders()->addHeaderLine( 'Access-Control-Allow-Headers', $requestHeaders->getFieldValue() ); } $this->getResponse()->getHeaders()->addHeaderLine( // allow any methods 'Access-Control-Allow-Methods', 'POST, GET, OPTIONS, PUT, DELETE, PATCH' ); $this->getResponse()->getHeaders()->addHeaderLine( // allow cookies 'Access-Control-Allow-Credentials', 'true' ); if (strtoupper($this->request->getMethod()) == 'OPTIONS') { return true; // we should return http 200 with empty body } try { $user = Registry::get('User'); } catch (\Exception $e) { $user = new User(); Registry::set('User', $user); } try { $user->auth(false); } catch (\Exception $e) { } $this->user = $user; $this->getLanguage(); return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function processRequest();", "public function requestAction()\n {\n }", "protected function _request() {}", "public function requests()\n\t{\n\t\t$this->checkRequest();\n\t\t$this->getResponse();\n\t}", "public function runRequest() {\n }", "public function process()\n\t{\n\t\t$action = $this->getAction();\n\t\tswitch (strtolower($action))\n\t\t{\n\t\t\tcase 'get':\n\t\t\tcase 'put':\n\t\t\tcase 'post':\n\t\t\tcase 'delete':\n\t\t}\t\n\t}", "public function processRequest() {\r\n switch($this->requestMethod) {\r\n case 'GET':\r\n if($this->id) {\r\n $response = $this->get($this->id);\r\n }\r\n else {\r\n $response = $this->getAll();\r\n }\r\n break;\r\n case 'POST':\r\n $response = $this->create();\r\n break;\r\n case 'PUT':\r\n $response = $this->update($this->id);\r\n break;\r\n case 'DELETE':\r\n $response = $this->delete($this->id);\r\n break;\r\n case 'OPTIONS':\r\n break;\r\n default:\r\n $response = $this->notFoundResponse();\r\n break;\r\n }\r\n\r\n header($response['status_code_header']);\r\n\r\n // If there is a body then echo it\r\n if($response['body']) {\r\n echo $response['body'];\r\n }\r\n }", "public abstract function processRequest();", "public function handleRequest() {}", "abstract public function processRequest();", "public function request()\n {\n }", "public function request()\n {\n }", "abstract protected function process(Request $request);", "public function serve_request()\n {\n }", "public function processRequest() {\n $action = \"\";\n //retrieve action from client.\n if (filter_has_var(INPUT_GET, 'action')) {\n $action = filter_input(INPUT_GET, 'action');\n }\n\n switch ($action) {\n case 'login':\n $this->login(); \n break;\n case 'register':\n $this->register(); //list all articles\n break;\n case 'search':\n $this->search(); //show a form for an article\n break;\n case 'searchList':\n $this->searchList();\n break;\n case 'remove':\n $this->removeArticle();\n break;\n case 'modify':\n $this->modifyArticle();\n break;\n case 'listCategoryForm':\n $this->listCategoryForm();\n break;\n case 'listCategory':\n $this->listCategory();\n break;\n default :\n break;\n }\n }", "public function run(){\n // server response object \n $requestMethod = $this->requestBuilder->getRequestMethod();\n $this->response = new Response($requestMethod);\n\n try{\n $route = $this->router->validateRequestedRoute($this->requestBuilder);\n\n // serve request object\n $this->requestBuilder->setQuery();\n $this->requestBuilder->setBody();\n $requestParams = $this->requestBuilder->getParam();\n $requestQuery = $this->requestBuilder->getQuery();\n $requestBody = $this->requestBuilder->getBody(); \n $this->request = new Request($requestParams, $requestQuery, $requestBody);\n\n $callback = $route->getCallback();\n $callback($this->request, $this->response);\n }catch(RouteNotImplementedException $e){\n $this->response->statusCode(404)->json($e->getMessage()); \n }\n \n }", "public function DispatchRequest ();", "public function prepareRequest()\r\n {\r\n\r\n }", "public function run()\n {\n $uri = $this->getURI();\n\n // Check the availability of this request in the array of routes (routesOld.php)\n foreach ($this->routes as $uriPattern => $path) {\n\n // Compare $uriPattern and $uri\n if (preg_match(\"~$uriPattern~\", $uri)) {\n\n $internalRoute = preg_replace(\"~$uriPattern~\", $path, $uri);\n\n\n $segments = explode('/', $internalRoute);\n\n $controllerName = array_shift($segments) . 'Controller';\n $controllerName = ucfirst($controllerName);\n\n $action = array_shift($segments);\n $actionName = 'action' . ucfirst($action);\n\n $parameters = $segments;\n\n $controllerName = $this->controlNameSpace . $controllerName;\n $controllerObject = new $controllerName;\n\n return ['ref' => $controllerObject,\n 'actionName' => $actionName,\n 'args' => $parameters];\n\n }\n }\n }", "private function _processRequest()\n\t{\n\t\t// prevent unauthenticated access to API\n\t\t$this->_secureBackend();\n\n\t\t// get the request\n\t\tif (!empty($_REQUEST)) {\n\t\t\t// convert to object for consistency\n\t\t\t$this->request = json_decode(json_encode($_REQUEST));\n\t\t} else {\n\t\t\t// already object\n\t\t\t$this->request = json_decode(file_get_contents('php://input'));\n\t\t}\n\n\t\t//check if an action is sent through\n\t\tif(!isset($this->request->action)){\n\t\t\t//if no action is provided then reply with a 400 error with message\n\t\t\t$this->reply(\"No Action Provided\", 400);\n\t\t\t//kill script\n\t\t\texit();\n\t\t}\n\n\t\t//check if method for the action exists\n\t\tif(!method_exists($this, $this->request->action)){\n\t\t\t//if method doesn't exist, send 400 code and message with reply'\n\t\t\t$this->reply(\"Action method not found\",400);\n\t\t\t//kill script\n\t\t\texit();\n\t\t}\n \n\t\tswitch($this->request->action){\n\t\t\tcase \"hello\":\n\t\t\t\t$this->hello($this->request->data);\n\t\t\t\tbreak;\n\t\t\tcase \"submit_video\":\n\t\t\t\t//error_log(\"formSubmit has been sent through\");\n\t\t\t\t$this->submit_video($this->request, $_FILES);\n\t\t\t\tbreak;\n\t\t\tcase \"remove_video\":\n\t\t\t\t//error_log(\"formSubmit has been sent through\");\n\t\t\t\t$this->remove_video($this->request);\n\t\t\t\tbreak;\n\t\t\tcase \"isSubmitted\":\n\t\t\t\t$this->isSubmitted($this->request);\n\t\t\tdefault:\n\t\t\t\t$this->reply(\"action switch failed\",400);\n\t\t\tbreak;\n\t\t}\n\n\n\n\t}", "public function process_request() {\n if(!empty($this->POST)) {\n return $this->handlePOST();\n } else {\n return $this->handleGET();\n }\n }", "public function prepareRequest()\n {\n }", "protected static function runController()\n {\n $msg = new MoovicoRequestMessage(self::$route);\n self::$response = self::doRunController($msg);\n }", "public function RequestLifeCycle(){\n }", "public function processApi() {\n $request = $this->_request['request'];\n $values = $this->_request;\n\n // WARNING: This method needs to add some ways to authenticate the user\n // and should also filter out any dangerous or magic methods before it\n // would be safe. This code is for demonstration purposes only!\n\n if (method_exists($this->database, $request)) {\n if (!empty($_REQUEST['request'])) {\n unset($values['request']);\n $result = $this->database->processRequest($request, $values);\n if (!empty($result)) {\n $this->response($this->json($result), 200);\n }\n else {\n // If no records \"No Content\" status\n $this->response('',204);\n }\n }\n else {\n // If the method not exist with in this class, response would be \"Page not found\".\n $this->response('',404);\n }\n }\n }", "public function run()\n {\n $requested_url = explode('/', $this->requestUrl);\n\n if (!empty($this->definedRoutes[$this->requestMethod])) {\n foreach ($this->definedRoutes[$this->requestMethod] as $route => $action) {\n $route = explode('/', $route);\n $route_depth = count($route);\n\n // Check for defined route parameters\n for( $i = 0; $i < $route_depth; $i++) {\n if (preg_match('/\\{([\\w?]+?)\\}/',$route[$i])) {\n if (isset($requested_url[$i])) {\n array_push($this->requestParameters, $requested_url[$i]);\n // replace defined route parameters with peer request url parameter for final comparison\n $route[$i] = $requested_url[$i];\n }\n }\n }\n\n // Check for unreplaced route parameters and delete them if are optional parameters (for final comparison)\n for ($j = 0; $j < $route_depth; $j++) {\n if (preg_match('/\\{([\\w]+?)\\?}/', $route[$j])) {\n unset($route[$j]);\n }\n }\n\n $route = implode('/', $route);\n\n // Final comparision. Check requested url is equal to current checking route\n if ($route == $this->requestUrl) {\n $this->matched = true;\n\n if ($action instanceof Closure) {\n return call_user_func_array($action, $this->requestParameters);\n } else if($this->isController($action)) {\n return $this->loadController($action);\n } else {\n throw new Exception('Invalid action for route');\n }\n break; // Route found, stop the operations\n } else {\n $this->reset();\n }\n }\n }\n\n if ($this->matched === false) {\n return $this->exception->notFound();\n }\n }", "abstract public function handle_request();", "public function preDispatch() { }", "public function processApi() {\n $func = strtolower(trim(str_replace(\"/\", \"\", $_REQUEST['request'])));\n if ((int) method_exists($this, $func) > 0)\n $this->$func();\n else\n $this->response('', 404); // If the method not exist with in this class, response would be \"Page not found\".\n }", "public function handleRequest();", "public function handleRequest();", "public function handleRequest();", "public function handlerNeedsRequest()\n {\n }", "public function preDispatch();", "protected function initRequest()\n {\n $context = new RequestContext();\n $context->fromRequest(self::$request);\n $matcher = new UrlMatcher($this->routCollection, $context);\n\n try {\n $attributes = $matcher->match(self::$request->getPathInfo());\n $response = $this->callController($attributes);\n } catch (ResourceNotFoundException $e) {\n $response = new Response('Not Found', 404);\n } catch (Exception $e) {\n $response = new Response('An error occurred', 500);\n }\n\n $response->send();\n }", "abstract public function request();", "public function process() {\n // on va lui passer le contexte en premier paramètre\n // puis on va lui passer les paramètres du path comme\n // paramètres supplémentaires\n $args = array_merge(\n array($this->_context),\n $this->_context->route->params\n );\n\n $this->_context->require_part('controller', $this->controller);\n $controller = new $this->controller;\n\n // CALL STAGES BEFORE ACTION\n\n $stages = array(\n '_before_action'\n );\n\n $_response = null;\n $responses_stack = array();\n\n foreach($stages as $stage) {\n $_response = $this->call_stage($controller,$stage,$this->action, $responses_stack);\n\n // Si on obtient un objet de type Response, on stoppe\n\n if($_response instanceof Response) {\n return $this->output($_response); // ! RETURN\n }\n else {\n $responses_stack[$stage] = $_response;\n }\n }\n\n\n // CALL ACTION\n if(! method_exists($controller, $this->action)) {\n throw new \\InvalidArgumentException('Action '.$this->action.' does not exists in controller '. get_class($controller));\n }\n $action_response = call_user_func_array(array($controller, $this->action), $args);\n\n if($action_response instanceof Response) {\n return $this->output($action_response); // ! RETURN\n }\n\n\n if(is_null($action_response)) {\n // si la réponse est nulle, on ne fait rien tout simplement\n //@todo : faire autre chose, envoyer un 204 ?\n $class = get_class($controller);\n r(\"@todo : empty $class return\");\n return; // ! RETURN\n }\n elseif(is_string($action_response)) {\n $response = new Response($action_response, $headers=array());\n return self::output($response); // ! RETURN\n }\n\n\n }", "public function processRequest()\n {\n $params = json_decode(file_get_contents('php://input'),true);\n\n if ( $_POST [ 'action' ] == 'setScreenVars' )\n {\n $this->setScreenVars();\n\n } \n elseif ( $_POST [ 'action' ] == 'loadHero' )\n\n {\n $this->loadHero();\n\n } \n elseif ( $_POST [ 'action' ] == 'loadThumb' )\n\n {\n $this->loadThumb();\n\n } \n elseif ( $_POST [ 'action' ] == 'setScreenVars' )\n\n {\n $this->setScreenVars();\n }\n //this one sent from angular, use $params\n elseif ( $params [ 'action' ] == 'getSiteData' )\n {\n $this->getSiteData();\n }\n elseif ( $_POST [ 'action' ] == 'contactFormSubmit' )\n {\n $this->contactFormSubmit();\n }\n else \n {\n\n if ( $_SESSION['user']['access'] == '2' ) {\n if ( $_POST [ 'action' ] == 'sortUpdate' )\n {\n $this->sortUpdate();\n }\n elseif ( $_POST [ 'action' ] == 'imgStatusUpdate' )\n {\n $this->imgStatusUpdate();\n }\n elseif ( $_POST [ 'action' ] == 'deleteImage' )\n {\n $this->deleteImage();\n }\n elseif ( $_POST [ 'action' ] == 'saveCaption' )\n {\n $this->saveCaption();\n }\n }\n else \n {\n //no action requested, just notifify this file being accessed\n echo ( 'ajax file' );\n } \n }\n\n }", "protected abstract function handleRequest();", "public function processApi() {\n\n $func = strtolower(trim(str_replace(\"/\", \"\", $_REQUEST['rquest'])));\n\n if ((int) method_exists($this, $func) > 0) {\n $this->$func();\n } else {\n $this->response('Method not Found', 404); // If the method not exist with in this class, response would be \"Page not found\".*/\n\t}\n\n }", "public function run() {\r\n $this->routeRequest(new Request());\r\n }", "function handleRequest() ;", "public function processApi(){\n $func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['rquest'])));\n if((int)method_exists($this,$func) > 0)\n $this->$func();\n else\n $this->response('',404);\t\t\t\t// If the method not exist with in this class, response would be \"Page not found\".\n }", "public function processRequest()\n\t\t{\n\t\t\t$request_method = strtolower($_SERVER['REQUEST_METHOD']);\n\t\t\tswitch ($request_method)\n\t\t\t{\n\t\t\t\tcase 'get':\n\t\t\t\t\t$data = $_GET['url'];\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'post':\n\t\t\t\t\t$data = $_GET['url'];\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t\t$request_parts = explode('/', $data);\n\t\t\t$controller = $request_parts[0];\n\t\t\tswitch ($controller)\n\t\t\t{\n\t\t\t\tcase 'ad':\n\t\t\t\t\tprocessAdRequest(substr($data, strlen('ad')+1));\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'category':\n\t\t\t\t\tprocessCategoryRequest(substr($data, strlen('category')+1));\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'user':\n\t\t\t\t\tprocessUserRequest(substr($data, strlen('user')+1));\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\techo \"Invalid Request!\";\n\t\t\t\t\tbreak;\n\t\t\t}\n\n\t\t}", "public function process() {\n\n try {\n \n /*\n * !! IMPORTANT !!\n * Collections with a name starting with '$' character are not collection\n * but reserved actions \n */\n if ($this->request['collection'] && substr($this->request['collection'], 0 , 1) === '$') {\n \n /*\n * Action always returns JSON\n */\n $this->request['format'] = self::DEFAULT_RESPONSE_FORMAT;\n \n /*\n * QueryAnalyzer standalone service\n */\n if ($this->request['collection'] === '$analyzeQuery' && class_exists('QueryAnalyzer')) {\n \n /*\n * Change parameter keys to model parameter key\n * and remove unset parameters\n */\n $params = array();\n foreach ($this->request['params'] as $key => $value) {\n if ($value) {\n foreach(array_keys(RestoController::$searchFiltersDescription) as $filterKey) {\n if ($key === RestoController::$searchFiltersDescription[$filterKey]['osKey']) {\n $params[$filterKey] = $value;\n }\n }\n }\n }\n $qa = new QueryAnalyzer($this->dictionary, RestoController::$searchFiltersDescription, class_exists('Gazetteer') ? new Gazetteer($this) : null);\n $this->response = $qa->analyze($params);\n $this->responseStatus = 200;\n }\n else {\n throw new Exception('Not Found', 404);\n }\n }\n /*\n * Collection is requested\n */\n else if ($this->request['collection']) {\n \n /*\n * Collection does not exist\n */\n if (!$this->collections[$this->request['collection']]) {\n throw new Exception('Not Found', 404);\n }\n \n /*\n * Search collection Controller name within collections list\n */\n $controllerName = null;\n foreach (glob(realpath(dirname(__FILE__)) . '/../controllers/*.php', GLOB_NOSORT) as $controller) {\n if ($this->collections[$this->request['collection']]['controller'] === basename($controller, '.php')) {\n $controllerName = basename($controller, '.php');\n break;\n }\n }\n\n /*\n * Invalid controller \n */\n if (!$controllerName) {\n throw new Exception('Invalid collection', 500);\n }\n \n /*\n * HTTP method is PUT, POST or DELETE and no identifier is set\n * \n * HTTP DELETE - Delete new collection (if CollectionManager module is active)\n * HTTP PUT - Update new collection (if CollectionManager module is active)\n */\n if ($this->request['method'] === 'put' && !$this->request['identifier']) {\n if (class_exists('CollectionManager')) {\n $collectionManager = new CollectionManager($this);\n $this->response = $collectionManager->update();\n }\n else {\n throw new Exception('Forbidden', 403);\n }\n }\n else if ($this->request['method'] === 'delete' && !$this->request['identifier']) {\n if (class_exists('CollectionManager')) {\n $collectionManager = new CollectionManager($this);\n $this->response = $collectionManager->delete();\n }\n else {\n throw new Exception('Forbidden', 403);\n }\n }\n /*\n * HTTP GET method on /collection\n * HTTP POST, PUT DELETE on /collection/identifier\n */\n else {\n \n /*\n * Instantiate RestoController\n */\n $controller = new ReflectionClass($controllerName);\n if (!$controller->isInstantiable()) {\n throw new Exception('Bad Request', 400);\n }\n try {\n $method = $controller->getMethod($this->request['method']);\n } catch (ReflectionException $re) {\n throw new Exception('Forbidden', 403);\n }\n\n /*\n * Initialize a controller instance\n */\n if (!$method->isStatic()) {\n $controllerInstance = $controller->newInstance($this);\n $method->invoke($controllerInstance);\n $this->response = $controllerInstance->getResponse();\n $this->responseStatus = $controllerInstance->getResponseStatus();\n $this->responseDescription = $controllerInstance->getDescription();\n } else {\n throw new Exception('Static methods not supported in Controllers', 500);\n }\n if (is_null($this->response)) {\n throw new Exception('Method not allowed', 405);\n }\n }\n }\n /*\n * No collection requested \n * \n * HTTP GET - HTTP 200 (will redirect to home page - see htmlResponse)\n * HTTP POST - Create new collection (if CollectionManager module is active)\n * HTTP PUT - Not allowed\n * HTTP DELETE - Not allowed\n * \n */\n else {\n if ($this->request['method'] === 'get') {\n $this->responseStatus = 200;\n }\n else if ($this->request['method'] === 'post' && class_exists('CollectionManager')) {\n $collectionManager = new CollectionManager($this);\n $this->response = $collectionManager->create();\n }\n else {\n throw new Exception('Method Not Allowed', 405);\n }\n }\n } catch (Exception $re) {\n $this->responseStatus = $re->getCode();\n $this->response = array('ErrorCode' => $re->getCode(), 'ErrorMessage' => $re->getMessage());\n }\n\n /*\n * Special case for stream !\n */\n if ($controllerInstance && $this->responseDescription['forceStream']) {\n return;\n }\n\n /*\n * Output result\n */\n $this->response()->send();\n }", "public function RouteRequest ();", "public static function process_http_request()\n {\n }", "public function request();", "public function processApi(){\n\t\t\t$func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['rquest'])));\n\t\t\tif((int)method_exists($this,$func) > 0)\n\t\t\t\t$this->$func();\n\t\t\telse\n\t\t\t\t$this->response('',404);\t\t\t\t// If the method not exist with in this class, response would be \"Page not found\".\n\t\t}", "public function processApi()\n {\n $data = array('404'=>'requested method not available');\n $func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['mode'])));\n if((int)method_exists($this,$func) > 0)\n $this->$func();\n else\n $this->response($this->json($data),'404');\n // If the method not exist with in this class, response would be \"Page not found\".\n }", "private function run()\n {\n $dispatcher = $this->getDispatcher(self::getConfigSection('routes'));\n\n $routeInfo = $dispatcher->dispatch(self::getRequest('method'), self::getRequest('path'));\n\n switch ($routeInfo[0]) {\n case \\FastRoute\\Dispatcher::NOT_FOUND:\n $this->errorNotFound();\n break;\n case \\FastRoute\\Dispatcher::METHOD_NOT_ALLOWED:\n $this->error405();\n break;\n case \\FastRoute\\Dispatcher::FOUND:\n $this->actionParams = $routeInfo[2];\n $handler = explode('.', $routeInfo[1]);\n $this->controllerName = 'app\\controllers\\\\' . ucfirst($handler[0]) . 'Controller';\n $controllerFile = ucfirst($handler[0]) . 'Controller.php';\n $this->actionName = 'action' . ucfirst($handler[1]);\n $this->actionSlug = $handler[0] . '.' . $handler[1];\n if (!file_exists(self::$request['root_path'] . '/app/controllers/' . $controllerFile) ||\n !method_exists($this->controllerName, $this->actionName)) {\n //there is not a controller file or action name == index\n if (App::getConfig('app.debug')) {\n echo 'There is not a controller file \"' . $controllerFile . '\" or action name == index';\n }\n $this->errorNotFound();\n }\n if (isset($handler[2])) {\n //part of hangler for checking permissions\n if ($handler[2] == 'auth') {\n //need login and not logged\n if (App::isGuest()) {\n $this->redirect(App::getConfig('app.login_url'));\n }\n } else {\n //check permission for $handler[2]\n $auth = self::getComponent('auth');\n $user = self::getUser();\n $checkUser = $user ? $auth->hasAccessTo($user->email, $handler[2]) : false;\n if (!$checkUser) {\n //user does not exists or user does not have a permission\n $this->error405();\n }\n }\n }\n break;\n }\n $this->startAction();\n }", "public function executeRequest() {\n $this->splitURL();\n $this->validateRequest();\n\n // Create controller to dispatch our request, eg new BlogsController\n // Note format eg $dispatch = new BlogsController('Blog', 'blogs', 'index')\n $model = ucwords(rtrim($this->controller, 's'));\n $controller = ucwords($this->controller) . 'Controller';\n $dispatch = new $controller($model, $this->controller, $this->action);\n\n // Execute\n if (!isset($this->parameter1)) {\n call_user_func(array($dispatch, $this->action));\n } else if (!isset($this->parameter2)) {\n call_user_func(array($dispatch, $this->action), $this->parameter1);\n } else if (!isset($this->parameter3)) {\n call_user_func(array($dispatch, $this->action), $this->parameter1, $this->parameter2);\n } else {\n call_user_func(array($dispatch, $this->action), $this->parameter1, $this->parameter2, $this->parameter3);\n }\n }", "public function processApi() {\n\t\t$func = strtolower(trim(str_replace(\"/\", \"\", $_REQUEST['rquest'])));\n\t\tif ((int) method_exists($this, $func) > 0)\n\t\t\t$this -> $func();\n\t\telse\n\t\t\t$this -> response('', 404);\n\t\t// If the method not exist with in this class, response would be \"Page not found\".\n\t}", "public function processApi() {\n\t\t$func = strtolower(trim(str_replace(\"/\", \"\", $_REQUEST['rquest'])));\n\t\tif ((int) method_exists($this, $func) > 0)\n\t\t\t$this -> $func();\n\t\telse\n\t\t\t$this -> response('', 404);\n\t\t// If the method not exist with in this class, response would be \"Page not found\".\n\t}", "public function controller()\n {\n $method = $_SERVER['REQUEST_METHOD'];\n if ($method == 'GET') {\n $this->getController();\n };\n if ($method == 'POST') {\n check_csrf();\n $this->createController();\n };\n }", "public function processApi(){\n\t\t$func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['rquest'])));\n\t\tif((int)method_exists($this,$func) > 0)\n\t\t\t$this->$func();\n\t\telse\n\t\t\t$this->response('',404);\t// If the method not exist with in this class, response would be \"Page not found\".\n\t}", "public function run()\n {\n $routeInfo = $this->foundRoute();\n\n if (isset($routeInfo['middleware'])) {\n $middleware = $this->gatherMiddlewareClassNames($routeInfo['middleware']);\n $this->runMiddleware($middleware);\n }\n $response = $this->callControllerAction($routeInfo);\n\n $this->sendRequest($this->response ?: $response);\n\n }", "public function processApi()\n {\n $func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['mode'])));\n if((int)method_exists($this,$func) > 0)\n {\n $this->$func();\n } \n else\n {\n $data = array('code' => \"404\", 'status' => \"failure\", \"msg\" => \"requested method not available\", \"data\" => array());\n $this->response($this->json($data)); \n }\n \n // If the method not exist with in this class, response would be \"Page not found\".\n }", "private function requestProcessor() {\n try {\n\n if (empty($this->uri))\n throw new \\Exception(\"Undefined url\");\n\n $ReqHandle = curl_init($this->uri);\n\n $body = json_encode([]);\n if( sizeof($this->data) > 0 )\n $body = json_encode($this->data);\n\n $returnTransfer = 0;\n if( $this->hasResponseToReturn )\n $returnTransfer = 1;\n\n $isPost = 0;\n if( $this->method != 'GET')\n $isPost = 1;\n\n\n if($isPost == 1){\n curl_setopt($ReqHandle,CURLOPT_POST, $isPost);\n curl_setopt($ReqHandle, CURLOPT_POSTFIELDS, $body);\n }\n \n curl_setopt_array($ReqHandle, [\n CURLOPT_RETURNTRANSFER => $returnTransfer,\n CURLOPT_HTTPHEADER => $this->headersToBeUsed\n ]);\n\n\n $result = curl_exec($ReqHandle);\n\n if(curl_errno($ReqHandle)){\n\n return curl_error($ReqHandle);\n }\n\n if($returnTransfer == 1)\n return json_decode($result);\n\n\n\n } catch (\\Throwable $t) {\n new ErrorTracer($t);\n }\n }", "public function preDispatch() {\n\t\t\n\t\t}", "public function call()\n {\n $this->dispatchRequest($this['request'], $this['response']);\n }", "public function run()\n\t{\n\t\t$_controller = $this->getController();\n\t\t\n\t\tif ( ! ( $_controller instanceof IXLRest ) )\n\t\t{\n\t\t\t$_controller->missingAction( $this->getId() );\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t//\tCall the controllers dispatch method...\n\t\t$_controller->dispatchRequest( $this );\n\t}", "public function preDispatch()\n {\n\n }", "protected function runLogic()\n {\n Logic::run($this->request); /* The logic to attempt to parse the request */\n }", "function onRequest(){\n\n\t// check if we need to reload the application\n\tcheckApplicationState();\n\n\t// initialize the ViewSate for every request\n\tsetViewState( getFactory()->getBean( 'ViewState' ) );\n\n\t// decide what to do, the front controller\n\thandleAction();\n\n\t// render the application\n\trenderApplication();\n}", "public function requestRun()\n {\n }", "function execute(){\n $method = strtolower( $this->getRequest()->getMethod() );\n\n if( !method_exists( $this, $method ) )\n throw new RoutingException( \"Controller not implement {$method} method.\" );\n\n $result = call_user_func_array( array( $this, $method ), func_get_args() );\n\n if( is_array($result) ){\n $this->assignParams( $result );\n }\n }", "public function action() {\n\t\tif( ! $this->request_method )\n\t\t\treturn false;\n\t\tswitch ($this->request_method) {\n\t\t\tcase 'read':\n\t\t\t\t$this->read();\t\t\t\t\t\n\t\t\tbreak;\t\t\t\t\n\t\t\tcase 'create':\t\n\t\t\t\t$this->create();\t\t\t\t\t\n\t\t\tbreak;\n\t\t\tcase 'update':\n\t\t\t\t$this->update();\t\t\t\t\t\n\t\t\tbreak;\n\t\t\tcase 'delete':\n\t\t\t\t$this->delete();\t\t\t\t\t\n\t\t\tbreak;\n\t\t}\n\t}", "private function resolveRequest(){\n\t\t$controllers_dir = puppy::getAppDir().'controllers';\n\t\t$path_segments = explode('/', $this->getPathInfo());\n\t\t\n\t\t$controller_location = null;\n\t\t$controller_name = null;\n\t\t$action_name = null;\n\t\t\n\t\t//build path to controller\n\t\t$build_path = $controllers_dir;\n\t\tforeach($path_segments as $k => $dir){\n\t\t\t$build_path = $build_path.'/'.$dir;\n\t\t\tif(file_exists($build_path.\"/\")){\n\t\t\t\tif(is_dir($build_path)){\n\t\t\t\t\t$controller_location = $build_path;\n\t\t\t\t\tif(is_file($build_path.'/'.$dir.'.php')){\n\t\t\t\t\t\t$controller_name = $dir;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$action_name = $dir;\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\t\n\t\t//call action\n\t\tif(file_exists($controller_location.'/'.$controller_name.'.php')){\n\t\t\t//wrap require in try catch to state file has error\n\t\t\trequire_once($controller_location.'/'.$controller_name.'.php');\n\t\t\t$controller = new $controller_name();\n\t\t\tif($action_name !== null)\n\t\t\t\t$controller->$action_name();\n\t\t}\n\t}", "public function processApi() {\n $func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['x'])));\n if((int)method_exists($this, $func) > 0)\n $this->$func();\n else\n $this->response('',404);\n }", "public function willProcessRequest(array $data) {\n }", "public function processAPI() {\n $file = __dir__ . \"/../Controllers/\" . $this->endpoint . \"Controller.php\";\n\n if (file_exists($file)) {\n require $file;\n $class = \"\\\\Controllers\\\\\" .$this->endpoint . \"Controller\";\n\n } else {\n throw new \\Exception($file . \" does not exist.\");\n }\n\n $response = [];\n switch($this->method) {\n case HttpMethod::DELETE:\n case HttpMethod::POST:\n case HttpMethod::PUT:\n case HttpMethod::PATCH:\n $data = file_get_contents(\"php://input\");\n $this->data = json_decode($data,true);\n break;\n case HttpMethod::GET:\n break;\n default:\n $response = [\n \"Error\" => true,\n \"ErrorMessage\" => \"Unsupported Method: \".$this->method\n ]; \n $status = 405; \n return $this->_response($response,$status);\n break;\n }\n\n $worker = new $class($this->method,$this->data);\n $response = $worker->actionJson();\n\n return $this->_response($response);\n\n }", "public function execute() {\n\n $this->parseRequestHeaders();\n\n $uri = $this->loadUrl(); // Loads the called URL\n String::arrayTrimNumericIndexed($uri); // Trim the URL array indexes\n\n /**\n * When server is running as a RESTful server\n */\n if (RESTFUL == '1') {\n RestServer::runRestMethod($uri);\n $this->terminate();\n }\n\n /**\n * When the request is not running over ajax,\n * then call the home for full page rendering\n * before calling the requested method\n */\n if (!$this->isAjax()) {\n\n $this->controller = $this->requireHome();\n $this->controller->itStarts($uri);\n $this->terminate();\n }\n\n /**\n * Normal Ajax Request, call the method only\n */\n $this->runMethod($uri);\n $this->terminate();\n }", "public function preDispatch()\n\t{\n\n\t\t\n\t\t\n\t}", "public function run()\n {\n if (isset($_SERVER[\"PATH_INFO\"]))\n {\n $requestPath = $_SERVER[\"PATH_INFO\"];\n }\n else\n {\n $requestPath =\"/\";\n }\n\n $router = Router::getInstance();\n $requestRoute = $router->getRoute($requestPath);\n\n $controllerName=$requestRoute[\"controller\"].\"Controller\";\n $controller = new $controllerName();\n $methodName=$requestRoute[\"method\"].\"Action\";\n\n if (method_exists($controller, $methodName))\n {\n $this->viewData = array_merge($this->viewData, (array)$controller->$methodName());\n $this->renderResponse();\n }\n else\n {\n throw new ErrorException(\"methode \\\" $methodName\\\" inconnue dans \\\" $controllerName\\\"\") ;\n }\n\n\n }", "public function processRequest() {\n $this->server->service($GLOBALS['HTTP_RAW_POST_DATA']);\n }", "private function processRequest()\n\t{\n\t\t\n\t\t$request = NEnvironment::getService('httpRequest');\n\t\t\n\t\tif ($request->isPost() && $request->isAjax() && $request->getHeader('x-callback-client')) { \n\t\t\t\n\t\t\t$data = json_decode(file_get_contents('php://input'), TRUE);\n\t\t\tif (count($data) > 0) {\n\t\t\t\tforeach ($data as $key => $value) {\n\t\t\t\t\tif (isset($this->items[$key]) && isset($this->items[$key]['callback']) && $value === TRUE) {\n\t\t\t\t\t\t$this->items[$key]['callback']->invokeArgs($this->items[$key]['args']);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\tdie(json_encode(array('status' => \"OK\")));\n\t\t}\n\t\t\n\t}", "public function start() {\n\n $controller = ucfirst($this->routes[0]);\n\n // Storing the method name if it is called else assign null.\n\n $method = isset($this->routes[1]) ? $this->routes[1] : null;\n\n // Stroing the parameter if it is passed else assign null.\n\n $parameter = isset($this->routes[2]) ? $this->routes[2] : null;\n \n // Requiring parent class of controller and model.\n\n require_once ROOT . '/system/core/Controller.php';\n require_once ROOT . '/system/core/Model.php';\n\n $this->auto_load();\n\n // Instanitaing an object of the controller class.\n\n $obj = new $controller();\n\n // If method was called also parameter was passed.\n\n if(!(is_null($method)) && !((is_null($parameter)))) {\n\n $obj->$method($parameter);\n }\n\n // If method was called but the parameter was null.\n\n else {\n \n $obj->$method();\n }\n }", "public function postExecution($request){}", "public function execute()\n\t{\n\t\t// Create the class prefix\n\t\t$prefix = 'controller_';\n\n\t\tif ($this->directory)\n\t\t{\n\t\t\t// Add the directory name to the class prefix\n\t\t\t$prefix .= str_replace(array('\\\\', '/'), '_', trim($this->directory, '/')).'_';\n\t\t}\n\n\t\tif (Kohana::$profiling)\n\t\t{\n\t\t\t// Set the benchmark name\n\t\t\t$benchmark = '\"'.$this->uri.'\"';\n\n\t\t\tif ($this !== Request::$instance AND Request::$current)\n\t\t\t{\n\t\t\t\t// Add the parent request uri\n\t\t\t\t$benchmark .= ' « \"'.Request::$current->uri.'\"';\n\t\t\t}\n\n\t\t\t// Start benchmarking\n\t\t\t$benchmark = Profiler::start('Requests', $benchmark);\n\t\t}\n\n\t\t// Store the currently active request\n\t\t$previous = Request::$current;\n\n\t\t// Change the current request to this request\n\t\tRequest::$current = $this;\n\n\t\ttry\n\t\t{\n\t\t\t// Load the controller using reflection\n\t\t\t$class = new ReflectionClass($prefix.$this->controller);\n\n\t\t\tif ($class->isAbstract())\n\t\t\t{\n\t\t\t\tthrow new Kohana_Exception('Cannot create instances of abstract :controller',\n\t\t\t\t\tarray(':controller' => $prefix.$this->controller));\n\t\t\t}\n\n\t\t\t// Create a new instance of the controller\n\t\t\t$controller = $class->newInstance($this);\n\n\t\t\t// Execute the \"before action\" method\n\t\t\t$class->getMethod('before')->invoke($controller);\n\n\t\t\t// Determine the action to use\n\t\t\t$action = empty($this->action) ? Route::$default_action : $this->action;\n\n\t\t\t// Execute the main action with the parameters\n\t\t\t$class->getMethod('action_'.$action)->invokeArgs($controller, $this->_params);\n\n\t\t\t// Execute the \"after action\" method\n\t\t\t$class->getMethod('after')->invoke($controller);\n\t\t}\n\t\tcatch (Exception $e)\n\t\t{\n\t\t\t// Restore the previous request\n\t\t\tRequest::$current = $previous;\n\n\t\t\tif (isset($benchmark))\n\t\t\t{\n\t\t\t\t// Delete the benchmark, it is invalid\n\t\t\t\tProfiler::delete($benchmark);\n\t\t\t}\n\n\t\t\tif ($e instanceof ReflectionException)\n\t\t\t{\n\t\t\t\t// Reflection will throw exceptions for missing classes or actions\n\t\t\t\t$this->status = 404;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t// All other exceptions are PHP/server errors\n\t\t\t\t$this->status = 500;\n\t\t\t}\n\n\t\t\t// Re-throw the exception\n\t\t\tthrow $e;\n\t\t}\n\n\t\t// Restore the previous request\n\t\tRequest::$current = $previous;\n\n\t\tif (isset($benchmark))\n\t\t{\n\t\t\t// Stop the benchmark\n\t\t\tProfiler::stop($benchmark);\n\t\t}\n\n\t\treturn $this;\n\t}", "public function run()\n\t{\n\n\t\t//excute request routing\n\t\t$this->request = new Request($this);\n\n\t\t$module = $this->load_module();\n\n\t\tif ($module !== false) {\n\n\t\t\t$className = $this->load_controller($module);\n\n\t\t\tif ($className !== false) {\n\n\t\t\t\t$controller = new $className();\n\t\t\t\t$response = $this->call_function($controller);\n\t\t\t\tif (is_array($response)) {\n\t\t\t\t\tResponse::show($response);\n\t\t\t\t} else {\n\t\t\t\t\tResponse::show(array(\n\t\t\t\t\t\t\t$response\n\t\t\t\t\t\t));\n\t\t\t\t}\n\n\t\t\t} else {\n\t\t\t\tResponse::show(array(\n\t\t\t\t\t\t'status'\t=> false,\n\t\t\t\t\t\t'message'\t=> 'Application controller required.'\n\t\t\t\t\t), 404);\n\t\t\t}\n\n\t\t} else {\n\t\t\tResponse::show(array(\n\t\t\t\t\t'status'\t=> false,\n\t\t\t\t\t'message'\t=> 'Application module required.'\n\t\t\t\t), 404);\n\t\t}\n\n\t}", "function Execute()\n\t\t{\n\t\t\t$controller = new $this->CONTROLLER();\n\t\t\t$controller->Initialise($this->get, $this->post, $this->files);\n\t\t\t$controller->StartFilters();\n\t\t\t$controller->{$this->ACTION}();\n\t\t\t$controller->StopFilters();\n\t\t}", "public function preDispatch()\n {\n //...\n }", "public function run() {\n $base = $this->request->getNextRoute();\n if ($base !== BASE) {\n $this->response->notFound();\n }\n $start = $this->request->getNextRoute();\n if ($rs = $this->getRs($start)) {\n if ($this->request->isOptions()) {\n $this->response->okEmpty();\n return;\n }\n try {\n $this->response->ok($rs->handleRequest());\n\n } catch (UnauthorizedException $e) {\n $this->response->unauthorized();\n\n } catch (MethodNotAllowedException $e) {\n $this->response->methodNotAllowed();\n\n } catch (BadRequestExceptionInterface $e) {\n $this->response->badRequest($e->getMessage());\n\n } catch (UnavailableExceptionInterface $e) {\n $this->response->unavailable($e->getMessage());\n\n } catch (Exception $e) {\n $this->response->unavailable($e->getMessage());\n }\n } else {\n $this->response->badRequest();\n }\n }", "function process_request() {\n\t\tglobal $publishthis;\n\n\t\ttry{\n\n\t\t\t$bodyContent = '';\n\n\t\t\tif ( function_exists( 'wpcom_vip_file_get_contents' ) ) {\n\t\t\t\t$bodyContent = wpcom_vip_file_get_contents( 'php://input', 10, 60 );\n\t\t\t} else {\n\t\t\t\t$bodyContent = file_get_contents( 'php://input' );\n\t\t\t}\n\n\t\t\t$publishthis->log->addWithLevel( array( 'message' => 'Endpoint Request', 'status' => 'info', 'details' => $bodyContent ), \"2\" );\n\n\t\t\t$arrEndPoint = json_decode( $bodyContent, true );\n\n\t\t\t$action = $arrEndPoint[\"action\"];\n\n\t\t\t$pt_settings = $publishthis->get_options();\n\n\t\t\tif( !in_array( $action, array('resetState', 'stopEndpoint', 'resumeEndpoint') ) ) {\n\t\t\t\t$manually_stopped = get_option( 'pt_import_manually_stopped' );\n\t\t\t\tif ( $manually_stopped == 1 ) {\n\t\t\t\t\t$this->sendFailure('Import manually stopped');\n\t\t\t\t\treturn;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tswitch( $action ) {\n\t\t\t\tcase \"verify\":\n\t\t\t\t\t$this->actionVerify();\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase \"publish\":\n\t\t\t\t\tif( $publishthis->get_option( 'curated_publish' ) != 'import_from_manager' ) {\n\t\t\t\t\t\t$this->sendFailure( \"Publishing through CMS is disabled\" );\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\t$feedId = intval( $arrEndPoint[\"feedId\"], 10 );\n\t\t\t\t\t$pageNum = intval( $arrEndPoint[\"pageNum\"], 10 );\n\t\t\t\t\t$importId = $arrEndPoint[\"importId\"];\n\n\t\t\t\t\t$this->actionPublish2( $feedId, $pageNum, $importId );\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase \"getAuthors\":\n\t\t\t\t\t$this->actionGetAuthors();\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase \"getCategories\":\n\t\t\t\t\t$this->actionGetCategories();\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase \"resetState\":\n\t\t\t\t\t$this->resetState();\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase \"stopEndpoint\":\n\t\t\t\t\t$this->stopEndpoint();\n\t\t\t\t\tbreak;\n\n\t\t\t\tcase \"resumeEndpoint\":\n\t\t\t\t\t$this->resumeEndpoint();\n\t\t\t\t\tbreak;\n\n\t\t\t\tdefault:\n\t\t\t\t\t$this->sendFailure( \"Empty or bad request made to endpoint\" );\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t} catch( Exception $ex ) {\n\t\t\t//we will log this to the pt logger, but we always need to send back a failure if this occurs\n\n\t\t\t$this->sendFailure( $ex->getMessage() );\n\t\t}\n\n\t\treturn;\n\t}", "public function execute()\n {\n $controllerClassName = $this->requestUrl->getControllerClassName();\n $controllerFileName = $this->requestUrl->getControllerFileName();\n $actionMethodName = $this->requestUrl->getActionMethodName();\n $params = $this->requestUrl->getParams();\n \n if ( ! file_exists($controllerFileName))\n {\n exit('controlador no existe');\n }\n\n require $controllerFileName;\n\n $controller = new $controllerClassName();\n\n $response = call_user_func_array([$controller, $actionMethodName], $params);\n \n $this->executeResponse($response);\n }", "public function handleRequest()\n {\n $router = new Router();\n $controllerClass = $router->resolve()->getController();\n $controllerAction = $router->getAction();\n\n \n\n if(!class_exists($controllerClass)\n || !method_exists($controllerClass,$controllerAction)\n ){\n header('Not found', true, 404);\n exit;\n }\n\n $controller = new $controllerClass();\n call_user_func([$controller, $controllerAction]);\n\n }", "public function doRequests();", "public function processApi(){\n\t\t\t$func = strtolower(trim(str_replace(\"/\",\"\",$_REQUEST['value'])));\n\t\t\tif((int)method_exists($this,$func) > 0)\n\t\t\t\t$this->$func();\n\t\t\telse\n\t\t\t\t$this->response('',404);\t\t\t\t// If the method not exist with in this class, response would be \"Page not found\".\n\t\t}", "public function dispatch()\n {\n $this->response = $this->frontController->execute();\n }", "public function request_handler(){\r\n\t\t$route = new Router;\r\n\t\t$session = new Session;\r\n\t\t$segments = $route->urlRoute();\r\n\t\t#check if controller/action exist\r\n\t\t#if not use default_controller / default_action\r\n\t\tif( count($segments) == 0 || count($segments) == 1 ){\r\n\t\t\tinclude_class_method( default_controller , default_action );\r\n\t\t}else{\r\n\t\t#if controller/action exist in the url\r\n\t\t#then check the controller if it's existed in the file\r\n\t\t\tif( file_exists( CONTROLLER_DIR . $segments[0] . CONT_EXT ) )\r\n\t\t\t{\r\n\t\t\t\t#check for segments[1] = actions\r\n\t\t\t\t#if segments[1] exist, logically segments[0] which is the controller is also exist!!\r\n\t\t\t\t//if( isset($segments[1]) ){\r\n\t\t\t\t\tinclude_class_method( $segments[0], $segments[1] . 'Action' );\r\n\t\t\t\t//}\r\n\t\t\t}else{\r\n\t\t\t\terrorHandler(CONTROLLER_DIR . $segments[0] . CONT_EXT);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "public function processApi()\n {\n\n $func = strtolower(trim(str_replace(\"/\", \"\", $_REQUEST['x'])));\n if ((int) method_exists($this, $func) > 0) {\n $this->$func();\n }\n else {\n $this->response('', 404);\n }\n }", "public function front_action() {\n\n\t\tif ( $this->is_request_to_forget() ) {\n\t\t\t$this->process_request_to_forget();\n\t\t}\n\n\t\tif ( $this->is_request_confirmation() ) {\n\t\t\t$this->process_confirm_request();\n\t\t}\n\t}", "public function processApi() {\r\n\tif($this->securedRest){\r\n\t if(!isset($this->requestSecure) || !isset($this->requestPublicKey)){\r\n\t\t$this->response('Utilisateur non authentifié', 401);\r\n\t }\r\n\t if(!$this->verifyKeys($this->requestPublicKey, $this->requestSecure)){\r\n\t\t$this->response('Utilisateur non authentifié', 401);\r\n\t }\r\n\t}\r\n\t\r\n\t$func = $this->_method;\r\n\tif ((int) method_exists($this, $func) > 0){\r\n\t $this->$func();\r\n\t}else{\r\n\t $this->response('', 404);\r\n\t}\r\n\t\r\n }", "function request()\n {\n }", "protected function processGetRequest()\n {\n $this->ajaxDie(json_encode([\n 'success' => true,\n 'operation' => 'get'\n ]));\n }", "public function run() {\n // 1. Getting the request string\n $uri = $this->getURI();\n $uri_arr = explode('/', $uri);\n if ($uri_arr !== false) {\n $flag = false;\n foreach ($uri_arr as $key=>$item) {\n if (($item === 'articles' or $item === 'auth') and $key > 0) {\n define('FOLDER_NAME', $uri_arr[$key - 1]);\n $flag = true;\n }\n }\n if (!$flag) {\n define('FOLDER_NAME', '');\n }\n }\n\n // 2. Checking if the request exists in routes\n foreach ($this->routes as $req=>$act) {\n // 3. If getting match then define the controller and action\n if (preg_match('@'.$req.'@', $uri)) {\n // 4. Importing file of chosen controller\n if ($req !== '') {\n $internal = preg_replace('@' . $req . '@', $act, $uri);\n }\n else {\n $internal = $act;\n }\n $matches = array();\n preg_match('@(articles/.*$|main/.*$|auth/.*$)@', $internal, $matches);\n $internal = $matches[0];\n $full_request = explode('/', $internal);\n $controller = ucfirst($full_request[0].'Controller');\n $action = 'action'.explode('?', ucfirst($full_request[1]))[0];\n $params = array();\n for ($i = 2; $i < count($full_request); $i++) {\n $params[$i - 2] = $full_request[$i];\n }\n $file = ROOT.'/controllers/'.$controller.'.php';\n if (file_exists($file)) {\n include_once($file);\n }\n // 5. Creating object and doing action\n try {\n $chosenController = new $controller;\n $is_done = call_user_func_array(array($chosenController, $action), $params);\n }\n catch (TypeError $e) {\n header(\"HTTP/1.0 404 Not Found\");\n $is_done = false;\n }\n if ($is_done) break;\n }\n }\n\n }", "protected function getRequest() {}", "public function createController(): void\n {\n $minimum_buffer_min = 3;\n $envelope_id= $this->args['envelope_id'];\n $token_ok = $this->routerService->ds_token_ok($minimum_buffer_min);\n if ($token_ok && $envelope_id) {\n # 2. Call the worker method\n $results = $this->worker($this->args);\n if ($results) {\n # results is an object that implements ArrayAccess. Convert to a regular array:\n $results = json_decode((string)$results, true);\n $this->clientService->showDoneTemplate(\n \"Envelope recipients results\",\n \"List the envelope's recipients and their status\",\n \"Results from the EnvelopesRecipients::list method:\",\n json_encode(json_encode($results))\n );\n }\n } elseif (! $token_ok) {\n $this->clientService->needToReAuth($this->eg);\n } elseif (! $envelope_id) {\n $this->clientService->envelopeNotCreated(\n basename(__FILE__),\n $this->routerService->getTemplate($this->eg),\n $this->routerService->getTitle($this->eg),\n $this->eg,\n ['envelope_ok' => false]\n );\n }\n }", "abstract function _do_execute(request $request);", "public function postDispatch()\n {\n parent::postDispatch();\n\n $this->getRequestData();\n }" ]
[ "0.729852", "0.7236937", "0.7135384", "0.70567757", "0.7007521", "0.69890356", "0.6892383", "0.6826791", "0.67978835", "0.6765718", "0.67466444", "0.67466444", "0.67083323", "0.66800493", "0.6589969", "0.6580475", "0.6578287", "0.6554143", "0.65331787", "0.65163714", "0.65061927", "0.6502081", "0.6497492", "0.6490251", "0.64832884", "0.64556015", "0.6438061", "0.64346236", "0.6423986", "0.6410231", "0.6410231", "0.6410231", "0.6399803", "0.6395986", "0.63769495", "0.6369593", "0.6348066", "0.63241285", "0.6308541", "0.63051355", "0.6304009", "0.6303608", "0.6298364", "0.6289127", "0.6283061", "0.62825555", "0.62810725", "0.6279487", "0.6271894", "0.6270604", "0.62581694", "0.62579453", "0.62553716", "0.62553716", "0.6254761", "0.62447417", "0.6242659", "0.6242428", "0.6213825", "0.6210455", "0.6196893", "0.6189616", "0.61881053", "0.617611", "0.61725104", "0.6167379", "0.61662626", "0.616622", "0.61521983", "0.6149354", "0.61403257", "0.6131812", "0.61308837", "0.61297417", "0.6129067", "0.61176676", "0.61160374", "0.61146283", "0.61116385", "0.6099851", "0.60973674", "0.6096707", "0.60841686", "0.60836065", "0.6065633", "0.60654986", "0.6058492", "0.6052172", "0.6043473", "0.6030588", "0.6028776", "0.6025885", "0.6021136", "0.60102206", "0.59989995", "0.59922636", "0.59758455", "0.59723175", "0.59555393", "0.59552896", "0.5952432" ]
0.0
-1
gets language from session or user settings
protected function getLanguage() { $lang = 1; try { $lang = Registry::get('lang'); } catch (\Exception $e) { if (!empty($_SESSION['lang'])) { $lang = $_SESSION['lang']; } if (!empty($this->user->languageId)) { $lang = $this->user->languageId; } $this->setLanguage($lang); } return $lang; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function get_lang ()\r\n {\r\n return $_SESSION[\"lang\"];\r\n }", "function pnUserGetLang()\r\n{\r\n $lang = pnSessionGetVar('lang');\r\n if (!empty($lang)) {\r\n return $lang;\r\n } else {\r\n return pnConfigGetVar('language');\r\n }\r\n}", "public function get_language()\n\t{\n\t\tif ($this->userdata['language'] != '')\n\t\t{\n\t\t\treturn $this->userdata['language'];\n\t\t}\n\t\tif (ee()->input->cookie('language'))\n\t\t{\n\t\t\treturn ee()->input->cookie('language');\n\t\t}\n\t\telse if (ee()->config->item('deft_lang') != '')\n\t\t{\n\t\t\treturn ee()->config->item('deft_lang');\n\t\t}\n\n\t\treturn 'english';\n\t}", "function getSessionLanguage()\n {\n\n // define all the global variables\n global $user;\n\n // check if its a user or guest session\n if ($this->logged_in()) { // user session\n\n // grab the users preferred language\n $language = $user->getPreferredLanguage();\n\n } else { // guest session\n\n // check if any cookies were to be found for a custom language\n if (isset($_COOKIE['language'])) {\n $language = $_COOKIE['language'];\n } else {\n $language = \"\";\n }\n }\n\n // check if $language has been initialized or not\n if (is_string($language) && $language != \"\") {\n return $language; // if no errors then return the language string\n } else {\n return false; // if no language, then just return false\n }\n }", "public static function getLanguage()\r\n {\r\n return session()->get(self::$sessLanguageKey);\r\n }", "public static function getLang(){\n\t\tif(!isset(self::$_config['lang'])) return null;\n\t\telse return $_COOKIE['lang'];\n\t}", "public function getLanguage() {}", "private function get_language ()\n {\n $lang = filter_input ( INPUT_COOKIE, 'lang', FILTER_CALLBACK, [ 'options' => [ $this, 'filter_lang' ] ] );\n\t$new_lang = filter_input ( INPUT_GET, 'lang', FILTER_CALLBACK, [ 'options' => [ $this, 'filter_lang' ] ] );\n\tif ( $new_lang ) {\n\t\t$lang = $new_lang;\n\t\tsetcookie( \"lang\", substr ( $lang, 0, 2 ), time() + 3600 * 24 * 365, '/' );\n\t}\n\t\n\treturn $lang ?? 'uk';\n }", "public function getLang()\n {\n \t$lang_path = 'lang/';\n if(isset($_GET['lang']))\n {\n Yii::app()->session[\"lang\"] = $_GET['lang']; \n }\n \n if(!file_exists($lang_path.Yii::app()->session[\"lang\"].'.ini'))\n {\n\t\t\tYii::app()->session[\"lang\"] = 'sr';\n }\n\t\t\n\t\t$this->langArray= parse_ini_file($lang_path.Yii::app()->session[\"lang\"].'.ini'); \n }", "public static function get_lang() {\n\t\t$language = \\Config::get ( 'language' );\n\t\tempty ( $language ) and $language = static::$fallback [0];\n\t\treturn $language;\n\t}", "private static function getLanguage()\n {\n if (isset($_COOKIE[\"language\"]))\n {\n return $_COOKIE[\"language\"];\n }\n else\n {\n // Default is Czech\n return \"cs\";\n }\n }", "abstract public function get_app_language();", "public function getLang();", "function common_current_language(){\r\n\tif($_SESSION['lang'] == 'id'){\r\n\t\treturn 'Bahasa Indonesia';\r\n\t}\r\n\telse if($_SESSION['lang'] == 'en'){\r\n\t\treturn 'English';\r\n\t}\r\n}", "public function getLanguage();", "public function getLanguage();", "public function getLanguage();", "public function getLanguage();", "public function getLanguage();", "public function getLanguage();", "public function getCurrentLanguage() {\n return $this->ci->session->userdata(\"language\");\n }", "static function getLanguage (){\n return self::$language;\n }", "public function get_language()\n {\n }", "function getLang() {\n\tif (request()->cookie(config('translate.su_cookie_name'))) {\n\t\t$cookie = request()->cookie(config('translate.su_cookie_name'));\n\t} else {\n\t\tif (request()->cookie(config('translate.cookie_name'))) {\n\t\t\t$cookie = request()->cookie(config('translate.cookie_name'));\n\t\t} else {\n\t\t\tif (substr(request()->server('HTTP_ACCEPT_LANGUAGE'), 0, 2)) {\n\t\t\t\t$cookie = substr(request()->server('HTTP_ACCEPT_LANGUAGE'), 0, 2);\n\t\t\t} else {\n\t\t\t\t$cookie = config('translate.default_locale');\n\t\t\t}\n\t\t}\n\t}\n\treturn $cookie;\n}", "public function getLanguage()\n\t{\n\t\t$language = isset($this->session->data['language']) ? $this->session->data['language'] : $this->config->get('config_language');\n\n\t\t$language_code = substr($language, 0, 2);\n\n\t\t$this->bootstrap();\n\n\t\t$is_available = @constant('\\Genesis\\API\\Constants\\i18n::' . strtoupper($language_code));\n\n\t\tif ($is_available) {\n\t\t\treturn strtolower($language_code);\n\t\t} else {\n\t\t\treturn 'en';\n\t\t}\n\t}", "function get_current_language() {\n $ci = & get_instance();\n if ($ci->session->userdata('lang')) {\n return $ci->session->userdata('lang');\n } else {\n return DEF_LANGUAGE;\n }\n}", "public static function getLang()\n {\n return self::getInstance()->lang;\n }", "static function get()\n\t{\n\t\treturn self::$lang;\n\t}", "public static function getLanguageName(){\n if(Cache::isStored('website_lang')) return Cache::get('website_lang'); \n $row = getDatabase()->queryFirstRow(\"SELECT `value` FROM `settings` WHERE `setting` = 'website_lang'\");\n Cache::store('website_lang', $row['value']);\n return $row['value'];\n }", "public function getLanguage() {\n\t\treturn $this->getParameter('app_language');\n\t}", "function _getLanguage() {\n global $basePath, $arrLanguages;\n\n $language = $this->defaultLanguage;\n\n if (isset($_SESSION['installer']['langId'])) {\n $language = $arrLanguages[$_SESSION['installer']['langId']]['lang'];\n } elseif (isset($_SERVER['HTTP_ACCEPT_LANGUAGE']) && !empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n $browserLanguage = substr(strtolower($_SERVER['HTTP_ACCEPT_LANGUAGE']),0,2);\n\n foreach ($arrLanguages as $arrLang) {\n if ($browserLanguage == $arrLang['lang']) {\n $language;\n break;\n }\n }\n }\n\n if ($this->_checkLanguageExistence($language)) {\n return $language;\n } else {\n return $this->defaultLanguage;\n }\n }", "function findLanguage() {\n\t\tif ((LANGUAGE == 'NULL') || (LANGUAGE === NULL)) {\n\t\t\treturn null;\n\t\t}\n\t\t/*\n\t\t\t\tif (isset ($this->Session)) {\n\t\t\t\t\t$code= $this->Session->read('Lang.Code');\n\t\t\t\t\tif (isset ($code) && !empty ($code)) {\n\t\t\t\t\t\treturn $code;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t*/\n\t\tif (LANGUAGE == 'VHOST') {\n\t\t\t$l= $this->getVhostLang();\n\t\t\tif (empty ($l)) {\n\t\t\t\t$l= $this->getBrowserLang();\n\t\t\t}\n\t\t\treturn $l;\n\t\t}\n\t\tif (LANGUAGE == 'BROWSER') {\n\t\t\treturn $this->getBrowserLang();\n\t\t}\n\t\treturn LANGUAGE;\n\t}", "protected function getLanguageService()\n {\n return $GLOBALS['LANG'];\n }", "protected function getLanguageService()\n {\n return $GLOBALS['LANG'];\n }", "protected function getLanguageService()\n {\n return $GLOBALS['LANG'];\n }", "protected function _language()\n {\n if (sizeof($this->_config['language']) > 1) {\n $language = $this->getRequest()->getParam('language');\n if (!empty($language)) {\n $this->_language = $language . '/';\n $this->_metaLanguage = $language;\n } else if (!empty($this->_session->language)) {\n $this->_language = $this->_session->language . '/';\n $this->_metaLanguage = $this->_session->language;\n } else {\n $browserLanguage = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);\n if (in_array($browserLanguage, $this->_config['language'])) {\n $this->_session->language = $browserLanguage;\n $this->_language = $browserLanguage . '/';\n $this->_metaLanguage = $browserLanguage;\n } else {\n $this->_language = $this->_config['language'][0] . '/';\n $this->_metaLanguage = $this->_config['language'][0];\n }\n }\n } else {\n $this->_language = '';\n $this->_metaLanguage = $this->_config['language'][0];\n }\n }", "protected function _extractLanguage() {\n // Default lanuage is always Lao\n $lang = 'lo';\n\n // Set the cookie name\n //$this->Cookie->name = '_osm_la';\n //echo $this->response->cookie(\"_osm_la\");\n \n // First check if the language parameter is set in the URL. The URL\n // parameter has first priority.\n $paramLang = $this->request->query(\"lang\");\n if (isset($paramLang)) {\n // Check if the URL parameter is a valid language identifier\n if (array_key_exists($paramLang, $this->_languages)) {\n // Set the language to the URL parameter\n $lang = $paramLang;\n }\n } else if ($this->Cookie->read($this->_languageCookie) != null) {\n // Check if a cookie is set and set its value as language. A Cookie\n // has second priority\n $cookieValue = $this->Cookie->read($this->_languageCookie);\n // Check if the URL parameter is a valid language identifier\n if (array_key_exists($cookieValue, $this->_languages)) {\n // Set the language to the Cookie value\n $lang = $cookieValue;\n }\n }\n\n // If neither the lang parameter nor a cookie is set, set and return\n // Lao as language.\n //$this->log(var_dump($this));\n //$this->response->cookie($this->_languageCookie => $lang ]);\n return $lang;\n }", "public function get_language() \n {\n return $this->language;\n }", "function setLanguage() {\n\t\tif(isset($_GET['lang'])) {\n\t\t\t$language = $this->getLanguageFileName($_GET['lang']);\n\t\t} elseif(isset($_COOKIE['lang'])) {\n\t\t\t$language = $this->getLanguageFileName($_COOKIE['lang']);\n\t\t} else {\n\t\t\t$language = $this->getLanguageFileName('en-us');\n\t\t}\n\n\t\t//Sets the language cookie for 30 days\n\t\tsetcookie('lang', $language['meta'], time() + 60 * 60 * 24 * 30, '/');\n\n\t\treturn $language;\n\t}", "final public function getLang(): string {\n $this->init();\n return $this->language;\n }", "function getCurrentLanguage() {\n if(strtolower($_SERVER['HTTP_HOST'][0].$_SERVER['HTTP_HOST'][1]) == \"en\") {\n return \"en\";\n }\n return \"cs\";\n}", "public function getLanguage()\n {\n return $this->getParameter('language');\n }", "public static function get() {\n\t\treturn self::$lang;\n\t}", "protected function getLang() {\n\t\t$locale = $this->getField()->getLocale();\n\t\tif($this->getField()->getConfig('jslocale')) {\n\t\t\t// Undocumented config property for now, might move to the jQuery view helper\n\t\t\t$lang = $this->getField()->getConfig('jslocale');\n\t\t} else if(array_key_exists($locale, self::$locale_map)) {\n\t\t\t// Specialized mapping for combined lang properties\n\t\t\t$lang = self::$locale_map[$locale];\n\t\t} else {\n\t\t\t// Fall back to default lang (meaning \"en_US\" turns into \"en\")\n\t\t\t$lang = i18n::get_lang_from_locale($locale);\n\t\t}\n\t\t\n\t\treturn $lang;\n\t}", "public function getLang(): string {\n return $this->lang;\n }", "static public function getLanguage() {\n\t\treturn self::$language;\n\t}", "protected function getLocale()\n {\n @session_start();\n return isset($_SESSION['varaa_locale'])\n ? $_SESSION['varaa_locale']\n : $this->config('app.locale');\n }", "public function get_language() {\r\n\t\treturn $this->language;\r\n\t}", "public function get_language() {\n if (defined('WPLANG')) {\n $language = WPLANG;\n }\n\n if (empty($language)) {\n $language = get_option('WPLANG');\n }\n\n if (!empty($language)) {\n $languageParts = explode('_', $language);\n return $languageParts[0];\n }\n\n return 'en';\n }", "public function getlanguage()\n {\n return $this->language;\n }", "public function getFromLanguage(): string;", "private function _getUserLanguage(): string\n {\n /** @var WebApplication|ConsoleApplication $this */\n // If the user is logged in *and* has a primary language set, use that\n if ($this instanceof WebApplication) {\n // Don't actually try to fetch the user, as plugins haven't been loaded yet.\n $session = $this->getSession();\n $id = $session->getHasSessionId() || $session->getIsActive() ? $session->get($this->getUser()->idParam) : null;\n if ($id && ($language = $this->getUsers()->getUserPreference($id, 'language')) !== null) {\n return $language;\n }\n }\n\n // Fall back on the default CP language, if there is one, otherwise the browser language\n return Craft::$app->getConfig()->getGeneral()->defaultCpLanguage ?? $this->_getFallbackLanguage();\n }", "public function language();", "public function language();", "public function language()\n {\n if(is_null($this->defaultLanguage)) {\n $config = $this->settings('config');\n\n if(!isset($config['i18n'])) {\n $config['i18n'] = 'en_US';\n }\n\n $settings = $this->path('settings');\n $path = $settings.'/i18n/'.$config['i18n'].'.php';\n\n $translations = array();\n\n if(file_exists($path)) {\n $translations = $this->settings('i18n/'.$config['i18n']);\n }\n\n $this->defaultLanguage = $this('language', $translations);\n }\n\n return $this->defaultLanguage;\n }", "public function getSiteDefaultLanguage();", "public function getCookieLanguage()\n {\n return isset($_COOKIE['lang']) ? $_COOKIE['lang'] : null;\n }", "function getlang() {\n $cooklang = $_COOKIE['cooklang'];\n $accept = $_SERVER['HTTP_ACCEPT_LANGUAGE'];\n $lang = $_GET['lang'];\n $dirlang = getdirlang();\n\n if (!isset ($lang)) {\n /* no language selection in http request */\n\n \n if (isset($dirlang)) {\n /* Language taken from path e.g., /fr/index.php -> fr */\n $lang = $dirlang;\n } else if (isset($cooklang)) {\n /* Language taken from cookie */\n $lang = $cooklang;\n } else {\n /* not even a cookie. Choose from http_accept_language --REWRITE this part!-- */\n/* while (\n empty($lang) &&\n preg_match('([a-z][a-z](-[A-Z][A-Z])?)', $accept, $res)\n ) {\n $lang = $res[1];\n $accept = ereg_replace(\"$lang\", '', $accept);\n } */\n }\n }\n\n if (!isset($lang) || !file_exists(BASEDIR . $lang . '/index.php')) {\n /* Use English as default */\n $lang = 'en';\n }\n\n /* Set the cookie only for the default path / but not e.g., /fr/ */\n if (!isset($dirlang))\n setcookie('cooklang', $lang, time() + 31536000);\n\n return $lang;\n}", "function lixgetlang() {\n $lang = 'rus';\n \n if ($_GET[lang] != 'rus' && $_GET[lang] != 'eng' && $_GET[lang] != 'deu') {\n if (lixlpixel_detect_lang() != 'ru') { $lang = 'eng'; }\n else { $lang = 'rus'; }\n } else {\n $lang = $_GET[lang];\n }\n \n return $lang;\n}", "public static function getLanguage() {\n $settings = self::getSettings();\n \n return $settings->language;\n }", "function lang()\n {\n global $CFG; \n $language = $CFG->item('language');\n \n $lang = array_search($language, $this->languages);\n if ($lang)\n {\n return $lang;\n }\n \n return NULL; // this should not happen\n }", "protected function getLanguageParameter() {}", "private function _detectLanguage() {\n if (isset($_GET['language']) && is_file('lang/'. $_GET['language'] .'.lang.php'))\n return $_GET['language'];\n\n $session = PHPSession::getInstance();\n\n if (isset($session['language']))\n return $session['language'];\n\n return $this->_getWebBrowserLanguage();\n }", "public function getLocale($lang = \"\")\n {\n if(!in_array($lang, getAvailableLanguages())) $lang = DEFAULT_LANG;\n if($this->lang == $lang)\n {\n return;\n }\n\n global $sDB;\n $this->lang = $lang;\n\n if(LANG_USE_CACHE && file_exists($this->getTemplateRootAbs().\"lang_\".$lang.\".php\"))\n {\n $langCache = file_get_contents($this->getTemplateRootAbs().\"lang_\".$lang.\".php\");\n if(strlen($langCache) > 3)\n {\n $langCache = unserialize(substr($langCache, 3));\n if(is_array($langCache))\n {\n foreach($langCache as $key => $val)\n {\n $this->LANG_SET[$key] = $val;\n }\n return;\n }\n }\n }\n\n // load global language variables e.g. \"de\" for \"deDE\"\n $res = $sDB->execLocalization(\"SELECT * FROM `localization` WHERE `loc_language` = '\".mysql_real_escape_string(substr($lang, 0, 2)).\"';\");\n while($row = mysql_fetch_object($res))\n {\n $this->LANG_SET[$row->loc_key] = $row->loc_val;\n }\n\n // load country specific overrides\n $res = $sDB->execLocalization(\"SELECT * FROM `localization` WHERE `loc_language` = '\".mysql_real_escape_string($lang).\"';\");\n while($row = mysql_fetch_object($res))\n {\n $this->LANG_SET[$row->loc_key] = $row->loc_val;\n }\n }", "function getLanguageName() {\n global $CONF, $member;\n\n if ($member && $member->isLoggedIn() ) {\n // try to use members language\n $memlang = $member->getLanguage();\n\n if (($memlang != '') && (checkLanguage($memlang) ) ) {\n return $memlang;\n }\n }\n\n // use default language\n if (checkLanguage($CONF['Language']) ) {\n return $CONF['Language'];\n } else {\n return 'english';\n }\n}", "protected function getLanguage() {\r\n\t\treturn $this->language;\r\n\t}", "public function getLang()\n {\n return $this->lang;\n }", "public function getLang()\n {\n return $this->lang;\n }", "function getLang() {\n\t\treturn $this->mLang;\n\t}", "protected function _getCurrentLanguage()\n {\n $availableLanguages = $this->_translate->getOptions('availableLanguage');\n if (sizeof($availableLanguages)) {\n $lang = $this->_request->getParam('lang');\n if (!is_null($lang) && in_array($lang, $availableLanguages)) {\n return $lang;\n }\n }\n\n if (isset($this->_session->lang)) {\n return $this->_session->lang;\n }\n\n return $this->_translate->getLocale();\n }", "public function getLang()\n\t{\n\t\treturn $this->pageLanguage;\n\t}", "function get_locale() {\n \n global $CONF;\n \n if( isset( $CONF ) ) {\n \t\t$supported_languages\t\t= $CONF['supported_languages'];\n } else {\n \t\t$supported_languages\t\t= array ('de', 'de_DE', 'en', 'en_US');\t\n }\n \n $lang_array \t\t\t\t\t\t= preg_split ('/(\\s*,\\s*)/', $_SERVER['HTTP_ACCEPT_LANGUAGE']);\n \n if (is_array ($lang_array)) {\n \n $lang_first \t\t\t\t\t= strtolower ((trim (strval ($lang_array[0]))));\n $lang_parts\t\t\t\t\t= explode( '-', $lang_array[0] );\n $count\t\t\t\t\t\t= count( $lang_parts );\n if( $count == 2 ) {\n \t\n \t\t$lang_parts[1]\t\t\t= strtoupper( $lang_parts[1] );\n \t\t$lang_first\t\t\t\t= implode( \"_\", $lang_parts );\n }\n \n if (in_array ($lang_first, $supported_languages)) {\n \n $lang \t\t\t\t\t\t= $lang_first;\n \n } else {\n \n $lang \t\t\t\t\t\t= $CONF['default_locale'];\n \n }\n \n } else {\n \n $lang\t\t\t\t\t\t\t = $CONF['default_locale'];\n \n }\n \n return $lang;\n}", "public function getLanguage()\n {\n return self::$language;\n }", "public function getLang()\n {\n return $this->_lang;\n }", "public function get_language() {\n return $this->_language;\n }", "function getUserLang($allowedLangs, $fallbackLang)\n{\n // reset user_lang array\n $userLangs = [];\n // 2nd highest priority: GET parameter 'lang'\n if (isset($_GET['lang']) && is_string($_GET['lang'])) {\n $userLangs[] = $_GET['lang'];\n }\n // 3rd highest priority: SESSION parameter 'lang'\n if (isset($_SESSION['lang']) && is_string($_SESSION['lang'])) {\n $userLangs[] = $_SESSION['lang'];\n }\n // 4th highest priority: HTTP_ACCEPT_LANGUAGE\n if (isset($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n foreach (explode(',', $_SERVER['HTTP_ACCEPT_LANGUAGE']) as $part) {\n $userLangs[] = strtolower(substr($part, 0, 2));\n }\n }\n // Lowest priority: fallback\n $userLangs[] = $fallbackLang;\n foreach ($allowedLangs as $al) {\n if ($userLangs[0] == $al) {\n return $al;\n }\n }\n return $fallbackLang;\n}", "function language($lang)\n\t{\n\t\treturn lava_instance()->lang->language($lang);\n\t}", "public function getUrlLanguage() {\n return $this->storedLanguage;\n }", "protected function _getDefaultLanguage()\n {\n \t$config = $this->getOptions();\n $languageList = array_keys($config['languages']);\n\n\n \t$defaultLanguage= '';\n \tif (array_key_exists('language', $_COOKIE)) {\n \t\t$defaultLanguage = $_COOKIE['language'];\n \t} else {\n \t$zl = new Zend_Locale();\n \t$defaultLanguage = $zl->getLanguage();\n \t}\n\n $defaultLanguage = in_array($defaultLanguage, $languageList)? $defaultLanguage: 'en';\n\n return $defaultLanguage;\n }", "public function getLanguage()\n\t{\n\t\treturn $this->language ?: config('laraform.language');\n\t}", "function themes_get_language($script = 'global')\n{\n}", "function signup_get_available_languages()\n {\n }", "private function getLanguageId()\n {\n $languageId = \"\";\n if (isset($_SESSION['Shopware'][\"Auth\"]->localeID) && $_SESSION['Shopware'][\"Auth\"]->localeID != \"\") {\n $languageId = $_SESSION['Shopware'][\"Auth\"]->localeID;\n }\n return $languageId;\n }", "public static function getLanguage() {\n\t\tglobal $current_user, $default_language;\n\t\tif (!empty($current_user) && !empty($current_user->column_fields['language'])) {\n\t\t\treturn $current_user->column_fields['language'];\n\t\t}\n\t\t// Fallback : Read the Accept-Language header of the request (really useful for login screen)\n\t\tif (!empty($_SERVER['HTTP_ACCEPT_LANGUAGE'])) {\n\t\t\t//Getting all languages in an array\n\t\t\t$languages = Vtiger_LanguageExport::getAll();\n\t\t\t//Extracting locales strings from header\n\t\t\tpreg_match_all(\"/([a-z-]+)[,;]/i\", $_SERVER['HTTP_ACCEPT_LANGUAGE'], $locales);\n\t\t\t//Looping in found locales and test match against languages\n\t\t\tforeach ($locales[1] as $locale) {\n\t\t\t\tforeach ($languages as $code => $lang) {\n\t\t\t\t\t//First case insensitive comparison\n\t\t\t\t\tif (strcasecmp($code, $locale) === 0) {\n\t\t\t\t\t\treturn $code;\n\t\t\t\t\t}\n\t\t\t\t\t//Second case with replacing '-' by '_'\n\t\t\t\t\tif (strcasecmp($code, str_replace('-', '_', $locale)) === 0) {\n\t\t\t\t\t\treturn $code;\n\t\t\t\t\t}\n\t\t\t\t\t//Finally, try with short 2 letters country code\n\t\t\t\t\tif (strcasecmp(substr($code, 0, 2), $locale) === 0) {\n\t\t\t\t\t\treturn $code;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t// Last fallback : global configuration\n\t\treturn $default_language;\n\t}", "private function lang($string='')\n {\n return $this->language->get($string);\n }", "public function getBackOfficeLanguage();", "function getRespectSysLanguage() ;", "protected static function getLanguageService() {}", "public function get_current_lang() {\n return \\Drupal::languageManager()->getCurrentLanguage()->getId();\n }", "public function language(){\n\t\tdefined('MGK_LANGUAGE')\n\t\t || define('MGK_LANGUAGE', $this->lang );\n\n\t\t$language = MGK_LANGUAGE;\t\n\t\t$file_lang = MGK_APPLICATION_DIRECTORY.'/_language/'.$language.'.json';\n\t\t$this->mgkLang = new Amaguk_lang( $language );\t\t\t\n\t\t$this->mgkLang->read_lang($file_lang);\t\t\t\n\t}", "protected function _set_current_language()\n\t{\n\t\t$folder = NULL;\n\n\n\t\t// If the use of COOKIES is enabled, we check the cookie\n\t\tif ($cookie = $this->CI->input->cookie($this->cookie, TRUE))\n\t\t{\n\t\t\t$folder = $cookie;\n\t\t\tunset($cookie);\n\t\t}\n\n\t\t// In case we use SESSION instead of COOKIE\n\t\telseif ($this->session !== NULL)\n\t\t{\n\t\t\t$folder = $this->CI->session->{$this->session};\n\t\t\t$folder OR $folder = $this->client['folder'];\n\t\t}\n\n\t\t// If neither COOKIE nor SESSION are used, we use\n\t\t// default language\n\t\telse\n\t\t{\n\t\t\t$folder = $this->client['folder'];\n\t\t}\n\n\t\t// We prepare our default language\n\t\t$current = $this->default;\n\n\t\t// We make sure the language is available\n\t\tif ($lang = $this->find_by('folder', $folder))\n\t\t{\n\t\t\t$current = $lang;\n\t\t\tunset($lang);\n\t\t}\n\n\t\t// We set COOKIE if enabled\n\t\tif ($this->cookie !== NULL)\n\t\t{\n\t\t\t$this->CI->input->set_cookie($this->cookie, $current['folder'], 2678400);\n\t\t}\n\n\t\t// If no cookie but session is ON\n\t\telseif ($this->session !== NULL)\n\t\t{\n\t\t\t$_SESSION[$this->session] = $current['folder'];\n\t\t}\n\n\t\treturn $current;\n\t}", "public static function getUserLocale()\n {\n $lang_id = Auth::user()->lang_id;\n $locale = ($lang_id == 1) ? 'en' : 'ar';\n Session::put('locale', $locale);\n return $locale;\n }", "function default_lang()\n {\n $browser_lang = !empty($_SERVER['HTTP_ACCEPT_LANGUAGE']) ? strtok(strip_tags($_SERVER['HTTP_ACCEPT_LANGUAGE']), ',') : '';\n $browser_lang = substr($browser_lang, 0,2);\n if(array_key_exists($browser_lang, $this->languages))\n return $browser_lang;\n else{\n reset($this->languages);\n return key($this->languages);\n }\n }", "private function setLang(){\n\n\t\tif( isset($_GET['lang']) )\n\t\t\t$lang\t= $_GET['lang'];\n\n\t\telse{\n\t\t\t$sess_lang\t= session('lang');\n\t\t\t$lang\t\t= $sess_lang ? $sess_lang : App::getLocale();\n\t\t}\n\n\t\tsession(['lang'=>$lang]);\n\t\tApp::setLocale( $lang );\n\t}", "protected function getLanguage()\n {\n return $this->localeHeper->getLanguage();\n }", "public function lang()\n {\n return $this->currlang();\n }", "public function getCurrentLanguage()\n {\n return self::$current_language;\n }", "function GetDefaultLang() : string\n{\n return 'ar';\n}", "function check_language () {\n \n global $CONF;\n $supported_languages \t\t\t= array ('de', 'en');\n $lang_array \t\t\t\t\t\t= preg_split ('/(\\s*,\\s*)/', $_SERVER['HTTP_ACCEPT_LANGUAGE']);\n \n if (is_array ($lang_array)) {\n \n $lang_first \t\t\t\t\t= strtolower ((trim (strval ($lang_array[0]))));\n $lang_first \t\t\t\t\t= substr ($lang_first, 0, 2);\n \n if (in_array ($lang_first, $supported_languages)) {\n \n $lang \t\t\t\t\t\t= $lang_first;\n \n } else {\n \n $lang \t\t\t\t\t\t= $CONF['default_language'];\n \n }\n } else {\n \n $lang\t\t\t\t\t\t\t = $CONF['default_language'];\n \n }\n \n return $lang;\n}", "public function getLanguage($controller);" ]
[ "0.8492926", "0.8411261", "0.8227795", "0.815557", "0.81290233", "0.8065087", "0.8047373", "0.80407894", "0.7973908", "0.794257", "0.79248923", "0.78895915", "0.7874101", "0.7873251", "0.7864251", "0.7864251", "0.7864251", "0.7864251", "0.7864251", "0.7864251", "0.780712", "0.7799282", "0.7777856", "0.7772115", "0.7756748", "0.7734071", "0.76682496", "0.7642929", "0.7612048", "0.75962466", "0.75811607", "0.75518006", "0.7480124", "0.7480124", "0.7480124", "0.7466548", "0.74656886", "0.7460783", "0.7456381", "0.745559", "0.74422073", "0.7435726", "0.7431952", "0.7431813", "0.7416285", "0.7413669", "0.74013954", "0.7393831", "0.73913264", "0.7375836", "0.7371768", "0.7369976", "0.7355834", "0.7355834", "0.7352186", "0.73476356", "0.7343619", "0.73228526", "0.7317538", "0.73016596", "0.7293852", "0.7282817", "0.72723305", "0.72598696", "0.7256626", "0.72548556", "0.72536206", "0.72536206", "0.72226727", "0.7222661", "0.7211999", "0.7210605", "0.72099656", "0.7202536", "0.71921146", "0.718873", "0.7182746", "0.71740234", "0.71722454", "0.71678054", "0.7162922", "0.71391815", "0.7132841", "0.7131393", "0.7129788", "0.71154654", "0.71137685", "0.7112219", "0.7107557", "0.7089708", "0.70792276", "0.706436", "0.7061443", "0.70524293", "0.7050433", "0.7049334", "0.70485675", "0.70485175", "0.7030632", "0.70286226" ]
0.77436715
25
write new language to session and to the database
protected function setLanguage($languageId) { $_SESSION['lang'] = (int)$languageId; if ($this->user->id && (empty($this->user->languageId) || $this->user->languageId != $languageId)) { $this->user->set(['languageId' => $languageId], $this->user->id); } Registry::set('lang', $_SESSION['lang']); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function saveLanguage()\n\t{\n\t\t$language = Piwik_Common::getRequestVar('language');\n\t\t$currentUser = Piwik::getCurrentUserLogin();\n\t\t$session = new Zend_Session_Namespace(\"LanguagesManager\");\n\t\t$session->language = $language;\n\t\tif($currentUser !== 'anonymous')\n\t\t{\n\t\t\tPiwik_LanguagesManager_API::setLanguageForUser($currentUser, $language);\n\t\t}\n\t\tPiwik_Url::redirectToReferer();\n\t}", "public function save()\r\n\t{\r\n\t\t// Check for request forgeries\r\n\t\tJRequest::checkToken() or die( 'Invalid Token' );\r\n\r\n\t\t$post\t= JRequest::get('post');\r\n\t\t$cid \t= JRequest::getVar( 'cid', array(), 'post', 'array' );\r\n\t\tJArrayHelper::toInteger($cid);\r\n\t\t\r\n\t\t$model = $this->getModel('languages');\r\n\t\t\r\n\t\tif ($model->store($cid, $post)) {\r\n\t\t\t$msg = JText::_( 'LANGUAGES_SAVED' );\r\n\t\t} else {\r\n\t\t\t$msg = JText::_( 'Error Saving Languages:' .$model->getErrors());\r\n\t\t}\r\n\r\n\t\t// Check the table in so it can be edited.... we are done with it anyway\r\n\t\t$link = 'index.php?option=com_joomfish';\r\n\t\t$this->setRedirect($link, $msg);\r\n\t}", "public function save_translation($lang)\n {\n\n if ($this->session->userdata(array('admin' => 'is_admin'))) {\n if (!$this->Madmin->change_language_translation($lang, $_POST['key'], $_POST['val'])) {\n json(array('error' => 'Unable to update language status'));\n } else {\n json(array('success' => 'Language status changed'));\n }\n } else {\n json(array('error' => 'Please login first!'));\n }\n }", "private function saveTranslateConfig(){\r\n\t\t// Check for request forgeries\r\n\t\tJRequest::checkToken() or die( 'Invalid Token' );\r\n\r\n\t\t$lang_id \t= JRequest::getInt( 'lang_id',0 );\r\n\t\t$model = $this->getModel('languages');\r\n\t\t$language = $model->getTable('JFLanguage');\t\t\r\n\t\t$language->load($lang_id);\r\n\r\n\t\tif (is_null($lang_id) || !isset($language->id) || $language->id<=0){\r\n\t\t\tdie( 'Invalid Language Id' );\r\n\t\t}\r\n\t\t\r\n\t\t$data = array();\r\n\t\tforeach ($_REQUEST as $key=>$val) {\r\n\t\t\tif (strpos($key,\"trans_\")===0){\r\n\t\t\t\t$key = str_replace(\"trans_\",\"\",$key);\r\n\t\t\t\tif (ini_get('magic_quotes_gpc')) {\r\n \t\t $val = stripslashes($val);\r\n \t\t} \r\n \t\t$data[$key]=$val;\r\n\t\t\t}\r\n\t\t}\r\n\t\t$registry = new JRegistry();\r\n\t\t$registry->loadArray($data);\r\n\t\t$language->params = $registry->toString();\r\n\r\n\t\t$language->store();\r\n\t\tJFactory::getApplication()->redirect(\"index.php?option=com_joomfish&task=languages.show\",JText::_( 'LANGUAGES_SAVED' ));\r\n\t}", "public function store(LanguageRequest $request)\n {\n $record = new Language;\n $record->name=$request->name;\n $record->is_valid=$request->is_valid;\n $record->icon=$request->icon;\n $record->slag=$request->slag;\n \n\n // Create and redirect\n $record->save();\n $request->session()->flash('message', 'Η γλώσσα αποθηκεύτηκε επιτυχώς!');\n return redirect('/language');\n }", "public function store(LanguageRequest $request)\n {\n $addLanguage = $request->all();\n\n $locales = $this->manager->getLocales();\n\n $newLocale = str_replace([], '-', trim($request->input('code')));\n if (!$newLocale || in_array($newLocale, $locales)) {\n return redirect()->back();\n }\n\n $locale = Config::get('translatable.locales');\n $setLocale = array_push($locale, $newLocale);\n Config::set('translatable.locales', [$setLocale]);\n\n\n $this->manager->addLocale($newLocale);\n Language::create($addLanguage);\n\n return redirect(route('admin.language.index'))->with(_sessionmessage());\n }", "public function storeLanguage(Request $request){\n $user = auth()->user()->employee_id;\n\n // Get the language selected by the user and update the employees table\n $language = $request->language;\n DB::update('update employees set language = :lang where id = :id',\n ['lang' => $language, 'id' => $user]);\n\n return redirect()->route('specialist_lang');\n }", "public function language()\n {\n \tif ( is_english() ){\n\t\t $this->session->engels = false;\n\t } else {\n\t\t $this->session->engels = true;\n }\n\t redirect($this->agent->referrer());\n }", "public function set_session_language()\n {\n $language = $this->input->post('language');\n $this->session->language = $language;\n $results['success'] = true;\n echo json_encode($results);\n die();\n }", "public function process_lang_change()\n {\n if (!isset($_POST['lang']) || !$_POST['lang']) {\n wp_send_json_error();\n }\n\n if (!session_id()) {\n session_start();\n }\n\n try {\n // Include Esc functions\n include_once(\\Esc::directory() . '/modules/general.php');\n include_once(\\Esc::directory() . '/includes/connect.php');\n\n if (!isset($_SESSION['esc_store']['selection_id'])) {\n \\EscConnect::getSelection();\n }\n\n $selection = \\EscConnect::init('selections/' . $_SESSION['esc_store']['selection_id'] . '/languages/' . $_POST['lang'])->put();\n\n if (!$selection || isset($selection['errors'])) {\n wp_send_json_error();\n }\n\n $_SESSION['esc_selection'] = $selection;\n\n wp_send_json_success();\n } catch (\\Exception $exp) {\n wp_send_json_error($exp->getMessage());\n }\n }", "public function add_language()\n {\n\n if ($this->session->userdata(array('admin' => 'is_admin'))) {\n $this->load_header();\n $this->vars['country_flags'] = $this->Madmin->load_country_images();\n if (isset ($_POST['add_language'])) {\n if ($_POST['name'] == '') {\n $this->vars['error'] = 'Please enter language name.';\n } else {\n if ($_POST['title'] == '') {\n $this->vars['error'] = 'Please enter language title.';\n } else {\n if ($this->Madmin->add_language($_POST)) {\n header('Location: ' . $this->config->base_url . 'admincp/edit-language/' . $_POST['name']);\n } else {\n $this->vars['error'] = $this->Madmin->error;\n }\n }\n }\n }\n $this->load->view('admincp' . DS . 'language_manager' . DS . 'view.add_language', $this->vars);\n $this->load_footer();\n } else {\n json(array('error' => 'Please login first!'));\n }\n }", "public function actionChangeLanguage()\n {\n $lang = Yii::$app->request->post('lang');\n\n $session = Yii::$app->session;\n $session->set('language', $lang ?? 'en');\n\n $query = Language::findOne(['code' => $lang]);\n\n if ($query) {\n Yii::$app->user->identity->language_id = $query->code;\n Yii::$app->user->identity->save();\n }\n\n return $this->redirect(Yii::$app->request->referrer ?: Yii::$app->homeUrl);\n }", "public function store(LanguageRequest $request)\n {\n LanguageOp::_store($request);\n toastr()->success(trans('local.saved_success'));\n return redirect()->route('languages.index');\n }", "public function store(LanguageRequest $request)\n {\n $data = $request->getData();\n Language::create($data);\n return redirect('jobseeker/language');\n }", "public function save()\n {\n $this->user->setCulture($this->getValue('language'));\n }", "public function saveLanguage($data = array()) {\n if(empty($data)) {\n return false;\n }\n\n $this->verifyUpdateDefault($data);\n $data['added_by'] = Auth::user()->id;\n\n return Language::create($data);\n }", "function set_lang ($lang)\r\n {\r\n $_SESSION[\"lang\"] = $lang;\r\n }", "private function setLang(){\n\n\t\tif( isset($_GET['lang']) )\n\t\t\t$lang\t= $_GET['lang'];\n\n\t\telse{\n\t\t\t$sess_lang\t= session('lang');\n\t\t\t$lang\t\t= $sess_lang ? $sess_lang : App::getLocale();\n\t\t}\n\n\t\tsession(['lang'=>$lang]);\n\t\tApp::setLocale( $lang );\n\t}", "public function store(CreateLanguageRequest $request)\n\t{\n\t \n\t\tLanguage::create($request->all());\n\n\t\treturn redirect()->route(config('quickadmin.route').'.language.index');\n\t}", "public function store(LanguageRequest $request)\n {\n $model = new LanguageModel($request->all());\n\n $model->save();\n\n return redirect('admin/language');\n }", "public static function en(){\n setcookie('language', 'en', time()+60);\n }", "public function setLanguage(Request $request){\n\n $request->session()->forget('app_language');\n session(['app_language' => $request->lang]);\n $cookie_id = $_COOKIE['gdoox_global_val'];\n\n if(Auth::user()){\n $data = UserLanguagePreference::where('user_id', Auth::user()->id)->orWhere('cookie_id', $cookie_id)->first();\n if(!empty($data)){\n $data->language = $request->lang;\n $data->user_id = Auth::user()->id;\n $data->save();\n if($request->session()->has('app_language')){\n return ['success' => true];\n }\n else {\n return ['success' => false];\n }\n }\n else {\n $data = new UserLanguagePreference();\n $data->user_id = Auth::user()->id;\n $data->language = $request->lang;\n $data->cookie_id = $cookie_id;\n $data->save();\n if($request->session()->has('app_language')){\n return ['success' => true];\n }\n else {\n return ['success' => false];\n }\n }\n }\n else {\n if(!empty($cookie_id)){\n $data = UserLanguagePreference::where('cookie_id', $cookie_id)->first();\n if(!empty($data)){\n $data->language = $request->lang;\n $data->save();\n if($request->session()->has('app_language')){\n return ['success' => true];\n }\n else {\n return ['success' => false];\n }\n }\n }\n else {\n $timestamp = time();\n $cookie_value = UUID::v4() . \"-\" . $timestamp;\n setcookie('gdoox_global_val', $cookie_value, time() + (86400 * 30), \"/\");\n $data = new UserLanguagePreference();\n $data->user_id = '';\n $data->language = $request->lang;\n $data->cookie_id = $cookie_id;\n $data->save();\n if($request->session()->has('app_language')){\n return ['success' => true];\n }\n else {\n return ['success' => false];\n }\n }\n }\n \n \n }", "public function store(Request $request)\n {\n $this->validate($request, [\n 'language' \t=> 'bail|required|max:40|unique:languages,language',\n 'code' \t\t=> 'bail|required|max:4|unique:languages,code',\n 'is_rtl' \t \t=> 'bail|required'\n ]);\n \t$record = new Language();\n $name \t\t\t\t\t = $request->language;\n $record->language \t\t = $name;\n $record->slug \t\t\t = $record->makeSlug($name);\n $record->code\t\t\t\t\t = $request->code;\n $record->is_rtl\t\t\t\t\t= $request->is_rtl;\n $record->save();\n LanguageHelper::flash('success','record_added_successfully', 'success');\n \treturn redirect(URL_LANGUAGES_LIST);\n }", "function language() {\n\t// Flip the language and go back\n\tCakeLog::write('debug', 'language: ' . print_r($this->request->named, true));\n\t$language = $this->request->named['new_language'];\n\n\tif (!empty($language)) {\n\t $referer = Router::normalize($this->referer(null, true));\n\t $urlRoute = Router::parse($referer);\n\t $urlRoute['language'] = $language;\n\t $urlRoute['url'] = array();\n\t $this->log(Router::reverse($urlRoute));\n\t $url = Router::normalize(Router::reverse($urlRoute));\n\t $this->params['language'] = $language;\n\t $this->redirect($url);\n\t} else {\n\t $this->redirect($this->referer());\n\t}\n }", "public function changeEnglishLanguage(){\n Session::forget('lang');\n return back();\n }", "public function run()\n {\n $language=New Language();\n $language->name='español';\n $language->save();\n\n $language=New Language();\n $language->name='ingles';\n $language->save();\n\n $language=New Language();\n $language->name='tailandes';\n $language->save();\n }", "public function store(Request $request)\n {\n $request->flash();\n $this->_validateInsert($request);\n\n DB::beginTransaction();\n try {\n\n $this->languageModel->locale = $request->locale;\n $this->languageModel->name_display = $request->name_display;\n $this->languageModel->icon = $request->icon;\n $this->languageModel->description = $request->description;\n $this->languageModel->status = $request->status;\n\n $this->languageModel->save();\n DB::commit();\n return redirect()->route('languages.index')->with('languages', 'success');\n } catch (Exception $e) {\n DB::rollback();\n }\n }", "public function storeLanguagesVarsToDB(): void\n {\n foreach ($this->getDirsWithLanguages() as $lang => $dir) {\n $fs = new Filesystem();\n $files = $fs->files($dir);\n foreach ($files as $fileName) {\n $filePath = $dir . \"/\" . $fileName->getRelativePathname();\n $array = (file_exists($filePath)) ? require($filePath) : [];\n $this->saveLanguageValueToDB(basename($fileName->getRelativePathname(), \".php\"), $lang, [], $array);\n }\n }\n }", "public static function ja(){\n setcookie('language', 'ja', time()+60);\n }", "public static function setLanguage($lid)\r\n {\r\n return session()->put(self::$sessLanguageKey, $lid);\r\n }", "function save( $id = false, $language_id =0 ) {\n\t\t// start the transaction\n\t\t$this->db->trans_start();\n\t\t\n\t\t/** \n\t\t * Insert Language Records \n\t\t */\n\t\t$data = array();\n\n\t\t// prepare language_id\n\t\tif ( $this->has_data( 'language_id' )) {\n\t\t\t$data['language_id'] = $this->get_data( 'language_id' );\n\t\t}\n\n\t\t// prepare key\n\t\tif ( $this->has_data( 'key' )) {\n\t\t\t$data['key'] = $this->get_data( 'key' );\n\t\t}\n\n\t\t// prepare value\n\t\tif ( $this->has_data( 'value' )) {\n\t\t\t$value = $this->get_data( 'value' );\n\t\t\t$data['value'] = htmlspecialchars_decode($value);\n\t\t}\n\n\n\t\t// save language\n\t\tif ( ! $this->Language_string->save( $data, $id )) {\n\t\t// if there is an error in inserting user data,\t\n\n\t\t\t// rollback the transaction\n\t\t\t$this->db->trans_rollback();\n\n\t\t\t// set error message\n\t\t\t$this->data['error'] = get_msg( 'err_model' );\n\t\t\t\n\t\t\treturn;\n\t\t}\n\t\t\n\t\t/** \n\t\t * Check Transactions \n\t\t */\n\n\t\t// commit the transaction\n\t\tif ( ! $this->check_trans()) {\n \t\n\t\t\t// set flash error message\n\t\t\t$this->set_flash_msg( 'error', get_msg( 'err_model' ));\n\t\t} else {\n\n\t\t\tif ( $id ) {\n\t\t\t// if user id is not false, show success_add message\n\t\t\t\t\n\t\t\t\t$this->set_flash_msg( 'success', get_msg( 'success_lang_str_edit' ));\n\t\t\t} else {\n\t\t\t// if user id is false, show success_edit message\n\n\t\t\t\t$this->set_flash_msg( 'success', get_msg( 'success_lang_str_add' ));\n\t\t\t}\n\t\t}\n\n\t\tredirect( site_url('admin/language_strings/'));\n\t}", "function saveTranslations()\n {\n // default language set?\n if (!isset($_POST[\"default\"]))\n {\n ilUtil::sendFailure($this->lng->txt(\"msg_no_default_language\"));\n return $this->editTranslations(true);\n }\n\n // all languages set?\n if (array_key_exists(\"\",$_POST[\"lang\"]))\n {\n ilUtil::sendFailure($this->lng->txt(\"msg_no_language_selected\"));\n return $this->editTranslations(true);\n }\n\n // no single language is selected more than once?\n if (count(array_unique($_POST[\"lang\"])) < count($_POST[\"lang\"]))\n {\n ilUtil::sendFailure($this->lng->txt(\"msg_multi_language_selected\"));\n return $this->editTranslations(true);\n }\n\n // save the stuff\n $this->ilObjectOrgUnit->removeTranslations();\n foreach($_POST[\"title\"] as $k => $v)\n {\n // update object data if default\n $is_default = ($_POST[\"default\"] == $k);\n if($is_default)\n {\n $this->ilObjectOrgUnit->setTitle(ilUtil::stripSlashes($v));\n $this->ilObjectOrgUnit->setDescription(ilUtil::stripSlashes($_POST[\"desc\"][$k]));\n $this->ilObjectOrgUnit->update();\n }\n\n $this->ilObjectOrgUnit->addTranslation(\n ilUtil::stripSlashes($v),\n ilUtil::stripSlashes($_POST[\"desc\"][$k]),\n ilUtil::stripSlashes($_POST[\"lang\"][$k]),\n $is_default);\n }\n\n ilUtil::sendSuccess($this->lng->txt(\"msg_obj_modified\"), true);\n $this->ctrl->redirect($this, \"editTranslations\");\n }", "public static function save($key, $value, $lang=null){\n\t\t\n\t\tif(!$lang){\n\t\t\t$lang = self::getLanguage();\n\t\t}\n\t\t\n\t\t$sql = new SqlManager();\n\t\t\n\t\t//Check if locale exists\n\t\t$sql->setQuery(\"\n\t\t\tSELECT locale_key FROM bd_sys_locale \n\t\t\tWHERE locale_key = '{{key}}' \n\t\t\tAND locale_language = '{{lang}}'\n\t\t\tLIMIT 1\");\n\t\t$sql->bindParam('{{key}}', $key);\n\t\t$sql->bindParam('{{lang}}', $lang, \"int\");\n\t\t$check = $sql->result();\n\t\t\n\t\t$loc = array(\n\t\t\t'locale_key' => $sql->escape($key),\n\t\t\t'locale_language' => $sql->escape($lang, \"int\"),\n\t\t\t'locale_text' => $sql->escape($value),\n\t\t\t'locale_lastchanged' => date(\"Y-m-d H:i:s\", time())\n\t\t);\n\n\t\t//Either update database or insert new entry for given locale\n\t\tif(!$check['locale_key']){\n\t\t\t$sql->insert(\"bd_sys_locale\", $loc);\n\t\t} else {\n\t\t\t$sql->update(\"bd_sys_locale\", $loc);\n\t\t}\n\t\t\n\t\t//Refresh cache to make sure new locale entry will be used\n\t\t$cachekey = \"locale:\" . $lang;\n\t\tCache::clearCache($cachekey);\n\t\tself::load($lang);\n\t}", "public function changeBanglaLanguage(){\n Session::put('lang',[\n 'lang_name' => 'bangla'\n ]);\n return back();\n }", "public function actionLanguageChanged() {\n\t\t$action = $_GET['action'];\n\t\tYii::app()->session['lang'] = $_GET['lang'];\n\t\tif (!Yii::app()->user->isGuest){\n\t\t\tYii::app()->user->lang = $_GET['lang'];\n\t\t}\n\t\tself::$trans=new Translations($_GET['lang']);\n\t\t\n\t\t$Session_Profiles_Backup = Yii::app()->session[$this->createBackup];\n\t\tif (isset($Session_Profiles_Backup)){\n\t\t\t$model = $Session_Profiles_Backup;\n\t\t} else {\n\t\t\tif ($action == 'register'){\n\t\t\t\t$model=new Profiles('register');\n\t\t\t} else {\n\t\t\t\t$model=new Profiles();\n\t\t\t}\n\t\t}\n\t\t$model->PRF_LANG = $_GET['lang'];\n\n\t\tYii::app()->session[$this->createBackup] = $model;\n\t\tif (isset($_GET['id'])){\n\t\t\t$this->redirect(array($action, 'id'=>$_GET['id']));\n\t\t} else {\n\t\t\t$this->redirect(array($action));\n\t\t}\n\t}", "public function set_session(Request $request) {\n\t\t if ($request->language) {\n\t\t\tSession::put('language', $request->language);\n\t\t\tApp::setLocale($request->language);\n\t\t}\n\t}", "function save_langfile()\n\t{\n\t\t//-----------------------------------------\n\n\t\tif ($this->ipsclass->input['id'] == \"\")\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Невозможно определить ID языка\");\n\t\t}\n\n\t\tif ($this->ipsclass->input['lang_file'] == \"\")\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Вы должны указать имя языкового модуля, вернитесь назад и попробуйте еще раз\");\n\t\t}\n\n\t\t$this->ipsclass->DB->simple_construct( array( 'select' => '*', 'from' => 'languages', 'where' => \"lid='\".$this->ipsclass->input['id'].\"'\" ) );\n\t\t$this->ipsclass->DB->simple_exec();\n\n\t\tif ( ! $row = $this->ipsclass->DB->fetch_row() )\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Невозможно найти язык по введенному ID\");\n\t\t}\n\n\t\t$lang_file = CACHE_PATH.\"cache/lang_cache/\".$row['ldir'].\"/\".$this->ipsclass->input['lang_file'];\n\n\t\tif (! file_exists( $lang_file ) )\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Невозможно найти файл '$lang_file', проверьте есть ли он.\");\n\t\t}\n\n\t\tif (! is_writeable( $lang_file ) )\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Невозможно записать в файл '$lang_file', проверьте права доступа (CHMOD) и, если необходимо установить права доступа 0777. IPB не может сделать это за вас\");\n\t\t}\n\n\t\t$barney = array();\n\n\t\tforeach ($this->ipsclass->input as $k => $v)\n\t\t{\n\t\t\tif ( preg_match( \"/^XX_(\\S+)$/\", $k, $match ) )\n\t\t\t{\n\t\t\t\tif ( isset($this->ipsclass->input[ $match[0] ]) )\n\t\t\t\t{\n\t\t\t\t\t$v = str_replace(\"&#39;\", \"'\", stripslashes($_POST[ $match[0] ]) );\n\t\t\t\t\t$v = str_replace(\"&#60;\", \"<\", $v );\n\t\t\t\t\t$v = str_replace(\"&#62;\", \">\", $v );\n\t\t\t\t\t$v = str_replace(\"&#38;\", \"&\", $v );\n\t\t\t\t\t$v = str_replace(\"\\r\", \"\", $v );\n\n\t\t\t\t\t$barney[ $match[1] ] = $v;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif ( count($barney) < 1 )\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Что-то сделано не так, вернитесь назад и попробуйте еще раз\");\n\t\t}\n\n\t\t$start = \"<?php\\n\\n\".'$lang = array('.\"\\n\";\n\n\t\tforeach($barney as $key => $text)\n\t\t{\n\t\t\t$text = preg_replace(\"/\\n{1,}$/\", \"\", $text);\n\t\t\t$start .= \"\\n'\".$key.\"' => \\\"\".str_replace( '\"', '\\\"', $text).\"\\\",\";\n\t\t}\n\n\t\t$start .= \"\\n\\n);\\n\\n?\".\">\";\n\n\t\tif ($fh = fopen( $lang_file, 'w') )\n\t\t{\n\t\t\tfwrite($fh, $start );\n\t\t\tfclose($fh);\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->ipsclass->admin->error(\"Нельзя сделать запись в $lang_file\");\n\t\t}\n\n\t\tif ( $this->ipsclass->input['id'] )\n\t\t{\n\t\t\t$this->ipsclass->admin->done_screen(\"Язык обновлен\", \"Управление языками\", \"{$this->ipsclass->form_code}&code=edit&id={$this->ipsclass->input['id']}\", 'redirect' );\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$this->ipsclass->admin->done_screen(\"Язык обновлен\", \"Управление языками\", \"{$this->ipsclass->form_code}\", 'redirect' );\n\t\t}\n\t}", "public function store(StoreLanguagesRequest $request)\n {\n if (! Gate::allows('language_create')) {\n return abort(401);\n }\n $language = Language::create($request->all());\n\n\n\n return redirect()->route('admin.languages.index');\n }", "public function languageAction() {\n\t\n\t\t//START LANGUAGE WORK\n\t\tEngine_Api::_()->getApi('language', 'sitestore')->languageChanges();\n\t\t//END LANGUAGE WORK\n\t\t$redirect = $this->_getParam('redirect', false);\n\t\tif($redirect == 'install') {\n\t\t\t$this->_redirect('install/manage');\n\t\t} elseif($redirect == 'query') {\n\t\t\t$this->_redirect('install/manage/complete');\n\t\t}\n\t}", "public function apply()\r\n\t{\r\n\t\t// Check for request forgeries\r\n\t\tJRequest::checkToken() or die( 'Invalid Token' );\r\n\r\n\t\t$post\t= JRequest::get('post');\r\n\t\t$cid \t= JRequest::getVar( 'cid', array(), 'post', 'array' );\r\n\t\tJArrayHelper::toInteger($cid);\r\n\t\t\r\n\t\t$model = $this->getModel('languages');\r\n\t\t\r\n\t\tif ($model->store($cid, $post)) {\r\n\t\t\t$msg = JText::_( 'LANGUAGES_SAVED' );\r\n\t\t} else {\r\n\t\t\t$msg = JText::_( 'ERROR_SAVING_LANGUAGES' );\r\n\t\t}\r\n\r\n\t\t// Check the table in so it can be edited.... we are done with it anyway\r\n\t\t$link = 'index.php?option=com_joomfish&task=languages.show';\r\n\t\t$this->setRedirect($link, $msg);\r\n\t}", "private function save() \n {\n $content = \"<?php\\n\\nreturn\\n[\\n\";\n\n foreach ($this->arrayLang as $this->key => $this->value) \n {\n $content .= \"\\t'\".$this->key.\"' => '\".$this->value.\"',\\n\";\n }\n\n $content .= \"];\";\n\n file_put_contents($this->path, $content);\n\n }", "public function set_lang($lang=NULL)\r {\r \t$CI =& get_instance();\r \t\r \t$CI->session->set_userdata('lang', $lang);\r\n \tredirect($_SERVER['HTTP_REFERER']);\r }", "public function store(Request $request)\n {\n language::create($request->all());\n return redirect('/admin')->with('status', 'Language berhasil ditambahkan!');\n }", "public function create()\n {\n $this->validate();\n\n $this->language->default = (bool) $this->language->default;\n\n $this->language->save();\n\n $this->notify(\n 'Language successfully created.',\n 'hub.languages.index'\n );\n }", "function add()\n\t{\n\t\t$data[\"title\"] = _e(\"Language\");\t\n\t\t$CFG = $this->config->item('language_configure');\n\t\t\n\t\t ## for check admin or not\t ##\t\n\t\t$data[\"response\"] = addPermissionMsg( $CFG[\"sector\"][\"add\"] );\t\t\t\n\t\t\t\t\t\n\t\t## Other auxilary variable ##\n\t\t$data['var'] = array();\t\t\t\t\n\t\t$data[\"top\"] = $this->template->admin_view(\"top\", $data, true, \"language\");\t\n\t\t$data[\"content\"] = $this->template->admin_view(\"language_add\", $data, true, \"language\");\n\t\t$this->template->build_admin_output($data);\n\t}", "function saveSession() {}", "private function changeLangFileContent() \n {\n $this->read();\n $this->arrayLang[$this->key] = $this->value;\n $this->save();\n }", "public function createSession(string $language): ForeignSession\n {\n $created = (int)time();\n $last_updated = $created;\n $session_id = Hashing::foreignSessionId($language, $created);\n $session_id = $this->coffeeHouse->getDatabase()->real_escape_string($session_id);\n $headers = $this->coffeeHouse->getDatabase()->real_escape_string(ZiProto::encode(array()));\n $cookies = $this->coffeeHouse->getDatabase()->real_escape_string(ZiProto::encode(array()));\n $variables = $this->coffeeHouse->getDatabase()->real_escape_string(ZiProto::encode(array()));\n $language = $this->coffeeHouse->getDatabase()->real_escape_string($language);\n $available = (int)true;\n $messages = 0;\n $expires = $created + 10800;\n\n $Query = QueryBuilder::insert_into('foreign_sessions', array(\n 'session_id' => $session_id,\n 'headers' => $headers,\n 'cookies' => $cookies,\n 'variables' => $variables,\n 'language' => $language,\n 'available' => $available,\n 'messages' => $messages,\n 'expires' => $expires,\n 'last_updated' => $last_updated,\n 'created' => $created\n ));\n $QueryResults = $this->coffeeHouse->getDatabase()->query($Query);\n if($QueryResults)\n {\n return($this->getSession(ForeignSessionSearchMethod::bySessionId, $session_id));\n }\n else\n {\n throw new DatabaseException($this->coffeeHouse->getDatabase()->error);\n }\n }", "public function store(StoreLanguagesRequest $request)\n {\n Language::create($request->all());\n\n return redirect()->route('languages.index');\n }", "public function store(LanguageRequest $request)\n {\n /*Input oculto para distinguir entre store y update*/\n $id_query = $request->input('id');\n $language = $request->input();\n $language_id = \\DB::table('languages')->where('language' , $language['language'])->value('id');\n\n if ($id_query == 0) {\n \n try {\n $queries = \\DB::table('studentlanguages')\n ->join('languages','studentlanguages.language_id','=','languages.id')\n ->join('students','studentlanguages.student_id','=','students.id')\n ->where('student_id',$this->student_id)\n ->insert(['readingComprehension' => $language['readingComprehension'],\n 'WrittedExpression' => $language['WrittedExpression'],\n 'listeningComprehension' => $language['listeningComprehension'],\n 'oralExpression' => $language['oralExpression'],\n 'language_id' => $language_id,\n 'student_id' => $this->student_id,\n 'created_at' => date('YmdHms')]); \n Session::flash('type',\"success\");\n Session::flash(\"insert\",\"Idioma guardado\");\n\n }\n catch(\\PDOException $e) {\n if($e->getCode() == 2002) {\n Session::flash('type',\"danger\");\n Session::flash('insert', \"No se ha podido guardar el idioma.\");\n } else {\n Session::flash('type',\"danger\");\n Session::flash(\"insert\",\"Ya tienes guardado ese idioma\");\n }\n }\n }else{\n try {\n $queries = \\DB::table('studentlanguages')\n ->join('languages','studentlanguages.language_id','=','languages.id')\n ->join('students','studentlanguages.student_id','=','students.id')\n ->where('student_id',$this->student_id)\n ->where('studentlanguages.id',$id_query)\n ->update(['readingComprehension' => $language['readingComprehension'],\n 'WrittedExpression' => $language['WrittedExpression'],\n 'listeningComprehension' => $language['listeningComprehension'],\n 'oralExpression' => $language['oralExpression'],\n 'language_id' => $language_id,\n 'student_id' => $this->student_id]);\n Session::flash('type',\"success\");\n Session::flash('insert', \"Idioma modificado\");\n\n } catch(\\PDOException $e) {\n if($e->getCode() == 2002) {\n Session::flash('type',\"danger\");\n Session::flash('insert', \"No se ha podido guardar el debido a un problema de comunicación.\");\n } \n }\n }\n return redirect('estudiante/curriculum'); \n}", "function ajax_addLanguage( $data )\n\t{\n\t\tglobal $_response;\n\n\t\t// check admin session expire\n\t\tif ( $this -> checkSessionExpire() === false )\n\t\t{\n\t\t\t$redirect_url = RL_URL_HOME . ADMIN .\"/index.php\";\n\t\t\t$redirect_url .= empty($_SERVER['QUERY_STRING']) ? '?session_expired' : '?'. $_SERVER['QUERY_STRING'] .'&session_expired';\n\t\t\t$_response -> redirect( $redirect_url );\n\t\t}\n\t\t\n\t\tloadUTF8functions('ascii', 'utf8_to_ascii', 'unicode');\n\t\t$lang_name = $lang_key = $this -> rlValid -> xSql( str_replace( array( '\"', \"'\" ), array( '', '' ), $data[0][1] ) );\n\t\t\n\t\tif ( empty($lang_name) )\n\t\t{\n\t\t\t$error[] = $GLOBALS['lang']['name_field_empty'];\n\t\t}\n\t\t\n\t\tif ( !utf8_is_ascii( $lang_name ) )\n\t\t{\n\t\t\t$lang_key = utf8_to_ascii( $lang_name );\n\t\t}\n\t\t\n\t\t$lang_key = strtolower( str_replace( array( '\"', \"'\" ), array( '', '' ), $lang_key ) );\n\t\t\n\t\t$iso_code = $this -> rlValid -> xSql( $data[1][1] );\n\t\t\n\t\tif ( !utf8_is_ascii( $iso_code ) )\n\t\t{\n\t\t\t$error = $GLOBALS['lang']['iso_code_incorrect_charset'];\n\t\t}\n\t\telse \n\t\t{\n\t\t\tif ( strlen( $iso_code )!= 2 )\n\t\t\t{\n\t\t\t\t$error[] = $GLOBALS['lang']['iso_code_incorrect_number'];\n\t\t\t}\n\t\t\t\n\t\t\t//check language exist\n\t\t\t$lang_exist = $this -> fetch( '*', array( 'Code' => $iso_code ), null, null, 'languages' );\n\n\t\t\tif ( !empty( $lang_exist ) )\n\t\t\t{\n\t\t\t\t$error[] = $GLOBALS['lang']['iso_code_incorrect_exist'];\n\t\t\t}\n\t\t}\n\n\t\t/* check direction */\n\t\t$direction = $data[4][1];\n\t\t\n\t\tif ( !in_array($direction, array('rtl', 'ltr')) )\n\t\t{\n\t\t\t$error[] = $GLOBALS['lang']['text_direction_fail'];\n\t\t}\n\t\t\n\t\t/* check date format */\n\t\t$date_format = $this -> rlValid -> xSql( $data[2][1] );\n\t\t\n\t\tif ( empty($date_format) || strlen($date_format) < 5 )\n\t\t{\n\t\t\t$error[] = $GLOBALS['lang']['language_incorrect_date_format'];\n\t\t}\n\t\t\n\t\tif ( !empty($error) )\n\t\t{\n\t\t\t/* print errors */\n\t\t\t$error_content = '<ul>';\n\t\t\tforeach ($error as $err)\n\t\t\t{\n\t\t\t\t$error_content .= \"<li>{$err}</li>\";\n\t\t\t}\n\t\t\t$error_content .= '</ul>';\n\t\t\t$_response -> script( 'printMessage(\"error\", \"'. $error_content .'\")' );\n\t\t}\n\t\telse \n\t\t{\n\t\t\t/* get & optimize new language phrases*/\n\t\t\t$source_code = $this -> rlValid -> xSql( $data[3][1] );\n\t\t\t$this -> setTable( 'lang_keys' );\n\t\t\t\n\t\t\t$source_phrases = $this -> fetch( '*', array( 'Code' => $source_code ) );\n\t\n\t\t\tif ( !empty($source_phrases) )\n\t\t\t{\n\t\t\t\t$step = 1;\n\t\t\t\t\n\t\t\t\tforeach ( $source_phrases as $item => $row )\n\t\t\t\t{\n\t\t\t\t\t$insert_phrases[$item] = $source_phrases[$item];\n\t\t\t\t\t$insert_phrases[$item]['Code'] = $iso_code;\n\t\t\t\t\n\t\t\t\t\tunset( $insert_phrases[$item]['ID'] );\n\t\t\t\t\t\t\n\t\t\t\t\tif ($step % 500 == 0)\n\t\t\t\t\t{\n\t\t\t\t\t\t$this -> rlActions -> insert( $insert_phrases, 'lang_keys' );\n\t\t\t\t\t\tunset($insert_phrases);\n\t\t\t\t\t\t$step = 1;\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$step++;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\tif ( !empty($insert_phrases) )\n\t\t\t\t{\n\t\t\t\t\t$this -> rlActions -> insert( $insert_phrases, 'lang_keys' );\n\t\t\t\t}\n\t\n\t\t\t\t$additional_row = array(\n\t\t\t\t\t'Code' => $iso_code,\n\t\t\t\t\t'Module' => 'common',\n\t\t\t\t\t'Key' => 'languages+name+' . $lang_key,\n\t\t\t\t\t'Value' => $lang_name,\n\t\t\t\t\t'Status' => 'active'\n\t\t\t\t);\n\t\t\t\t\n\t\t\t\t$this -> rlActions -> insertOne( $additional_row, 'lang_keys' );\n\t\t\t}\n\t\t\telse \n\t\t\t{\n\t\t\t\t$error[] = $GLOBALS['lang']['language_no_phrases'];\n\t\t\t}\n\t\t\t\n\t\t\tif ( !empty($error) )\n\t\t\t{\n\t\t\t\t/* print errors */\n\t\t\t\t$_response -> script(\"printMessage('error', '{$error}')\");\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t$insert = array(\n\t\t\t\t\t'Code' => $iso_code,\n\t\t\t\t\t'Direction' => $direction,\n\t\t\t\t\t'Key' => $lang_key,\n\t\t\t\t\t'Status' => 'active',\n\t\t\t\t\t'Date_format' => $date_format\n\t\t\t\t);\n\t\t\t\t$this -> rlActions -> insertOne( $insert, 'languages' );\n\t\t\t\t\t\t\t\t\n\t\t\t\t/* print notice */\n\t\t\t\t$_response -> script(\"\n\t\t\t\t\tprintMessage('notice', '{$GLOBALS['lang']['language_added']}');\n\t\t\t\t\tshow('lang_add_container');\n\t\t\t\t\tlanguagesGrid.reload();\n\t\t\t\t\");\n\t\t\t}\n\t\t}\n\t\t\n\t\t$_response -> script( \"$('#lang_add_load').fadeOut('slow');\" );\n\n\t\treturn $_response;\n\t}", "public function store(Request $request)\n {\n $ValidateData=$this->validate($request, [\n 'language' => 'required|unique:languages,language'\n ]);\n $validator=Validator::make($request->all(),[\n 'language' => 'required|unique:languages,language'\n ]);\n if($validator->fails()){\n $errors=\"This language was added before\";\n return redirect('quizzes.create')->withErrors($errors);\n }else {\n $language = new Language();\n response(redirect()->route('languages.store'));\n $language->language = ucfirst($request->language);\n $language->save();\n return redirect(route('quizzes.create'));\n }\n }", "function save($xml = false)\n {\n global $debug;\n global $warn;\n global $userid;\n global $connection;\n\n if (is_string($xml))\n { // string tag name\n $tagname = $xml;\n $xml = true;\n } // string tag name\n else\n if ($xml)\n { // true\n $tagname = 'cmd';\n } // true\n\n if ($this->needInsert)\n { // create new record\n $fldnames = '';\n $comma = '';\n $values = '';\n $parms = array();\n foreach($this->row as $fld => $value)\n {\n $fldnames .= $comma . \"`$fld`\";\n $values .= $comma . '?';\n array_push($parms, $value);\n $comma = \", \";\n } // loop through all fields in record\n\n // construct the SQL INSERT command \n $insert = \"INSERT INTO Languages ($fldnames) VALUES($values)\";\n $insertText = debugPrepQuery($insert, $parms);\n\n // insert the new record into the database\n $stmt = $connection->prepare($insert);\n if ($stmt->execute($parms))\n { // success\n $result = $stmt->fetchAll(PDO::FETCH_ASSOC);\n $count = count($result);\n if ($xml)\n print \"<$tagname result='$count'>\" .\n htmlentities($insertText,ENT_XML1) . \n \"</$tagname>\\n\";\n if ($debug)\n {\n $warn .= \"<p>$insertText</p>\\n\";\n $warn .= \"<p>count=$count</p>\\n\";\n }\n\n $this->changed = array(); // reset\n $this->needInsert = false;\n\n // log the update\n logSqlUpdate($insert,\n $parms,\n 0, // compound key\n '',\n $this->toJson(false));\n } // success\n else\n { // error inserting record\n throw new Exception(\"Language::save:\n '$insertText', \" .\n print_r($stmt->errorInfo(),true));\n } // error inserting record\n } // create new record\n else\n { // update existing record\n $update = \"UPDATE Languages SET \";\n $set = '';\n $comma = '';\n $count = 0;\n $parms = array();\n foreach($this->changed as $fld => $value)\n {\n $set .= $comma . \"`$fld`=?\";\n array_push($parms, $value);\n $comma = ', ';\n } // loop through all fields in record\n $this->changed = array(); // reset\n\n if (strlen($set) > 0)\n { // changes made\n // assemble the UPDATE command\n $update .= $set .\" WHERE `Code639_1`=?\";\n if ($this->former)\n array_push($parms, $this->former['code639_1']);\n else\n array_push($parms, $this->row['code639_1']);\n\n // perform the update\n $updateText = debugPrepQuery($update, $parms);\n $stmt = $connection->prepare($update);\n if ($stmt->execute($parms))\n {\n $count = $stmt->rowCount();\n if ($xml)\n print \"<$tagname count='$count'>\" .\n htmlentities($updateText,ENT_XML1) . \"</$tagname>\\n\";\n if ($debug)\n $warn .= \"<p>'$updateText' count=$count</p>\\n\";\n\n // log the update\n logSqlUpdate($update,\n $parms,\n 0, // compound key\n json_encode($this->former),\n $this->toJson(false));\n }\n else\n { // error updating record\n throw new Exception(\"Language::save:\n '$updateText', \" .\n print_r($stmt->errorInfo(),true));\n } // error updating record\n } // changes made\n } // update existing record\n return $count;\n }", "protected function _setLanguage() {\n\t// Get the default user language\n\t$userLanguage = Configure::read('User.defaultLanguage');\n\n\t// Use cookie, session, or params\n\tif ($this->Cookie->read('User.language')) {\n\t $userLanguage = $this->Cookie->read('User.language');\n\t}\n\tif ($this->Session->check('User.language')) {\n\t $userLanguage = $this->Session->read('User.language');\n\t}\n\tif (isset($this->params['language'])) {\n\t $userLanguage = $this->params['language'];\n\t}\n\n\t// Update the session\n\t$this->Session->write('User.language', $userLanguage);\n\t// Update the cookie if changed\n\tif ($this->Cookie->read('User.language') != $userLanguage) {\n\t $this->Cookie->write('User.language', $userLanguage, false, '20 days');\n\t}\n\n\t// Update the global used by CakePHP - don't use a different name!!!\n\tConfigure::write('Config.language', $userLanguage);\n }", "public function settingLanguage() {}", "function switchLanguage()\n {\n $language_id = $this->input->post('language_id');\n if (intval($language_id)) {\n switch ($language_id) {\n case 2:\n # English\n $config['language'] = 'english';\n $config['active_language'] = 'english';\n break;\n\n case 1:\n # Indonesian\n $config['language'] = 'indonesian';\n $config['active_language'] = 'indonesian';\n break;\n\n default:\n # default\n $config['language'] = 'indonesian';\n $config['active_language'] = 'indonesian';\n break;\n }\n $this->session->set_userdata('active-language', $config['active_language']);\n $result = array('status' => 'ok', 'language' => $language_id);\n exit(json_encode($result));\n } else {\n return null;\n }\n }", "function save()\n\t{\n\t\t$this->store() ;\n\t\t$link = 'index.php?option=com_arts_curriculum';\n\t\t$this->setRedirect( $link, $this->msg);\n\t}", "public function store(Request $request)\n {\n \t$Language = new LanguageSettings();\n \t$Language->name = $request->name;\n \t$Language->code = $request->code;\n \t$Language->direction = $request->direction;\n \t$Language->icon = $request->icon;\n \t$Language->directory = $request->directory;\n \t$Language->default = $request->default;\n \t$Language->save();\n\n \treturn redirect()->action( 'LanguageSettingsController@index' );\n }", "public function store(Request $request)\n {\n // $current_user = Auth::user();\n // if ($current_user->can([Config::get('constants.modules.STATE')]) == false) {\n // return abort(401);\n // }\n\n $this->validate($request, [\n 'name' => 'required|unique:language',\n 'ar_name' => 'required|unique:language',\n ],\n [\n 'name.required' => 'Please enter language name',\n 'name.unique' => 'Sorry! Language name Already Exists, please try again with new record',\n 'ar_name.required' => 'Please enter language name arabic',\n 'ar_name.unique' => 'Sorry! Language name arabic Already Exists, please try again with new record',\n ]);\n $input = $request->all();\n\n $input['created_at'] = date('Y-m-d h:i:s');\n\n $clinic = $this->lang->createlanguage($input);\n\n return redirect()->route('admin.lang.index')\n ->with(self::SUCCESS, 'Language added successfully.');\n }", "public static function set_language($language) {\n\t\tsetcookie(self::$cookie_name, $language, time() + (86400 * 30), \"/\"); // 30 days\n\t}", "public function store(LanguageRequest $request)\n {\n return $this->createFlashRedirect(Language::class, $request, $this->imageColumn);\n }", "private function setLanguage()\n\t{\n\t\tif (isset($_GET['language']))\n\t\t\t$id_lang = (int)($_GET['language'])>0 ? $_GET['language'] : 0;\n\t\tif (!isset($id_lang))\n\t\t\t$id_lang = ($this->getIdByHAL());\n\t\t$this->lang = $this->xml_file->lang[(int)($id_lang)];\n\t}", "function updateUserLanguage_post(){\n $this->check_service_auth();\n //pr($_POST);\n $this->form_validation->set_rules('languages','language','required');\n\t if($this->form_validation->run() == FALSE){\n\t $response = array('status'=>FAIL,'message'=>strip_tags(validation_errors()));\n\t $this->response($response);\n\t }\n \t$language = $this->post('languages');\n \t$languageCode = $this->post('languageCode');\n \t$data['user_id'] = $this->authData->userId;\n\t$data['upd'] = datetime();\n $res = $this->common_model->updateFields(USERS,array('userId'=>$this->authData->userId),array('language'=>$language,'languageCode'=>$languageCode));//update user language.\n if($res){\n $response = array('status'=>SUCCESS,'message'=>ResponseMessages::getStatusCodeMessage(171));\n }else{\n $response = array('status'=>FAIL,'message'=>ResponseMessages::getStatusCodeMessage(172));\n }\n $this->response($response);\n }", "public function translate_store(Request $request)\n {\n\n if (env('DEMO_MODE') === \"YES\") {\n Alert::warning('warning', 'This is demo purpose only');\n return back();\n }\n\n try {\n $language = Language::findOrFail($request->id);\n\n //check the key have translate data\n $data = openJSONFile($language->code);\n foreach ($request->translations as $key => $value) {\n $data[$key] = $value;\n }\n\n //save the new keys translate data\n saveJSONFile($language->code, $data);\n\n notify()->success(translate('Translated'));\n \n return back();\n } catch (\\Throwable $th) {\n Alert::error(translate('Whoops'), translate('Something went wrong'));\nreturn back();\n }\n \n }", "public function store(Request $request)\n {\n $input_all = $request->all();\n $validator = Validator::make($request->all(), [\n 'languages_name' => 'required',\n ]);\n if (!$validator->fails()) {\n \\DB::beginTransaction();\n try {\n $Language = new Language;\n foreach ($input_all as $key => $val) {\n $Language->{$key} = $val;\n }\n if (!isset($input_all['languages_status'])) {\n $Language->languages_status = 0;\n }\n $Language->save();\n \\DB::commit();\n $return['status'] = 1;\n $return['content'] = 'Success';\n } catch (Exception $e) {\n \\DB::rollBack();\n $return['status'] = 0;\n $return['content'] = 'Unsuccess';\n }\n } else {\n $failedRules = $validator->failed();\n $return['content'] = 'Unsuccess';\n if (isset($failedRules['languages_name']['required'])) {\n $return['status'] = 2;\n $return['title'] = \"Language is required\";\n }\n }\n $return['title'] = 'Insert';\n return $return;\n }", "public function save()\n\t{\n\t\tparent::save();\n\t\t\n\t\t$table_prefix = Kohana::config('database.default.table_prefix');\n\t\t\n\t\t$this->db->query('UPDATE `'.$table_prefix.'indicator_lang` SET indicator_title = ?, indicator_description = ? WHERE indicator_id = ? AND locale = ?',\n\t\t\t$this->indicator_title, $this->indicator_description, $this->id, $this->locale\n\t\t);\n\t}", "public function updateLanguage($id){\n\t\tif(htmlentities($id)){\n\t\t\tif(Auth::check()){\n\t\t\t\t$user=Auth::user();\n\t\t\t\tif($user->id==htmlentities($id)){\n\t\t\t\t\t$user->language = $user->language+1;\n\t\t\t\t\tif($user->language > 1){\n\t\t\t\t\t\t$user->language = 0;\n\t\t\t\t\t}\n\t\t\t\t\tif ($user->language == 0){\n\t\t\t\t\t\tsession(['locale'=> \"fr\"]);\n\t\t\t\t\t}else if ($user->language == 1){\n\t\t\t\t\t\tsession(['locale'=> \"en\"]);\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tsession(['locale'=> \"en\"]);\n\t\t\t\t\t}\n\t\t\t\t\t$user->save();\n\t\t\t\t\treturn back()->with('success','Enjoy your new language.');\n\n\t\t\t\t}else{\n\t\t\t\t\treturn redirect('/home')->with('error','You are not allowed to edit other users\\' profiles.');\n\t\t\t\t}\n\t\t\t}else{\n\t\t\t\treturn redirect('/login')->with('error','Please log in to perform this action.');\n\t\t\t}\n\n\t\t}else{\n\t\t\treturn redirect('/dashboard')->with('error','An error occured while updating your settings. Please try again');\n\t\t}\n\t}", "private function _makeSureThereIsALanguageID()\n {\n if (empty(Session::get('languageID'))) {\n if (strstr(URL::getDomainExtension(), 'localhost')\n || strstr(URL::getDomainExtension(), 'nl')\n ) {\n Session::save('languageID', 1);\n } elseif (strstr(URL::getDomainExtension(), 'com')) {\n Session::save('languageID', 2);\n }\n }\n }", "public function changeLangEn($lang = 'en_US')\n{\n $this->Cookie->write('lang', $lang);\n return $this->redirect($this->request->referer());\n}", "public function store()\n {\n if(!\\Session::has('locale'))\n {\n \\Session::put('locale', Input::get('locale'));\n }else \n {\n \\Session::put('locale', Input::get('locale'));\n }\n return Input::get('locale');\n }", "public function store(Request $request)\n {\n $array_one[$request->language_id]=$request->language_id;\n if($request->session()->has('job_category_lang_id')){\n $lang = $request->session()->get('job_category_lang_id');\n $request->session()->forget('job_category_lang_id');\n $request->session()->put('job_category_lang_id',$lang+$array_one);\n }else{\n $request->session()->put('job_category_lang_id',$array_one);\n }\n\n $id =0;\n if($request->session()->has('job_category_id')){\n $categ = $request->session()->get('job_category_id');\n foreach ($categ as $c){\n $id = $c;\n }\n }\n\n $array_lang = $request->session()->get('job_category_lang_id');\n $language = Language::whereNotIn('id',$array_lang)->pluck('name','id');\n if(!count($language)){\n $request->session()->forget('job_category_lang_id');\n $request->session()->forget('job_category_id');\n $language = Language::pluck('name','id');\n }\n $check = Jobcategory::where('id',$id)->get();\n if($request->ajax()) {\n if (!count($check)) {\n $cat = new Jobcategory();\n $cat->date = Carbon::now()->toDateString();\n $cat->trash = 0;\n $cat->user_added = Auth::user()->id;\n $cat->user_modifies =0;\n $cat->save();\n $id = $cat->id;\n $request->session()->put('job_category_id', [$id => $id]);\n $cat->languages()->attach($request->language_id, ['name' => $request->name]);\n return response()->json(['id' => 0, 'language' => $language]);\n } else {\n DB::table('jobcategory_language')->insert(['language_id' => $request->language_id, 'jobcategory_id' => $id, 'name' => $request->name]);\n if (!$request->session()->has('job_category_lang_id')) {\n $id = 0;\n }\n return response()->json(['id' => 0, 'language' => $language]);\n }\n }\n }", "public function store(Request $request)\n {\n $language = new userLanguage();\n $language->user_id = Auth::user()->id;\n $language->language_id = $request->language_id;\n $language->level = $request->level_id;\n $language->save();\n $language[\"lang\"] = language::where('id',$language->language_id)->first();\n return response::json($language);\n }", "public function createLanguagesAction() {\n $em = $this->getDoctrine()->getManager();\n $list = array(\"zh\", \"en\", \"es\", \"hi\", \"bn\", \"pt\", \"ru\", \"fr\", \"ur\", \"ja\", \"de\", \"ko\", \"tr\", \"it\", \"ar\");\n\n foreach ($list as $key => $value) {\n $object = new \\Skaphandrus\\AppBundle\\Entity\\SkLanguage();\n $object->setName($value);\n $em->persist($object);\n }\n $em->flush();\n\n $entities = $em->getRepository('SkaphandrusAppBundle:SkLanguage')->findAll();\n\n return $this->render('SkaphandrusAppBundle:SkBusiness:createLanguage.html.twig', array(\n 'entities' => $entities,\n ));\n }", "public function languages_save(Request $request) {\n \n try {\n \n $language_details = CommonRepo::languages_save($request);\n \n if ($language_details['success'] == true) {\n \n return redirect(route('admin.languages.index'))->with('flash_success', $language_details['message']); \n } \n \n throw new Exception($language_details['error'], $language_details['code']); \n\n } catch( Exception $e) {\n \n $error = $e->getMessage();\n\n return redirect()->back()->withInput()->with('flash_error',$error);\n }\n \n }", "public function interested_lang($data){\n\t\n\t$id = $_SESSION['id'];\n\n\t\t$q = \"SELECT * FROM interested\";\n\t\t$result = $this->connection->query($q);\n\n\t\tif($result->num_rows > 0){\n\n\n\t\t\t$q = \"DELETE FROM interested WHERE u_id='$id'\";\n\t\t\t$result = $this->connection->query($q);\n\n\t\t\tforeach ($data['interested'] as $value) \n\t\t {\n\n\t\t $q = \"INSERT INTO interested (u_id, lang_id) VALUES ($id, $value)\";\n\t\t $result = $this->connection->query($q);\n\n\t\t }\n\n\t\t}else{\n\n foreach ($data['interested'] as $value) \n\t\t {\n\n\t\t $q = \"INSERT INTO interested (u_id, lang_id) VALUES ($id, $value)\";\n\t\t $result = $this->connection->query($q);\n\n\t\t }\n\t\t}\n }", "public static function lv(){\n setcookie('language', 'lv', time()+60);\n }", "private function save_to_session()\n {\n if (strtolower($_SESSION['country_name']) !== strtolower($this->country_name)) {\n $_SESSION['country_name'] = $this->country_name;\n $_SESSION['country_code'] = $this->country_code;\n }\n if (strtolower($_SESSION['region_name']) !== strtolower($this->region_name)) {\n $_SESSION['region_name'] = $this->region_name;\n $_SESSION['region_code'] = $this->region_code;\n }\n\n }", "public static function add_lang($lang_name, $prof)\n\t{\n\t\t$email = $_SESSION['email'];\n\t\t$dbhandle=DataAccessHelper::getConnection();\n\n\t\t$sql = \"select * from language WHERE email = ? AND langName =? AND proficiency =?;\" ;\n\n\t\t$stmt = \tmysqli_stmt_init($dbhandle);\n\n\t\tif(!mysqli_stmt_prepare($stmt, $sql)){\n\n\t\t\techo \"SQL statement failed\";\n\t\t}\n\t\telse\n\t\t{\n\t\t\tmysqli_stmt_bind_param($stmt, \"sss\",$email, $lang_name, $prof);\n\t\t\tmysqli_stmt_execute($stmt);\n\t\t\t$result = mysqli_stmt_get_result($stmt);\n\t\t\tif($result->num_rows > 0){\n\t\t\t\t\treturn \"Record already exists!\";\n\t\t\t}\n\t\t\telse{\n\t\t\t\t$sql = \"INSERT INTO language(email,langName,proficiency) VALUES (?, ? , ?)\";\n\t\t\t\t\t$stmt = mysqli_stmt_init($dbhandle);\n\t\t\t\t\tif(!mysqli_stmt_prepare($stmt, $sql)){\n\t\t\t\t\t\t\n\t\t\t\t\t\techo \"SQL error\";\n\t\t\t\t\t}\n\t\t\t\t\telse{\n\n\t\t\t\t\t\tmysqli_stmt_bind_param($stmt, \"sss\",$email, $lang_name, $prof);\n\t\t\t\t\t\tmysqli_stmt_execute($stmt);\n\t\t\t\t\t\treturn \"language added successfully\";\n\n\t\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\t// $result = mysqli_query($dbhandle,\"select * from language WHERE email = '$email' AND langName ='$lang_name' AND proficiency ='$prof';\") or die(\"Failed to query database\".mysqli_error($dbhandle));\n\t\t// //echo $result->num_rows;\n\t\t// if ($result->num_rows > 0) {\n\t\t// \treturn \"Record already exists!\";\n\t\t// }\n\t\t// else{\n\t\t// \tmysqli_query($dbhandle,\"INSERT INTO language(email,langName,proficiency) VALUES ('$email', '$lang_name' , '$prof')\");\n\n\t\t// \treturn \"language added successfully\";\n\t\t// }\n\t}", "public function store(Request $request)\n {\n $this->_MODEL = new \\App\\Models\\Language(); \n return $this->_StoreItem($request); \n }", "public function store(Request $request) {\n $request->validate([\n 'name'=>'required',\n 'name_in_language'=>'required',\n 'code'=>'required',\n 'country'=>'required'\n ]);\n $languages = new Languages;\n $languages->name = $request->input('name');\n $languages->country_id = $request->input('country');\n $languages->name_in_language = $request->input('name_in_language');\n $languages->code = strtolower($request->input('code'));\n $languages->status = $request->input('status') != \"\" ? $request->input('status') : 0;\n\n if (!$languages->save()) {\n //Redirect error\n return redirect()->route('languages')->with('error', 'Failed to update languages details.');\n }\n\n //Redirect success\n return redirect()->route('languages')->with('success', 'Languages added successfully.');\n\n }", "public function syncUserLanguage($observer)\n\t{\n\t $locale = Mage::app()->getLocale();\n\t $session = Mage::getSingleton('customer/session');\n $current_language = $session->getJoomlaLanguage();\n $lang = substr($locale->getLocaleCode(), 0, 2);\n \n if (!$current_language || $current_language != $lang) {\n $session->setJoomlaLanguage($lang);\n \n\t\t\t$cookiePath = Mage::app ()->getStore ()->getConfig ( 'web/cookie/cookie_path' );\n\t\t\t$cookieDomain = Mage::app ()->getStore ()->getConfig ( 'web/cookie/cookie_domain' );\n\t\t\t$cookieLifetime = Mage::app ()->getStore ()->getConfig ( 'web/cookie/cookie_lifetime' );\n\t\t\t\t\n\t\t\t$cookiesHelper = Mage::helper ( 'joomla/cookies' );\n\t\t\t$cookiesHelper->setCookies ( array (array ('jfcookie[lang]=' . $lang ) ), null, $cookiePath, $cookieLifetime, 0, 0 );\n\t\t\t\n\t\t\t/**\n\t\t\t * The cookie below is created only if the magento config doesn't include store in URL but we want it for any case\n\t\t\t * to test and define the url language in the index.php of Magento (custom code) or to inform Joomla about which language is used in Magento\n\t\t\t */\n\t\t\t$cookiesHelper->setCookies ( array (array ('store=' . $lang ) ), $cookieDomain, $cookiePath, $cookieLifetime, 0, 0 );\n }\n\t}", "public function action_setlang($lang=null){\n\tif ($lang!=null){\n\t $auth = Auth::instance();\n\t $auth->update_user(array(\"language\"=>$lang));\n\t Response::redirect(\"/\");\n\t}\n }", "public function store(Request $request, Languages $languages)\n {\n //echo\"<pre>\";print_r($request->all());die;\n $rules = [\n 'title' => 'required'\n ];\n\n\n $input = $request->all();\n $validator = Validator::make($input, $rules);\n if ($validator->fails()) {\n return redirect()->back()->withErrors($validator)->withInput();\n }else{\n $inputArr = $request->except(['_token']);\n $languagesObj = $languages->saveLanguages($inputArr);\n if(!$languagesObj){\n return redirect()->back()->with('error', 'Unable to add language. Please try again later.');\n }\n\n return redirect()->route('languages.index')->with('success', 'Language account added successfully.');\n }\n }", "private function setLanguage() {\n//\t\tYii::app()->language = @Yii::app()->user->getState('lang');\n\t}", "public function run()\n\t{\n\t\tDB::statement(\"INSERT INTO language (language) VALUES ('Nederlands')\");\n\t\tDB::statement(\"INSERT INTO language (language) VALUES ('Engels')\");\n\t\tDB::statement(\"INSERT INTO language (language) VALUES ('Frans')\");\n\t}", "function saveToSession() {\n\t\t// Unset sessions since this info is elsewhere in the database\n\t\tunset($this->_questions);\n\t\ttx_wecassessment_sessiondata::storeSessionData($this, $this->getPID());\n\t}", "public function setLocale()\n {\n $lang = Request::segment(2);\n\n try {\n $this->language->set($lang);\n return Redirect::back();\n } catch (Exception $e) {\n //show error\n }\n }", "public function create_new_lang()\n {\n $root_directory = FCPATH.\"application/language/\";\n $scan_root_directory = array_diff(scandir($root_directory),array('.','..'));\n $data['root_dir'] = $scan_root_directory;\n\n // Application Languages\n $directory = FCPATH.\"application/language/english\";\n $file_lists = scandir($directory,0);\n $total_file = count($file_lists);\n $language_Files = array();\n\n for($i = 2; $i< $total_file; $i++) \n {\n array_push($language_Files, $file_lists[$i]);\n }\n\n for ($i = 0; $i < count($language_Files); $i++) \n {\n $file_name = $language_Files[$i];\n include FCPATH.\"application/language/english/\".$file_name;\n $data['file_name'][$i] = $file_name;\n }\n\n // datatables plugins language\n $directory2 = FCPATH.\"assets/modules/datatables/language/english.json\";\n $plugin_file = file_get_contents($directory2);\n $plugin_file_contents = json_decode($plugin_file,TRUE);\n\n $lang = array();\n\n foreach ($plugin_file_contents as $key => $value) \n {\n if($key == \"oPaginate\")\n {\n foreach ($value as $key1 => $value1) \n {\n $lang[$key1] = $value1;\n }\n\n } else if ($key =='oAria') {\n\n foreach ($value as $key1 => $value1) \n {\n $lang[$key1] = $value1;\n }\n } else {\n $lang[$key] = $value;\n\n } \n }\n\n\n // Addon Language\n $addon_directory = FCPATH.\"application/modules/\";\n $scan_directory = scandir($addon_directory,0);\n $addon_files = array();\n\n for ($i = 2; $i < count($scan_directory) ; $i++) \n {\n array_push($addon_files, $scan_directory[$i]);\n }\n\n $addon_lang_folder = array();\n for ($i = 0; $i < count($addon_files); $i++) \n {\n $module_directory = FCPATH.\"application/modules/\".$addon_files[$i].\"/language\";\n if(file_exists($module_directory))\n {\n $scan_module_directories = array_diff(scandir($module_directory),array('.','..'));\n if(!empty($scan_module_directories))\n {\n $addon_name = $addon_directory.$addon_files[$i];\n array_push($addon_lang_folder,$addon_name);\n }\n }\n }\n\n\n $addon_dir_arr = array();\n for ($i = 0; $i < count($addon_lang_folder); $i++) \n {\n $addon_lang_file = $addon_lang_folder[$i];\n $addon_lang_file_dir = $addon_lang_file.\"/language/english/\";\n $addon_lang_file_dir_scan[] = scandir($addon_lang_file_dir,1);\n array_push($addon_dir_arr,$addon_lang_file_dir_scan[$i][0]);\n }\n $data['addons'] = $addon_dir_arr;\n\n $data['body'] = 'admin/multi_language/add_language';\n $data['page_title'] = $this->lang->line(\"New Language\");\n $this->_viewcontroller($data);\n }", "protected function persistTranslations()\n\t{\n\t\tTranslation::patchTranslationsForModel($this, $this->getActiveLanguage(), $this->translatedAttributes);\n\t}", "public function language($id) {\n $this->code_image();\n Session::put('language', $id);\n return redirect()->back();\n }", "public function switchLang($lang)\n {\n //return $lang;\n if (array_key_exists($lang, Config::get('languages'))) {\n Session::set('applocale', $lang);\n }\n return Redirect::back();\n }", "public function langStore(Request $request)\n {\n\n if (env('DEMO_MODE') === \"YES\") {\n Alert::warning('warning', 'This is demo purpose only');\n return back();\n }\n\n try {\n $request->validate([\n 'code' => ['required', 'unique:languages'],\n 'name' => ['required', 'unique:languages'],\n 'image' => ['required', 'unique:languages']\n ]);\n $lan = new Language();\n $lan->code =Str::lower(str_replace(' ','_',$request->code));\n $lan->name = $request->name;\n $lan->image = $request->image;\n $lan->save();\n\n notify()->success(translate('Stored'));\n \n return back();\n } catch (\\Throwable $th) {\n Alert::error(translate('Whoops'), translate('Something went wrong'));\nreturn back();\n }\n \n }", "public function saveTranslations()\n {\n /** @var ActiveRecord $translationModel */\n $translationModel = new $this->translationModelClass();\n\n $data = \\Yii::$app->request->post($translationModel->formName());\n\n if (empty($data)) return;\n\n foreach ($data as $lang => $record) {\n $translation = $this->getTranslationModel($lang);\n $translation->setAttributes(ArrayHelper::merge($record, [\n $this->translationModelRelationColumn => $this->owner->getPrimaryKey(),\n $this->translationModelLangColumn => $lang,\n ]));\n\n if (!$translation->save()) {\n Toastr::warning(\\Yii::t('admin', \"Перевод на {$lang} неполный, не сохранен\"));\n }\n }\n }", "protected function _writeLocale()\n {\n $text = $this->_tpl['locale'];\n \n $file = $this->_class_dir . DIRECTORY_SEPARATOR . \"/Locale/en_US.php\";\n if (file_exists($file)) {\n $this->_outln('Locale file exists.');\n } else {\n $this->_outln('Writing locale file.');\n file_put_contents($file, $text);\n }\n }", "function addLanguage(){\n $currentLanguage=\"\";\n if(!empty($_GET)){\n $currentLanguage = $_GET[\"lang\"];\n return \"lang=\".$currentLanguage; \n }\n else {\n return \"lang=\".\"eng\"; \n }\n \n }", "function setLanguage() {\n\t\tif(isset($_GET['lang'])) {\n\t\t\t$language = $this->getLanguageFileName($_GET['lang']);\n\t\t} elseif(isset($_COOKIE['lang'])) {\n\t\t\t$language = $this->getLanguageFileName($_COOKIE['lang']);\n\t\t} else {\n\t\t\t$language = $this->getLanguageFileName('en-us');\n\t\t}\n\n\t\t//Sets the language cookie for 30 days\n\t\tsetcookie('lang', $language['meta'], time() + 60 * 60 * 24 * 30, '/');\n\n\t\treturn $language;\n\t}", "protected function save(): void\n\t{\n\t\t$this->session->set($this->flashKey, $this->flashRecord);\n\t}", "function lang_list( $language_id = 0 ) {\n\t\t$this->session->set_userdata(array(\"language_id\" => $language_id ));\n\t\t\n\t\tredirect( site_url('admin/language_strings/index/') );\n\t}", "public function languages_set_default(Request $request) {\n\n try {\n\n // Load setting table\n DB::beginTransaction();\n\n $setting_details = Settings::where('key','default_lang')->first();\n\n if (!$setting_details) { \n\n throw new Exception(tr('something_error'), 101); \n }\n\n $setting_details->value = $request->language_file;\n\n if( $setting_details->save()) {\n\n DB::commit();\n\n $fp = fopen(base_path() .'/config/new_config.php' , 'w');\n\n fwrite($fp, \"<?php return array( 'locale' => '\".$request->language_file.\"', 'fallback_locale' => '\".$request->language_file.\"');?>\");\n \n fclose($fp);\n\n \\Log::info(\"Key : \".config('app.locale'));\n\n return back()->with('flash_success' , tr('set_default_language_success'))->with('flash_language', true);\n } \n\n throw new Exception(tr('something_error'), 101); \n \n\n } catch (Exception $e) {\n \n DB::rollback();\n \n $error = $e->getMessage();\n\n return redirect()->route('admin.languages.index')->with('flash_error',$error);\n }\n\n }", "public function createLangue($name,$translate){\n\n global $conn;\n\n $request_insert = \"INSERT INTO `langue` (`name`,`translate`) VALUES ('\" . $name . \"','\" . $translate . \"')\";\n\n $conn->query($request_insert);\n }", "public function storeSession() {}" ]
[ "0.78030044", "0.72334784", "0.67094594", "0.66621286", "0.66117656", "0.65595144", "0.6551577", "0.65339106", "0.65281236", "0.6503313", "0.6464807", "0.6427674", "0.64075905", "0.64045167", "0.63727605", "0.6339596", "0.62854654", "0.62723625", "0.6242576", "0.62247586", "0.62126464", "0.61901915", "0.61775213", "0.6176832", "0.61727506", "0.61419666", "0.6098525", "0.60889685", "0.60887986", "0.60813165", "0.6081115", "0.60744315", "0.6045031", "0.60415936", "0.6025407", "0.6024522", "0.6021608", "0.60123104", "0.59996116", "0.5995588", "0.59760463", "0.5972319", "0.59699917", "0.59696734", "0.59426004", "0.5932859", "0.5927667", "0.5914202", "0.59135187", "0.59083426", "0.5903662", "0.5897471", "0.5882872", "0.5868654", "0.58646023", "0.58615166", "0.58570796", "0.58388996", "0.5838123", "0.58173156", "0.58025736", "0.5787924", "0.5779299", "0.57681817", "0.57605857", "0.5751377", "0.57508475", "0.57493204", "0.5748836", "0.5735793", "0.57241726", "0.5722833", "0.5695355", "0.568413", "0.5676824", "0.5654964", "0.56519824", "0.56510895", "0.56500596", "0.5648677", "0.56436265", "0.56395054", "0.56231606", "0.56203455", "0.5618644", "0.56147635", "0.56143093", "0.5607589", "0.5607377", "0.5598604", "0.5596409", "0.55898196", "0.5580931", "0.5573717", "0.5565228", "0.5562504", "0.5561271", "0.55569667", "0.5555112", "0.5554935", "0.5542811" ]
0.0
-1
return jsonencoded data responce
public function returnData($data = null, $httpStatusCode = 200) { $this->getResponse()->setStatusCode($httpStatusCode); $model = new JsonModel($data); //$model = $this->acceptableViewModelSelector($this->acceptCriteria); $model->setOption('prettyPrint', DEBUG); return $model; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function getJSON(){\n return json_encode($this->getResponseStructure());\n }", "private function json()\n {\n return json_encode($this->data);\n }", "private function json($data){\n header('Content-type: application/json');\n return json_encode($data);\n }", "public function return_json(){\n\t\t$this->output\n\t ->set_content_type('application/json')\n\t ->set_output(json_encode($this->response));\n\t}", "public function json();", "public function json() {\n return json_encode($this->response);\n }", "protected function returnJSON($data) {\n\t //header('Content-type: application/json');\n\t echo CJSON::encode($data);\n\t}", "public function toJSON () {\r\n \treturn json_encode($this->_response);\r\n }", "public function getJsonString(){\n\t\treturn json_encode(array($this->getRequestData()));\n\t}", "private function json($data){\r\n if(is_array($data)){\r\n return json_encode($data);\r\n }\r\n else return json_encode($data);\r\n }", "public function render(){\n\t\treturn json_encode($this->data,$this->options);\n\t}", "private function jsonResponse() {\n return json_format($this->response, $this->pretty);\n }", "private function json($data){\r\n\t\t\tif(is_array($data)){\r\n\t\t\t\treturn json_encode($data);\r\n\t\t\t}\r\n\t\t}", "protected function _response($data) : string\n {\n return json_encode($data);\n }", "public function JSONreturn()\n\t{\n\t\techo json_encode( $this->json_return );\n\t}", "public function func_json_builder () {\n return json_encode ($this -> raw_data);\n }", "private function json($data){\n\t\t\tif(is_array($data)){\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json($data){\n\t\t\tif(is_array($data)){\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json($data){\n\t\t\tif(is_array($data)){\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json($data){\n\t\t\tif(is_array($data)){\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json($data){\n\t\t\tif(is_array($data)){\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json($data){\n\t\t\tif(is_array($data)){\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json() {\n if( $this->format === 'application/hal+json' ) {\n header('Content-Type: application/hal+json; charset=utf-8', TRUE, $this->status);\n $hal_response = (new Resource())\n ->setURI(\"/{$this->resource}\". (isset($this->filters['id']) ? $this->filters['id'] : ''))\n ->setLink($this->resource, new Link(\"/{$this->resource}\"))\n ->setData($this->content);\n\n $writer = new Hal\\JsonWriter(true);\n return $writer->execute($hal_response);\n } else {\n header('Content-Type: application/json; charset=utf-8', TRUE, $this->status);\n return json_encode($this->content, JSON_NUMERIC_CHECK);\n }\n }", "public function json()\n {\n return json_encode(\n [\n 'errors' => $this->error,\n 'success' => $this->ok,\n 'debug' => $this->debug,\n\n ]\n );\n }", "public function response()\n {\n $metadata = $this->metadata;\n $tmp = array();\n \n if ($this->showConfigRoot != false) {\n $tmp['root'] = $metadata['root'];\n $tmp['totalProperty'] = $metadata['totalProperty'];\n $tmp['successProperty'] = $metadata['successProperty'];\n $tmp['messageProperty'] = $metadata['messageProperty'];\n }\n \n $tmp[$metadata['root']] = (empty($this->data)) ? array() : $this->data;\n $tmp[$metadata['successProperty']] = $this->success;\n \n // if metadata Is String return as Raw else create new array\n if ($this->showMetaData != false)\n if ($metadata['onlyRaw'] === true) {\n $tmp['metaData'] = \"|1|2|3|4|5|...5|||\";\n } else {\n $tmp['metaData'] = $this->metadata;\n }\n $rawJson = json_encode($tmp);\n if ($metadata['onlyRaw'] === true) {\n return str_replace('\"|1|2|3|4|5|...5|||\"', $metadata['raw'], $rawJson);\n }\n \n return $rawJson;\n }", "public function json($data): PsrResponseInterface;", "private function json($data){\n\t\tif(is_array($data)){\n\t\t\treturn json_encode($data);\n\t\t}\n\t}", "public function jsonResponse(): string {\n\n header_remove();\n http_response_code(200);\n header('Content-Type: application/json');\n header('Status: 200');\n $response = [\n 'visited' => $this->visited,\n 'cleaned' => $this->cleaned,\n 'final' => $this->final,\n 'battery' => $this->battery\n ];\n\n return json_encode($response,JSON_PRETTY_PRINT);\n }", "protected function jsonEncode($data){\n\t\treturn json_encode($data);\n\t}", "public function getData(){\n $data = json_encode($this->data);\n return $data;\n }", "private function output($data)\n {\n return json_encode($data);\n }", "private function ajson($data){\n $json = $this->get('serializer')->serialize($data, 'json');\n\n // Response with httpfoundation\n $response = new Response();\n\n // Assign content to the response\n $response->setContent($json);\n\n // Specify response format\n $response->headers->set('Content-Type', 'application/json');\n\n // Return response\n return $response;\n }", "public function json(){ return json_encode( $this->objectify() ); }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function json()\n {\n }", "public function jsonString(){\n return json_encode($this->createRequestsArray());\n }", "static function toJsonString() {\n if(self::$error != null)\n return json_encode(self::$error);\n return json_encode(self::$data);\n }", "private function convertirJson($data){\n\t\treturn json_encode($data);\n\t}", "public function json() \n\t{\n return json_encode($this);\n\t}", "private function getJsonResponse($data) {\r\n $response = json_encode($data);\r\n return $response;\r\n }", "private function json($data)\n\t\t{\n\t\t\tif (is_array($data))\n\t\t\t{\n\t\t\t\treturn json_encode($data);\n\t\t\t}\n\t\t}", "private function json($data)\n {\n if(is_array($data)){\n return json_encode($data);\n }\n }", "public function getJsonResponse() {\n return \\Lib\\Format::forge($this->_response)->to_json();\n }", "private function json($data) {\n if (is_array($data)) {\n return json_encode($data);\n }\n }", "public function json()\n {\n // if dirty data exists\n $this->swallow();\n // if redirecting\n if ($this->redirect) {\n /*header(\"Location: {$this->redirect}\");\n // more headers\n foreach ( $this->headers as $header ) {\n header($header);\n }*/\n $this->redirect($this->redirect, array(), false);\n } else {\n // header json data\n header('Content-Type: application/json');\n // more headers\n foreach ($this->headers as $header) {\n header($header);\n }\n //过滤$CFG\n if (!empty($this->vars['CFG'])) {\n unset($this->vars['CFG']);\n }\n // if cli add time\n if ($cli = Utility::isCli()) {\n echo \"[\". date('Y-m-d H:i:s') . \"] \";\n }\n // set varibales data\n if ($cli && version_compare(phpversion(), '5.4.0') > 0) {\n $results = json_encode($this->vars, JSON_PRETTY_PRINT);\n } else {\n $results = json_encode($this->vars);\n }\n // send\n echo $results;\n // if cli add \\n\n if ($cli) {\n echo \"\\n\";\n }\n }\n }", "public function getResultsInJSON(): string {\n return json_encode($this->getResults());\n }", "private function json($data) {\n if (is_array($data)) {\n return json_encode($data);\n }\n }", "public function toJson() : string\n {\n return json_encode($this->toArray(), http_response_code(200));\n }", "public function json()\n\t{\n\t\t$data = [\n\t\t\t'totalResults' => '3',\n\t\t\t'values' => [\n\t\t\t\t['name' => 'John', 'age' => 30],\n\t\t\t\t['name' => 'Mary', 'age' => 24],\n\t\t\t\t['name' => 'Petter', 'age' => 18],\n\t\t\t],\n\t\t];\n\n\t\treturn $data;\n\t}", "public function toJson(): string\n {\n $is_success = $this->errors ? false : true;\n\n return json_encode([\n 'status' => $is_success ? 'success' : 'fail',\n 'data' => $this->data,\n 'errors' => $this->errors\n ]);\n }", "public static function json($data = array()) {\n header('Cache-Control: no-cache, must-revalidate');\n header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');\n header(\"content-type: application/json\");\n echo json_encode((array) $data);\n }", "public function Encode()\r\n {\r\n if (!is_array($this->data))\r\n {\r\n $this->data = array();\r\n }\r\n return json_encode($this->data);\r\n }", "public function json()\n {\n $code = 200;\n\n if (!Request::has(\"no_response_code\") || Request::input('no_response_code') != \"yes\") {\n $code = $this->getCode();\n }\n\n return response()->json($this->getResponse(), $code);\n }", "private function writeJSON($data){\n\t\tif(!class_exists('Services_JSON')){\n require_once('JSON.php');\n }\n\t\t$json = new Services_JSON();\n\n\t\treturn $json->encode($data);\n }", "public function buildJson();", "protected function _getJSONEncodedResponse()\n {\n if (function_exists('__json_encode'))\n {\n return json_encode($this->_Response);\n }\n else\n {\n return $this->_prepareJSONToEval($this->_jsonEncode($this->_Response));\n }\n\n }", "public function json($data){\n\tif(is_array($data)){\n\t\treturn json_encode($data, JSON_PRETTY_PRINT | JSON_UNESCAPED_UNICODE | JSON_UNESCAPED_SLASHES);\n\t}\n}", "public function response($data){\n echo json_encode($data);\n }", "public function getJSON(){\n return '{\"tag\":\"'.$this->getTag().'\" , \"name\":\"'.$this->getName().'\" , \"donations\":\"'.$this->getDonations().'\", \n \"received\":\"'.$this->getReceived().',\"tagClan\":\"'.$this->getTagClan().'\"}' ;\n }", "function json_response( $data ) {\n\t\theader( 'Cache-Control: no-cache, must-revalidate' );\n\t\theader( 'Pragma: no-cache' );\n\t\theader( 'Content-type: application/json' );\n\n\t\t// Output JSON-encoded result and quit\n\t\techo json_encode( $data );\n\t\texit;\n\t}", "public function toJson();", "public function toJson();", "function render_json($data)\n {\n $this->response->add_header('Content-Type', 'application/json');\n $this->render_text(json_encode(studip_utf8encode($data)));\n }", "function return_json($sqlresult) {\n header(\"Content-type:application/json;charset=utf-8\");\n echo json_encode($sqlresult);\n }", "private function getJsonData() {\n if (empty($this->fields)) {\n return json_encode($this->fields, JSON_FORCE_OBJECT);\n } else {\n return json_encode($this->fields);\n }\n \n // Example of returned string:\n // $jsonData = '{\"name\":\"foo.antox.intra\",\"ipv4addr\":\"192.168.1.2\"}'; \n //$obj = json_decode($jsonData);\n //echo $obj->{'name'};\n //it works, it print \"foo.antox.intra\"\n }", "public function getJsonData()\n {\n $code = ApiReturnCode::SUCCESS;\n return $this->Api->response($code, [\n 'foo' => 'bar',\n 'baz' => 'buff'\n ]);\n }", "public function responseJson() {\n return Response::json($this->_responseData, $this->_responseCode);\n }", "public function json($data)\n {\n $this->template = NULL;\n $this->response->headers('Content-Type', 'application/json; charset=utf-8');\n $this->response->body(json_encode($data));\n }", "public function toJson()\n {\n return json_encode($this->data);\n }", "private function json($data){\n\t\tif(is_array($data)){\n\t\t\tif (getParameter('f')) {\n\t\t\t\tswitch(getParameter('f')){\n\t\t\t\t\tcase \"json\":\n\t\t\t\t\t\treturn json_encode($data);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\tcase \"pjson\":\n\t\t\t\t\t\tif(defined(JSON_PRETTY_PRINT))\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\treturn json_encode($data, JSON_PRETTY_PRINT);\n\t\t\t\t\t\t}\n\t\t\t\t\t\telse\n\t\t\t\t\t\t{\t\n\t\t\t\t\t\t\treturn json_encode($data);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tbreak;\t\t\t\t\t\t\n\t\t\t\t}\n\t\t\t}\n\t\t\telse return $data;\n\t\t}\n\t}", "public function jsonSerialize();", "public function jsonSerialize();", "public function jsonSerialize();", "public function jsonSerialize();", "public function jsonSerialize();", "public function jsonSerialize();", "public function jsonSerialize();", "public function jsonSerialize();", "public function json($data)\n {\n header(\"Access-Control-Allow-Origin: *\");\n header('Content-Type: application/json');\n\n echo json_encode($data, JSON_PARTIAL_OUTPUT_ON_ERROR | JSON_PRETTY_PRINT | JSON_NUMERIC_CHECK | JSON_BIGINT_AS_STRING);\n }", "protected function json($data){\n\t\tif(is_array($data)){\n\t\t\tif($this->_prettyPrint === true) return $this->prettyJSON(json_encode($data)); //Pretty?\n\t\t\telse return json_encode($data);\n\t\t}\n\t}", "public function json() {\n\t\t$data = parent::json();\n\n\t\t$data['id'] = $this->type . '-' . $this->id;\n\t\t$data['label'] = html_entity_decode( $this->label, ENT_QUOTES, get_bloginfo( 'charset' ) );\n\t\t$data['value'] = $this->value();\n\t\t$data['link'] = $this->get_link();\n\t\t$data['defaultValue'] = $this->setting->default;\n\n\t\treturn $data;\n\t}", "public function __toString() {\n\t\t$data = array();\n\t\tforeach ($this->fields as $name => $field) {\n\t\t\t$data += [$name => $field->toJson()];\n\t\t}\n\t\t$top = array(\"success\"=>$this->success,\"data\"=>$data,\"text\"=>$this->text);\n\t\treturn json_encode($top);\n\t}", "public function jsonSerialize()\n {\n return array('title' => $this->title,\n 'size' => $this->size,\n 'unit_price' => $this->unitPrice,\n 'description' => $this->description);\n }", "public function toJson()\n\t{\n\t\treturn json_encode($this->data());\n\t}", "public function toJson() {\n return json_encode($this->data);\n }", "private function _a2j($data)\n {\n try {\n $result = Json::encode($data);\n return $result;\n } catch (\\Exception $e) {\n throw new ServerErrorHttpException(Yii::t('common', 'data_error'));\n }\n }", "public function get_data_type() { return \"json\"; }", "public function getData(){ \n return json_decode($this->data); \n }", "public function outputAsJson()\n {\n header('Content-type: application/json');\n echo json_encode($this->result());\n }", "public function toJson() {\n\t\t$data = array();\n\t\tforeach ($this->fields as $name => $field) {\n\t\t\t$data += [$name => $field->toJson()];\n\t\t}\n\t\t$top = array(\"success\"=>$this->getSuccess(),\"data\"=>$data,\"text\"=>$this->text);\n\t\treturn $top;\n\t}", "public function jsonSerialize()\n {\n return [\n \"str\"=>$this->getStr(),\n 'total' => $this->getTotal()\n ];\n }" ]
[ "0.8052981", "0.80510956", "0.800637", "0.7904996", "0.7665152", "0.76454794", "0.7564097", "0.75515175", "0.75512314", "0.7510979", "0.74232316", "0.7417802", "0.7415712", "0.741355", "0.7393738", "0.7393599", "0.73513645", "0.73513645", "0.73513645", "0.73513645", "0.73513645", "0.73513645", "0.7350781", "0.7345813", "0.73154086", "0.72929597", "0.7281166", "0.7274478", "0.7271278", "0.72505516", "0.723571", "0.7191559", "0.7182612", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7179336", "0.7176785", "0.7175565", "0.71752006", "0.71653855", "0.7146443", "0.71401143", "0.7123102", "0.7111371", "0.7103968", "0.7102567", "0.7096378", "0.7046574", "0.70381236", "0.70353526", "0.7034882", "0.7015126", "0.69920266", "0.69889784", "0.6980435", "0.6966447", "0.6960829", "0.69482905", "0.6943793", "0.69415814", "0.6936008", "0.6928865", "0.6926527", "0.6926527", "0.69132423", "0.6912183", "0.69028383", "0.69017327", "0.6891437", "0.6888984", "0.6875153", "0.6874569", "0.68635714", "0.68635714", "0.68635714", "0.68635714", "0.68635714", "0.68635714", "0.68635714", "0.68635714", "0.68552244", "0.6846786", "0.6844659", "0.68416464", "0.6829714", "0.6823272", "0.68205154", "0.6807649", "0.6803241", "0.68029195", "0.67928594", "0.6791455", "0.6790514" ]
0.0
-1
send json error to client
public function returnError($text = '', $code = false, $httpStatusCode = 400) { return $this->returnData(['code' => $code, 'message' => $text], $httpStatusCode); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function error($message){\n die(json_encode([\"error\"=>true,\"data\"=>$message]));\n}", "function errorJSON(){\n header('Content-Type: application/json');\n $output['Error'] = \"Invalid Request\";\n die(json_encode($output));\n }", "protected function error()\n {\n $this->response = $this->response->withStatus(500);\n $this->jsonBody([\n 'input' => $this->payload->getInput(),\n 'error' => $this->payload->getOutput(),\n ]);\n }", "function sendError($errorText){\n echo json_encode(array(\n 'status' => '50x',\n 'infotext' => $errorText\n ));\n die();\n}", "private function error()\n {\n $json = array_merge($this->data, ['message' => $this->error, 'class' => 'error']);\n wp_send_json($json);\n }", "private function send_error($error) {\n header('Content-Type: application/json');\n echo json_encode(array(\n 'error' => $error\n ));\n return;\n }", "function showjson_error($message) {\n\theader('Content-type: application/json');\n\techo json_encode( array(\"error\" => $message) );\n\texit();\n}", "function errorJson($msg){\n\tprint json_encode(array('error'=>$msg));\n\texit();\n}", "function errorResponse ($messsage) {\n header('HTTP/1.1 500 Internal Server Error');\n die(json_encode(array('message' => $messsage)));\n }", "function failure($error) {\r\n $data = array();\r\n $data['success'] = false;\r\n $data['error'] = $error;\r\n\r\n header('Content-Type: application/json');\r\n exit(json_encode($data));\r\n}", "function Error(){\n header('Content-Type: application/json');\n echo ('false');\n http_response_code(200);\n }", "function error($sql) {\n\tif (defined('DEBUG')) {\n\t\tdie($sql);\n\t}\n\theader('Content-Type: application/json');\n\tdie('{\"result\":\"error\"}');\n}", "private function throwJsonError($status, $error)\n\t\t{\n\t\t\t$response = array('status' => $status, 'error' => $error);\n\t\t\techo json_encode($response);\n\t\t\texit;\n\t\t}", "function returnWithError( $err )\n\t{\n\t\t$retValue = json_encode($err);\n\t\tsendResultInfoAsJson( $retValue, JSON_FORCE_OBJECT);\n\t}", "public function actionError() {\n if ($error = Yii::app()->errorHandler->error) {\n\t\t\t$this->sendRestResponse(500,array(\n\t\t\t\t'status' => false,\n\t\t\t\t'message' => $error['message'],\n\t\t\t\t'data' => $error,\n\t\t\t));\t\t\t\n }\n\t}", "function newErr($type, $message) {\n $response = array(\n 'error' => $type,\n 'message' => $message\n );\n return json_encode($response);\n \n }", "function json_error ($msg='', $retval=null, $jqremote = false)\r\n {\r\n if (!empty($msg))\r\n {\r\n $msg = Lang::get($msg);\r\n }\r\n $result = array('done' => false , 'msg' => $msg);\r\n if (isset($retval)) $result['retval'] = $retval;\r\n\r\n $this->json_header();\r\n $json = ecm_json_encode($result);\r\n if ($jqremote === false)\r\n {\r\n $jqremote = isset($_GET['jsoncallback']) ? trim($_GET['jsoncallback']) : false;\r\n }\r\n if ($jqremote)\r\n {\r\n $json = $jqremote . '(' . $json . ')';\r\n }\r\n\r\n echo $json;\r\n }", "function sendFailure( $message ) {\n\t\t$obj = new stdClass();\n\n\t\t$obj->success = false;\n\t\t$obj->errorMessage = $this->escapeJsonString( $message );\n\n\t\t$this->sendJSON( $obj );\n\t}", "public function throw()\n {\n $response = new JsonResponse($this->getResponse(), $this->code);\n\n die($response->send());\n }", "function respondWithError($message, $httpCode = 500) {\n header('Content-Type: application/json');\n http_response_code($httpCode);\n $json = json_encode([\n 'ok' => false,\n 'error' => $message,\n ], JSON_PRETTY_PRINT);\n echo $json;\n exit();\n}", "function upload_error($error)\n{\n\techo json_encode(array(\"error\"=>$error));\n}", "private static function sendBackError() {\n $supported_versions['ERROR'] = JText::_('COM_EASYSDI_SERVICE_FORM_DESC_SERVICE_NEGOTIATION_ERROR');\n echo json_encode($supported_versions);\n die();\n }", "public static function send_http_error( $data )\n {\n \\HttpResponse::status( 400 );\n \\HttpResponse::setContentType( 'application/json' ); \n \\HttpResponse::setData( $data );\n \\HttpResponse::send();\n }", "public function sendError($message=null, $endApplication = false) {\n $error = json_encode(array(\n 'jsonrpc' => $this->version,\n 'id' => isset($this->_request['id']) ? $this->_request['id'] : null,\n 'error' => $message,\n ));\n if ($endApplication) {\n die($error);\n } else {\n echo $error;\n }\n }", "function returnWithError( $err ) {\r\n\t\t$retValue = array('error' => $err);\r\n\t\tsendResultInfoAsJson( $retValue );\r\n\t}", "function report_error($msg) {\n print json_encode ( array (\n \"ResultSet\" => array(\"Result\" => array()),\n \"Message\" => $msg\n ));\n exit;\n}", "protected function get_json_last_error()\n {\n }", "protected abstract function send_error($ex=null) ;", "function return_error($code) {\n $return[\"error\"] = $code;\n echo json_encode($return);\n exit();\n}", "private function json_error($error)\n {\n return response()->json($error,500);\n }", "function returnWithError($err)\n\t{\n\t\t$retVal = '{\"id\" : -1, \"error\":\"' . $err . '\"}';\n\t\tsendResultInfoAsJson($retVal);\n\t}", "function exceptionHandler($e) {\n $msg = array(\"status\" => \"500\", \"message\" => $e->getMessage(), \"file\" => $e->getFile(), \"line\" => $e->getLine());\n $usr_msg = array(\"status\" => \"500\", \"message\" => \"Sorry! Internal server error!\");\n header(\"Access-Control-Allow-Origin: *\"); \n header(\"Content-Type: application/json; charset=UTF-8\"); \n header(\"Access-Control-Allow-Methods: GET, POST\");\n echo json_encode($usr_msg);\n logError($msg);\n\n }", "function error(){}", "function json_error($message, $extra = NULL, $die = TRUE){\r\n\t$json_out = array(\r\n\t\t\"status\" => \"2\",\r\n\t\t\"message\" => $message\r\n\t);\r\n\tif(is_array($extra)){\r\n\t\t$json_out = array_merge($json_out, $extra);\r\n\t}\r\n\tif($die){\r\n\t\tdie(json_encode($json_out));\r\n\t}else{\r\n\t\treturn $json_out;\r\n\t}\r\n}", "public static function sendErrorResponse($error = null){\n http_response_code(500);\n echo $error;\n die();\n }", "function upload_error($error)\n{\n echo json_encode(array(\"error\"=>$error));\n}", "function report_error( $msg ) {\n $status_encoded = json_encode( \"error\" );\n $msg_encoded = json_encode( '<b><em style=\"color:red;\" >Error:</em></b>&nbsp;'.$msg );\n print <<< HERE\n{\n \"ResultSet\": {\n \"Status\": {$status_encoded},\n \"Message\": {$msg_encoded}\n }\n}\nHERE;\n exit;\n}", "public function handleError($e)\n {\n $code = (int) $e->getCode();\n $message = $e->getMessage();\n if ( !in_array($code, $this->_allowedErrorCodes) && $this->isDebugging ) {\n $code = self::ERROR_UNKNOWN;\n }\n \n $this->_server->fault($message, $code, null);\n \n /*\n * Due to a bug in Zend_Json_Server_Error, we have to modify the error\n * response to make sure the custom error code makes it to the client.\n */\n $badJson = $this->_server->getResponse()->toJson();\n \n $decoded = Zend_Json::decode($badJson);\n if ( isset($decoded['error']) \n && isset($decoded['error']['code']) ) {\n $decoded['error']['code'] = $code;\n }\n \n $json = Zend_Json::encode($decoded);\n \n if ($code == self::ERROR_CREDENTIALS_INVALID \n || $code == self::ERROR_DIGEST_INVALID \n || $code == self::ERROR_DIGEST_MISSING) {\n $this->sendAuthChallengeHeader();\n }\n \n header('Content-Type: application/json');\n if (isset($_GET['d'])) die($_GET['jsoncallback'].\"(\".$json.\")\");\n else die($json);\n }", "function errorOutput($output, $code = 500) {\n http_response_code($code);\n echo json_encode($output);\n}", "function showError(){\n\t\techo json_encode(array(\n\t\t\t\"alert\" => \"error\",\n\t\t\t\"title\" => \"Failed to Update!\",\n\t\t\t\"message\" => \"Program Updating has been Failed\"\n\t\t));\n\t}", "function errorMsg($msg){\n $error = array(\"eroare\" => $msg);\n echo JSON_encode($error);\n }", "function showError(){\n\t\techo json_encode(array(\n\t\t\t\"alert\" => \"error\",\n\t\t\t\"title\" => \"Failed to Create!\",\n\t\t\t\"message\" => \"Course Creation has been Failed\"\n\t\t));\n\t}", "private function getError()\n {\n return json_encode(array(\"error\" => $this->errorStack));\n }", "function report_error_and_return( $msg ) {\n $status_encoded = json_encode( \"error\" );\n $msg_encoded = json_encode( '<b><em style=\"color:red;\" >Error:</em></b>&nbsp;'.$msg );\n print <<< HERE\n{\n \"status\": {$status_encoded},\n \"ResultSet\": {\n \"Status\": {$status_encoded},\n \"Message\": {$msg_encoded}\n }\n}\nHERE;\n exit;\n}", "public function getErrors(){\n echo json_encode($this->errors, JSON_PRETTY_PRINT);\n }", "protected function failure()\n {\n $this->response = $this->response->withStatus(400);\n $this->jsonBody($this->payload->getInput());\n }", "public static function sendError($errMessage = \"\") {\n //TODO: send 404\n $responseObj = new Response();\n $body = array();\n $body['error']['code'] = 400;\n $body['error']['type'] = \"error_unknown\";\n $body['error']['message'] = $errMessage;\n $responseObj->setContent(json_encode($body));\n $responseObj->setStatus('400');\n $responseObj->setHeader('Content-Type: application/json');\n\n $responseObj->sendResponse();\n }", "public function Access_error ()\n\t\t{\n\t\t\t$errMsg[0]['error'] = \"Invalid URL!\";\n\t\t\treturn json_encode ($errMsg);\n\t\t}", "function json_error_msg($msg){\n return json_encode('{ \"msg\":\"Error: ' . $msg . '\", \"success\":\"error\" }');\n}", "public function displayException($i) {\n if (!headers_sent())\n header('X-Error: By Brid Api');\n $error = array('name' => $i->getMessage(), 'message' => $i->getFile(), 'error' => $i->getMessage(), 'class' => get_class($i));\n if ($i->getCode() != 0) {\n $error['code'] = $i->getCode();\n }\n\n echo json_encode($error);\n }", "function HTTPFail($message)\n{\n\terrorlog_withlevel(\"message=====>\".$message,3);\n\tprint json_encode(array('error'=>$message));\n\texit(0);\n}", "public function send_resp($error = \"\"){\n\t\tif($error != \"\"){\n\t\t\t$this -> add_error_msg($error);\n\t\t}\n\t\theader(\"Content-type: application/json; charset=UTF-8\");\n\t\theader(\"Pragma: no-cache\");\n\t\theader(\"Expires: Thu, 01 Dec 1997 16:00:00 GMT\");\n\t\techo json_encode($this->return_data);\n\t\tdie;\n\t}", "function raiseError($errorMessage, $responseCode){\n\t global $errors;\n\n\t\thttp_response_code($responseCode);\n\n\t die(json_encode(array(\n\t \t\"error\" => $errorMessage\n\t )));\n\t}", "function setErrorHeader($message){\n\thttp_response_code(404);\n\theader('Content-Type: application/json');\n\techo $message;\n}", "function errorHandler($message, $code){\n echo '{\"errors\":\"'.$message.'\"}';\n http_response_code($code);\n return false;\n }", "public function actionError()\n {\n if($error=Yii::app()->errorHandler->error)\n {\n if($error['code'] != 404 || !isset($aErrorMsg[$error['errorCode']])){\n Yii::log(' error : ' . $error['file'] .\":\". $error['line'] .\":\". $error['message'], 'error', 'system');\n }\n $ret = new ReturnInfo(FAIL_RET, Yii::t('exceptions', $error['message']), intval($error['errorCode']));\n if(Yii::app()->request->getIsAjaxRequest()){\n echo json_encode($ret);\n \n }else{\n if( empty($error['errorCode']) ){\n if(isset($this->aErrorMsg[$error['code']])){\n if(empty($this->aErrorMsg[$error['code']]['message'])) {\n $this->aErrorMsg[$error['code']]['message'] = $error['message'];\n }\n $this->render('error', $this->aErrorMsg[$error['code']]);\n }else{\n $this->render('error', $this->aErrorMsg['1000']);\n }\n }else{\n $this->render('error', $this->aErrorMsg[ $error['errorCode'] ]);\n \n }\n }\n \n } \n }", "public function failAction()\n {\n //====================================================================//\n // Return Dummy Response\n return new JsonResponse(array('result' => 'Ko'), 500);\n }", "function returnWithError($error) {\n $returnValue = '{\"characterNames\": \"\", \"campaignNames\": \"\", \"campaignIDs\": \"\", \"characterID\": \"\",\"DMs\": \"\", \"partySizes\": \"\", \"error\": \"' . $error . '\"}';\n sendResultInfoAsJson($returnValue);\n}", "public function databaseError($errorArray)\n { \n $errorArray = json_encode($errorArray, JSON_PRETTY_PRINT);\n header(\"HTTP/1.0 400 Bad request\");\n header(\"Content-type: application/json\");\n exit($errorArray);\n }", "private function returnError($message){\n return response()->json([\n 'status' => 'error',\n 'error' => $message\n ], 200);\n }", "public function error();", "public function get_errors_json() {\n return json_encode($this->errors);\n }", "private function errorResponse($error)\n {\n $response['status_code_header'] = 'HTTP/1.1 404 Not Found';\n $response['status'] = '400';\n $response['error'] = $error;\n header('HTTP/1.1 404 Not Found');\n echo json_encode($response);\n }", "static function throw_json_last_error (): void {\n if (StaticHandler::supervisor() == false) {\n return;\n }\n\n switch (json_last_error()) {\n case JSON_ERROR_NONE: {\n throw new Exception('JSON_LAST_ERROR: No errors');\n break;\n }\n case JSON_ERROR_DEPTH: {\n throw new Exception('JSON_LAST_ERROR: Maximum stack depth exceeded');\n break;\n }\n case JSON_ERROR_STATE_MISMATCH: {\n throw new Exception('JSON_LAST_ERROR: Underflow or the modes mismatch');\n break;\n }\n case JSON_ERROR_CTRL_CHAR: {\n throw new Exception('JSON_LAST_ERROR: Unexpected control character found');\n break;\n }\n case JSON_ERROR_SYNTAX: {\n throw new Exception('JSON_LAST_ERROR: Syntax error, malformed JSON');\n break;\n }\n case JSON_ERROR_UTF8: {\n throw new Exception('JSON_LAST_ERROR: Malformed UTF-8 characters, possibly incorrectly encoded');\n break;\n }\n default: {\n throw new Exception('JSON_LAST_ERROR: Unknown error');\n break;\n }\n }\n }", "public function getErrorResponseJson()\n { \n $data = array();\n \n foreach ($this->_fields as $name => $info) {\n $errors = array();\n if (isset($this->_errors[$name]) && is_array($this->_errors[$name]) && count($this->_errors[$name]) > 0) { \n $errors = $this->_errors[$name];\n }\n $fieldData = ' \"' . $name . '\" : { \"value\" : \"' . $info['value'] . '\"';\n if (count($errors) > 0) {\n $fieldData .= ', \"errors\" : [ \"' . join('\", \"', $errors) . '\" ]';\n }\n $fieldData .= ' }';\n \n $data[] = $fieldData;\n }\n \n $response = '{ \"type\" : \"error\", \"data\" : { ' . join(', ', $data) . ' } }';\n return $response;\n }", "public function record(): JsonResponse\n {\n $data = request()->input('data');\n $url = request()->input('url');\n $personId = request()->input('person_id');\n $errorType = request()->input('error_type');\n\n $record = [\n 'error_type' => $errorType,\n 'ip' => request_ip(),\n 'url' => $url,\n 'user_agent' => request()->userAgent(),\n 'data' => $data,\n ];\n\n if (is_numeric($personId)) {\n $record['person_id'] = $personId;\n }\n\n $log = new ErrorLog($record);\n $log->save();\n\n return $this->success();\n }", "function constructError($e)\n{\n\treturn json_encode(array('status' => 'Failed', 'error' => '\"' . $e . '\"'));\n}", "public function error(BaseResponse $response);", "function json_response($message = 'Error', $code = 500, $data = null)\n{\n header('Content-Type: application/json');\n $response = array(\n 'code' => $code,\n 'data' => $data,\n 'message' => $message\n );\n http_response_code($code);\n echo json_encode($response);\n}", "public function testError()\n {\n $error = $this->response->error(404, 'File Not Found');\n json_decode($error);\n $checkJson = (json_last_error() == JSON_ERROR_NONE);\n\n $this->assertTrue($checkJson);\n }", "function exitWithError($errorMessage) {\n global $result;\n $result['errorMessage'] = \"Database error: \" . $errorMessage;\n echo json_encode($result);\n exit(1);\n }", "private function jsonException($data)\n {\n $meta = $data->meta;\n return $meta->status.' '.$meta->description.' '.$meta->message.' For more info please visit: '.$meta->moreInfo;\n }", "public function render()\n {\n if(strstr($this->getMessage(), 'PDOException: SQLSTATE[')) {\n if(preg_match('/SQLSTATE\\[(\\w+)\\]:(.*):(\\s+\\d)(.*):(.*)/', $this->getMessage(), $matches) === false) {\n $this->message = 'Generic SQL exception unhandled';\n }\n else {\n $this->message = empty($matches[5]) ? 'Generic SQL exception unhandled' : trim($matches[5]);\n }\n }\n else {\n $this->message = 'Generic SQL exception unhandled';\n }\n\n return response()->json(['message' => $this->getMessage()], 409);\n }", "public function jsonout($error=\"faild\",$msg=\"\",$data){\n $result=array();\n $result['error']=$error;\n $result['msg']=$msg;\n $result['data']=$data;\n die(json_encode($result));\n }", "protected function notValid()\n {\n $this->response = $this->response->withStatus(422);\n $this->jsonBody([\n 'input' => $this->payload->getInput(),\n 'output' => $this->payload->getOutput(),\n 'messages' => $this->payload->getMessages(),\n ]);\n }", "public function error( $data = null ) {\n\t\t$this->send( $data, false );\n\t}", "function ReturnServerError()\n{\n header('HTTP/1.1 500 Internal Server Error');\n die(\"A server error occured while saving your request.\\r\\nPlease check our API status page at http://status.prybar.io and try again later\");\n}", "function returnWithError($error) {\n $returnValue = '{\"campaignID\": \"\", \"error\": \"' . $error . '\"}';\n sendResultInfoAsJson($returnValue);\n}", "function admin_error($code = 5000, $data = [], $msg = '')\n{\n if (empty($data)) $data = (object)[];\n if ($msg == '') {\n $msg = config('admin_response_code')[$code];\n }\n $json = [\n 'code'=>$code,\n 'data'=>$data,\n 'msg'=>$msg\n ];\n return response()->json($json);\n}", "private function fail() {\n\t\theader('HTTP/1.1 400 BAD REQUEST');\n\t\tdie('400 BAD REQUEST');\n\t}", "function errore($messaggio) {\n header($_SERVER['SERVER_PROTOCOL'] . ' 500 Internal Server Error', true, 500);\n die($messaggio);\n}", "function missingParamToPostResponse(){\n\n $return = array(\n 'status' => 400,\n 'message' => \"Missing params to post.\"\n );\n\n http_response_code(400);\n\n //Send back response to client. \n print_r(json_encode($return));\n\n}", "public function error($data)\n {\n $data = ['erro'=>$data];\n return $this->coreResponse($data);\n }", "public function testSendError()\n {\n $this->setMockHttpResponse('JsonPurchaseResponseError.txt');\n $response = $this->request->send();\n\n $data = $this->request->getData();\n\n $code = $response->response->getStatusCode();\n $this->assertFalse($response->isSuccessful());\n $this->assertEquals(500, $data['amount']);\n $this->assertEquals(400, $code);\n $this->assertSame('BAD_REQUEST', $response->getCode());\n $this->assertSame(\"This card is not accepted for Test transactions\", $response->getMessage());\n $this->assertNull($response->getTransactionReference());\n $this->assertNull($response->getCardReference());\n }", "abstract public function error();", "function jsonError($error) {\n\tswitch ( $error ) {\n\t\tcase JSON_ERROR_NONE:\n\t\t\treturn \"No error occurred\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_DEPTH:\n\t\t\treturn \"The maximum stack depth has been exceeded\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_STATE_MISMATCH:\n\t\t\treturn \"Invalid or malformed JSON\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_CTRL_CHAR:\n\t\t\treturn \"Control character error, possibly incorrectly encoded\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_SYNTAX:\n\t\t\treturn \"Syntax error\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_UTF8:\n\t\t\treturn \"Malformed UTF-8 characters, possibly incorrectly encoded\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_RECURSION:\n\t\t\treturn \"One or more recursive references in the value to be encoded\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_INF_OR_NAN:\n\t\t\treturn \"One or more NAN or INF values in the value to be encoded\";\n\t\t\tbreak;\n\t\tcase JSON_ERROR_UNSUPPORTED_TYPE:\n\t\t\treturn \"A value of a type that cannot be encoded was given\";\n\t\t\tbreak;\n\t\tdefault:\n\t\t\treturn \"Unknown error\";\n\t\t\tbreak;\n\t}\n}", "public function jsonSerialize()\n {\n return $this->errors;\n }", "protected static function checkJsonError() {\n if (json_last_error()) {\n throw new Exception('Invalid JSON data: ' . json_last_error_msg());\n }\n }", "function invalidMethodResponse(){\n\n $return = array(\n 'status' => 400,\n 'message' => \"Bad method given\"\n );\n\n http_response_code(400);\n\n //Send back response to client. \n print_r(json_encode($return));\n\n}", "function handle_error($exception) {\n try {\n print $this->encode(array(\n 'error' => $exception->getMessage(),\n 'message' => $exception->getMessage(), // Should be a i18n end user message\n 'data' => @$exception->data,\n 'status' => @$exception->status\n ));\n } catch(Exception $e) {\n echo 'Error: '.$e->getmessage();\n }\n }", "function getErrorMessage(){\n\t$rawerrormessage = array(\"loginError\" => \"User has been logged out\");\n\t$errormessage = json_encode($rawerrormessage);\n\treturn $errormessage;\n}", "public static function sendError($status_code,$message=null) {\n\t\thttp_response_code($status_code);\n\t\techo $message;\n\t}", "public function wrongData($message){\n return response()->json([\n 'success' => false,\n 'message' => $message,\n 'time' => $this->time\n ], 412);\n }", "protected function renderAsError() {}", "function api_error($code=5000, $data = [], $msg = '')\n{\n if (empty($data)) $data = (object)[];\n if ($msg == '') {\n $msg = config('api_response_code')[$code];\n }\n $json = [\n 'code'=>$code,\n 'data'=>$data,\n 'msg'=>$msg\n ];\n return response()->json($json);\n}", "function error($msg)\n{\n header('HTTP/1.1 500 ' . $msg);\n die($msg);\n}", "public function isServerError();", "public function testFailedSend()\n {\n $gateway = $this->app[CoinmarketcapGateway::class];\n $response = $gateway->send('/v1/cryptocurrency/info');\n $this->assertIsString($response);\n $response = json_decode($response, true);\n $this->assertGreaterThan(0, array_get($response, 'status.error_code'));\n }", "function loginFail($type) {\n echo json_encode(['code'=>$type]);\n\n exit();\n}", "protected abstract function send($json);", "public function error()\n {\n $this->status = JSendResponse::STATUS_ERROR;\n\n return $this;\n }" ]
[ "0.7632979", "0.7585827", "0.7397123", "0.7388099", "0.73791444", "0.73624575", "0.72480583", "0.7191553", "0.7074379", "0.7067786", "0.70450485", "0.70417243", "0.6949387", "0.6923869", "0.68519014", "0.6843898", "0.68427193", "0.67916495", "0.6772515", "0.6714598", "0.668935", "0.6686705", "0.66842496", "0.66436553", "0.66331524", "0.66119975", "0.66047615", "0.6522699", "0.65086114", "0.64924914", "0.6444026", "0.6436459", "0.6433161", "0.643085", "0.64302737", "0.6420349", "0.6411698", "0.6409598", "0.63992906", "0.6372245", "0.63710064", "0.63506424", "0.63402027", "0.63385236", "0.6335094", "0.6309019", "0.6296665", "0.6291372", "0.62833655", "0.6270207", "0.6262705", "0.6261245", "0.6252515", "0.6243767", "0.62339836", "0.6197735", "0.6177501", "0.6170526", "0.6154974", "0.613328", "0.61164933", "0.6077423", "0.6070969", "0.6070372", "0.6057632", "0.6053135", "0.60482806", "0.60240036", "0.60199887", "0.6016366", "0.59965235", "0.59881926", "0.5986663", "0.59834987", "0.5980125", "0.59767216", "0.5942118", "0.59290045", "0.59282905", "0.59246075", "0.59066564", "0.5904985", "0.5904687", "0.5904316", "0.5901996", "0.5901274", "0.58895403", "0.5881684", "0.5878127", "0.5860853", "0.5852731", "0.5850609", "0.5848546", "0.5841556", "0.583249", "0.5823221", "0.58164334", "0.58159983", "0.58028895", "0.57866716", "0.5783469" ]
0.0
-1
Send HTTP 401 "Authentication required" status code
public function returnAuthenticationRequired() { return $this->returnData(['message' => 'Authentication required', 'code' => 0], 401); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function send401Unauthorized()\n {\n $this->sendHeader('HTTP/1.1 401 Unauthorized');\n }", "public static function sendUnauthorizedResponse(){\n http_response_code(401);\n die();\n }", "function auth_fail() {\n header('HTTP/1.1 401 Unauthorized');\n header('WWW-Authenticate: Digest realm=\"'.$realm.\n\t '\",qop=\"auth\",nonce=\"'.uniqid().'\",opaque=\"'.md5($realm).'\"');\n}", "public static function error401() {\n header('Unauthorized', true, 401);\n $html401 = sprintf(\"<title>Error 401: Unauthorized</title>\\n\" .\n \"<main><div class=\\\"container\\\"><div class=\\\"row\\\"><div class=\\\"col-lg-10 offset-lg-1\\\">\" .\n \"<div class=\\\"row wow fadeIn\\\" data-wow-delay=\\\"0.4s\\\"><div class=\\\"col-lg-12\\\"><div class=\\\"divider-new\\\">\" .\n \"<h2 class=\\\"h2-responsive\\\">Error 401</h2>\" .\n \"</div></div>\" .\n \"<div class=\\\"col-lg-12 text-center\\\">\" .\n \"<p>You aren’t authenticated, please login and try again.</p>\" .\n \"</div></div></div></div></div></main>\", $_SERVER[\"REQUEST_URI\"]);\n echo $html401;\n }", "public function s401($message = '') { self::respondWithJSON($message, 401); }", "function unauthorized($realm = 'PHPRestSQL') {\n header('WWW-Authenticate: Basic realm=\"'.$realm.'\"');\n header('HTTP/1.0 401 Unauthorized');\n }", "protected function notAuthenticated()\n {\n $this->response = $this->response->withStatus(401);\n $this->jsonBody($this->payload->getInput());\n }", "protected function statusCodeFail(): int\n {\n return 401;\n }", "function unauthorized() {\n\treturn show_template('401');\n}", "function http_require_auth() {\n\theader('WWW-Authenticate: Basic realm=\"HTTP Authentication System\"');\n\theader('HTTP/1.0 401 Unauthorized');\n\techo \"You must enter a valid login ID and password to access this resource\\n\";\n\texit;\n}", "protected function protect()\n {\n header('HTTP/1.1 401 Unauthorized');\n\n switch ($this->type) {\n default:\n case self::AUTH_BASIC:\n header('WWW-Authenticate: Basic realm=\"' . $this->realm . '\"');\n break;\n case self::AUTH_DIGEST:\n header(\n 'WWW-Authenticate: Digest realm=\"' . $this->realm .\n '\", qop=\"auth\", nonce=\"' . md5(uniqid()) . '\", opaque=\"' . md5(uniqid()) . '\"'\n );\n break;\n }\n }", "function req_auth($realm = 'Secret Realm') {\n\theader('WWW-Authenticate: Basic realm=\"'.$realm.'\"');\n\theader('HTTP/1.1 401 Unauthorized');\n\tprint '<h1>Error 401: Authorization Required</h1>';\n\texit;\n}", "function authenticateHeader($message = 'Authentication required')\n{\n header('WWW-Authenticate: Basic realm=\"FusionDirectory\"');\n header('HTTP/1.0 401 Unauthorized');\n echo \"$message\\n\";\n exit;\n}", "public function getAssociatedStatusCode()\n {\n return AbstractResponse::RESPONSE_UNAUTHORIZED;\n }", "function send($error_message)\n\t\t{\n\t\t\theader('WWW-Authenticate: Digest '.\n\t\t\t\t'realm=\"'.$this->realm.'\", '.\n\t\t\t\t'domain=\"'.$this->baseURL.'\", '.\n\t\t\t\t'qop=auth, '.\n\t\t\t\t'algorithm=MD5, '.\n\t\t\t\t'nonce=\"'.$this->getNonce().'\", '.\n\t\t\t\t'opaque=\"'.$this->getOpaque().'\"'\n\t\t\t);\n\t\t\theader('HTTP/1.0 401 Unauthorized');\n\n\t\t\techo $error_message;\n\t\t\texit;\n\t\t}", "function auth() {\n header('WWW-Authenticate: Basic realm=\"Citations\"');\n header('HTTP/1.0 401 Unauthorized');\n print 'authorisation required';\n exit;\n }", "public function authenticationFailure()\n {\n return $this->sendFailed(\"not authenticated\");\n }", "public static function unauthorized($message = 'Unauthorized.')\n {\n throw new ResponseException($message, 401);\n }", "protected function statusCodeUnauthorized(): int\n {\n return $this->statusCodeUnauthorized ?? 403;\n }", "protected function handleUnauthorizedCommand()\n\t{\n // si appel xmlhttp\n\t\tif ( (isset($_SERVER['HTTP_USER_AGENT']) && (strpos($_SERVER['HTTP_USER_AGENT'], 'XMLHTTP') === 0)) \n\t\t\t || (strpos($_SERVER['HTTP_ACCEPT'], 'application/json') === 0) )\n return new ReturnedValues\\Json(json_encode(array('statut'=>false, 'message'=>'Request is not authorized.')), false);\n else\n return new ReturnedValues\\PHP('Request is not authorized.', false);\n\t}", "public function respondUnauthorised($message = 'Unauthorised!')\n {\n return $this->setStatusCode(401)->respondWithError($message);\n }", "public function authenticationReqd(){\n\t\theader('HTTP/1.0 401 Unauthorized');\n\t\t$this['app']['hologram']->setModule(\"WWW\")->log(\\Bakery\\Utilities\\Hologram::NORMAL, \"Response: Page requires authentication\");\r\n\t\t\n\t\t$_SESSION['redirect_to'] = $this['request']['uri'];\n\t\t\n\t\tif($this->isJson()){\n\n\t\t\treturn array(\"response\" => \"authentication required\");\n\t\t\t\n\t\t}\n\t\t\n\t\theader(\"Location: {$this['app']['security.login']['handler']}\");\n\t\t\n\t}", "public function unauthorized()\n\t{\n\t\t$this->template->content = $this->add_view('extinfo/unauthorized');\n\t\t$this->template->content->error_description = _('If you believe this is an error, check the HTTP server authentication requirements for accessing this page and check the authorization options in your CGI configuration file.');\n\t}", "public function test_unauthenticated_error()\n {\n $response = $this->get($this->apiUrl('user'));\n\n $response->assertStatus(401);\n\n $response->assertJson([\n 'message' => 'Unauthenticated.'\n ]);\n }", "protected function setErrorHeader() {\n\t\tif ($this->response_code >= 400 && $this->response_code < 500) {\n\t\t\theader('HTTP/1.1 ' . $this->response_code . \" \" . SVException::g($this->response_code));\n\t\t\texit(0);\n\t\t}\n\t}", "public function unauthorized($message = \"You dont have permissions for this resource\",\n $errorCode = \"AuthException\")\n {\n $this->response = $this->laravelResponse->setContent(json_encode(['message' => $message,\n 'ErrorCode' => $errorCode]))->setStatusCode(401);\n return $this->respond();\n }", "public function respondUnauthorized($message = 'Not authorized!')\n {\n return $this->setStatusCode(401)->respondWithErrors($message);\n }", "function errorHandler($status, $code, $message = null) {\n switch ($code) {\n case 406:\n header(\"HTTP/1.1 $code User $status\");\n if ($message == null)\n $message = 'Wrong credentials provided'; \n break;\n case 409:\n header(\"HTTP/1.1 $code $status\");\n if ($message == null)\n $message = 'There was a conflict with the data being sent'; \n break;\n case 500:\n header(\"HTTP/1.1 $code $status. Bad connection, portal is down\");\n if ($message == null)\n $message = \"The server is down, we couldn't retrieve data from the database\";\n break;\n }\n die($message);\n }", "protected function unauthorizedArea()\n\t{\n\t\t// Disable if there is a text file there.\n\t\tif ( file_exists(LD_PLUGIN_DIR.'/disable_auth.txt'))\n\t\t\treturn;\n\t\t\n\t\theader('WWW-Authenticate: Basic realm=\"'. $this->instance->relm.'\"');\n\t\theader('HTTP/1.0 401 Unauthorized');\n\t\techo '<h1>Authorization Required.</h1>';\n\t\texit;\n\t}", "private function fail() {\n\t\theader('HTTP/1.1 400 BAD REQUEST');\n\t\tdie('400 BAD REQUEST');\n\t}", "public function checkAccess()\n {\n if (!$this->isAuthenticated()) {\n header('HTTP/1.1 401 Unauthorized');\n exit();\n }\n }", "protected function failedAuthorization()\n {\n throw new UnauthorizedException();\n }", "protected function getUnauthorizedResponse()\n {\n $authHeaderValue = $this->realm === null ? static::AUTHENTICATION_SCHEME :\n static::AUTHENTICATION_SCHEME . ' realm=\"' . $this->realm . '\"';\n\n return $this->integration->createResponse(\n null,\n Response::HTTP_UNAUTHORIZED,\n [self::HEADER_WWW_AUTHENTICATE => $authHeaderValue]\n );\n }", "protected function notAuthorized()\n {\n $this->response = $this->response->withStatus(403);\n $this->jsonBody($this->payload->getInput());\n }", "private function _prompt_login($user_id = 0)\n {\n header('WWW-Authenticate: Basic realm=\"'.$user_id.'\"');\n header('HTTP/1.0 401 Unauthorized');\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)->respondWithError($message);\n }", "function checkAuthorized() {\n\t if (AUTHORIZED === true) {\n\t \t// authorized\n\t } else {\n\t \theader('HTTP/1.0 401 Unauthorized');\n\t \techo 'failed authorization';\n\t \texit(401);\n\t } \n }", "public function failedAuthorization()\n {\n\n throw new HttpResponseException(response()->json(['message' => 'You are not authorized to edit this Note.'],\n 429));\n\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n $this->error($message, 401);\n }", "public function errorUnauthorized($content = '') {\n return $this->error($content, Codes::HTTP_UNAUTHORIZED);\n }", "function authError()\r\n\t{\r\n\t\t$ajax = ajax();\r\n\t\t\r\n\t\t$ajax->warning(\"Could no Authenticate. Please re-login\");\r\n\t}", "function statusCode()\n {\n }", "public static function error_response() {\r\n header(\"HTTP/1.1 404 Recurso no encontrado\");\r\n exit();\r\n }", "function HTTPFailWithCode($code,$message)\n{\n\theader(reasonForCode($code));\n\texit($message);\n}", "public function respondUnauthorizedError($message = 'Unauthorized!')\n {\n return $this->setStatusCode(IlluminateResponse::HTTP_UNAUTHORIZED)->respondWithError($message);\n }", "protected function sendFailedLoginResponse()\n {\n return response()->json([\n 'message' => $this->errorMessage,\n ], 401);\n }", "public function respondUnauthorized($message = 'Unauthorized!')\n {\n if (!!$this->customStatusCode) {\n return $this->setCustomStatusCode($this->customStatusCode)->respondWithError($message);\n }\n return $this->setCustomStatusCode(4001)->respondWithError($message);\n }", "private function _secureBackend()\n\t{\n\t\tif (!$this->_isAuthenticated()) {\n\t\t\theader(\"HTTP/1.1 401 Unauthorized\");\n\t\t\texit();\n\t\t}\n\t}", "public static function requireUnauthorized()\n {\n if(SessionHelper::isUserLoggedIn()){\n header('location: ' . (string)getenv('URL') . '/');\n }\n }", "function httpForbidden() {\n header('HTTP/1.1 403 Forbidden');\n echo '<h1>403 - Interdit</h1>';\n exit('Le serveur a compris la requête, mais refuse de l\\'exécuter.');\n}", "protected static function apiResponseUnauthorized($message){\n self::setStatusCode(Response::HTTP_UNAUTHORIZED);\n return self::apiResponse([\n 'status' => 'error',\n 'status_code' => self::getStatusCode(),\n 'message' => $message,\n ]);\n }", "protected function failedAuthorization()\n {\n if ($this->container['request'] instanceof Request) {\n throw new HttpException(403);\n }\n\n parent::failedAuthorization();\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(HttpResponse::HTTP_UNAUTHORIZED)\n ->respondWithError($message, self::CODE_UNAUTHORIZED);\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)\n ->respondWithError($message);\n }", "function check_auth() {\n global $conf;\n if ($_SERVER['PHP_AUTH_USER'] !== $conf['username'] && $_SERVER['PHP_AUTH_PW'] !== $conf['password']) {\n header('WWW-Authenticate: Basic realm=\"CMS\"');\n header('HTTP/1.0 401 Unauthorized');\n print 'Could not authorise.';\n die();\n }\n}", "public function get_response()\r\n {\r\n $response = Response::factory()\r\n ->status(401)\r\n ->headers('Location', URL::site('user/enter'));\r\n return $response;\r\n }", "function status($code) {\n $reason=@constant('self::HTTP_'.$code);\n if (PHP_SAPI!='cli')\n header($_SERVER['SERVER_PROTOCOL'].' '.$code.' '.$reason);\n return $reason;\n }", "public function testFailLogin()\n {\n $response = $this->call('GET', '/api/v1/[email protected]&password=12345');\n \n $this->assertEquals(401, $response->status());\n }", "protected function respondUnauthorized(\n string $message = 'Unauthorized',\n int $code = 40100,\n array $headers = []\n ): JsonResponse\n {\n $this->setStatusCode(IlluminateResponse::HTTP_UNAUTHORIZED);\n\n return $this->respondWithError($message, $code, $headers);\n }", "public function respondUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)->respondWithError($message);\n }", "public function index()\n {\n return Response::json([\n 'error' => 'access_denied'\n ], 401);\n }", "public function start(Request $request, AuthenticationException $authException = null) : Response\n {\n return new Response(Constants::UNAUTHORIZED_MESSAGE, 401, [\"Content-Type\" => \"application/json\"]);\n }", "public function forbidden() :string {\n\t\theader('HTTP/1.0 403 Forbidden');\n\t\tdie('Api overloaded 403 forbidden');\n\t}", "private function login()\n {\n if (!isset($_SERVER['PHP_AUTH_USER']) || !$this->isAdmin()) {\n header('WWW-Authenticate: Basic realm=\"My Realm\"');\n header('HTTP/1.0 401 Unauthorized');\n exit;\n }\n }", "public function report(Exception $exception)\n {\n\t\t/*if ($exception instanceof \\League\\OAuth2\\Server\\Exception\\OAuthServerException && $exception->getCode() == 9) {\n\t\t\treturn response()->json(['message' => 'Unauthenticated'], 200);\n\t\t}*/\n parent::report($exception);\n }", "public function getErrorStatusCode(): int\n {\n return 403;\n }", "private function unauthorized($message = null){\n return response()->json([\n 'message' => $message ? $message : 'No estas autorizado para acceder a este recurso',\n 'success' => false\n ], 401);\n }", "function check_auth_response_code($status) {\n\n if ($status != 'S000') {\n $message = get_ticket_error_message($status);\n return result_error($status,$message);\n }\n return result_success();\n}", "function authenticate() {\n //this would be for hard-coded username/password, sometimes useful if you \n //don't have a database\n //echo $_SERVER[\"PHP_AUTH_USER\"] . \"<BR>\";\n if ((isset($_SERVER[\"PHP_AUTH_USER\"]) && ($_SERVER['PHP_AUTH_USER'] == 'client') &&\n isset($_SERVER['PHP_AUTH_PW']) && ($_SERVER[\"PHP_AUTH_PW\"] == 'secret'))) {\n header('HTTP/1.0 200 OK'); //all is good!\n } else {\n -\n //don't let them in!\n header('WWW-Authenticate: Basic realm=\"Test Authentication System\"');\n header('HTTP/1.0 401 Unauthorized');\n echo \"You must enter a valid login ID and password to access this resource\\n\";\n }\n exit; //stop execution of the program so we don't get any more errors\n}", "function setErrorHeader($message){\n\thttp_response_code(404);\n\theader('Content-Type: application/json');\n\techo $message;\n}", "public static function access_denied($error = 'Access Denied') {\n // Clear any buffered crap\n ob_end_clean();\n header(\"HTTP/1.1 403 $error\");\n require_once Config::get('prefix') . '/templates/show_denied.inc.php';\n exit;\n }", "function getStatusCode();", "public function isUnauthorized(): bool\n {\n return \\in_array($this->getStatusCode(), [401, 403]);\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->setStatusCode(401)\n ->respondWithError($message, self::CODE_UNAUTHORIZED);\n }", "public function forbidden() {\n return $this->setStatus(403);\n }", "public function assertUnauthorized(): self\n {\n $actual = $this->response->getStatusCode();\n\n PHPUnit::assertSame(\n 401, $actual,\n \"Response status code [{$actual}] is not an unauthorized status code.\"\n );\n\n return $this;\n }", "public function forbiddenResponse()\n {\n // (default is to just redirect to initial page with errors)\n //\n // Can return a response, a view, a redirect, or whatever else\n\n return Response::make('Permission denied foo!', 403);\n }", "public function forbiddenResponse()\n {\n //return redirect('error')->with('error_message', $this->error);\n //return response(view('errors.403'), 403);\n abort(403);\n }", "public function test_unauthorized_user_cannot_access_the_user_route()\n {\n $response = $this->getJson('/user');\n\n $response->assertStatus(401);\n }", "function http_send_status($status) {}", "protected function respondUnauthorized($message)\n {\n return response()->json([\n 'success' => false,\n 'message' => $message\n ], 401);\n }", "public function uriError()\n {\n header(\"HTTP/1.0 404\");\n exit();\n }", "public function onAuthenticationFailure(\n Request $request,\n AuthenticationException $exception)\n {\n return new Response('Authentication Failed. ', 403);\n }", "private static function generateFailedAuthResponse(&$response) {\n $response->getHeaders()->addHeaders([\n 'Date' => gmdate('D, d M Y H:i:s T'),\n 'Content-Type' => 'application/json; charset=UTF-8'\n ]);\n $response->setContent(\\Zend\\Json\\Json::encode(['success' => false, 'data' => false, 'errors' => 'Request authorization failed, check keys/payload']));\n $response->getHeaders()->addHeaderLine('Content-Type', 'application/json');\n $response->setStatusCode(403);\n }", "public function abortIfRequestUnauthorized(): void\n {\n if ($this->isUnauthorized()) {\n throw new UnauthorizedException($this);\n }\n }", "public static function halt($status = 401, $message = null) {\n if ($message === null) {\n $requestHeaders = Rock::getHeaders();\n $origin = array_key_exists('Origin', $requestHeaders) === true ? $requestHeaders['Origin'] : '*';\n\n header(\"HTTP/1.1 $status \". Util::$codes[$status]);\n header(\"Access-Control-Allow-Origin: $origin\");\n header('Access-Control-Allow-Methods: '. implode(', ', Config::get('CORS_METHODS')));\n header('Access-Control-Allow-Headers: '. implode(', ', Config::get('CORS_HEADERS')));\n header('Access-Control-Allow-Credentials: true');\n header('Access-Control-Max-Age: '. Config::get('CORS_MAX_AGE'));\n header('Content-Type: application/json');\n } else {\n Rock::JSON(['error' => $message], $status);\n }\n\n exit;\n }", "public static function errorUnauthorized($message = 'Unauthorized')\n {\n return static::error($message, 401);\n }", "public function unauthorized($message = null)\n {\n throw new Zend_Controller_Action_Exception($message, 401);\n }", "public function s403($message = '') { self::respondWithJSON($message, 403); }", "public function testOnAuthenticationFailure(): void\n {\n $this->serverService->expects($this->once())\n ->method('getVariable')\n ->with('realm')\n ->will($this->returnValue('mock_realm'))\n ;\n\n $response = $this->authenticator->onAuthenticationFailure(\n new Request(),\n new AuthenticationException('Authentication failure message')\n );\n\n $this->assertSame(401, $response->getStatusCode());\n $this->assertSame('{\"error\":\"access_denied\",\"error_description\":\"Authentication failure message\"}', $response->getContent());\n }", "protected function redirectNotAuthorized(){\r\n if(!$this->auth()->isAuthorized()){\r\n header(\"Location: \".BASE_URI.Routes::getUri('access_denied_authorization'));\r\n }\r\n }", "protected function abortUnauthorized() {\n\t\t$identifier = KLog::log('Unauthorized execution of controller task \"'.$this->executedTask.'\" was attempted. Request variables were '.var_export(KRequest::getAll(), true), 'authorization');\n\t\tthrow new Exception('Application authentication and authorization needed. See authorization log file, identifier '.$identifier, 403);\n\t}", "public function renderErrorNotAdmin(): void\n {\n header('HTTP/1.1 301 Not Found');\n header('Location: /error/notAdmin');\n die();\n }", "public function errorUnauthorized($message = 'Unauthorized')\n {\n return $this->failed($message, 401);\n }", "public function testUnauthorizedGetUserPeopleFails()\n {\n $response = $this->withHeaders([\n 'Accept' => 'application/json'\n ]) ->get('/api/v1/people');\n\n\n $response->assertStatus(401);\n }", "function response400( $missing_param = '' ) {\n if ( headers_sent() )\n return;\n header( 'HTTP/1.1 400 Bad Request', true, 400 );\n header( 'Content-Type: text/plain', true );\n if ( $missing_param )\n echo $missing_param . ' required';\n exit();\n}", "public function test_unauthorized_fetch()\n {\n $headers = [\n 'Authorization' => \"Bearer None\"\n ];\n\n $response = $this\n ->withHeaders($headers)\n ->json('GET', '/api/github-users', [\n 'logins' => [\n 'souinhua',\n 'taylorotwell',\n 'no_one_151asd@'\n ]\n ]);\n\n $response->assertStatus(Response::HTTP_UNAUTHORIZED);\n }", "public function testUnsubscribe401() {\n list($provider, $api) = $this->mockProvider();\n $api->method('get')->willReturn(['id' => 'foo']);\n $api->method('delete')->will($this->throwException(new ApiError('dotmailer', 'Access denied', [], 401)));\n $this->expectException(ApiError::class);\n $list = new NewsletterList(['identifier' => 'mock_list']);\n $item = new QueueItem(['email' => '[email protected]']);\n // Throw exception.\n $provider->unsubscribe($list, $item);\n }", "public function action_basic() {\n\tif (Input::server(\"PHP_AUTH_USER\", null) == null) {\n\t $response = new Response();\n\t $response->set_header('WWW-Authenticate', 'Basic realm=\"Authenticate for eventual.org\"');\n\t return $response;\n\t} else {\n\t $response = Response::forge(\"You are authenticated as \" . Input::server(\"PHP_AUTH_USER\"));\n\t return $response;\n\t}\n }", "public function testWrongUser(){\n Session::flush();\n $user = $this->postuser(array('username'=>'XxX','password'=>'XxX'));\n $status_message = $this->getJsonResponse();\n $this->assertResponseStatus('401');\n $this->assertTrue($status_message['message'] == 'login refused');\n }" ]
[ "0.8216201", "0.81008023", "0.7846694", "0.7755906", "0.77222306", "0.7478525", "0.7337011", "0.7301291", "0.7268585", "0.6983205", "0.691656", "0.6889534", "0.68442875", "0.68035966", "0.6802673", "0.67704", "0.6762086", "0.6607522", "0.65094084", "0.6444533", "0.6435986", "0.6419534", "0.63998246", "0.6397129", "0.63325024", "0.6323926", "0.6311193", "0.63058424", "0.62791246", "0.62753594", "0.6255149", "0.624618", "0.62410086", "0.62330043", "0.61758715", "0.61698514", "0.6155704", "0.61476016", "0.6143195", "0.6142114", "0.6123459", "0.6095815", "0.6094713", "0.6089017", "0.6081616", "0.607205", "0.6067266", "0.606461", "0.60501796", "0.6049031", "0.604344", "0.6033214", "0.60204303", "0.60134345", "0.60117567", "0.6011202", "0.60005766", "0.5991155", "0.5990364", "0.5988714", "0.59731156", "0.5968504", "0.59678674", "0.59525925", "0.59406686", "0.59294367", "0.59211123", "0.5912875", "0.5909674", "0.58931637", "0.5879496", "0.58719105", "0.58689", "0.5867515", "0.5853746", "0.58534276", "0.58515704", "0.58486736", "0.583668", "0.5834423", "0.58328694", "0.5829473", "0.5819041", "0.58183706", "0.58163196", "0.5789149", "0.5788631", "0.5772205", "0.5771692", "0.57714623", "0.57667685", "0.5756158", "0.57518095", "0.57417953", "0.5732344", "0.57321626", "0.5725836", "0.57027483", "0.5694034", "0.56844944" ]
0.65937203
18
Send HTTP 403 "Forbidden" status code
public function forbiddenAction(string $message = null, int $code = 0) { if (is_null($message)) { $message = 'Action is forbidden for your role'; } return $this->returnData(['message' => $message, 'code' => $code], 403); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function forbidden() :string {\n\t\theader('HTTP/1.0 403 Forbidden');\n\t\tdie('Api overloaded 403 forbidden');\n\t}", "function httpForbidden() {\n header('HTTP/1.1 403 Forbidden');\n echo '<h1>403 - Interdit</h1>';\n exit('Le serveur a compris la requête, mais refuse de l\\'exécuter.');\n}", "public function forbidden() {\n return $this->setStatus(403);\n }", "public function forbidden()\n {\n return response()->json([\"error\" => Config::get('constants.http_error.e403')], 403);\n }", "public function s403($message = '') { self::respondWithJSON($message, 403); }", "public function forbidden() {\n\t\t\theader('HTTP/1.0 403 Forbidden');\n\t\t\t$this->render('error/403.twig.html');\n\t\t}", "public function forbiddenResponse()\n {\n //return redirect('error')->with('error_message', $this->error);\n //return response(view('errors.403'), 403);\n abort(403);\n }", "public static function error403() {\n header('Forbidden', true, 403);\n $html403 = sprintf(\"<title>Error 403: Forbidden</title>\\n\" .\n \"<main><div class=\\\"container\\\"><div class=\\\"row\\\"><div class=\\\"col-lg-10 offset-lg-1\\\">\" .\n \"<div class=\\\"row wow fadeIn\\\" data-wow-delay=\\\"0.4s\\\"><div class=\\\"col-lg-12\\\"><div class=\\\"divider-new\\\">\" .\n \"<h2 class=\\\"h2-responsive\\\">Error 403</h2>\" .\n \"</div></div>\" .\n \"<div class=\\\"col-lg-12 text-center\\\">\" .\n \"<p>You don’t have permission to access this resource.</br>\n If you think that this is a mistake, please contact the system administrator.</p>\" .\n \"</div></div></div></div></div></main>\", $_SERVER[\"REQUEST_URI\"]);\n echo $html403;\n }", "public static function write403() {\r\n // impostiamo il codice della risposta http a 404 (file not found)\r\n header('HTTP/1.0 403 Forbidden');\r\n $titolo = \"Accesso negato\";\r\n $messaggio = \"Non hai i diritti per accedere a questa pagina\";\r\n $login = true;\r\n include_once('error.php');\r\n exit();\r\n }", "protected function notAuthorized()\n {\n $this->response = $this->response->withStatus(403);\n $this->jsonBody($this->payload->getInput());\n }", "public function forbiddenResponse( ) {\n if ( $this->ajax() || $this->wantsJson() ) {\n return (new ApiController())->setStatusCode(403)->respondWithError($this->ForbiddenMessage);\n }//if ( $this->ajax() || $this->wantsJson() )\n return parent::forbiddenResponse();\n }", "public static function forbidden($message = 'Forbidden.')\n {\n throw new ResponseException($message, 403);\n }", "public static function forbidden(){\n\n throw new \\yii\\web\\HttpException(403, 'Forbidden Access not Available', 405);\n\n }", "public function forbiddenResponse()\n {\n // (default is to just redirect to initial page with errors)\n //\n // Can return a response, a view, a redirect, or whatever else\n\n return Response::make('Permission denied foo!', 403);\n }", "public function indexAction() {\n return $this->getResponse()->setHttpResponseCode(403);\n }", "public function isForbidden();", "public function redirect403(){\n\t\t\n\t\t$this->page = new PageGenerator($this->app);\n\t\t$this->page->setContentFile(__DIR__ . '/../Errors/403');\n\t\t\n\t\t$this->addHeader('HTTP/1.0 403 Forbidden');\n\t\t\n\t\t$this->send();\n\t\t\n\t}", "public static function sendUnauthorizedResponse(){\n http_response_code(401);\n die();\n }", "function forbidden($message = null){\n\t\t$this->setStatusCode(403);\n\t\t$this->clearOutputBuffer();\n\t\tif(!isset($message)){\n\t\t\t$message = \"\n\t\t\t\tYou don't have permission to access \".htmlspecialchars($GLOBALS[\"HTTP_REQUEST\"]->getRequestURI()).\"\n\t\t\t\ton this server.\n\t\t\t\";\n\t\t}\n\t\t$this->_writeStatusMessage($message);\n\t}", "public static function error403($text = '') {\n header(\"{$_SERVER['SERVER_PROTOCOL']} 403 Forbidden\");\n View::render(static::VIEW_ERROR_HTTP, [\n 'code' => 403,\n 'msg' => $text ? $text : 'You are not authorized to perform this action.',\n ], static::LAYOUT_ERROR_HTTP, false, App::requestIsAjax());\n static::end(43);\n }", "public function forbidden($code = 403)\n {\n return response([\n \"status\" => false,\n \"message\" => __(\"Forbidden request.\"),\n ], $code);\n }", "public function postAction() {\n return $this->getResponse()->setHttpResponseCode(403);\n }", "private static function rejectRequest()\n {\n header('HTTP/1.1 403 Forbidden'); \n\n die(MODE == 'DEV' ? 'Request is missing the required CSRF token' : '');\n }", "protected function show403()\n {\n $resp = $this->render('errors/403.phtml');\n $resp->status = 403;\n return $resp;\n }", "public function throwForbidden()\n {\n throw new Exception\\ForbiddenException('Forbidden', 1449130939);\n }", "public function getErrorStatusCode(): int\n {\n return 403;\n }", "public function respondForbidden($message = 'Forbidden!')\n {\n if (!!$this->customStatusCode) {\n return $this->setCustomStatusCode($this->customStatusCode)->respondWithError($message);\n }\n return $this->setCustomStatusCode(4003)->respondWithError($message);\n }", "public function respondForbidden($message = 'Forbidden')\n {\n return $this->setStatusCode(403)->respondWithError($message);\n }", "public static function access_denied($error = 'Access Denied') {\n // Clear any buffered crap\n ob_end_clean();\n header(\"HTTP/1.1 403 $error\");\n require_once Config::get('prefix') . '/templates/show_denied.inc.php';\n exit;\n }", "public function errorForbidden($message = 'Forbidden')\n {\n return $this->setStatusCode(403)->respondWithError($message);\n }", "public function errorForbidden($message = 'Forbidden')\n {\n $this->error($message, 403);\n }", "public function show() {\r\n\t\t@header('HTTP/1.0 403 Forbidden');\r\n\t\tWCF::getTPL()->display('permissionDenied');\r\n\t}", "public static function errorForbidden($message = 'Forbidden')\n {\n return static::error($message, 403);\n }", "public function csrfForbiddenAction() {\n \t$this->getResponse()->setRawHeader(\"HTTP/1.1 403 Forbidden\");\n\n parent::$_flashmessenger->addMessage(\"Attenzione, per questioni di sicurezza si prega di aggiornare la pagina prima di effettuare la login.\");\n parent::$_flashmessenger->addMessage(\"Si consiglia di non memorizzare mai le informazioni di login.\");\n \n // assegno i valori alla view\n $this->viewInit();\n $this->view->messaggi= parent::$_flashmessenger->getMessages();\n $this->view->title = parent::$_config->application->name.\" - 403 Forbidden\";\n $this->view->pagetitle = \"403 Forbidden\";\n\n // Redirect all'homepage\n parent::$_redirector->gotoUrl($this->_siteurl.\"/home\");\n }", "public function respondForbiddenError($message = 'Forbidden!')\n {\n return $this->setStatusCode(IlluminateResponse::HTTP_FORBIDDEN)->respondWithError($message);\n }", "public function errorForbidden($message = 'Forbidden')\n {\n return $this->setStatusCode(403)\n ->respondWithError($message);\n }", "function redirect_403()\n{\n // prevent Browser cache for php site\n header(\"Cache-Control: no-store, no-cache, must-revalidate, max-age=0\");\n header(\"Cache-Control: post-check=0, pre-check=0\", false);\n header(\"Pragma: no-cache\");\n header('HTTP/1.1 403 Forrbidden');\n exit;\n}", "public function errorForbidden($message = 'Forbidden')\n {\n return $this->setStatusCode(HttpResponse::HTTP_FORBIDDEN)\n ->respondWithError($message, self::CODE_FORBIDDEN);\n }", "public function deleteAction() {\n return $this->getResponse()->setHttpResponseCode(403);\n }", "public function errorForbidden($message = 'Forbidden')\n {\n return $this->setStatusCode(403)\n ->respondWithError($message, self::CODE_FORBIDDEN);\n }", "function accessDenied($message = null)\n{\n $final_message = \"Access denied\";\n\n if ($message) {\n $final_message = \"$final_message: $message\";\n }\n \n $return = jsonErrorResponse($final_message, 403);\n\n return $return;\n}", "function show_deny() {\n\t\t\tshow_error(\n\t\t\t\t'403 Forbidden',\n\t\t\t\t'You do not have sufficient clearance to view this page.'\n\t\t\t);\n\t\t}", "public function formatForbiddenError();", "public static function forbidden(ServerRequestInterface $request, ResponseInterface $response) {\n global $app;\n //On met a jour les donnees flash\n Flash::next();\n\n $img = self::getGIF(\"no\", $request->getUri()->getBaseUrl() . \"/ressources/img/403.gif\");\n\n return $app->getContainer()->view->render($response, \"erreur403.html\", compact(\"img\"))->withStatus(403);\n }", "public function putAction() {\n return $this->getResponse()->setHttpResponseCode(403);\n }", "public function forbiddenAction() {\n }", "public static function send403($msg=null, $detail=null) {\n if ( headers_sent() ) {\n echo(\"Headers sent - they would be:\\n\");\n echo(\"HTTP/1.1 403 Forbidden\".\"\\n\");\n if ( is_string($msg) ) echo(\"X-Error-Message: \".$msg.\"\\n\");\n if ( is_string($detail) ) echo(\"X-Error-Detail: \".$detail.\"\\n\");\n } else {\n header(\"HTTP/1.1 403 Forbidden\");\n if ( is_string($msg) ) header(\"X-Error-Message: \".$msg);\n if ( is_string($detail) ) header(\"X-Error-Detail: \".$detail);\n }\n }", "function methodNotAllowed($allowed = 'GET, HEAD') {\n header('HTTP/1.0 405 Method Not Allowed');\n header('Allow: '.$allowed);\n }", "protected function sendForbidden($error) {\n ob_start();\n echo 'WMI_RESULT=RETRY&WMI_DESCRIPTION=' . urlencode($error);\n ob_end_flush();\n }", "public function forbiddenResponse()\n {\n flash('Você não tem permissão para acessar a página solicitada.', 'danger');\n\n return $this->redirector->back();\n }", "public static function forbiddenException(string $message = null): JsonResponse\n {\n static::$statusCode = Response::HTTP_FORBIDDEN;\n static::$content = [\n 'message' => $message ?? Lang::get('exception.forbidden'),\n 'error' => 'Forbidden'\n ];\n return static::sendResponse();\n }", "function forbidden(){\n\t\t$this->render_view(\"errors/forbidden.php\");\n\t}", "function access_denied() {\n\t\tif ( ! php_version_at_least( '4.1.0' ) ) {\n\t\t\tglobal $_SERVER;\n\t\t}\n\n\t\t// Si viene por webservice no necesita estar logueado.\n\t\tif($_POST['code']=='14149989'){\n\t\t\treturn;\n\t\t}\n\t\t\n\t\tif ( ! auth_is_user_authenticated() ) {\n\t\t\t$p_return_page = string_url( $_SERVER['REQUEST_URI'] );\n\t\t\tprint_header_redirect( 'index.php?m=webtracking&a=login_page&return=' . $p_return_page );\n\t\t} else {\n\t\t\tglobal $AppUI;\n\t\t\t$AppUI->redirect(\"m=public&a=access_denied\");\n\t\t\t\n\t\t\t/*\n\t\t\tprint '<center>';\n\t\t\tprint '<p>'.error_string(ERROR_ACCESS_DENIED).'</p>';\n\t\t\tprint_bracket_link( 'index.php?m=webtracking&a=main_page', lang_get( 'proceed' ) );\n\t\t\tprint '</center>';*/\n\t\t}\n\t\texit;\n\t}", "public function forbiddenError() {\n sfContext::getInstance()->getController()->redirect('errores/forbidden');\n\t}", "public function notAllowedDeliverHook()\n {\n if (CHAMELEON_CHECK_VALID_USER_SESSION_ON_PROTECTED_DOWNLOADS) {\n throw new AccessDeniedHttpException('Access denied.');\n }\n }", "public static function sendNotFoundResponse(){\n http_response_code(404);\n die();\n }", "public function assertForbidden(): self\n {\n PHPUnit::assertSame(\n 403, $this->response->getStatusCode(),\n 'Response status code [' . $this->response->getStatusCode() . '] is not a forbidden status code.'\n );\n\n return $this;\n }", "function unauthorized() {\n\treturn show_template('401');\n}", "private function userNotPermit(){\n throw new \\Symfony\\Component\\HttpKernel\\Exception\\AccessDeniedHttpException('Bad user',null, 403);\n }", "function deny($message = null) {\n // Ignore soft 403 for ajax requests as redirections is transparent.\n if (config\\SOFT_403 != false && !\\melt\\request\\is_ajax()) {\n $user = get_user();\n if ($user === null) {\n if (config\\LAST_DENY_AUTOREDIRECT)\n $_SESSION['userx\\LAST_DENY_PATH'] = APP_ROOT_URL . \\substr(REQ_URL, 1);\n if ($message === null)\n $message = _(\"Access denied. You are not logged in.\");\n \\melt\\messenger\\redirect_message(config\\SOFT_403, $message, \"bad\");\n } else {\n if ($message === null)\n $message = _(\"Access denied. Insufficient permissions.\");\n \\melt\\messenger\\redirect_message(config\\SOFT_403, $message, \"bad\");\n }\n } else\n \\melt\\request\\show_xyz(403);\n exit;\n}", "public static function uriProcessorForbidden()\n {\n return 'Forbidden.';\n }", "protected function accessDenied()\n\t{\n\t\t$this->title = \"Доступ закрыт!\";\n\t\t$this->meta_desc = \"Доступ к данной странице закрыт.\";\n\t\t$this->meta_key = \"доступ закрыт, доступ закрыт страница, доступ закрыт страница 403\";\n\n\t\t$pm = new PageMessage();\n\t\t$pm->header = \"Доступ закрыт!\";\n\t\t$pm->text = \"У Вас нет прав доступа к данной странице.\";\n\t\t$this->render($pm);\n\t}", "public static function banned()\n {\n // Set the \"forbidden\" status code\n Http::setHeadersByCode(403);\n\n // Inclusion of the HTML IP Banned page\n include PH7_PATH_SYS . 'global/views/' . PH7_DEFAULT_THEME . '/other/banned.html.php';\n\n // Stop script\n exit;\n }", "protected function failedAuthorization()\n {\n if ($this->container['request'] instanceof Request) {\n throw new HttpException(403);\n }\n\n parent::failedAuthorization();\n }", "public function forbiddenResponse()\n {\n flash()->error(trans('defaults.auth.error'));\n\n return redirect()->back();\n }", "public function createForbidden($message = 'Forbidden')\n {\n return $this->createWithError($message, 403, self::CODE_FORBIDDEN);\n }", "public function send401Unauthorized()\n {\n $this->sendHeader('HTTP/1.1 401 Unauthorized');\n }", "function Generic_deny($message = \"An error has occured\")\n{\n exit(\n json_encode(\n array(\n \"message\"=>$message,\n \"tracking_id\"=>LoggingEngine::$TRACKING_ID\n )\n )\n );\n}", "public function action_access_denied()\r\n\t{\r\n\t\t$this->title = \"Access Denied\";\r\n\t\t$this->template->content = View::factory('access_denied');\r\n\t}", "protected function methodNotAllowed()\n\t{\n $this->response->setStatusCode(405);\n\n return [\n 'content' => 'Method Not Allowed'\n ];\t\t\n\t}", "protected function redirectNotAuthorized(){\r\n if(!$this->auth()->isAuthorized()){\r\n header(\"Location: \".BASE_URI.Routes::getUri('access_denied_authorization'));\r\n }\r\n }", "public static function accessDenied() {\r\n self::redirectTo(self::urlFor('includes/shared/access_denied.php'));\r\n }", "static function denied()\n {\n\n }", "public function forbidden() {\n\t\treturn [\n\t\t\t'errors' => [\n\t\t\t\t[\n\t\t\t\t\t'message' => \"You don't have permission to access this.\",\n\t\t\t\t\t'extensions' => [ 'code' => 'FORBIDDEN' ],\n\t\t\t\t],\n\t\t\t]\n\t\t];\n\t}", "public function test403()\n {\n $schedule = $this->createFactorySchedule();\n\n $user = $this->randomEntrant();\n\n $response = $this->requestToApi(\n $user, 'DELETE', '/schedules/'. $schedule->id\n );\n\n $response->assertStatus(403);\n }", "public function index()\n {\n return Response::json([\n 'error' => 'access_denied'\n ], 401);\n }", "function ReturnServerError()\n{\n header('HTTP/1.1 500 Internal Server Error');\n die(\"A server error occured while saving your request.\\r\\nPlease check our API status page at http://status.prybar.io and try again later\");\n}", "protected function statusCodeUnauthorized(): int\n {\n return $this->statusCodeUnauthorized ?? 403;\n }", "function getHTTPCode() {\n\n return 500;\n\n }", "public function failedAuthorization()\n {\n\n throw new HttpResponseException(response()->json(['message' => 'You are not authorized to edit this Note.'],\n 429));\n\n }", "public static function sendMethodNotAllowedResponse(){\n http_response_code(405);\n die();\n }", "public function actionPermissionDenied() {\n ErrorHandler::logError('Permission denied!<br />- You do not have enough privilege to access the page you requested or<br />- The requested page is accessible but a service on that page cannot be performed on your behalf.');\n Yii::app()->layout = 'permission';\n $this->render('PermissionDenied');\n }", "static function http404()\n {\n header('HTTP/1.1 404 Not Found');\n exit;\n }", "public function forbidden(string $message = NULL)\r\n\t\t\t{\r\n\t\t\t\tHTTP::generateHeader(HTTP::FORBIDDEN);\r\n\r\n\t\t\t\t$ApplicationModule = $this->ApplicationModule;\r\n\t\t\t\t$ConfigModule = $this->ConfigModule;\r\n\r\n\t\t\t\t$error = HTTP::getName(HTTP::FORBIDDEN);\r\n\t\t\t\tif(!is_null($message)) { $error = $message; }\r\n\r\n\t\t\t\t$view = $this->ConfigModule->get('ShirOS.Name.File.Error.Forbidden');\r\n\t\t\t\t$fileUser = $this->errorViewPath . DIRECTORY_SEPARATOR . str_replace('.', DIRECTORY_SEPARATOR, $view) . '.php';\r\n\t\t\t\t$fileBundle = $this->bundleErrorViewPath . DIRECTORY_SEPARATOR . str_replace('.', DIRECTORY_SEPARATOR, $view) . '.php';\r\n\r\n\t\t\t\trequire (file_exists($fileUser) ? $fileUser : $fileBundle);\r\n\t\t\t}", "public static function denyAccess()\n {\n static::redirect(static::adminPath(), cbTrans('denied_access'));\n }", "public function forbiddenResponse()\n {\n // (default is to just redirect to initial page with errors)\n // \n // Can return a response, a view, a redirect, or whatever else\n flash()->error('Please verify your email first');\n return $this->redirector->back();\n }", "public function notAuthorized(ResponseInterface $response);", "function rest_send_allow_header($response, $server, $request)\n {\n }", "public function setStatusDenied()\n {\n $this->status = 'DENIED';\n\n return $this;\n }", "public function forbiddenResponse()\n {\n return redirect()->back()->withInput()->withErrors('forbidden');\n }", "public function index(){\n \tdump('You are not allowed to access this server resource.');\n }", "public function getAssociatedStatusCode()\n {\n return AbstractResponse::RESPONSE_UNAUTHORIZED;\n }", "public function denyNotAjax($message = false)\n {\n if (!$this->isAjax()) {\n throw new Exception(403, $message ? $message : 'Access denied.');\n }\n }", "public static function forbidden($message = '', \\Exception $previous = NULL)\n {\n return new self($message, 403, $previous);\n }", "function http_send_status($status) {}", "public function create()\n\t{\n\t\treturn \\Response::json('Forbiden Access',403);\n\t}", "public function indexAction()\n {\n echo 'Forbidden access';\n }", "public static function deny(Request $request);", "function notFound() {\n header('HTTP/1.0 404 Not Found');\n }", "protected function errorCodeForbidden()\n {\n return $this->errorCodeForbidden ?? null;\n }", "public static function error_response() {\r\n header(\"HTTP/1.1 404 Recurso no encontrado\");\r\n exit();\r\n }" ]
[ "0.83065283", "0.82348335", "0.8190337", "0.8046724", "0.7816505", "0.7717207", "0.76824474", "0.76738983", "0.76049703", "0.75228775", "0.7480175", "0.7459356", "0.74414325", "0.74196357", "0.74079907", "0.73378026", "0.73046184", "0.7304244", "0.72887915", "0.72566295", "0.7253238", "0.7251671", "0.7161282", "0.71544445", "0.71453154", "0.7138205", "0.7110234", "0.70773745", "0.6964383", "0.6913793", "0.68943465", "0.6849188", "0.68408823", "0.68262625", "0.6819678", "0.67989874", "0.678008", "0.67793965", "0.6726571", "0.67127454", "0.67092973", "0.67015964", "0.66533023", "0.6591972", "0.6588132", "0.6578984", "0.6565576", "0.6540555", "0.6520652", "0.6498187", "0.64876044", "0.64750737", "0.6470437", "0.64117765", "0.6410087", "0.63928926", "0.6319379", "0.63150215", "0.63129014", "0.63009", "0.62982863", "0.62882715", "0.6282642", "0.62729794", "0.6260163", "0.62487715", "0.6247882", "0.62473756", "0.6225274", "0.6219888", "0.6210858", "0.62083596", "0.6201501", "0.6186987", "0.61822397", "0.61798745", "0.61779773", "0.61762875", "0.61627066", "0.6141593", "0.6119176", "0.6108198", "0.6106655", "0.6099241", "0.6099109", "0.60827166", "0.60795337", "0.6078863", "0.6072953", "0.6061534", "0.6059269", "0.6054666", "0.60470706", "0.6024312", "0.59995043", "0.59872824", "0.5978513", "0.5968379", "0.5955062", "0.59471035", "0.5943284" ]
0.0
-1
Inject an EventManager instance
public function setEventManager(EventManagerInterface $eventManager) { $controller = $this; $eventManager->attach('dispatch', function ($e) use ($controller) { $matches = $e->getRouteMatch(); $params = $matches->getParams(); $params['method'] = $this->getRequest()->getMethod(); $response = $controller->ready(); $auth = new Authentication(); if (!$response) { $response = $auth->preDispatch($params, $this, $this->isAjax, true); } if ($response !== false) { $e->stopPropagation(true); $jsonRenderer = new \Laminas\View\Renderer\JsonRenderer(); if (!is_bool($response)) { $this->getResponse()->setContent($jsonRenderer->render($response)); } return $this->getResponse(); } }); parent::setEventManager($eventManager); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function initEventsManager()\n {\n $this->di->setShared('eventsManager', function () {\n $em = new EventsManager;\n $em->enablePriorities(true);\n\n return $em;\n });\n }", "public function setEventsManager(ManagerInterface $eventsManager);", "private function getEventManager()\n {\n return $this->container->get('event_manager');\n }", "protected function getEventsManager() {}", "protected function setEventsManager(EventsManagerInterface $eventsManager) {}", "public function setEventsManager(ManagerInterface $eventsManager): void;", "public function setEventManager(EventManager $eventManager)\n {\n $this->eventManager = $eventManager;\n }", "public function setEventManager(EventManager $eventManager): void\n {\n $this->eventManager = $eventManager;\n }", "public function __construct()\n {\n $this->events = new EventDispatcher();\n }", "public function getEventsManager() : ManagerInterface;", "public function attach(EventManagerInterface $events)\n {\n $sm = $this->getServiceManager();\n $em = $this->getEventManager();\n $shared = $em->getSharedManager();\n \n $this->listeners = array(\n $shared->attach(\n 'Zend\\Mvc\\Application', \n MvcEvent::EVENT_BOOTSTRAP, \n array($this, 'logout'), \n 1000002\n ),\n $shared->attach(\n 'Zend\\Mvc\\Application', \n MvcEvent::EVENT_BOOTSTRAP, \n array($this, 'authenticateRequest'), \n 1000001\n ),\n $shared->attach(\n 'Zend\\Mvc\\Application', \n MvcEvent::EVENT_BOOTSTRAP, \n array($this, 'prepareAuthorise'), \n 1000000\n ),\n $shared->attach(\n 'Zend\\Mvc\\Application', \n MvcEvent::EVENT_ROUTE, \n array($this, 'authoriseRoute')\n ),\n $shared->attach(\n 'Zend\\Mvc\\Application', \n MvcEvent::EVENT_DISPATCH,\n array($this, 'authoriseModule'),\n 10\n ),\n $shared->attach(\n 'Zend\\View\\View', \n ViewEvent::EVENT_RENDERER, \n array($this, 'updateView')\n ),\n $shared->attach(\n 'ZucchiSecurity',\n SecurityEvent::EVENT_AUTHENTICATE, \n array($this, 'doLocalAuthentication')\n ),\n $shared->attach(\n 'ZucchiSecurity',\n SecurityEvent::EVENT_LOGIN_FORM_BUILD, \n array('ZucchiSecurity\\Authentication\\Plugin\\Local', 'extendLoginForm')\n ),\n $shared->attach(\n 'ZucchiSecurity',\n SecurityEvent::EVENT_LOGOUT_FORM_BUILD, \n array('ZucchiSecurity\\Authentication\\Plugin\\Local', 'extendLogoutForm')\n ),\n $shared->attach(\n 'ZucchiSecurity',\n SecurityEvent::EVENT_LOGIN_FORM_BUILD, \n array('ZucchiSecurity\\Authentication\\Plugin\\Captcha', 'extendLoginForm')\n ),\n );\n }", "public function __construct(EntityManagerInterface $em, EventManager $events)\n {\n $this->em = $em;\n\n $this->setEventManager($events);\n }", "public function init(ModuleManager $manager)\n {\n // Get event manager.\n $eventManager = $manager->getEventManager();\n $sharedEventManager = $eventManager->getSharedManager();\n // Register the event listener method.\n $sharedEventManager->attach(__NAMESPACE__, MvcEvent::EVENT_DISPATCH, [$this, 'onDispatch'], 100);\n // Register the event listener method.\n $sharedEventManager->attach(__NAMESPACE__, 'route', [$this, 'onRoute'], 100);\n // Register the event listener method.\n $sharedEventManager->attach(__NAMESPACE__, MvcEvent::EVENT_DISPATCH_ERROR, [$this, 'onError'], 100);\n $sharedEventManager->attach(__NAMESPACE__, MvcEvent::EVENT_RENDER_ERROR, [$this, 'onError'], 100);\n\n }", "public function getEventManager()\n {\n return $this->eventManager;\n }", "public function getEventManager()\n {\n return $this->eventManager;\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n if ($this->eventManager === $eventManager || $eventManager === null) {\n return;\n }\n\n if ($this->eventManager !== null) {\n $this->detach($this->eventManager);\n }\n\n $this->eventManager = $eventManager;\n $this->eventManager->addIdentifiers([\n 'EntityService',\n 'PolderKnowledge\\EntityService\\Service\\EntityService',\n $this->getEntityServiceName(),\n trim($this->getEntityServiceName(), '\\\\'),\n ]);\n\n $this->attach($this->eventManager);\n }", "public function getEventsManager()\n {\n return $this->eventsManager;\n }", "public function getEventManager()\n {\n if (!isset($this['event.manager'])) {\n $this['event.manager'] = new Manager($this['dispatcher']);\n }\n return $this['event.manager'];\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n $this->eventManager = $eventManager;\n }", "public function attach(EventManagerInterface $events)\n {\n // TODO: Implement attach() method.\n }", "public function setEvents(EventsManager $events)\n {\n $this->events = $events;\n return $this;\n }", "public function setEventManager(EventManagerInterface $events)\n {\n\n $entityManager = $this->entityManager;\n $role_id = $this->auth_user_role;\n // echo \" the fuck? ... not sure why this runs twice\";\n $events->attach('load-person', function (EventInterface $e) use ($entityManager, $role_id) {\n $person = $e->getParam('person');\n $hat = $person->getHat();\n $form = $e->getParam('form');\n $hat_options = $form->get('user')->get('person')->get('hat')\n ->getValueOptions();\n $hats_allowed = array_column($hat_options, 'value');\n if (! in_array($hat->getId(), $hats_allowed)) {\n $message = sprintf(\n 'The person identified by id %d, %s %s, wears the hat %s, '\n . 'but people in that category do not have user accounts '\n . 'in this system.',\n $person->getId(),\n $person->getFirstName(),\n $person->getLastname(),\n $hat\n );\n $controller = $e->getTarget();\n $controller->flashMessenger()->addErrorMessage($message);\n return $controller->redirect()->toRoute('users');\n }\n\n /**\n * this needs work. there are rare cases where one and the same\n * person may legitimately have to have more than one user account,\n * only one of which can be active at any one time, and each having\n * a different role from the other: 'submitter' vs any of the other\n * roles.\n */\n $user = $entityManager->getRepository('InterpretersOffice\\Entity\\User')\n ->findOneBy(['person' => $person]);\n //->getUser(['entity'=>'person','id' => $person->getId()]);\n if ($user) {\n $container = $e->getTarget()->getEvent()->getApplication()\n ->getServiceManager();\n\n $message = sprintf(\n 'We can\\'t create a new user account because this person '\n . ' (%s %s, id %d) already has one. ',\n $person->getFirstname(),\n $person->getLastname(),\n $person->getId()\n );\n $acl = $e->getTarget()->getEvent()->getApplication()\n ->getServiceManager()->get('acl');\n if ($acl->isAllowed($role_id, $user->getResourceId())) {\n $helper = $container->get('ViewHelperManager')->get('url');\n $url = $helper('users/edit', ['id' => $user->getId()]);\n $message .= sprintf(\n 'You can <a href=\"%s\">edit it</a> if you want to.',\n $url\n );\n }\n $controller = $e->getTarget();\n $controller->flashMessenger()->addErrorMessage($message);\n return $controller->redirect()->toRoute('users');\n }\n });\n // are they authorized to edit this user account?\n $events->attach('load-user', function (EventInterface $e) use ($role_id) {\n $resource_id = $e->getParam('user')->getResourceId();\n $acl = $e->getTarget()->getEvent()->getApplication()\n ->getServiceManager()->get('acl');\n if (! $acl->isAllowed($role_id, $resource_id)) {\n $controller = $e->getTarget();\n $message = \"Access denied to {$resource_id}'s user account\";\n $controller->flashMessenger()->addErrorMessage($message);\n return $controller->redirect()->toRoute('users');\n } else {\n $services = $e->getTarget()->getEvent()->getApplication()\n ->getServiceManager();\n $services->get(Entity\\Listener\\UpdateListener::class)\n ->setAuth($this->auth);\n }\n });\n\n return parent::setEventManager($events);\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n $eventManager->setIdentifiers(array(__CLASS__, get_class($this)));\n\n $this->eventManager = $eventManager;\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n $eventManager->setIdentifiers(array(__CLASS__, get_class($this)));\n\n $this->eventManager = $eventManager;\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n $eventManager->setIdentifiers(array(__CLASS__, get_class($this)));\n\n $this->eventManager = $eventManager;\n }", "public function getEventsManager(): ?ManagerInterface;", "public function setEventManager (EventManagerInterface $events)\n\t{\n\t\t$this->events = $events;\n\t\tparent::setEventManager($events);\n\t\t// Register the listener and callback method with a priority of 10\n\t\t$events->attach('dispatch', array(\n\t\t\t\t$this,\n\t\t\t\t'checkOptions'\n\t\t), 10);\n\t}", "public function getEventManager()\n {\n return $this->events;\n }", "public function __initEvents($app)\n {\n }", "public function setEventManager(EventManagerInterface $events) {\n \n parent::setEventManager($events);\n \n $events->attach('dispatch', function ($e) {\n \n $controllerClass = $e->getRouteMatch()->getParam('controller', 'index');\n // przekazuje do szablonu wywoływany kontroler \n $e->getViewModel()->setVariable('controller', $controllerClass);\n //przekazuje baseUrl do szablonu layout.phtml\n $e->getViewModel()->setVariable('baseUrl', $this->getRequest()->getBasePath()); \n \n $userSession = new Session\\Container('uzytkownik'); \n \n if ($userSession->details) {\n $e->getViewModel()->setVariable('uzytkownik', $userSession->details); \n } \n }, 100);\n \n \n \n }", "function event(): EventEmitter\n{\n return EventEmitter::getInstance();\n}", "public function attach(EventManagerInterface $events)\n {\n $this->listeners[] = $events->attach('get.pre', array($this, 'load'), 100);\n $this->listeners[] = $events->attach('get.post', array($this, 'save'), -100);\n }", "public function getEventManager()\n {\n if (is_null($this->_events)) {\n $container = ContainerBuilder::buildContainer(\n [\n 'DefaultEventManager' => Definition::object(\n 'Zend\\EventManager\\SharedEventManager'\n )\n ]\n );\n $sharedEvents = $container->get('DefaultEventManager');\n $events = new EventManager();\n $events->setSharedManager($sharedEvents);\n $this->setEventManager($events);\n }\n return $this->_events;\n }", "public function attach(EventManagerInterface $events)\n {\n $this->listeners[] = $events->attach(MvcEvent::EVENT_ROUTE, array($this, 'initAuth'));\n }", "public function getEventManager()\n {\n Deprecation::triggerIfCalledFromOutside(\n 'doctrine/dbal',\n 'https://github.com/doctrine/dbal/issues/5784',\n '%s is deprecated.',\n __METHOD__,\n );\n\n return $this->_eventManager;\n }", "private function registerEventStore() : void\n {\n $this->app->bind(IlluminateEventStore::class, function ($app) {\n $connection = $app->make(Connection::class);\n $serializer = $app->make(Serializer::class);\n $eventStoreTable = $app->config->get('event_sourcing.event_store_table');\n\n return new IlluminateEventStore(\n $connection,\n $serializer,\n $eventStoreTable\n // decorators (we could decorate the stream with account_id)\n );\n });\n\n $this->app->bind(\n EventStore::class,\n IlluminateEventStore::class\n );\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager);\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if ($this->eventManager == null) {\n ControllerException::eventManagerNotDefined();\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function getEventManager()\n {\n if (null === $this->eventManager) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->eventManager;\n }", "public function testEventManagerReset1(): EventManager\n {\n $eventManager = EventManager::instance();\n $this->assertInstanceOf('Cake\\Event\\EventManager', $eventManager);\n\n return $eventManager;\n }", "public function attachShared(SharedEventManagerInterface $events)\n\t\t{\n\t\t\t$this->listeners['Admin'] = \n\t\t\t\t$events->attach('Admin', MvcEvent::EVENT_DISPATCH, function($e) {\n\t\t\t\t\t// This event will only be fired when an ActionController under the MyModule namespace is dispatched.\n\t\t\t\t\t$controller = $e->getTarget();\n\t\t\t\t\t$controller->layout('layout/admin');\n\t\t\t\t}, 1000);\n\t\t}", "protected function registerManager()\n {\n $this->app->bindShared('dropbox', function ($app) {\n $config = $app['config'];\n $factory = $app['dropbox.factory'];\n\n return new DropboxManager($config, $factory);\n });\n\n $this->app->alias('dropbox', 'GrahamCampbell\\Dropbox\\DropboxManager');\n }", "public function attachShared(SharedEventManagerInterface $events)\n {\n // TODO: Implement attachShared() method.\n }", "protected function getEventDispatcherService()\n {\n if (isset($this->shared['event_dispatcher'])) return $this->shared['event_dispatcher'];\n\n $class = $this->getParameter('event_dispatcher.class');\n $instance = new $class($this);\n $this->shared['event_dispatcher'] = $instance;\n\n return $instance;\n }", "public function attach(EventManagerInterface $events)\r\n {\r\n $this->listeners[] = $events->attach(MvcEvent::EVENT_RENDER, array($this, 'renderSeo'), -100);\r\n }", "public function __construct(\n ObjectManager $addressObjectManager,\n AddressEventDispatcher $addressEventDispatcher\n ) {\n $this->addressObjectManager = $addressObjectManager;\n $this->addressEventDispatcher = $addressEventDispatcher;\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n $this->eventManager = $eventManager;\n return $this;\n }", "public static function initialize()\n {\n date_default_timezone_set('Asia/Shanghai');\n //注册自定义异常\n Di::getInstance()->set(SysConst::HTTP_EXCEPTION_HANDLER,[ExceptionHandler::class,'handle']);\n\n //自定义事件注册\n// TestEvent::getInstance()->set('test', function () {\n// echo 'test event';\n// });\n //TestEvent::getInstance()->set('test','\\App\\Service\\TaskService');//相当于注册一个容器\n\n }", "protected function getEventDispatcherService()\n {\n $this->services['event_dispatcher'] = $instance = new \\Symfony\\Component\\EventDispatcher\\ContainerAwareEventDispatcher($this);\n\n $instance->addListenerService('kernel.request', array(0 => 'knp_menu.listener.voters', 1 => 'onKernelRequest'), 0);\n $instance->addListenerService('victoire_core.build_menu', array(0 => 'victoire_blog.blog_menu_listener', 1 => 'addGlobal'), 90);\n $instance->addListenerService('victoire_core.article_menu.contextual', array(0 => 'victoire_blog.article_menu.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('victoire_core.article_menu.contextual', array(0 => 'victoire_blog.article_settings_menu.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('victoire_core.blog_menu.contextual', array(0 => 'victoire_blog.blog_menu.contextual', 1 => 'addBlogContextual'), 0);\n $instance->addListenerService('victoire_core.article_template_menu.contextual', array(0 => 'victoire_blog.article_template_menu.menu_listener.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('victoire_core.blog_menu.contextual', array(0 => 'victoire_blog.blog_page_menu.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('victoire.widget_filter.form.pre_set_data', array(0 => 'victoire.widget_filter.form.listener.presetdata', 1 => 'manageExtraFiltersFields'), 1);\n $instance->addListenerService('victoire.widget_filter.form.pre_submit', array(0 => 'victoire.widget_filter.form.listener.presubmit', 1 => 'manageExtraFiltersFields'), 1);\n $instance->addListenerService('victoire.widget_filter.form.date.set_default_value', array(0 => 'victoire.widget_filter.blog.set.default.values.form.listener', 1 => 'setDefaultDateValue'), 1);\n $instance->addListenerService('victoire_core.build_menu', array(0 => 'victoire_business_page.business_template_menu_listener', 1 => 'addGlobal'), 50);\n $instance->addListenerService('victoire_core.business_template_menu.contextual', array(0 => 'victoire_core.business_template_menu.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('kernel.request', array(0 => 'victoire_core.menu_dispatcher', 1 => 'onKernelRequest'), 0);\n $instance->addListenerService('victoire_core.backend_menu.global', array(0 => 'victoire_core.backend_menu_listener', 1 => 'addGlobal'), 100);\n $instance->addListenerService('kernel.controller', array(0 => 'victoire_core.listener.controller_listener', 1 => 'preExecuteAutorun'), 0);\n $instance->addListenerService('victoire.on_render_page', array(0 => 'victoire_core.view_css_listener', 1 => 'onRenderPage'), 0);\n $instance->addListenerService('kernel.request', array(0 => 'victoire_i18n.kernelrequest.listener', 1 => 'onKernelRequest'), 0);\n $instance->addListenerService('victoire_core.build_menu', array(0 => 'victoire_core.media_menu_listener', 1 => 'addGlobal'), 60);\n $instance->addListenerService('victoire_core.build_menu', array(0 => 'victoire_core.page_menu_listener', 1 => 'addGlobal'), 100);\n $instance->addListenerService('victoire_core.page_menu.contextual', array(0 => 'victoire_core.page_menu.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('victoire_core.build_menu', array(0 => 'victoire_sitemap.sitemap_menu_listener', 1 => 'addGlobal'), 70);\n $instance->addListenerService('victoire_core.build_menu', array(0 => 'victoire_core.template_menu_listener', 1 => 'addGlobal'), 80);\n $instance->addListenerService('victoire_core.template_menu.contextual', array(0 => 'victoire_core.template_menu.contextual', 1 => 'addContextual'), 0);\n $instance->addListenerService('kernel.request', array(0 => 'victoire_twig.kernelrequest.listener', 1 => 'onKernelRequest'), 0);\n $instance->addListenerService('kernel.request', array(0 => 'victoire_view_reference.cache_warmer', 1 => 'warmUp'), 0);\n $instance->addSubscriberService('response_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\ResponseListener');\n $instance->addSubscriberService('streamed_response_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\StreamedResponseListener');\n $instance->addSubscriberService('locale_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\LocaleListener');\n $instance->addSubscriberService('validate_request_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\ValidateRequestListener');\n $instance->addSubscriberService('translator_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\TranslatorListener');\n $instance->addSubscriberService('session_listener', 'Symfony\\\\Bundle\\\\FrameworkBundle\\\\EventListener\\\\SessionListener');\n $instance->addSubscriberService('session.save_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\SaveSessionListener');\n $instance->addSubscriberService('fragment.listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\FragmentListener');\n $instance->addSubscriberService('debug.debug_handlers_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\DebugHandlersListener');\n $instance->addSubscriberService('router_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\RouterListener');\n $instance->addSubscriberService('security.firewall', 'Symfony\\\\Component\\\\Security\\\\Http\\\\Firewall');\n $instance->addSubscriberService('security.rememberme.response_listener', 'Symfony\\\\Component\\\\Security\\\\Http\\\\RememberMe\\\\ResponseListener');\n $instance->addSubscriberService('twig.exception_listener', 'Symfony\\\\Component\\\\HttpKernel\\\\EventListener\\\\ExceptionListener');\n $instance->addSubscriberService('monolog.handler.console', 'Symfony\\\\Bridge\\\\Monolog\\\\Handler\\\\ConsoleHandler');\n $instance->addSubscriberService('swiftmailer.email_sender.listener', 'Symfony\\\\Bundle\\\\SwiftmailerBundle\\\\EventListener\\\\EmailSenderListener');\n $instance->addSubscriberService('sensio_framework_extra.controller.listener', 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\ControllerListener');\n $instance->addSubscriberService('sensio_framework_extra.converter.listener', 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\ParamConverterListener');\n $instance->addSubscriberService('sensio_framework_extra.view.listener', 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\TemplateListener');\n $instance->addSubscriberService('sensio_framework_extra.cache.listener', 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\HttpCacheListener');\n $instance->addSubscriberService('sensio_framework_extra.security.listener', 'Sensio\\\\Bundle\\\\FrameworkExtraBundle\\\\EventListener\\\\SecurityListener');\n $instance->addSubscriberService('troopers_alertifybundle.event_listener', 'Troopers\\\\AlertifyBundle\\\\EventListener\\\\AlertifyListener');\n $instance->addSubscriberService('fos_user.security.interactive_login_listener', 'FOS\\\\UserBundle\\\\EventListener\\\\LastLoginListener');\n $instance->addSubscriberService('fos_user.listener.authentication', 'FOS\\\\UserBundle\\\\EventListener\\\\AuthenticationListener');\n $instance->addSubscriberService('fos_user.listener.flash', 'FOS\\\\UserBundle\\\\EventListener\\\\FlashListener');\n $instance->addSubscriberService('fos_user.listener.resetting', 'FOS\\\\UserBundle\\\\EventListener\\\\ResettingListener');\n $instance->addSubscriberService('victoire_core.cache_subscriber', 'Victoire\\\\Bundle\\\\CoreBundle\\\\EventSubscriber\\\\CacheSubscriber');\n $instance->addSubscriberService('victoire_i18n.locale_subscriber', 'Victoire\\\\Bundle\\\\I18nBundle\\\\Subscriber\\\\LocaleSubscriber');\n $instance->addSubscriberService('victoire_view_reference.listener', 'Victoire\\\\Bundle\\\\ViewReferenceBundle\\\\Listener\\\\ViewReferenceListener');\n\n return $instance;\n }", "abstract protected function getObjectManager(EventArgs $args);", "public function __construct() {\n $this->eventManager = new EventManager;\n $this->mh = curl_multi_init();\n }", "public function setEventManager(EventManagerInterface $events){\n\t parent::setEventManager($events);\n\t $controller = $this;\n\t $events->attach('dispatch', function ($e) use ($controller) {\n\t $controller->layout('layout/admin');\n\t }, 100);\n\t}", "public function bootstrap(MvcEvent $e)\n {\n /** @var ServiceLocatorInterface $serviceManager */\n $serviceManager = $e->getParam('application')->getServiceManager();\n \n // Enable queue manager\n if (isset($this->getConfig()->enable_queue_manager) && $this->getConfig()->enable_queue_manager) {\n $this->queueManager = $serviceManager->get($this->getConfig()->queue_manager);\n }\n \n if (isset($this->getConfig()->enable_job_manager) && $this->getConfig()->enable_job_manager) {\n $this->jobManager = $serviceManager->get($this->getConfig()->job_manager);\n }\n\n }", "public function setEventManager(EventCollection $event_manager)\r\n {\r\n $this->events = $event_manager;\r\n return $this;\r\n }", "public function init()\n {\n// $eventSystem = $this->_bootstrap->getResource('EventSystem');\n// $eventSystem->raiseEvent($event);\n\n }", "public function getEventManager()\n {\n if (null === $this->events) {\n $this->setEventManager(new EventManager());\n }\n return $this->events;\n }", "public function attach(EventManagerInterface $events) {\n $this->listeners[] = $events->attach(MvcEvent::EVENT_DISPATCH, __CLASS__ . '::onDispatch', 1000);\n }", "public function setEventManager(EventManagerInterface $events)\n {\n parent::setEventManager($events);\n\n $controller = $this;\n $events->attach('dispatch', function ($e) use ($controller) {\n $actionName = $controller->params()->fromRoute('action');\n $applicationName = $controller->params()->fromRoute('application');\n if (in_array($actionName, array('index'))) {\n $searchForms = $controller->forward()->dispatch('Controller\\Equipment', array('action' => 'advanced-search', 'application' => $applicationName));\n $controller->layout()->addChild($searchForms, 'searchForms');\n }\n }, -100); // execute after executing action logic\n\n return $this;\n }", "public function inject(MenuManager $menuManager)\n\t{\n\t\t$this->menuManager = $menuManager;\n\t}", "public function __construct()\n {\n $this->loop = Factory::create();//app('eventLoop');\n }", "public function getEvent()\n {\n return $this->getServiceLocator()->get('Application')->getEventManager();\n }", "public function setEventManager(EventManagerInterface $events)\n {\n $events->setIdentifiers([\n self::class,\n static::class,\n ]);\n $this->events = $events;\n return $this;\n }", "public function getEventManager()\n {\n if (! $this->events) {\n $this->setEventManager(new EventManager());\n }\n return $this->events;\n }", "public function attach(EventManagerInterface $em)\n {\n $this->listeners[] = $em->attach(MvcEvent::EVENT_DISPATCH_ERROR, array($this, 'prepareRedirect'));\n }", "public function setEventManager(EventManagerInterface $eventManager)\n {\n $eventManager->setIdentifiers(\n array(\n __CLASS__,\n get_class($this),\n )\n );\n $this->_events = $eventManager;\n return $this;\n }", "protected function getEventLogger()\n {\n $event_manager = new EventsManager;\n\n $event_manager->attach($this->alias, function ($event, $conn) {\n if ($event->getType() == 'beforeQuery') {\n $logging_name = 'db';\n\n if (logging_extension()) {\n $logging_name = 'db-'.logging_extension();\n }\n\n $logger = new Logger('DB');\n $logger->pushHandler(\n new StreamHandler(\n storage_path('logs').'/'.$logging_name.'.log',\n Logger::INFO\n )\n );\n\n $variables = $conn->getSQLVariables();\n\n if ($variables) {\n $logger->info(\n $conn->getSQLStatement().\n ' ['.implode(',', $variables).']'\n );\n } else {\n $logger->info($conn->getSQLStatement());\n }\n }\n });\n\n return $event_manager;\n }", "public function __construct(EntityTypeManagerInterface $entity_type_manager, EventDispatcherInterface $event_dispatcher) {\n $this->entityTypeManager = $entity_type_manager;\n $this->eventDispatcher = $event_dispatcher;\n }", "protected function getEventDispatcherService()\n {\n $this->services['event_dispatcher'] = $instance = new \\Symfony\\Component\\EventDispatcher\\ContainerAwareEventDispatcher($this);\n\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['App\\EventSubscriber\\RestSubscriber']) ? $this->services['App\\EventSubscriber\\RestSubscriber'] : $this->getRestSubscriberService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 0);\n $instance->addListener('kernel.controller', array(0 => function () {\n return ${($_ = isset($this->services['App\\EventSubscriber\\RestSubscriber']) ? $this->services['App\\EventSubscriber\\RestSubscriber'] : $this->getRestSubscriberService()) && false ?: '_'};\n }, 1 => 'onKernelController'), 0);\n $instance->addListener('kernel.view', array(0 => function () {\n return ${($_ = isset($this->services['App\\EventSubscriber\\RestSubscriber']) ? $this->services['App\\EventSubscriber\\RestSubscriber'] : $this->getRestSubscriberService()) && false ?: '_'};\n }, 1 => 'onKernelView'), 0);\n $instance->addListener('kernel.exception', array(0 => function () {\n return ${($_ = isset($this->services['App\\EventSubscriber\\RestSubscriber']) ? $this->services['App\\EventSubscriber\\RestSubscriber'] : $this->getRestSubscriberService()) && false ?: '_'};\n }, 1 => 'onKernelException'), 0);\n $instance->addListener('kernel.response', array(0 => function () {\n return ${($_ = isset($this->services['response_listener']) ? $this->services['response_listener'] : $this->services['response_listener'] = new \\Symfony\\Component\\HttpKernel\\EventListener\\ResponseListener('UTF-8')) && false ?: '_'};\n }, 1 => 'onKernelResponse'), 0);\n $instance->addListener('kernel.response', array(0 => function () {\n return ${($_ = isset($this->services['streamed_response_listener']) ? $this->services['streamed_response_listener'] : $this->services['streamed_response_listener'] = new \\Symfony\\Component\\HttpKernel\\EventListener\\StreamedResponseListener()) && false ?: '_'};\n }, 1 => 'onKernelResponse'), -1024);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['locale_listener']) ? $this->services['locale_listener'] : $this->getLocaleListenerService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 16);\n $instance->addListener('kernel.finish_request', array(0 => function () {\n return ${($_ = isset($this->services['locale_listener']) ? $this->services['locale_listener'] : $this->getLocaleListenerService()) && false ?: '_'};\n }, 1 => 'onKernelFinishRequest'), 0);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['validate_request_listener']) ? $this->services['validate_request_listener'] : $this->services['validate_request_listener'] = new \\Symfony\\Component\\HttpKernel\\EventListener\\ValidateRequestListener()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 256);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['resolve_controller_name_subscriber']) ? $this->services['resolve_controller_name_subscriber'] : $this->getResolveControllerNameSubscriberService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 24);\n $instance->addListener('console.error', array(0 => function () {\n return ${($_ = isset($this->services['console.error_listener']) ? $this->services['console.error_listener'] : $this->load('getConsole_ErrorListenerService.php')) && false ?: '_'};\n }, 1 => 'onConsoleError'), -128);\n $instance->addListener('console.terminate', array(0 => function () {\n return ${($_ = isset($this->services['console.error_listener']) ? $this->services['console.error_listener'] : $this->load('getConsole_ErrorListenerService.php')) && false ?: '_'};\n }, 1 => 'onConsoleTerminate'), -128);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['session_listener']) ? $this->services['session_listener'] : $this->getSessionListenerService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 128);\n $instance->addListener('kernel.response', array(0 => function () {\n return ${($_ = isset($this->services['session_listener']) ? $this->services['session_listener'] : $this->getSessionListenerService()) && false ?: '_'};\n }, 1 => 'onKernelResponse'), -1000);\n $instance->addListener('kernel.finish_request', array(0 => function () {\n return ${($_ = isset($this->services['session_listener']) ? $this->services['session_listener'] : $this->getSessionListenerService()) && false ?: '_'};\n }, 1 => 'onFinishRequest'), 0);\n $instance->addListener('kernel.response', array(0 => function () {\n return ${($_ = isset($this->services['session.save_listener']) ? $this->services['session.save_listener'] : $this->services['session.save_listener'] = new \\Symfony\\Component\\HttpKernel\\EventListener\\SaveSessionListener()) && false ?: '_'};\n }, 1 => 'onKernelResponse'), -1000);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['translator_listener']) ? $this->services['translator_listener'] : $this->getTranslatorListenerService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 10);\n $instance->addListener('kernel.finish_request', array(0 => function () {\n return ${($_ = isset($this->services['translator_listener']) ? $this->services['translator_listener'] : $this->getTranslatorListenerService()) && false ?: '_'};\n }, 1 => 'onKernelFinishRequest'), 0);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['debug.debug_handlers_listener']) ? $this->services['debug.debug_handlers_listener'] : $this->getDebug_DebugHandlersListenerService()) && false ?: '_'};\n }, 1 => 'configure'), 2048);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['router_listener']) ? $this->services['router_listener'] : $this->getRouterListenerService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 32);\n $instance->addListener('kernel.finish_request', array(0 => function () {\n return ${($_ = isset($this->services['router_listener']) ? $this->services['router_listener'] : $this->getRouterListenerService()) && false ?: '_'};\n }, 1 => 'onKernelFinishRequest'), 0);\n $instance->addListener('kernel.exception', array(0 => function () {\n return ${($_ = isset($this->services['router_listener']) ? $this->services['router_listener'] : $this->getRouterListenerService()) && false ?: '_'};\n }, 1 => 'onKernelException'), -64);\n $instance->addListener('console.error', array(0 => function () {\n return ${($_ = isset($this->services['maker.console_error_listener']) ? $this->services['maker.console_error_listener'] : $this->services['maker.console_error_listener'] = new \\Symfony\\Bundle\\MakerBundle\\Event\\ConsoleErrorSubscriber()) && false ?: '_'};\n }, 1 => 'onConsoleError'), 0);\n $instance->addListener('console.terminate', array(0 => function () {\n return ${($_ = isset($this->services['maker.console_error_listener']) ? $this->services['maker.console_error_listener'] : $this->services['maker.console_error_listener'] = new \\Symfony\\Bundle\\MakerBundle\\Event\\ConsoleErrorSubscriber()) && false ?: '_'};\n }, 1 => 'onConsoleTerminate'), 0);\n $instance->addListener('kernel.response', array(0 => function () {\n return ${($_ = isset($this->services['security.rememberme.response_listener']) ? $this->services['security.rememberme.response_listener'] : $this->services['security.rememberme.response_listener'] = new \\Symfony\\Component\\Security\\Http\\RememberMe\\ResponseListener()) && false ?: '_'};\n }, 1 => 'onKernelResponse'), 0);\n $instance->addListener('kernel.request', array(0 => function () {\n return ${($_ = isset($this->services['security.firewall']) ? $this->services['security.firewall'] : $this->getSecurity_FirewallService()) && false ?: '_'};\n }, 1 => 'onKernelRequest'), 8);\n $instance->addListener('kernel.finish_request', array(0 => function () {\n return ${($_ = isset($this->services['security.firewall']) ? $this->services['security.firewall'] : $this->getSecurity_FirewallService()) && false ?: '_'};\n }, 1 => 'onKernelFinishRequest'), 0);\n\n return $instance;\n }", "public function attach(EventManagerInterface $events)\n {\n $this->listeners[] = $events->attach('blog.model.post.save', array($this, 'onPostSave'));\n $this->listeners[] = $events->attach('blog.model.post.create', array($this, 'onPostSave'));\n }", "protected function registerManager()\n {\n $this->app->singleton('digitalocean', function (Container $app) {\n $config = $app['config'];\n $factory = $app['digitalocean.factory'];\n\n return new DigitalOceanManager($config, $factory);\n });\n\n $this->app->alias('digitalocean', DigitalOceanManager::class);\n }", "public function getEventManager()\n {\n if (null === $this->events) {\n $this->setEventManager(new EventManager());\n }\n\n return $this->events;\n }", "public function init(ModuleManager $manager)\n {\n $eventManager = $manager->getEventManager();\n $sharedEventManager = $eventManager->getSharedManager();\n $sharedEventManager->attach('Laminas\\Mvc\\Application', MvcEvent::EVENT_ROUTE, function(MvcEvent $event) {\n $this->domainMapper->createRoute($event->getRouter()->getRoutes());\n }, 100);\n }", "public function setEventManager(EventManagerInterface $events)\n {\n $events->setIdentifiers(\n array(\n __CLASS__,\n get_called_class(),\n )\n );\n $this->eventManager = $events;\n\n return $this;\n }", "public function getEventManager()\n {\n if (!$this->events instanceof EventManagerInterface) {\n $this->setEventManager(new \\Zend\\EventManager\\EventManager());\n }\n\n return $this->events;\n }", "public function init(Manager $moduleManager)\n {\n $events = StaticEventManager::getInstance();\n\n // Bootstrap the app\n $events->attach('bootstrap', 'bootstrap', array($this, 'wireJsonStrategy'), 100);\n $events->attach('bootstrap', 'bootstrap', array($this, 'initView'), 100);\n $events->attach('bootstrap', 'bootstrap', array($this, 'initializeRegistry'));\n\n // Add queue listener in lieu of a cron script\n $events->attach('Zend\\Mvc\\Application', 'finish', array($this, 'processQueue'));\n\n // Always force login\n $events->attach('Zend\\Mvc\\Application', 'dispatch', array($this, 'checkSecurity'));\n }", "public function injectEventDispatcher(\\EssentialDots\\ExtbaseHijax\\Event\\Dispatcher $eventDispatcher) {\n\t\t$this->hijaxEventDispatcher = $eventDispatcher;\n\t}", "public function setEventManager(EventManagerInterface $events)\n {\n $identifiers = array(__CLASS__, get_class($this));\n if (isset($this->eventIdentifier)) {\n if ((is_string($this->eventIdentifier))\n || (is_array($this->eventIdentifier))\n || ($this->eventIdentifier instanceof \\Traversable)\n ) {\n $identifiers = array_unique(array_merge($identifiers, (array) $this->eventIdentifier));\n } elseif (is_object($this->eventIdentifier)) {\n $identifiers[] = $this->eventIdentifier;\n }\n // silently ignore invalid eventIdentifier types\n }\n $events->setIdentifiers($identifiers);\n $this->events = $events;\n\n return $this;\n }", "public function setEventManager(EventManagerInterface $events)\n {\n $events->setIdentifiers([\n __CLASS__,\n get_class($this),\n ]);\n $this->events = $events;\n\n return $this;\n }", "public function testFireEventWithClass()\n {\n $eventManager = new EventManager;\n $secret = '1234';\n $eventManager->listen('secret', 'Underlay\\Tests\\Events\\Test@call', function (\n $receivedSecret\n )\n use (\n $secret\n ) {\n $this->assertEquals($secret, $receivedSecret);\n });\n $eventManager->fire('secret', $secret);\n }", "public static function get_instance() \n {\n if ( ! isset(self::$instance)) \n {\n self::$instance = new Event();\n }\n\n return self::$instance;\n }", "public function attach(EventManagerInterface $eventManager, $priority = 100)\n {\n $shared = $eventManager->getSharedManager();\n $this->listeners[] = '???';\n }", "protected function initEvent()\n {\n $locales = $this->container->getParameter('event.locales');\n $event = $this->getRepository('EventEventBundle:Event')->getEvent();\n $now = new \\DateTime();\n\n if (!$event) {\n $event = new Event();\n $event\n ->setTitle('My Event')\n ->setDescription('My another awesome event!')\n ->setStartDate($now)\n ->setEndDate($now->modify('+1 day'))\n ->setVenue('Burj Khalifa Tower')\n ->setEmail('[email protected]')\n ;\n\n $speaker = new Speaker();\n $speaker\n ->setFirstName('Phill')\n ->setLastName('Pilow')\n ->setCompany('Reseach Supplier')\n ;\n\n if ($locales) {\n foreach ($locales as $locale => $title) {\n $eventTranslation = new EventTranslation();\n $eventTranslation->setEvent($event);\n $eventTranslation->setlocale($locale);\n\n $this->getManager()->persist($eventTranslation);\n\n $speakerTranslation = new SpeakerTranslation();\n $speakerTranslation->setSpeaker($speaker);\n $speakerTranslation->setlocale($locale);\n\n $this->getManager()->persist($speakerTranslation);\n }\n }\n\n $this->getManager()->persist($event);\n $this->getManager()->persist($speaker);\n $this->getManager()->flush();\n }\n }", "public function __construct(EventsService $eventService)\n {\n $this->service = $eventService;\n }", "public function testAttach()\n {\n $event = new EventManager();\n\n /** @var \\Closure $closure */\n $closure = function () {\n return $this->listeners;\n };\n\n $this->mvcKeeper->attach($event);\n\n $getListeners = $closure->bindTo($this->mvcKeeper, get_class($this->mvcKeeper));\n $listeners = $getListeners();\n\n foreach ($listeners as $listener) {\n $this->assertInstanceOf('Zend\\Stdlib\\CallbackHandler', $listener);\n }\n }", "public function injectObjectManager(ObjectManagerInterface $qomFactory)\n {\n $this->objectManager = $qomFactory;\n }", "public function onBootstrap(MvcEvent $e)\n {\n \t$config = $e->getApplication()->getServiceManager()->get('config');\n \t$dbAdapter = new \\Zend\\Db\\Adapter\\Adapter($config['db']);\n \t$sessionOptions = new \\Zend\\Session\\SaveHandler\\DbTableGatewayOptions();\n \t$sessionTableGateway = new \\Zend\\Db\\TableGateway\\TableGateway('session', $dbAdapter);\n \t$saveHandler = new \\Zend\\Session\\SaveHandler\\DbTableGateway($sessionTableGateway, $sessionOptions);\n \t$sessionManager = new \\Zend\\Session\\SessionManager(NULL, NULL, $saveHandler);\n \tContainer::setDefaultManager($sessionManager);\n \t\n $eventManager = $e->getApplication()->getEventManager();\n $moduleRouteListener = new ModuleRouteListener();\n $moduleRouteListener->attach($eventManager);\n }", "public function attach(EventManagerInterface $events)\n {\n $this->listeners[] = $events->attach(MvcEvent::EVENT_DISPATCH, [$this, 'onDispatch'], 2);\n }", "public function attach(EventManagerInterface $events)\n {\n foreach ($this->hooks as $name => $spec) {\n $listeners[] = $events->attach($spec['event'], array($this, \"do$name\"));\n }\n }", "public function onBootstrap(MvcEvent $e)\n {\n $sm = $e->getApplication()->getServiceManager();\n $sm->get('auditManager');\n }", "public function attach(EventManagerInterface $events)\n {\n $this->listeners[] = $events->attach(MessageDispatch::ROUTE, [$this, 'onRoute'], 100);\n }", "public function __construct(?EventConfig $cfg = null) {}", "protected function registerManager()\n {\n $this->app->singleton('freshdesk', function (Container $app) {\n $config = $app['config'];\n $factory = $app['freshdesk.factory'];\n return new FreshdeskManager($config, $factory);\n });\n $this->app->alias('freshdesk', FreshdeskManager::class);\n }", "public function testAttachsToSharedEventManager()\n {\n $target = new CheckJobCreatePermissionListener();\n\n $events = $this->getMockBuilder('\\Zend\\EventManager\\SharedEventManager')\n ->disableOriginalConstructor()\n ->getMock();\n\n $events->expects($this->once())\n ->method('attach')\n ->with('Jobs/Acl/Assertion/Create', AssertionEvent::EVENT_ASSERT, array($target, 'checkCreatePermission'));\n\n $target->attachShared($events);\n }", "protected function registerManager()\n {\n $this->app->singleton('sendwithus', function (Container $app) {\n $config = $app['config'];\n $factory = $app['sendwithus.factory'];\n\n return new SendWithUsManager($config, $factory);\n });\n\n $this->app->alias('sendwithus', SendWithUsManager::class);\n }", "public function attach(EventManagerInterface $events)\n {\n $this->listeners[] = $events->attach('received.node.void', [$this, 'onReceivedNodeVoid']);\n $this->listeners[] = $events->attach('received.node.receipt', [$this, 'onReceivedNodeReceipt']);\n }", "public function __construct(EventStore $eventStore)\n {\n $this->eventStore = $eventStore;\n }", "protected function registerManager()\n {\n $this->app->singleton('queue', function ($app) {\n // Once we have an instance of the queue manager, we will register the various\n // resolvers for the queue connectors. These connectors are responsible for\n // creating the classes that accept queue configs and instantiate queues.\n return tap(new QueueManager($app), function ($manager) {\n $this->registerConnectors($manager);\n });\n });\n }" ]
[ "0.7497449", "0.6994349", "0.6907434", "0.6757924", "0.662997", "0.6580762", "0.6572978", "0.65540475", "0.64335847", "0.64333284", "0.634556", "0.63343143", "0.6311854", "0.6300844", "0.6300844", "0.6239075", "0.6222791", "0.6214359", "0.6191025", "0.6087846", "0.60754097", "0.59766346", "0.5970946", "0.5970946", "0.5970946", "0.59699607", "0.5945543", "0.5921521", "0.5909447", "0.588101", "0.5874578", "0.58045363", "0.5804439", "0.5803449", "0.5799264", "0.5790888", "0.5783637", "0.57770354", "0.57593715", "0.57593715", "0.57593715", "0.57593715", "0.5743405", "0.57414865", "0.57152414", "0.57144827", "0.5682283", "0.5660371", "0.5659554", "0.5653586", "0.56512135", "0.562241", "0.5620753", "0.56147313", "0.56125516", "0.56117135", "0.56108594", "0.5608303", "0.5593143", "0.55925167", "0.5588334", "0.5581073", "0.5566035", "0.5565212", "0.55550504", "0.55531824", "0.5552752", "0.55342215", "0.553232", "0.55257905", "0.55201834", "0.55175525", "0.5510565", "0.5502038", "0.5495961", "0.5495527", "0.54857385", "0.54844034", "0.5468122", "0.54644835", "0.54641277", "0.54606384", "0.5458806", "0.54575586", "0.54555583", "0.54546267", "0.5454376", "0.5451964", "0.5436896", "0.54349893", "0.5434375", "0.54212797", "0.5409592", "0.5406906", "0.53922224", "0.5387599", "0.53679436", "0.53643054", "0.5358642", "0.53559744" ]
0.5710292
46
Create the event listener.
public function __construct(Mailer $mailer) { $this->mailer = $mailer; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function addRequestCreateListener($listener);", "public function onEvent();", "private function init_event_listeners() {\n\t\t// add_action('wp_ajax_example_action', [$this, 'example_function']);\n\t}", "public function listener(Listener $listener);", "protected function setupListeners()\n {\n //\n }", "function eventRegister($eventName, EventListener $listener);", "public function listen($event, $listener);", "private function createStreamCallback()\n {\n $read =& $this->readListeners;\n $write =& $this->writeListeners;\n $this->streamCallback = function ($stream, $flags) use(&$read, &$write) {\n $key = (int) $stream;\n if (\\EV_READ === (\\EV_READ & $flags) && isset($read[$key])) {\n \\call_user_func($read[$key], $stream);\n }\n if (\\EV_WRITE === (\\EV_WRITE & $flags) && isset($write[$key])) {\n \\call_user_func($write[$key], $stream);\n }\n };\n }", "public function addEventListener(string $eventClass, callable $listener, int $priority = 0): EnvironmentBuilderInterface;", "public function setupEventListeners()\r\n\t{\r\n\t\t$blueprints = craft()->courier_blueprints->getAllBlueprints();\r\n\t\t$availableEvents = $this->getAvailableEvents();\r\n\r\n\t\t// Setup event listeners for each blueprint\r\n\t\tforeach ($blueprints as $blueprint) {\r\n\t\t\tif (!$blueprint->eventTriggers) {\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\t\t\tforeach ($blueprint->eventTriggers as $event) {\r\n\t\t\t\t// Is event currently enabled?\r\n\t\t\t\tif (!isset($availableEvents[$event])) {\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\t\t\t\tcraft()->on($event, function(Event $event) use ($blueprint) {\r\n\t\t\t\t\tcraft()->courier_blueprints->checkEventConditions($event, $blueprint);\r\n\t\t\t\t});\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t// On the event that an email is sent, create a successful delivery record\r\n\t\tcraft()->on('courier_emails.onAfterBlueprintEmailSent', [\r\n\t\t\tcraft()->courier_deliveries,\r\n\t\t\t'createDelivery'\r\n\t\t]);\r\n\r\n\t\t// On the event that an email fails to send, create a failed delivery record\r\n\t\tcraft()->on('courier_emails.onAfterBlueprintEmailFailed', [\r\n\t\t\tcraft()->courier_deliveries,\r\n\t\t\t'createDelivery',\r\n\t\t]);\r\n\t}", "protected function registerListeners()\n {\n }", "public function listen($listener);", "public function listenForEvents()\n {\n Event::listen(DummyEvent::class, DummyListener::class);\n\n event(new DummyEvent);\n }", "public function createEvent()\n {\n return new Event();\n }", "public function attachEvents();", "public function attachEvents();", "public function add_event_handler($event, $callback);", "function addListener(EventListener $listener): void;", "public static function initListeners() {\n\t\t\n\t\tif(GO::modules()->isInstalled('files') && class_exists('\\GO\\Files\\Controller\\FolderController')){\n\t\t\t$folderController = new \\GO\\Files\\Controller\\FolderController();\n\t\t\t$folderController->addListener('checkmodelfolder', \"GO\\Projects2\\Projects2Module\", \"createParentFolders\");\n\t\t}\n\t\t\n\t\t\\GO\\Base\\Model\\User::model()->addListener('delete', \"GO\\Projects2\\Projects2Module\", \"deleteUser\");\n\n\t}", "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 }", "private static function event()\n {\n $files = ['Event', 'EventListener'];\n $folder = static::$root.'Event'.'/';\n\n self::call($files, $folder);\n\n $files = ['ManyListenersArgumentsException'];\n $folder = static::$root.'Event/Exceptions'.'/';\n\n self::call($files, $folder);\n }", "public function addEventListener($event, $callable){\r\n $this->events[$event] = $callable;\r\n }", "public function testEventCallBackCreate()\n {\n }", "public function listeners($event);", "public function addListener($event, $listener, $priority = 0);", "public function on($name, $listener, $data = null, $priority = null, $acceptedArgs = null);", "public function createWatcher();", "public function __construct()\n\t{\n\t\t$this->delegate = Delegate_1::fromMethod($this, 'onEvent');\n\t}", "public function init_listeners( $callable ) {\n\t}", "public static function events();", "public static function __events () {\n \n }", "public function onEventAdd()\n\t{\n\t\t$this->onTaskAdd();\n\t}", "public function addApplicationBuilderListener( \n MyFusesApplicationBuilderListener $listener );", "public function addListener($eventName, $listener, $priority = 0);", "public function __construct(){\n\n\t\t\t$this->listen();\n\n\t\t}", "protected function registerListeners()\n {\n // Login event listener\n #Event::listen('auth.login', function($user) {\n //\n #});\n\n // Logout event subscriber\n #Event::subscribe('Mrcore\\Parser\\Listeners\\MyEventSubscription');\n }", "public function __construct()\n {\n// global $callback;\n // $this->eventsArr = $eventsArr;\n $this->callback = function () {\n\n // echo \"event: message\\n\"; // for onmessage listener\n echo \"event: ping\\n\";\n $curDate = date(DATE_ISO8601);\n echo 'data: {\"time\": \"' . $curDate . '\"}';\n echo \"\\n\\n\";\n\n while (($event = ServerSentEvents::popEvent()) != null) {\n $m = json_encode($event->contents);\n echo \"event: $event->event\\n\";\n echo \"data: $m\";\n echo \"\\n\\n\";\n }\n // echo \"event: message\\n\";\n // $curDate = date(DATE_ISO8601);\n // echo 'data: {\"message-time\": \"' . $curDate . '\"}';\n // echo \"\\n\\n\";\n // while(true){\n // if ($index != $this->eventsCounter){\n // ServerSentEvents::sendEvent($this->event, $this->eventBody);\n // $index = $this->eventsCounter;\n // }\n\n // sleep(1);\n // }\n };\n\n $this->setupResponse();\n }", "private function createMyEvents()\n {\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PostDispatchSecure_Frontend_Checkout',\n 'onPostDispatchCheckoutSecure'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_Frontend_Checkout_PreRedirect',\n 'onPreRedirectToPayPal'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PreDispatch_Frontend_PaymentPaypal',\n 'onPreDispatchPaymentPaypal'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_Frontend_PaymentPaypal_Webhook',\n 'onPaymentPaypalWebhook'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_Frontend_PaymentPaypal_PlusRedirect',\n 'onPaymentPaypalPlusRedirect'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PostDispatch_Frontend_Account',\n 'onPostDispatchAccount'\n );\n $this->subscribeEvent(\n 'Theme_Compiler_Collect_Plugin_Javascript',\n 'onCollectJavascript'\n );\n $this->subscribeEvent(\n 'Shopware_Components_Document::assignValues::after',\n 'onBeforeRenderDocument'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PostDispatchSecure_Backend_Config',\n 'onPostDispatchConfig'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PostDispatch_Backend_Order',\n 'onPostDispatchOrder'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PostDispatch_Backend_PaymentPaypal',\n 'onPostDispatchPaymentPaypal'\n );\n $this->subscribeEvent(\n 'Theme_Compiler_Collect_Plugin_Less',\n 'addLessFiles'\n );\n $this->subscribeEvent(\n 'Enlight_Bootstrap_InitResource_paypal_plus.rest_client',\n 'onInitRestClient'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Dispatcher_ControllerPath_Api_PaypalPaymentInstruction',\n 'onGetPaymentInstructionsApiController'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Front_StartDispatch',\n 'onEnlightControllerFrontStartDispatch'\n );\n $this->subscribeEvent(\n 'Enlight_Controller_Action_PreDispatch',\n 'onPreDispatchSecure'\n );\n }", "public static function creating(callable $listener, $priority = 0)\n {\n static::listen(ModelEvent::CREATING, $listener, $priority);\n }", "public function listen();", "public function listen() {\n $this->source->listen($this->id);\n }", "public function addEventListener($event, $callback, $weight = null);", "public function testAddListener()\n {\n // Arrange\n $listenerCalled = false;\n $communicator = new Communicator();\n\n // Act\n $communicator->addListener(function () use (&$listenerCalled) {\n $listenerCalled = true;\n });\n\n $communicator->broadcast([], 'channel', [], []);\n\n // Assert\n static::assertTrue($listenerCalled);\n }", "public function addListener($name, $listener, $priority = 0);", "public static function created(callable $listener, $priority = 0)\n {\n static::listen(ModelEvent::CREATED, $listener, $priority);\n }", "public function on($event, $callback){ }", "public function appendListenerForEvent(string $eventType, callable $listener): callable;", "public function initEventLogger()\n {\n $dispatcher = static::getEventDispatcher();\n\n $logger = $this->newEventLogger();\n\n foreach ($this->listen as $event) {\n $dispatcher->listen($event, function ($eventName, $events) use ($logger) {\n foreach ($events as $event) {\n $logger->log($event);\n }\n });\n }\n }", "protected function getCron_EventListenerService()\n {\n return $this->services['cron.event_listener'] = new \\phpbb\\cron\\event\\cron_runner_listener(${($_ = isset($this->services['cron.lock_db']) ? $this->services['cron.lock_db'] : $this->getCron_LockDbService()) && false ?: '_'}, ${($_ = isset($this->services['cron.manager']) ? $this->services['cron.manager'] : $this->getCron_ManagerService()) && false ?: '_'}, ${($_ = isset($this->services['request']) ? $this->services['request'] : ($this->services['request'] = new \\phpbb\\request\\request(NULL, true))) && false ?: '_'});\n }", "public function getListener(/* ... */)\n {\n return $this->_listener;\n }", "protected function _listener($name) {\n\t\treturn $this->_crud()->listener($name);\n\t}", "private function listeners()\n {\n foreach ($this['config']['listeners'] as $eventName => $classService) {\n $this['dispatcher']->addListener($classService::NAME, [new $classService($this), 'dispatch']);\n }\n }", "public function initializeListeners()\n {\n $this->eventsEnabled = false;\n $this->setPreloads();\n $this->setEvents();\n $this->eventsEnabled = true;\n }", "protected function listenForEvents()\n {\n $callback = function ($event) {\n foreach ($this->logWriters as $writer) {\n $writer->log($event);\n }\n };\n\n $this->events->listen(JobProcessing::class, $callback);\n $this->events->listen(JobProcessed::class, $callback);\n $this->events->listen(JobFailed::class, $callback);\n $this->events->listen(JobExceptionOccurred::class, $callback);\n }", "protected function registerListeners()\n {\n $this->container['listener.server'] = $this->container->share(function ($c) {\n return new \\Symfttpd\\EventDispatcher\\Listener\\ServerListener($c['filesystem'], $c['generator.server']);\n });\n\n $this->container['listener.gateway'] = $this->container->share(function ($c) {\n return new \\Symfttpd\\EventDispatcher\\Listener\\GatewayListener($c['filesystem'], $c['generator.gateway']);\n });\n }", "public function listeners($eventName);", "public static function create()\n {\n list(\n $message,\n $callbackService,\n $callbackMethod,\n $callbackParams\n ) = array_pad( func_get_args(), 4, null);\n\n static::addToEventQueue( array(\n 'type' => \"alert\",\n 'properties' => array(\n 'message' => $message\n ),\n 'service' => $callbackService,\n 'method' => $callbackMethod,\n 'params' => $callbackParams ?? []\n ));\n }", "public function requestCreateEvent()\n {\n $ch = self::curlIni('event_new', $this->eventParams);\n\n return $ch;\n }", "function __construct()\n\t{\n\t\t$this->events[\"AfterAdd\"]=true;\n\n\n\t}", "public function __construct()\n {\n Hook::listen(__CLASS__);\n }", "function add_listener($hook, $function_name){\n\t\tglobal $listeners;\n\n\t\t$listeners[$hook][] = $function_name;\n\t}", "public function __construct()\n {\n $this->events = new EventDispatcher();\n }", "protected function initEventLogger(): void\n {\n $logger = $this->newEventLogger();\n\n foreach ($this->listen as $event) {\n $this->dispatcher->listen($event, function ($eventName, $events) use ($logger) {\n foreach ($events as $event) {\n $logger->log($event);\n }\n });\n }\n }", "public function listen($events, $listener = null): void;", "public function onCreate($callback)\n {\n $this->listeners[] = $callback;\n return $this;\n }", "public static function listen() {\n $projectId = \"sunday-1601040613995\";\n\n # Instantiates a client\n $pubsub = new PubSubClient([\n 'projectId' => $projectId\n ]);\n\n # The name for the new topic\n $topicName = 'gmail';\n\n # Creates the new topic\n $topic = $pubsub->createTopic($topicName);\n\n echo 'Topic ' . $topic->name() . ' created.';\n }", "protected function registerEventListeners()\n {\n Event::listen(Started::class, function (Started $event) {\n $this->progress = $this->output->createProgressBar($event->objects->count());\n });\n\n Event::listen(Imported::class, function () {\n if ($this->progress) {\n $this->progress->advance();\n }\n });\n\n Event::listen(ImportFailed::class, function () {\n if ($this->progress) {\n $this->progress->advance();\n }\n });\n\n Event::listen(DeletedMissing::class, function (DeletedMissing $event) {\n $event->deleted->isEmpty()\n ? $this->info(\"\\n No missing users found. None have been soft-deleted.\")\n : $this->info(\"\\n Successfully soft-deleted [{$event->deleted->count()}] users.\");\n });\n\n Event::listen(Completed::class, function (Completed $event) {\n if ($this->progress) {\n $this->progress->finish();\n }\n });\n }", "public function addBeforeCreateListener(IBeforeCreateListener $listener)\n {\n $this->_lifecyclers[BeanLifecycle::BeforeCreate][] = $listener;\n }", "protected function registerInputEvents() {\n\t\t$this->getEventLoop()->addEventListener('HANG', function($event) {\n\t\t\t// Update our state\n\t\t\t$this->offHook = (bool)$event['value'];\n\n\t\t\t// Trigger specific events for receiver up and down states\n\t\t\t$eventName = $this->isOffHook() ? 'RECEIVER_UP' : 'RECEIVER_DOWN';\n\t\t\t$this->fireEvents($eventName, $event);\n\t\t});\n\n\t\t$this->getEventLoop()->addEventListener('TRIG', function($event) {\n\t\t\t// Update our state\n\t\t\t$this->dialling = (bool)$event['value'];\n\t\t});\n\n\t\t// Proxy registration for all EventLoop events to pass them back up to our own listeners\n\t\t$this->getEventLoop()->addEventListener(true, function ($event, $type) {\n\t\t\t// Fire event to our own listeners\n\t\t\t$this->fireEvents($type, $event);\n\t\t});\n\t}", "public static function creating($callback)\n {\n self::listenEvent('creating', $callback);\n }", "public function attach(string $event, callable $listener, int $priority = 0): void;", "public function __construct()\n {\n $this->listnerCode = config('settings.listener_code.DeletingVoucherEventListener');\n }", "protected function registerEventListener()\n {\n $subscriber = $this->getConfig()->get('audit-trail.subscriber', AuditTrailEventSubscriber::class);\n $this->getDispatcher()->subscribe($subscriber);\n }", "function listenTo(string $eventName, callable $callback)\n {\n EventManager::register($eventName, $callback);\n }", "public function attach($identifier, $event, callable $listener, $priority = 1)\n {\n }", "public function testRegisiterListenerMethodAddsAListener()\n\t{\n\t\t$instance = new Dispatcher();\n\n\t\t$instance->register_listener('some_event', 'my_function');\n\n\t\t$this->assertSame(array('some_event' => array('my_function')), $instance->listeners);\n\t\t$this->assertAttributeSame(array('some_event' => array('my_function')), 'listeners', $instance);\n\t}", "protected function getPhpbb_Viglink_ListenerService()\n {\n return $this->services['phpbb.viglink.listener'] = new \\phpbb\\viglink\\event\\listener(${($_ = isset($this->services['config']) ? $this->services['config'] : $this->getConfigService()) && false ?: '_'}, ${($_ = isset($this->services['template']) ? $this->services['template'] : $this->getTemplateService()) && false ?: '_'});\n }", "public static function create($className, array &$extraTabs, $selectedTabId)\r\n {\r\n $createClass = XenForo_Application::resolveDynamicClass($className, 'listener_th');\r\n if (!$createClass) {\r\n throw new XenForo_Exception(\"Invalid listener '$className' specified\");\r\n }\r\n \r\n return new $createClass($extraTabs, $selectedTabId);\r\n }", "function listen($listener)\n{\n return XPSPL::instance()->listen($listener);\n}", "function getEventListeners()\n {\n $listeners = array();\n \n $listener = new Listener($this);\n \n $listeners[] = array(\n 'event' => RoutesCompile::EVENT_NAME,\n 'listener' => array($listener, 'onRoutesCompile')\n );\n\n $listeners[] = array(\n 'event' => GetAuthenticationPlugins::EVENT_NAME,\n 'listener' => array($listener, 'onGetAuthenticationPlugins')\n );\n\n return $listeners;\n }", "protected static function loadListeners() {\n\t\t\n\t\t// default var\n\t\t$configDir = Config::getOption(\"configDir\");\n\t\t\n\t\t// make sure the listener data exists\n\t\tif (file_exists($configDir.\"/listeners.json\")) {\n\t\t\t\n\t\t\t// get listener list data\n\t\t\t$listenerList = json_decode(file_get_contents($configDir.\"/listeners.json\"), true);\n\t\t\t\n\t\t\t// get the listener info\n\t\t\tforeach ($listenerList[\"listeners\"] as $listenerName) {\n\t\t\t\t\n\t\t\t\tif ($listenerName[0] != \"_\") {\n\t\t\t\t\t$listener = new $listenerName();\n\t\t\t\t\t$listeners = $listener->getListeners();\n\t\t\t\t\tforeach ($listeners as $event => $eventProps) {\n\t\t\t\t\t\t$eventPriority = (isset($eventProps[\"priority\"])) ? $eventProps[\"priority\"] : 0;\n\t\t\t\t\t\tself::$instance->addListener($event, array($listener, $eventProps[\"callable\"]), $eventPriority);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t}\n\t\t\n\t}", "function __construct()\n\t{\n\t\t$this->events[\"BeforeShowList\"]=true;\n\n\t\t$this->events[\"BeforeProcessList\"]=true;\n\n\t\t$this->events[\"BeforeProcessPrint\"]=true;\n\n\t\t$this->events[\"BeforeShowPrint\"]=true;\n\n\t\t$this->events[\"BeforeQueryList\"]=true;\n\n\t\t$this->events[\"BeforeAdd\"]=true;\n\n\t\t$this->events[\"BeforeProcessEdit\"]=true;\n\n\t\t$this->events[\"BeforeEdit\"]=true;\n\n\t\t$this->events[\"BeforeShowEdit\"]=true;\n\n\t\t$this->events[\"BeforeProcessView\"]=true;\n\n\t\t$this->events[\"BeforeShowView\"]=true;\n\n\n\n\n\t\t$this->events[\"ProcessValuesView\"]=true;\n\n\t\t$this->events[\"ProcessValuesEdit\"]=true;\n\n\t\t$this->events[\"CustomAdd\"]=true;\n\n\t\t$this->events[\"CustomEdit\"]=true;\n\n\t\t$this->events[\"ProcessValuesAdd\"]=true;\n\n\t\t$this->events[\"BeforeQueryEdit\"]=true;\n\n\t\t$this->events[\"BeforeQueryView\"]=true;\n\n\n\t\t$this->events[\"BeforeProcessAdd\"]=true;\n\n\n//\tonscreen events\n\t\t$this->events[\"calmonthly_snippet2\"] = true;\n\t\t$this->events[\"calmonthly_snippet1\"] = true;\n\t\t$this->events[\"Monthly_Next_Prev\"] = true;\n\n\t}", "function defineHandlers() {\n EventsManager::listen('on_rawtext_to_richtext', 'on_rawtext_to_richtext');\n EventsManager::listen('on_daily', 'on_daily');\n EventsManager::listen('on_wireframe_updates', 'on_wireframe_updates');\n }", "public function createEvents()\n {\n //\n\n return 'something';\n }", "public static function createInstance()\n {\n return new GridPrintEventManager('ISerializable');\n }", "public function setUp()\n {\n if ($this->getOption('listener') === true) \n $this->addListener(new BlameableListener($this->_options));\n }", "public static function created($callback)\n {\n self::listenEvent('created', $callback);\n }", "public function addListener()\n {\n $dispatcher = $this->wrapper->getDispatcher();\n $listener = new TestListener();\n\n $dispatcher->addListener(PsKillEvents::PSKILL_PREPARE, [$listener, 'onPrepare']);\n $dispatcher->addListener(PsKillEvents::PSKILL_SUCCESS, [$listener, 'onSuccess']);\n $dispatcher->addListener(PsKillEvents::PSKILL_ERROR, [$listener, 'onError']);\n $dispatcher->addListener(PsKillEvents::PSKILL_BYPASS, [$listener, 'onBypass']);\n\n return $listener;\n }", "public static function addEventListener($event, $listenerClassName) {\n\t\tif (!is_a($listenerClassName, EventListenerInterface::class, TRUE)) {\n\t\t\tthrow new \\RuntimeException(\n\t\t\t\tsprintf(\n\t\t\t\t\t'Invalid CMIS Service EventListener: %s must implement %s',\n\t\t\t\t\t$listenerClassName,\n\t\t\t\t\tEventListenerInterface::class\n\t\t\t\t)\n\t\t\t);\n\t\t}\n\t\tstatic::$eventListeners[get_called_class()][$event][] = $listenerClassName;\n\t}", "public function makeListener($listener, $wildcard = false): Closure;", "public function createSubscriber();", "public function listener() {\n\t\treturn $this->_runtime['listener'];\n\t}", "public function addEventListener($events, $eventListener)\n {\n $this->eventListeners[] = array('events' => $events, 'listener' => $eventListener);\n }", "function __construct()\r\n\t{\r\n\t\t$this->events[\"BeforeAdd\"]=true;\r\n\r\n\r\n\t}", "function __construct()\n\t{\n\n\t\t$this->events[\"BeforeEdit\"]=true;\n\n\n\t\t$this->events[\"BeforeShowAdd\"]=true;\n\n\t\t$this->events[\"BeforeShowEdit\"]=true;\n\n\t\t$this->events[\"IsRecordEditable\"]=true;\n\n\t\t$this->events[\"AfterAdd\"]=true;\n\n\t\t$this->events[\"BeforeAdd\"]=true;\n\n\t\t$this->events[\"AfterDelete\"]=true;\n\n\t\t$this->events[\"AfterEdit\"]=true;\n\n\t\t$this->events[\"BeforeMoveNextList\"]=true;\n\n\n//\tonscreen events\n\n\t}", "public function startListening();", "public function addEntryAddedListener(callable $listener): SubscriptionInterface;", "function __construct()\n\t{\n\t\t$this->events[\"BeforeAdd\"]=true;\n\n\t\t$this->events[\"BeforeEdit\"]=true;\n\n\t\t$this->events[\"AfterAdd\"]=true;\n\n\n\t}", "function GetEventListeners() {\n $my_file = '{%IEM_ADDONS_PATH%}/dynamiccontenttags/dynamiccontenttags.php';\n $listeners = array ();\n\n $listeners [] =\n array (\n 'eventname' => 'IEM_SENDSTUDIOFUNCTIONS_GENERATEMENULINKS',\n 'trigger_details' => array (\n 'Addons_dynamiccontenttags',\n 'SetMenuItems'\n ),\n 'trigger_file' => $my_file\n );\n\n $listeners[] =\n array (\n 'eventname' => 'IEM_USERAPI_GETPERMISSIONTYPES',\n 'trigger_details' => array (\n 'Interspire_Addons',\n 'GetAddonPermissions',\n ),\n 'trigger_file' => $my_file\n );\n\n $listeners [] =\n array (\n 'eventname' => 'IEM_DCT_HTMLEDITOR_TINYMCEPLUGIN',\n 'trigger_details' => array (\n 'Addons_dynamiccontenttags',\n 'DctTinyMCEPluginHook'\n ),\n 'trigger_file' => $my_file\n );\n\n $listeners [] =\n array (\n 'eventname' => 'IEM_EDITOR_TAG_BUTTON',\n 'trigger_details' => array (\n 'Addons_dynamiccontenttags',\n 'CreateInsertTagButton'\n ),\n 'trigger_file' => $my_file\n );\n\n $listeners[] =\n array (\n 'eventname' => 'IEM_ADDON_DYNAMICCONTENTTAGS_GETALLTAGS',\n 'trigger_details' => array (\n 'Addons_dynamiccontenttags',\n 'getAllTags'\n ),\n 'trigger_file' => $my_file\n );\n\n $listeners[] =\n array (\n 'eventname' => 'IEM_ADDON_DYNAMICCONTENTTAGS_REPLACETAGCONTENT',\n 'trigger_details' => array (\n 'Addons_dynamiccontenttags',\n 'replaceTagContent'\n ),\n 'trigger_file' => $my_file\n );\n\n return $listeners;\n }", "function on_creation() {\n $this->init();\n }", "public function addEventListener(ListenerInterface $eventListener)\n {\n $this->eventListeners[] = $eventListener;\n }" ]
[ "0.65685207", "0.62875676", "0.6221792", "0.6197413", "0.61627764", "0.6129312", "0.6096226", "0.6056844", "0.6051069", "0.6041841", "0.596228", "0.596194", "0.5957539", "0.59439605", "0.58821785", "0.58821785", "0.5874665", "0.5864387", "0.5856076", "0.584338", "0.5824244", "0.5820997", "0.5791637", "0.57913053", "0.57893854", "0.57716024", "0.5764599", "0.5744472", "0.57417566", "0.57387024", "0.5721539", "0.57068586", "0.5699624", "0.56838834", "0.5675836", "0.56686187", "0.5661412", "0.56601405", "0.56584114", "0.5649107", "0.5638085", "0.56257224", "0.56172097", "0.56064796", "0.55919635", "0.5579062", "0.55775297", "0.5559927", "0.5546297", "0.5546121", "0.5545537", "0.5539715", "0.55295366", "0.55276597", "0.5527287", "0.551302", "0.5497285", "0.5495119", "0.54845315", "0.54834753", "0.54812366", "0.5478984", "0.5474917", "0.5471286", "0.54693574", "0.54684293", "0.5466594", "0.5465012", "0.5450231", "0.5450062", "0.5450001", "0.544321", "0.54308116", "0.54218924", "0.5389615", "0.53857446", "0.5378957", "0.5378836", "0.53771406", "0.5368413", "0.5360908", "0.5356685", "0.5349897", "0.53419805", "0.5340825", "0.53330225", "0.53323317", "0.5330117", "0.53270465", "0.5326564", "0.5307367", "0.52996707", "0.52980274", "0.52973336", "0.52886003", "0.528163", "0.5276869", "0.5269541", "0.5268173", "0.5265876", "0.52629435" ]
0.0
-1
Set your App ID and App Secret.
public function GetInfo($id1) { $appID = '1811806812250197'; $appSecret = '51aa7241711eecf5d9f4da5010b553ab'; //Create an access token using the APP ID and APP Secret. $accessToken = $appID . '|' . $appSecret; //The ID of the Facebook page in question. //Tie it all together to construct the URL $url = "https://graph.facebook.com/$id1?fields=id,name,from,link,created_time,images,reactions.summary(true)&access_token=$accessToken"; //Make the API call $result = file_get_contents($url); //echo $result; //Decode the JSON result. $decoded = json_decode($result, true); //echo $de ; $id = $decoded['id']; $date = $decoded['created_time']; $net = 'Facebook'; $medio = $decoded['from']['name']; $resume = $decoded['name']; $pos = 0; $negs = 0; $neut = 0; $link = $decoded['link']; $asunto = 0; $actores = 0; $reacts = $decoded['reactions']['summary']['total_count']; $shares = 0; $img = $decoded["images"][0]['source']; $fpost = new fbpost($id, $date, $net, $medio, $resume, $pos, $negs, $neut, $link, $asunto, $actores, $reacts, $shares, $img); // // echo"<br>". $fpost->id; // echo"<br>". $fpost->date; // echo"<br>". $fpost->net; // echo"<br>". $fpost->medio; // echo"<br>". $fpost->resume; // echo"<br>". $fpost->pos; // echo"<br>". $fpost->negs; // echo"<br>". $fpost->neut; // echo"<br>". $fpost->link; // echo"<br>". $fpost->asunto; // echo"<br>". $fpost->actores; // echo"<br>". $fpost->reacts; // echo"<br>". $fpost->shares; // return $fpost; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setAppSecret($appSecret)\n {\n $this->appSecret = $appSecret;\n }", "function __construct($appId, $appSecret) {\n $this->appId = $appId;\n $this->appSecret = $appSecret;\n }", "public function setAppID($id)\n {\n $this->parameters['appid'] = $id;\n }", "public function setAppId($value);", "function setAppId($value)\n {\n $this->_props['AppId'] = $value;\n }", "private function setCredentials()\n\t{\n\t\t$this->credentials['app_token'] = $this->settings_repo->getSiteSetting('facebook', 'app_token');\n\t\t$this->credentials['page_id'] = $this->settings_repo->getSiteSetting('facebook', 'page_id');\n\t}", "public function facebookAppSecret()\r\n\t{\r\n\t\treturn Mage::getStoreConfig('ezfacebook/facebook/appsec');\r\n\t}", "public function generateKeyAndSecret() {\n $user = user_load($this->uid);\n\n $this->app_key = str_replace(array(' ', '', '-'), '_', strtolower($this->title));\n $this->app_secret = md5($user->name . $this->time);\n }", "public function getAppSecret()\n {\n return $this->appSecret;\n }", "public function getAppSecret(): string;", "public function setAppSecret(string $secret): SocketApp;", "public function setClientSecret($clientSecret){\n $this->clientSecret = $clientSecret;\n }", "public function setAppId($val)\n {\n $this->_propDict[\"appId\"] = $val;\n return $this;\n }", "public function setClientSecret($client_secret) {\n\t\t$this->client_secret = $client_secret;\n\t}", "public function setToken()\n\t{\n\t\t $args = phpSmug::processArgs( func_get_args() );\n\t\t $this->oauth_token = $args['id'];\n\t\t $this->oauth_token_secret = $args['Secret'];\n\t}", "public function setSecret($secret);", "public function setSecret($secret);", "public function setApp($app)\n {\n $this->app = $app;\n }", "public function setApplicationID($app_id) \n\t{\n\t\t$this->application_id = $app_id;\n\t}", "public function setUseAppID($use_appid) \n \t{\n \t\t$this->use_appid = $use_appid;\n \t}", "public function __construct($appId = null, $appSecret = null)\r\r\n {\r\r\n $this->appId = FacebookSession::_getTargetAppId($appId);\r\r\n $this->appSecret = FacebookSession::_getTargetAppSecret($appSecret);\r\r\n\r\r\n $this->instantiateSignedRequest();\r\r\n }", "public function run()\n {\n Setting::create([\n 'app_name' => 'StreamApp',\n 'authorization' => '', \n 'tmdb_api_key' => 'a95c0a3b234912d28326d5c272124ad1',\n 'tmdb_lang' => [\n 'english_name' => \"English\",\n 'iso_639_1' => \"en\",\n 'name' => \"English\"\n ],\n 'app_url_android' => '',\n 'app_url_ios' => '',\n 'title_in_poster' => false,\n 'app_bar_animation' => true,\n 'livetv' => true,\n 'kids' => true,\n 'ad_app_id' => 'ca-app-pub-3940256099942544~3347511713',\n 'ad_banner' => false,\n 'ad_unit_id_banner' => 'ca-app-pub-3940256099942544/6300978111',\n 'ad_interstitial' => false, \n 'ad_unit_id_interstitial' => 'ca-app-pub-3940256099942544/1033173712',\n 'ad_ios_app_id' => 'ca-app-pub-3940256099942544~1458002511',\n 'ad_ios_banner' => false,\n 'ad_ios_unit_id_banner' => 'ca-app-pub-3940256099942544/2934735716', \n 'ad_ios_interstitial' => false,\n 'ad_ios_unit_id_interstitial' => 'ca-app-pub-3940256099942544/4411468910', \n 'app_color_dark' => true,\n 'app_background_color' => '#1C1C1C',\n 'app_header_recent_task_color' => '#212121', \n 'app_primary_color' => '#FF4500', \n 'app_splash_color' => '#FF4500', \n 'app_buttons_color' => '#FF4500', \n 'app_bar_color' => '#000000',\n 'app_bar_opacity' => 0.15,\n 'app_bar_icons_color' => '#FFFFFF', \n 'bottom_navigation_bar_color' => '#1C1C1C',\n 'icons_color' => '#FFFFFF',\n 'text_color' => '#FFFFFF',\n 'app_bar_title_color' => '#FFFFFF'\n ]);\n }", "public function run()\n {\n DB::table(\"apps\")->delete();\n\n App::create([\n 'client_id' => 'koala',\n 'name' => 'Koala',\n 'author_id' => 1,\n 'homepage_url' => 'http://121.42.144.117:2111',\n 'logo_url' => 'https://www.prepbootstrap.com/bootstrap-theme/shield/preview/images/team/team04.jpg',\n 'description' => '西邮Linux兴趣小组资源管理平台',\n 'secret' => '$2y$10$8Gz5X7XkQtVzwFU8C9zSQ.FzIH6OZNd5D',\n 'redirect_uri' => 'http://121.42.144.117:2111/connect/adam/callback',\n 'status' => 3,\n 'submit_status' => 3,\n 'scopes' => 'all'\n ]);\n }", "public function __construct($appId = null, $appSecret = null)\r\n \t{\r\n \t\t$appId = (null !== $appId) ? $appId : FACEBOOK_API_APPID;\r\n \t\t$appSecret = (null !== $appSecret) ? $appSecret : FACEBOOK_API_APPSECRET;\r\n\r\n \t\t// build credentials\r\n \t\t$credentials = new API\\Credentials(array\r\n \t\t(\r\n \t\t\t'appId' => $appId,\r\n \t\t\t'secret' => $appSecret,\r\n \t\t));\r\n\r\n \t\t$credentials->setCookieSupport(true);\r\n \t\t$credentials->setBaseDomain($_SERVER['HTTP_HOST']);\r\n \t\t$credentials->setFileUploadSupport(true);\r\n\r\n \t\t// build api client\r\n \t$this->_client = new API\\Client\\PhpSession($credentials);\r\n \t$this->_credentials = $credentials;\r\n \t}", "public function setClientSecret($secret)\n {\n $this->sharedSecret = $secret;\n }", "function setConfig() {\n $credentialsPath = './credentials.json';\n $credentialsAvailable = false;\n \n $shortopts = \"\";\n $longopts = array(\n \"cid:\",\n \"pid:\",\n \"csec:\",\n \"ruri:\"\n );\n \n $options = getopt($shortopts, $longopts);\n \n if(!file_exists($credentialsPath) && count($options) < 3 ) {\n print(\"You must specify the app credentials!\");\n die;\n }\n \n if(!!$options['cid'] && !!$options['csec'] && !!$options['ruri']) {\n $credentials = [\n \"web\" => [\n \"client_id\" => $options['cid'],\n \"project_id\" => \"\",\n \"auth_uri\" => \"https://accounts.google.com/o/oauth2/auth\",\n \"token_uri\" => \"https://oauth2.googleapis.com/token\",\n \"auth_provider_x509_cert_url\" => \"https://www.googleapis.com/oauth2/v1/certs\",\n \"client_secret\" => $options['csec'],\n \"redirect_uris\" => [\n $options['ruri']\n ]\n ]\n ];\n \n file_put_contents($credentialsPath, json_encode($credentials));\n $credentialsAvailable = true;\n }\n else {\n if(file_exists($credentialsPath)) {\n $credentialsAvailable = true;\n }\n }\n \n if(!$credentialsAvailable) {\n print(\"You must specify the app credentials!\");\n die;\n }\n\n return $credentialsPath;\n}", "public function manageApp($client_id, $client_secret)\n {\n $data = [\n \"client_id\" => $client_id,\n \"client_secret\" => $client_secret\n ];\n return self::execute(\"POST\", \"authorized-apps\", $data);\n }", "public function getAppId();", "function facebook_app_token()\r\n{\r\n\tglobal $settings;\r\n\r\n\treturn $settings['facebook_app_id'] . '|' . $settings['facebook_app_secret'];\r\n}", "public function run()\n {\n Passport::client()->create([\n 'user_id' => null,\n 'name' => 'Mobile App',\n 'secret' => env('PASSPORT_CLIENT_SECRET', '1dvxrJwoSD287sqsxJENNSh2hglXivbyqRbTPNU2'),\n 'redirect' => config('app.url'),\n 'personal_access_client' => 0,\n 'password_client' => 1,\n 'revoked' => false,\n ]);\n }", "public function init()\n {\n $this->accessToken = 'EAAPgIZBacbTMBAJnVjjmoOW3tjZClqcJDUP3NZB5Dbi72zA2Ix8tE5qviZAE4BF3UqluxlZCLAOnlqe0WYeTXGZBTesuyGPQXb7iPZAC2qOWnX376GvrvZAiO34bcEJ7TYyPqgqV2uLZAkvHD8DkjuPZC7OEpS91ydHnNXbEPpclLSQQZDZD';\n }", "public static function setApplication(Application $app)\n {\n static::$app = $app;\n }", "public function attachClientIdAndSecretToIntegration(string $consumerKey, string $clientId, string $clientSecret): void;", "public function __construct() {\n $this->config = $config\t = &get_config();\n\n $this->app_id\t\t= $config['linkedin_app_id'];\n $this->app_secret\t= $config['linkedin_app_secret'];\n\n if(!$this->app_id || !$this->app_secret) {\n throw new Exception('Application ID not set', APP_ID_OR_SECRET_NOT_SET);\n }\n\n }", "function GET_APP_ID(){\n return \"7d0df388-f064-48eb-9092-27fbbf0a438e\";\n}", "public function setAppKey($key)\n\t{\n\t\tif (empty($key)) {\n\t\t\trequire_once 'Syx/Platform/Exception.php';\n\t\t\tthrow new Syx_Platform_Exception(\"empty for appKey\");\n\t\t}\n\t\t$this->_appKey = (string)$key;\n\t}", "function set_laravel_passport_grant_client_token()\n {\n DB::table('oauth_clients')\n ->where('id', 2)\n ->update(['secret' => 'dLdsIf3nPMWJC4gOCNcsUn5pBSv5tTPSaU51Gu2F']);\n }", "public function run()\n {\n $datetime = \\Carbon\\Carbon::now();\n\n // Client\n $clientId = 'ANGULAR_APP';\n $client = DB::table('oauth_clients')->where('id', $clientId)->first();\n if ($client) {\n $secret = $client->secret;\n\n } else {\n DB::table('oauth_clients')->insert([\n 'id' => $clientId,\n 'name' => 'Autentication for Angular',\n 'secret' => $secret = str_random(20),\n 'created_at' => $datetime,\n 'updated_at' => $datetime,\n ]);\n }\n\n $constants = [\n 'BASE_PATH' => 'http://localhost:8000',\n 'API_URL' => 'http://localhost:8000',\n 'AUTH_SECURE' => false,\n 'BROADCAST_DRIVER' => config('broadcasting.default'),\n 'PUSHER_API_KEY' => config('broadcasting.connections.pusher.key'),\n 'FANOUT_REALM_ID' => config('broadcasting.connections.fanout.realm_id'),\n ];\n\n $path = base_path('env-config.json');\n if (File::exists($path)) {\n $atual = (array) @json_decode(File::get($path));\n $constants = array_merge($constants, $atual);\n }\n\n File::put(base_path('env-config.json'), str_replace('\\\\', '', json_encode($constants)));\n\n // Grant\n $grantId = 'password';\n $grant = DB::table('oauth_grants')->where('id', $grantId)->first();\n if (!$grant) {\n DB::table('oauth_grants')->insert([\n 'id' => $grantId,\n 'created_at' => $datetime,\n 'updated_at' => $datetime,\n ]);\n }\n\n // Client to Grant\n $clientGrant = DB::table('oauth_client_grants')\n ->where('client_id', $clientId)\n ->where('grant_id', $grantId)\n ->first();\n\n if (!$clientGrant) {\n DB::table('oauth_client_grants')->insert([\n 'client_id' => $clientId,\n 'grant_id' => $grantId,\n 'created_at' => $datetime,\n 'updated_at' => $datetime,\n ]);\n }\n }", "private function set_secret($secret) {\n\t\t$this->secret = $secret;\n\t}", "public function setToken($token, $token_secret) {}", "public function getAppId()\n {\n }", "public function setAppId(int $appId) : self\n {\n $this->initialized['appId'] = true;\n $this->appId = $appId;\n return $this;\n }", "public function setSecret($secret)\n {\n $this->secret = $secret;\n }", "public function setSecret($secret)\n {\n $this->secret = $secret;\n }", "public function setSecret($secret)\n {\n $this->secret = $secret;\n }", "public function setApiSecret($apiSecret){\n\t\t$this->apiSecret = $apiSecret;\n\t}", "protected function setAppSettings()\n {\n // set the application time zone\n date_default_timezone_set($this->config->get('app.timezone','UTC'));\n\n // set the application character encoding\n mb_internal_encoding($this->config->get('app.encoding','UTF-8'));\n }", "public function run()\n {\n DB::table('oauth_clients')->where('personal_access_client', 1)->update([\n 'id' => 'a9d26ed9-abb9-4582-b8bd-2998a10fc6c7',\n 'secret' => 'VfTtHS8UCLtQpLeDgdnMLDlOtlziZmFvaniiVQFW',\n ]);\n\n DB::table('oauth_clients')->where('password_client', 1)->update([\n 'id' => 'b45ce90e-63a0-45a7-a73d-6c7523e06be1',\n 'secret' => 'xjPdb7F7LMCtqKCuJFrAc0pp1gZydWRfjwoSqxsG',\n ]);\n }", "public function setSecret($secret) {\n $this->secret = $secret;\n }", "public function __construct($appId)\n {\n $this->appId = $appId;\n }", "public function run()\n {\n $client = [\n 'id' => 'LavAngId',\n 'secret' => 'SeCrEt_WoRd',\n 'name' => 'LavAngAPP'\n ];\n\n OauthClient::create($client);\n }", "public function setSecret($secret)\n\t{\n\t\t$this->secret = $secret;\n\t}", "public function get_app_secret() {\n\n\t\t// Get plugin settings.\n\t\t$settings = $this->get_plugin_settings();\n\n\t\treturn rgar( $settings, 'customAppSecret' ) ? rgar( $settings, 'customAppSecret' ) : null;\n\n\t}", "public function display_app_secret() {\n\t\t// Now grab the options based on what we're looking for\n\t\t$opts = get_option( 'emcl_settings' );\n\t\t$emc_app_secret = isset( $opts['emc_app_secret'] ) ? $opts['emc_app_secret'] : '';\n\t\t// And display the view\n\t\tinclude $this->views . 'settings-app-secret-field.php';\n\t}", "public function run()\n {\n Config::create(['igdb_key' => '1234test']);\n }", "public function getAppId(){\n return $this->appId;\n }", "public function __construct( $app ) {\r\n // Make sure we have the app they're talking about\r\n if ( !array_key_exists( $app, $this->apps ) )\r\n throw new InvalidParametersException( _('You entered an invalid facebook application name') );\r\n\r\n // Get facebook\r\n\t\tlibrary('facebook/facebook');\r\n\r\n\t\t// Create our Application instance (replace this with your appId and secret).\r\n\t\t$this->facebook = new Facebook(array(\r\n\t\t\t'appId' => $this->apps[$app]['id'],\r\n\t\t\t'secret' => $this->apps[$app]['secret'],\r\n\t\t\t'cookie' => true,\r\n\t\t));\r\n\r\n $this->id = $this->apps[$app]['id'];\r\n $this->secret = $this->apps[$app]['secret'];\r\n\t}", "private function set_idapp($idapp = '') {\r\n if (empty($idapp)) {\r\n $this->add_log('set_idapp: IdApp KO, parameter is empty', 'ERROR');\r\n return false;\r\n }\r\n\r\n $this->add_log('set_idapp: IdApp OK, setted to \"'.$idapp.'\"');\r\n\r\n $this->idApp = $idapp;\r\n return true;\r\n }", "public function __construct($appId = null)\n {\n $this\n ->setAppId($appId);\n }", "public function setCurrentAppId($appId) {\n $this->container->offsetSet('appId', $appId);\n }", "private function setSettings() {\n $this ->setAccessToken( $this ->token );\n $this ->setAccountId( self::ACCOUNT_ID );\n }", "public function setUp(): void\n {\n // https://docs.aws.amazon.com/sdk-for-php/v3/developer-guide/guide_credentials_environment.html\n putenv('AWS_ACCESS_KEY_ID=AKIAIOSFODNN7EXAMPLE');\n putenv('AWS_SECRET_ACCESS_KEY=wJalrXUtnFEMI/K7MDENG/bPxRfiCYEXAMPLEKEY');\n }", "public function getClientSecret();", "public function getClientSecret();", "public function set_access_token($token, $secret) {\n $this->access_token = $token;\n $this->access_token_secret = $secret;\n }", "function encryptWithAppSecret($password)\n{\n return hash_hmac('sha256', $password, env('APP_HASH'));\n}", "public static function setAuth($accessKey, $secretKey)\n\t{\n\t\tself::$__accessKey = $accessKey;\n\t\tself::$__secretKey = $secretKey;\n\t}", "public function __construct ( $client_id, $client_secret, $access_token = null, $refresh_token = null ) {\n \n \t$this->client_id \t\t= $client_id;\n $this->client_secret \t= $client_secret;\n $this->access_token \t= $access_token;\n $this->refresh_token \t= $refresh_token;\n \n echo '=================================================='. PHP_EOL;\n echo 'FUNFOU !!!' . PHP_EOL;\n }", "public function getAppId(): string;", "public function getAppKey(): string;", "public function setConfig($apiKey, $secret = null)\n {\n $this->apiKey = $apiKey;\n $this->secret = $secret;\n }", "public function setAppId($var)\n {\n GPBUtil::checkString($var, True);\n $this->app_id = $var;\n }", "public function setAppId($var)\n {\n GPBUtil::checkString($var, True);\n $this->app_id = $var;\n }", "public function setAppId($var)\n {\n GPBUtil::checkString($var, True);\n $this->app_id = $var;\n }", "public function setAppId($var)\n {\n GPBUtil::checkString($var, True);\n $this->app_id = $var;\n }", "public function setAuth($key, $secret)\n {\n $this->apiKey = $key;\n $this->apiSecret = $secret;\n }", "private function _set_secret($secret) {\n\t\t$this->set_secret(bin2hex($secret));\n\t}", "public function setApplicationId(?string $value): void {\n $this->getBackingStore()->set('applicationId', $value);\n }", "public function getAppId()\n {\n return $this->appId;\n }", "public function getAppId()\n {\n return $this->appId;\n }", "public function setAppKey(string $key): SocketApp;", "private function define_jwt_secret_key() {\n\t\tdefine( 'JWT_AUTH_SECRET_KEY', get_option( $this->option_name_jwt_secret_key ) );\n\t}", "public function & SetAppDir ($appDir);", "public function app_secret_callback()\n {\n printf(\n '<input type=\"text\" id=\"app_secret\" name=\"firebird_name[app_secret]\" value=\"%s\" />',\n isset( $this->options['app_secret'] ) ? esc_attr( $this->options['app_secret']) : ''\n );\n }", "public static function client($id, $secret)\n {\n Authentication::$defaultClientId = $id;\n Authentication::$defaultClientSecret = $secret;\n }", "public function appId(?string $value): self\n {\n $this->instance->setAppId($value);\n return $this;\n }", "public function facebookStoreToken() {\n if ( ! empty( $_GET['access_token'] ) ) {\n $this->instagramCode = $_GET['access_token'];\n update_option( self::FACEBOOK_TOKEN, $_GET['access_token'] );\n }\n }", "private function setSenderAppId($senderAppID)\n {\n\n // Check to see if the $senderAppID was set\n if(empty($senderAppID)) {\n\n throw new \\Exception('The senderAppId cannot be blank. Please contact AITS for a senderAppId');\n\n }\n\n $this->senderAppID = $senderAppID;\n\n }", "public function run()\n {\n // Seed app client 1\n factory(App\\Models\\OAuthClient::class)->create([\n 'id' => '6fC2745co07D4yW7X9saRHpJcE0sm0MT',\n 'secret' => 'KLqMw5D7g1c6KX23I72hx5ri9d16GJDW',\n 'name' => 'App 1'\n ]);\n\n // Seed app client 2\n factory(App\\Models\\OAuthClient::class)->create([\n 'id' => '4dJn65Dwvau4cj97a9BFEGrpJPl5E4t3',\n 'secret' => '8d5LY0WDd4S26Wlbgb6JFcvh0OJ52ENu',\n 'name' => 'App 2'\n ]);\n }", "public function setClientSecret($secret)\n\t{\n\t\tif (is_string($secret)) {\n\t\t\t$this->_values['client_secret'] = $secret;\n\t\t}\n\t}", "private function setOptions()\n {\n $this->clientId = $this->config['stravaSettings']['clientId'];\n $this->clientSecret = $this->config['stravaSettings']['clientSecret'];\n $this->redirectUri = $this->config['stravaSettings']['redirectUri'];\n $this->aprovalPrompt = $this->config['stravaSettings']['approval_prompt'];\n $this->scopes = $this->config['stravaSettings']['scopes'];\n }", "public function __construct()\n {\n parent::__construct();\n CoinGate::config([\n 'app_id' => '5507',\n 'api_key' => '8aPuGKxTwVAr9ycZ3n2zvN',\n 'api_secret' => 'lgTBcsASv7a8QjxO1kC5nyHdI0qVJmeE',\n ]);\n }", "public function testAppId()\n {\n $appId = 'id';\n $client = new Client();\n $driver = new OpenExchangeRatesDriver(\n $client,\n 'http://openexchangerates.org/api/latest.json'\n );\n $driver->setAppId($appId);\n $this->assertEquals($appId, $driver->getAppId());\n }", "public function __construct($app_id, $app_key, $api_url) {\n $this->_app_id = $app_id;\n $this->_app_key = $app_key;\n $this->_api_url = $api_url;\n }", "public function getAppKey();", "public static function set_token_access() {\n if (SesLibrary::_get('_uuid') || SesLibrary::_get('_uuid') == null) {\n $param = [\n 'uri' => config('app.base_api_uri') . '/generate-token-access?deviceid=' . SesLibrary::_get('_uuid'),\n 'method' => 'GET'\n ];\n $this->__init_request_api($param);\n }\n }", "public function run()\n {\n $client=new ClientSetting;\n $client->client_name='app1';\n $client->client_token='123456';\n $client->client_service='helpdesk';\n $client->client_db_connection='mysql';\n $client->client_db_driver='mysql';\n $client->client_db_host='127.0.0.1';\n $client->client_db_port='3306';\n $client->client_db_database='helpdesk';\n $client->client_db_username='forethought';\n $client->client_db_password='123456';\n $client->client_db_prefix='';\n $client->save();\n // $client->client_='';\n \n\n // $client->secondary_logo_url='www.Mastechsecondrylogo.com';\n // $client->mnemonic_url='www.mnemonic_url.com';\n // $client->logo_usage='The Mastech Digital Logo is primary symbol which represents the Mastech Digital Brand and its subdiaries. The logotype is stylized to represent our modern take on the rapidly-evolving digital landscape.';\n // $logos->save();\n\n \n \n }", "function confdev()\n{\n global $app, $appname, $appversion;\n $app->config([\n 'debug' => true,\n 'cookies.lifetime' => '5 minutes',\n 'cookies.secret_key' => 'b4924c3579e2850a6fad8597da7ad24bf43ab78e',\n\n ]);\n $app->getLog()->setEnabled(true);\n $app->getLog()->setLevel(\\Slim\\Log::DEBUG);\n $app->getLog()->info($appname . ' ' . $appversion . ': Running in development mode.');\n $app->getLog()->info('Running on PHP: ' . PHP_VERSION);\n}", "protected function getEnvironmentSetUp($app)\n {\n $app['config']->set('services.pushmix.key', 'subscription_id');\n }", "public function __construct($secret_key){\n $this->secret_key = $secret_key;\n }", "public static function setApplication(Application $app)\n {\n // fail if an attempt is made to overwrite\n // an existing Application reference.\n if (static::$app and ($app !== static::$app)) {\n new \\RuntimeException(\n 'Overwriting an existing Application instance is forbidden.');\n }\n\n static::$app = $app;\n }" ]
[ "0.73377156", "0.6571047", "0.64972275", "0.6430009", "0.6236499", "0.621495", "0.6097906", "0.60939777", "0.60877126", "0.60464454", "0.60283065", "0.59364027", "0.58002025", "0.5732319", "0.5718225", "0.5714254", "0.5714254", "0.5626632", "0.5625663", "0.55696946", "0.553913", "0.5520847", "0.5486403", "0.54554933", "0.5434542", "0.5434509", "0.543377", "0.5425155", "0.5419677", "0.54115415", "0.5377929", "0.5371424", "0.53676033", "0.5359853", "0.5343898", "0.52993417", "0.5297698", "0.5296223", "0.52874446", "0.5266853", "0.52564836", "0.5248851", "0.5242923", "0.5242923", "0.5242923", "0.5235374", "0.5225121", "0.5218946", "0.52162296", "0.5211875", "0.52079487", "0.51972693", "0.51945966", "0.51903665", "0.51891196", "0.5185779", "0.5183544", "0.51767844", "0.51514286", "0.5132169", "0.51278573", "0.5118338", "0.51170796", "0.51170796", "0.51058614", "0.51038754", "0.5096284", "0.5069888", "0.5056561", "0.5055349", "0.5043977", "0.50413907", "0.50413907", "0.50413907", "0.50413907", "0.50399023", "0.503897", "0.5031973", "0.49952242", "0.49952242", "0.49909645", "0.4977908", "0.49758682", "0.49752802", "0.497063", "0.49653527", "0.4962405", "0.49423972", "0.49314195", "0.49309832", "0.49281865", "0.4926852", "0.49212942", "0.4920009", "0.49167708", "0.48972413", "0.48803115", "0.4873464", "0.48705736", "0.48646095", "0.4864101" ]
0.0
-1
Constructor method for OfferScType
public function __construct(\StructType\PackageType $package = null, \StructType\AccommodationType $accommodation = null, \StructType\FlightType $flight = null, \StructType\RentalCarDetails4ScType $rentalCar = null, \StructType\InsuranceDetails4ScType $insurance = null, \StructType\TransferDetails4ScType $transfer = null, \StructType\ParkingDetails4ScType $parking = null, \StructType\AdditionalCostType $additionalCost = null) { $this ->setPackage($package) ->setAccommodation($accommodation) ->setFlight($flight) ->setRentalCar($rentalCar) ->setInsurance($insurance) ->setTransfer($transfer) ->setParking($parking) ->setAdditionalCost($additionalCost); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct(Offer $offer)\n {\n $this->offer = $offer;\n }", "public function __construct(\\StructType\\OfferScType $offer = null, \\StructType\\CommentList $comments = null)\n {\n $this\n ->setOffer($offer)\n ->setComments($comments);\n }", "public function __construct() {\n parent::__construct();\n $this->setOdataType('#microsoft.graph.offerShiftRequest');\n }", "public function __construct(Offer $offer, Scenario $scenario)\n {\n $this->offer = $offer;\n $this->scenario = $scenario;\n }", "public function __construct()\n {\n $this->types = array(self::TYPE_EMISSION, self::TYPE_TRANSFER);\n }", "public function __construct($offer = null, $price = null)\n {\n $this\n ->setOffer($offer)\n ->setPrice($price);\n }", "function __construct($type) {\n\t$this->type = $type;\n\t}", "public function __construct($type)\n {\n }", "function __construct($offers){\r\n $this->offers = $offers;\r\n $this->construct_xml_contain();\r\n $this->create_xml_file();\r\n }", "public function __construct($offer, $settings, $user)\n {\n if ($offer && $settings) {\n $this->offer = $offer;\n $this->settings = $settings;\n $this->user = $user;\n $this->accountId = $user->accountId;\n }\n }", "function __construct($type='simple')\n {\n $this->type = $type;\n }", "public function __construct($id, $seller, $type, $description, $askingPrice, $closingDate, $bid)\n {\n $this->id = $id;\n $this->seller = $seller;\n $this->type = $type;\n $this->description = $description;\n $this->askingPrice = $askingPrice;\n $this->closingDate = $closingDate;\n $this->bid = $bid;\n $this->sold = false;\n }", "public function __construct($type, $params, $culture) {\n\n parent::__construct($type, $params, $culture);\n\n \n }", "public function __construct($license, $driver, $typeCarAccepted, $seatMaterial) \n {\n //Hereda los atributos de car\n parent::__construct($license, $driver);\n $this->typeCarAccepted = $typeCarAccepted;\n $this->$seatMaterial = $seatMaterial;\n }", "public function __construct() {\n parent::__construct();\n //setting attribute types.\n settype($this->id, \"integer\");\n settype($this->name, \"string\");\n settype($this->question_type_id, \"integer\");\n }", "public function _construct()\n {\n $this->_init('sellerplan/sellerplan', 'sellerplan_id');\n }", "protected function _construct()\n {\n $this->_init(QuotePickupLocation::class, QuotePickupLocationResource::class);\n }", "public function __construct(User $user, Offer $offer)\n {\n $this->user = $user;\n $this->offer = $offer;\n }", "public function __construct( string$type='' )\n\t{\n\t\t$this->type= $type;\n\t}", "public function __construct($type) {\n $this->type = $type;\n }", "public function __construct($sender_name, $document, $data, $is_offer)\n {\n $this->sender_name = $sender_name;\n $this->document = $document;\n $this->data = $data;\n $this->is_offer = $is_offer;\n }", "public function __CONSTRUCT($type,$name) {\n $this->type = $type;\n $this->name = $name;\n $typeElement = new Element(\"input\",\"text\",\"listingType\",\"listingType\");\n $typeElement->setValue($this->type);\n $this->addRegisterElement($typeElement);\n }", "protected function _construct()\r\n {\r\n $this->_init('ss_price', 'price_id');\r\n }", "public function __construct($type, $price)\n {\n $this->type = $type;\n $this->price = $price;\n }", "public function __construct($type)\n {\n $this->type=$type;\n }", "public function __construct() {\n parent::__construct();\n $this->setOdataType('#microsoft.graph.windowsQualityUpdateCatalogItem');\n }", "public function __construct($type)\n {\n $this->type = $type;\n }", "public static function AddOffer(){\n\n\t\t\t\n\n\t\t}", "protected function _construct()\n {\n $this->_init('mageworx_optiontemplates_group_option_type_value', 'option_type_id');\n }", "public function __construct()\n {\n parent::__construct();\n $this->setType('smile_virtualcategories/rule_condition_combine');\n }", "public function __construct(array $partnerType = array())\n {\n $this\n ->setPartnerType($partnerType);\n }", "public function __construct() {\r\n parent::__construct(\r\n 'eightstore_lite_promo', 'ES : Promotional Banner Widget', array(\r\n 'description' => __('A widget that Gives Promo of the object', 'eightstore-lite')\r\n )\r\n );\r\n }", "public function __construct($id, $ProductName, $Extra, $maxExtra , $price, $type) {\n $this->id = $id;\n $this->ProductName = $ProductName;\n $this->Extra = $Extra;\n $this->maxExtra = $maxExtra;\n $this->price = $price;\n $this->type = $type;\n}", "public function __construct($_cardType = NULL,$_cardNumber = NULL,$_bankName = NULL,$_bankCode = NULL)\n {\n parent::__construct(array('CardType'=>$_cardType,'CardNumber'=>$_cardNumber,'BankName'=>$_bankName,'BankCode'=>$_bankCode),false);\n }", "public function __construct() {\n parent::__construct();\n $this->setOdataType('#microsoft.graph.windows10SecureAssessmentConfiguration');\n }", "public function __construct()\n {\n if (2 == func_num_args()) {\n $this->catalogName = func_get_arg(0);\n $this->brands = func_get_arg(1);\n }\n }", "function makeOffer()\r\n {\r\n \r\n }", "public function __construct() {\n\t\tparent::__construct();\n\n\t\t$this->category = _x( 'Multi Fields', 'xprofile field type category', 'buddypress' );\n\t\t$this->name = _x( 'Drop Down Select Box', 'xprofile field type', 'buddypress' );\n\n\t\t$this->supports_options = true;\n\n\t\t$this->set_format( '/^.+$/', 'replace' );\n\t\tdo_action( 'bp_xprofile_field_type_selectbox', $this );\n\t}", "public function __construct() {\n $this->Types;\n }", "function __construct ($intCreditCardType=null)\n\t\t{\n\t\t\tparent::__construct ('CreditCardTypes');\n\t\t\t\n\t\t\t// Instantiate the Variable Values for possible selection\n\t\t\t$this->_VISA\t\t= $this->Push (new CreditCardType (CREDIT_CARD_VISA));\n\t\t\t$this->_MASTERCARD\t= $this->Push (new CreditCardType (CREDIT_CARD_MASTERCARD));\n\t\t\t$this->_AMEX\t\t= $this->Push (new CreditCardType (CREDIT_CARD_AMEX));\n\t\t\t$this->_DINERS\t\t= $this->Push (new CreditCardType (CREDIT_CARD_DINERS));\n\t\t\t\n\t\t\t$this->setValue ($intCreditCardType);\n\t\t}", "public function __construct(ListingOffer $listing_offer, $cso, $donor)\n {\n $this->listing_offer = $listing_offer;\n $this->cso = $listing_offer->cso;\n $this->donor = $listing_offer->listing->donor;\n }", "public function __construct(\n string $type,\n string $name,\n string $id = null,\n string $subType = null\n )\n {\n $this->type = PeerEnums::{$type}();\n $this->id = $id;\n $this->name = $name;\n $this->subType = $subType;\n }", "public function __construct($seeker,$company,$listing)\n {\n $this->seeker = $seeker;\n $this->company = $company;\n $this->listing = $listing;\n\n }", "public function _construct()\n {\n $this->_init(\\Test\\Banner\\Model\\ResourceModel\\Banner::class);\n }", "function __construct ($strId)\n\t\t{\n\t\t\tparent::__construct ('ServiceStateType');\n\t\t\t\n\t\t\t$strName = 'Unknown';\n\t\t\t\n\t\t\tswitch ($strId)\n\t\t\t{\n\t\t\t\tcase SERVICE_STATE_TYPE_ACT:\n\t\t\t\t\t$strName = 'Australian Capital Territory';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_NSW:\n\t\t\t\t\t$strName = 'New South Wales';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_NT:\n\t\t\t\t\t$strName = 'Northern Territory';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_QLD:\n\t\t\t\t\t$strName = 'Queensland';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_SA:\n\t\t\t\t\t$strName = 'South Australia';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_TAS:\n\t\t\t\t\t$strName = 'Tasmania';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_VIC:\n\t\t\t\t\t$strName = 'Victoria';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase SERVICE_STATE_TYPE_WA:\n\t\t\t\t\t$strName = 'Western Australia';\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t}\n\t\t\t\n\t\t\t$this->oblstrType\t\t= $this->Push (new dataString\t('Id',\t\t$strId));\n\t\t\t$this->oblstrName\t\t= $this->Push (new dataString\t('Name',\t$strName));\n\t\t}", "public function __construct()\n {\n parent::__construct();\n\n // Set data types\n $this->data_types = array(\n 'title' => 'string',\n 'url' => 'url',\n 'url_key' => 'md5',\n 'embed' => 'string',\n 'created_on' => 'datetime'\n );\n\n }", "public function __construct()\n {\n $this->suits = \\Config::get('enums.card_suits');\n $this->values = \\Config::get('enums.card_values');\n }", "public function __construct(array $args)\n {\n parent::__construct(FALSE);\n $this->data['errors'] = array();\n // Check if the offer id is set\n $m_offer = new Offer_Model();\n if(isset($args['error'])){\n array_push($this->data['errors'], $args['error']);\n } \n // Check if we are giving a warning\n if (isset($args['warn']))\n {\n $this->warn($args['warn']);\n $this->back();\n }\n else if (isset($args['id']))\n {\n $this->offer = $m_offer->getOffer($args['id']);\n\n if ($this->offer)\n {\n\n // There is such an offer.. okay\n // Hold on tho, are we making a bid?\n // Process the bid first before displaying the offer\n if (isset($_POST[\"bid\"]))\n {\n $this->makeBid();\n $this->back();\n }\n\n $this->data[\"title\"] = \"Offer\";\n $this->data[\"specifier\"] = $this->offer[\"category\"];\n\n $this->data[\"offer\"] = $this->offer;\n\n // Get owner of this offer\n $owner = $m_offer->getOwner($args['id']);\n $this->data[\"owner\"] = $owner;\n\n // Construct the bidding area\n $m_category = new Category_Model();\n $categories = $m_category->getAllCategories();\n\n // Get owner transaction\n $m_transact = new Transact_Model();\n $transact = $m_transact->getTransactionByOfferId($args['id']);\n if( $transact ){\n $this->data[\"transact\"] = $transact[0];\n $this->data[\"CanStore\"] = $this->canStoreOffer($transact[0]);\n }\n\n //Can bid? Can Reserve?\n $this->data[\"CanBid\"] = $this->CanBids();\n $this->data[\"categories\"] = $categories;\n if(!($this->data['offer']['price']>0.00)){\n $this->data[\"CanReserve\"] = $this->CanReserve();\n }\n\n // Check if the current viewer is the offer owner\n // To disallow owner bidding on his own item\n if ($this->getMemberId() == $owner[\"id\"])\n $this->data[\"is_owner\"] = TRUE;\n\n // Prepare all the bidding/reserves information for this offer\n $this->getBids($this->offer[\"id\"]);\n $reserves = $this->getReserves($this->offer[\"id\"]);\n\n\n $this->display(\"offer.twig\", $this->data);\n }\n else\n {\n $this->redirect(self::REDIRECT_ERROR);\n }\n }\n elseif (isset($args['delete']))\n {\n if($m_offer->deleteOffer($args['delete'])){\n $this->back();\n }\n }\n else\n {\n // Go back to where the user come from\n $this->back();\n }\n\n }", "protected function _construct()\n {\n $this->_init(\n \\Harriswebworks\\Sizing\\Model\\Size::class,\n \\Harriswebworks\\Sizing\\Model\\ResourceModel\\Size::class\n );\n $this->_map['fields']['store_id'] = 'store_table.store_id';\n $this->_map['fields']['size_id'] = 'main_table.size_id';\n //phpcs: enable\n }", "public function __construct($type, $id = null, $url = null);", "public function __construct($type, $message = null)\n\t{\n\t\tparent::__construct($message);\n\t\t$this->setType($type);\n\t}", "protected function _construct()\n {\n $this->_init(\\MagentoCoders\\CustomCatalog\\Model\\Product::class, Product::class);\n }", "public function _construct()\n {\n $this->_init('seller/seller', 'seller_id');\n }", "public function __construct()\n {\n $fullClassName = explode('\\\\', get_class($this));\n $this->type = (string)array_pop($fullClassName);\n }", "public function __construct($license, $driver, $model, $brand)\n {\n parent::__construct($license, $driver); //metodo para traer de car las dos variables \n $this->brand = $brand;\n $this->model = $model;\n }", "public function __construct() {\n parent::__construct();\n $this->setOdataType('#microsoft.graph.subjectRightsRequestEnumeratedSiteLocation');\n }", "public function __construct()\n {\n if (10 == func_num_args()) {\n $this->productTypeUuid = func_get_arg(0);\n $this->customer = func_get_arg(1);\n $this->adults = func_get_arg(2);\n $this->children = func_get_arg(3);\n $this->seniors = func_get_arg(4);\n $this->arrivalDate = func_get_arg(5);\n $this->partnerReference = func_get_arg(6);\n $this->options = func_get_arg(7);\n $this->message = func_get_arg(8);\n $this->timeSlotUuid = func_get_arg(9);\n }\n }", "public function __construct(\n int $id,\n string $name,\n string $type,\n int $vp,\n object $orders,\n string $description = '',\n object $upsells = null\n ) {\n parent::__construct( $id, $name );\n $this->type = $type;\n $this->vp = $vp;\n $this->orders = $orders;\n $this->description = $description;\n $this->upsells = $upsells;\n }", "public function __construct($htCatNum,$htDescrip,$nQty,$nPrice,$nShItem,$nShPkg) {\n\t$this->htCatNum = $htCatNum;\n\t$this->htDescrip = $htDescrip;\n\t$this->nQty = $nQty;\n\t$this->nPrice = $nPrice;\n\t$this->nShItem = $nShItem;\n\t$this->nShPkg = $nShPkg;\n }", "public function __construct($brandname, $modelNumber, $price, $weight, $processorType, $ramSize, $hdSize, $noCPU){\n\t\tparent::__construct($brandname, $modelNumber, $price, $weight);\n\t\t$this->processorType = $processorType;\n\t\t$this->ramSize = $ramSize;\n\t\t$this->hdSize = $hdSize;\n\t\t$this->noCPU = $noCPU;\n\t}", "public function __construct() {\r\n\t\tparent::__construct(\r\n\t \t\t'amzrp_widget', // Base ID\r\n\t\t\t'Amazon Related Products', // Name\r\n\t\t\tarray( 'description' => __( 'Amazon Related Products Widget based on your keywords') ) // Args\r\n\t\t);\r\n\t}", "function __construct($TableName = 'item_type') {\r\n $this->idItem_Type = new DB_Field('idItem_Type', 0, new DbIntSanitizer(), TRUE, TRUE);\r\n $this->Category_Type = new DB_Field('Category_Type', 0, new DbIntSanitizer(), TRUE, TRUE);\r\n $this->Type_Description = new DB_Field('Type_Description', '', new DbStrSanitizer(100), TRUE, TRUE);\r\n $this->Order_Line_Type_Id = new DB_Field('Order_Line_Type_Id', 0, new DbIntSanitizer(), TRUE, TRUE);\r\n\r\n parent::__construct($TableName);\r\n }", "function __construct(Supplier $supplier) {\n\t\t$this->supplier = $supplier;\n\t}", "public function __construct($_sKU = NULL,$_startPrice = NULL,$_quantity = NULL,$_variationSpecifics = NULL,$_quantitySold = NULL,$_sellingStatus = NULL,$_discountPriceInfo = NULL,$_any = NULL)\r\n\t{\r\n\t\tparent::__construct(array('SKU'=>$_sKU,'StartPrice'=>$_startPrice,'Quantity'=>$_quantity,'VariationSpecifics'=>($_variationSpecifics instanceof EbayShoppingStructNameValueListArrayType)?$_variationSpecifics:new EbayShoppingStructNameValueListArrayType($_variationSpecifics),'QuantitySold'=>$_quantitySold,'SellingStatus'=>$_sellingStatus,'DiscountPriceInfo'=>$_discountPriceInfo,'any'=>$_any));\r\n\t}", "public function __construct()\n\t{\n\t\t$this->srs = Supplier::srs();\n\n\t\tparent::__construct();\n\t}", "public function __construct($resource_type, $resource_id, $actor_id)\n {\n $this->resource_type = $resource_type;\n $this->resource_id = $resource_id;\n $this->actor_id = $actor_id;\n }", "public function __construct() {\n parent::__construct();\n $this->setOdataType('#microsoft.graph.itemPhone');\n }", "public function __construct(){\n\t\t$this->addType('year', 'int');\n\t\t$this->addType('coverFileId', 'int');\n\t}", "function __construct(){\n parent::__construct();\n $this->set_primitive_type('string');\n $this->set_core(true);\n $this->set_related_mapped_prop('title');\n $this->set_component('tainacan-text');\n $this->set_name( __('Core Description', 'tainacan') );\n $this->set_description( __('The \"Core Title\" is a compulsory metadata automatically created for all collections by default. It is the main metadatum of the item and where the basic research tools will do their searches.', 'tainacan') );\n }", "function __construct($title,$prodName,$price, $appropriateAges){\n\t\t// you become responsible for the parent constructor as well\n\t\tparent::__construct($title, $prodName,$price); // puts these defaults into the parent constructor\n\t\t$this->appropriateAges=$appropriateAges; // sets the child property\n\t\t}", "public function __construct()\n {\n $this->city = new City;\n $this->country = new Country;\n $this->event = new Event;\n $this->experience = new Experience;\n $this->place = new Place;\n $this->type = new Type;\n $this->subcategory = new Subcategory;\n }", "public function __construct($_oprL = null,$_oprType = null,$_label = null,$_name = null,$_oper = null,$_debit = null,$_credit = null)\n {\n parent::__construct(array('oprL'=>$_oprL,'oprType'=>$_oprType,'Label'=>$_label,'Name'=>$_name,'oper'=>$_oper,'Debit'=>$_debit,'Credit'=>$_credit), false);\n }", "public function __construct()\n {\n $this->movieCredits = new CreditsCollection\\MovieCredits();\n $this->tvCredits = new CreditsCollection\\TvCredits();\n $this->combinedCredits = new CreditsCollection\\CombinedCredits();\n $this->images = new Images();\n $this->changes = new GenericCollection();\n $this->externalIds = new ExternalIds();\n $this->knownFor = new GenericCollection();\n }", "function __construct() {\n\t\tparent::__construct(\n\t\t\t'services_widget', // Base ID\n\t\t\t__('Services Widget', 'graff'), // Name\n\t\t\tarray( 'description' => __( 'All Services', 'graff' ), ) // Args\n\t\t);\n\t}", "public function __construct(StockPrice $stockPrice)\n {\n //\n $this->stockPrice = $stockPrice;\n\n }", "public function __construct() {\n parent::__construct();\n $this->setOdataType('#microsoft.graph.stsPolicy');\n }", "public function __construct()\n {\n $this->_serviceResource = 'Offers/';\n }", "protected abstract function __construct();", "function __construct() {\n\t\tparent::__construct(\n\t\t\t'askthelawyer_widget', // Base ID\n\t\t\t__('Ask the lawyer', 'piananotizie'), // Name\n\t\t\tarray( 'description' => __( 'Show widget ask the lawyer', 'piananotizie' ), ) // Args\n\t\t);\n\t}", "public function __construct($value = null, \\StructType\\OfferGridGroupType $group = null, \\StructType\\ReducedOfferType $offer = null)\n {\n $this\n ->setValue($value)\n ->setGroup($group)\n ->setOffer($offer);\n }", "public function __construct() {\n\t\tparent::__construct(\n\t \t\t'star_review_widget', // Base ID\n\t\t\t'Star Review Widget', // Name\n\t\t\tarray( 'description' => __( 'Star Review Widget description', 'wrb' ), ) // Args\n\t\t);\n\t}", "public function __construct($data,$type=false)\n {\n $this->data=$data;\n $this->type=$type;\n }", "public function __construct($client, $seance, $survey, $company_name)\n {\n $this->client = $client;\n $this->seance = $seance;\n $this->survey = $survey;\n $this->company_name = ! empty($company_name) ? $company_name : '';\n }", "public function __construct($name,$type=self::PLAYER) {\n\t\t\t$this->_name = $name;\n\t\t\t$this->_type = $type;\n\t\t}", "function __construct()\n\t{\n\t\tparent::__construct(\n\t\t\t'jetty_widget_promo',\n\t\t\t__('Jetty Promo', 'jetty'),\n\t\t\tarray( 'description' => __( 'This widget for display promo section on certain page', 'jetty' ), )\n\t\t);\n\t}", "public function __construct($type, $pref, $uri)\n {\n $this->_type = $type;\n $this->_preferred = $pref;\n $this->_imUri = $uri;\n }", "public function __construct($value = null, int $type = VT_EMPTY, $codepage = CP_ACP) {}", "protected function _construct()\n\t{\n\t\t$this->setUsedModuleName('Gri_CatalogCustom');\n\t}", "public function __construct() {\n\t\tparent::__construct();\n\n\t\t$this->category = _x( 'Multi Fields', 'xprofile field type category', 'buddypress' );\n\t\t$this->name = _x( 'Multi Select Box', 'xprofile field type', 'buddypress' );\n\n\t\t$this->supports_multiple_defaults = true;\n\t\t$this->accepts_null_value = true;\n\t\t$this->supports_options = true;\n\n\t\t$this->set_format( '/^.+$/', 'replace' );\n\t\tdo_action( 'bp_xprofile_field_type_multiselectbox', $this );\n\t}", "public function __construct(TDProject_Core_Interfaces_Block_Widget_Form $form, $blockName, $blockTitle) {\n // call the parent constructor\n parent::__construct($form, $blockName, $blockTitle);\n \t// set the CSS class\n \t$this->_setCssClass('type-text');\n \t// set standard width to 300px\n \t$this->setWidth(300);\n // set the template name\n $this->_setTemplate('www/design/core/templates/widget/element/select.phtml');\n // initialize the Collection for the options\n $this->_options = new TechDivision_Collections_ArrayList();\n }", "public function __construct($sp_id) {\n $this->providerID = $sp_id;\n }", "public function __construct ()\n {\n parent::__construct(NULL);\n $this->name_tuples = [];\n // use name attributes must conform to: AS 5017-2006: Health Care Client Name Usage\n $this->acceptable_use_attributes = UseAttributeInterface::NameValues;\n }", "public function __construct()\n {\n parent::__construct(new WalletType);\n }", "protected function _construct()\n {\n $this->_init(\\AddictedToMagento\\DynamicForms\\Model\\ResourceModel\\Form::class);\n }", "function __construct() {\n\t\tparent::__construct(\n\t\t\t'Aweber_Newsletter_Subscribtion_Widget', // Base ID\n\t\t\t__( 'Aweber Newsletter Subscribtion Widget', 'rfsl_domain' ), // Name\n\t\t\tarray( 'description' => __( 'A widget that gererates form for your aweber newsletter subscription ', 'rfsl_domain' ), ) // Args\n\t\t);\n\t}", "function __construct() {\n\t\tparent::__construct(\n\t\t\t'broker_widget', // Base ID\n\t\t\t__( 'Broker Options', 'text_domain' ), // Name\n\t\t\tarray( 'description' => __( 'Display Broker Widget', 'text_domain' ), ) // Args\n\t\t);\n\t}", "function __construct() {\n parent::__construct();\n\n $this->_converter = new \\System\\Data\\Converter();\n }", "public function __construct()\n {\n $lang = getLang();\n $sqlSub = \",mpt.name_$lang as parcel_type_name ,mst.name_$lang as supplies_type_name\";\n $this->sqlSub = $sqlSub ;\n }", "public function __construct(\n private string $address,\n private string $type\n ){\n // \n }", "function __construct() \n\t{\n\t\tparent::__construct( 'rt_shop_rating', 'id', 'shoprat' );\n\t}", "public function __construct($_originalRetailPrice = NULL,$_minimumAdvertisedPrice = NULL,$_minimumAdvertisedPriceExposure = NULL,$_pricingTreatment = NULL,$_soldOneBay = false,$_soldOffeBay = false,$_any = NULL)\r\n\t{\r\n\t\tparent::__construct(array('OriginalRetailPrice'=>$_originalRetailPrice,'MinimumAdvertisedPrice'=>$_minimumAdvertisedPrice,'MinimumAdvertisedPriceExposure'=>$_minimumAdvertisedPriceExposure,'PricingTreatment'=>$_pricingTreatment,'SoldOneBay'=>$_soldOneBay,'SoldOffeBay'=>$_soldOffeBay,'any'=>$_any));\r\n\t}" ]
[ "0.6953972", "0.6837813", "0.65894425", "0.6343466", "0.6319581", "0.62328494", "0.6187161", "0.6178737", "0.61759126", "0.6062386", "0.6061911", "0.60495937", "0.60423416", "0.60393405", "0.60345054", "0.60339177", "0.6031263", "0.5974754", "0.5973947", "0.59738517", "0.5973849", "0.5933081", "0.59288627", "0.59001386", "0.5893676", "0.5890295", "0.58804333", "0.5857797", "0.58388674", "0.5832926", "0.5829232", "0.577803", "0.57666975", "0.5763043", "0.575737", "0.57546407", "0.5747989", "0.57360786", "0.5711575", "0.56967014", "0.56945926", "0.56853724", "0.5684585", "0.56784934", "0.5676662", "0.5670721", "0.56684124", "0.5666981", "0.5647525", "0.56279767", "0.5625809", "0.5624421", "0.56225026", "0.56029", "0.56002927", "0.5593556", "0.55886006", "0.5579114", "0.55746895", "0.5571909", "0.55680555", "0.5568055", "0.5566477", "0.5564894", "0.5539646", "0.5539138", "0.5537999", "0.5528794", "0.5528404", "0.55266225", "0.55179024", "0.55163074", "0.550911", "0.550564", "0.5505014", "0.5501973", "0.54960936", "0.54826623", "0.54738134", "0.5473479", "0.54714084", "0.5470666", "0.54702884", "0.54611605", "0.5460979", "0.5455492", "0.5454777", "0.5451997", "0.54519266", "0.5449413", "0.5444644", "0.544184", "0.54400045", "0.54383796", "0.5438265", "0.543445", "0.5431048", "0.54309374", "0.5430635", "0.5430113", "0.54278094" ]
0.0
-1
Method called when an object has been exported with var_export() functions It allows to return an object instantiated with the values
public static function __set_state(array $array) { return parent::__set_state($array); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function ExportObject() {\n // Init object\n $plugin = new stdClass();\n // Set values\n $plugin->Name = $this->Name;\n $plugin->Version = $this->Version;\n $plugin->Author = $this->Author;\n $plugin->About = $this->About;\n $plugin->Root = $this->Root;\n $plugin->Identifier = $this->Identifier;\n \n // Return result\n return $plugin;\n }", "protected function constructExportObject()\n\t{\n\t\t//default export is \"all public fields\"\n\t\treturn (object) Arrays::getPublicPropertiesOfObject($this);\n\t}", "function from_export($value) {\n return $value;\n }", "public function export(): mixed;", "public function ExportObject() {\n // Init object\n $col = new stdClass();\n \n // Set values\n $col->id = $this->Id;\n $col->type = $this->Type;\n $col->label = $this->Label;\n $col->p = $this->P;\n \n // Return values\n return $col;\n }", "public function exportData() {\n\t\treturn $this->constructExportObject();\n\t}", "public function toObject();", "function ctools_export_new_object($table, $set_defaults = TRUE) {\r\n $schema = ctools_export_get_schema($table);\r\n $export = $schema['export'];\r\n\r\n $object = new $export['object'];\r\n foreach ($schema['fields'] as $field => $info) {\r\n if (isset($info['object default'])) {\r\n $object->$field = $info['object default'];\r\n }\r\n else if (isset($info['default'])) {\r\n $object->$field = $info['default'];\r\n }\r\n else {\r\n $object->$field = NULL;\r\n }\r\n }\r\n\r\n if ($set_defaults) {\r\n // Set some defaults so this data always exists.\r\n // We don't set the export_type property here, as this object is not saved\r\n // yet. We do give it NULL so we don't generate notices trying to read it.\r\n $object->export_type = NULL;\r\n $object->{$export['export type string']} = t('Local');\r\n }\r\n return $object;\r\n}", "public function export();", "public function export();", "public function export();", "public function export();", "public function export();", "public function createExport();", "public function newInstance(): object;", "public static function createFromGlobals();", "public function export (){\n\n }", "function &object(object $value, string $namespace = 'default'): object\n{\n $var = new Variable\\ObjectVariable($value);\n Repository::add($var, $namespace);\n return $var->getValue();\n}", "public function getObj();", "public static function toObject(){\r\n $args = func_get_args();\r\n \r\n if(count($args) >=2){\r\n $className = '\\\\'.str_replace('.', '\\\\', $args[0]);\r\n $refClass = new \\ReflectionClass($className);\r\n $toObjInstance = $refClass->newInstance();\r\n\r\n unset($args[0]);\r\n \r\n foreach($args as $arg){\r\n \r\n if(is_object($arg)){\r\n $arg = Obj::getProperties($arg);\r\n }\r\n \r\n if(is_array($arg)){\r\n foreach($arg as $propertyName=>$propertyValue){\r\n if($refClass->hasProperty($propertyName)){\r\n $property = $refClass->getProperty($propertyName);\r\n $property->setAccessible(true);\r\n $property->setValue($toObjInstance, $propertyValue);\r\n }\r\n }\r\n }\r\n }\r\n return $toObjInstance;\r\n }\r\n }", "public function export()\n {\n }", "function &stdClass(stdClass $value, string $namespace = 'default'): stdClass\n{\n $var = new Variable\\StdClassVariable($value);\n Repository::add($var, $namespace);\n return $var->getValue();\n}", "public function getExportableValues() {\n\t\telgg_deprecated_notice(__METHOD__ . ' has been deprecated by toObject()', 1.9);\n\t\treturn array(\n\t\t\t'id',\n\t\t\t'entity_guid',\n\t\t\t'name',\n\t\t\t'value',\n\t\t\t'value_type',\n\t\t\t'owner_guid',\n\t\t\t'type',\n\t\t);\n\t}", "public function ExportObject() {\n // Init object\n $overviewChart = new stdClass();\n \n // Set values\n $overviewChart->Types = $this->Types;\n $overviewChart->Chart = $this->Chart->ExportObject();\n \n //return result\n return $overviewChart;\n }", "public function export()\n {\n \n }", "public function newInstance(): object\n {\n return $this->instantiator->instantiate($this->name);\n }", "public function getter () {\n return (object)[\n get_plugin_name => $this->plugin_name,\n get_plugin_version => $this->plugin_version,\n get_translation_slug => $this->translation_slug,\n get_admin_page_slug => $this->admin_page_slug,\n get_api_namespace => $this->api_namespace,\n get_options_name => $this->options_name\n ];\n }", "public function getObject() {}", "public function getObject() {}", "public function export()\n {\n //\n }", "function _instantiateExportDeployment($context) {\n\t\t$exportDeploymentClassName = $this->getExportDeploymentClassName();\n\t\t$this->import($exportDeploymentClassName);\n\t\t$exportDeployment = new $exportDeploymentClassName($context, $this);\n\t\treturn $exportDeployment;\n\t}", "function get_obj()\n {\n $object = new ApiRest;\n return $object;\n }", "public function newInstance();", "public function newInstance();", "public function __CONSTRUCT(){\n\t}", "public function getInstance(): object;", "public function exportedVars(): iterable;", "public static function fromGlobals() {}", "public function ExportObject() {\n // Init object\n $submission = new stdClass();\n \n // Set values\n $submission->Id = $this->Id;\n $submission->DateTime = $this->DateTime;\n $submission->GitHash = $this->GitHash;\n $submission->Categories = array();\n \n // Export each category\n foreach ($this->Categories as $category) {\n $submission->Categories[] = $category->ExportObject();\n }\n \n // return result\n return $submission;\n }", "public function getInstance(): object\n {\n }", "function ctools_get_default_object($table, $name) {\r\n $schema = ctools_export_get_schema($table);\r\n $export = $schema['export'];\r\n\r\n if (!$export['default hook']) {\r\n return;\r\n }\r\n\r\n // Try to load individually from cache if this cache is enabled.\r\n if (!empty($export['cache defaults'])) {\r\n $defaults = _ctools_export_get_some_defaults($table, $export, array($name));\r\n }\r\n else {\r\n $defaults = _ctools_export_get_defaults($table, $export);\r\n }\r\n\r\n $status = variable_get($export['status'], array());\r\n\r\n if (!isset($defaults[$name])) {\r\n return;\r\n }\r\n\r\n $object = $defaults[$name];\r\n\r\n // Determine if default object is enabled or disabled.\r\n if (isset($status[$object->{$export['key']}])) {\r\n $object->disabled = $status[$object->{$export['key']}];\r\n }\r\n\r\n $object->{$export['export type string']} = t('Default');\r\n $object->export_type = EXPORT_IN_CODE;\r\n $object->in_code_only = TRUE;\r\n\r\n return $object;\r\n}", "public function toStdClass() {\n $stdClass = new stdClass();\n $stdClass->number = $this->_number;\n $stdClass->internal = $this->_internal;\n return $stdClass;\n }", "public function getObject(): object;", "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 dataProviderExport()\n {\n // Regular :\n $data = [\n [\n 'test string',\n var_export('test string', true),\n ],\n [\n 75,\n var_export(75, true),\n ],\n [\n 7.5,\n var_export(7.5, true),\n ],\n [\n null,\n 'null',\n ],\n [\n true,\n 'true',\n ],\n [\n false,\n 'false',\n ],\n [\n [],\n '[]',\n ],\n ];\n // Arrays :\n $var = [\n 'key1' => 'value1',\n 'key2' => 'value2',\n ];\n $expectedResult = <<<'RESULT'\n[\n 'key1' => 'value1',\n 'key2' => 'value2',\n]\nRESULT;\n $data[] = [$var, $expectedResult];\n $var = [\n 'value1',\n 'value2',\n ];\n $expectedResult = <<<'RESULT'\n[\n 'value1',\n 'value2',\n]\nRESULT;\n $data[] = [$var, $expectedResult];\n $var = [\n 'key1' => [\n 'subkey1' => 'value2',\n ],\n 'key2' => [\n 'subkey2' => 'value3',\n ],\n ];\n $expectedResult = <<<'RESULT'\n[\n 'key1' => [\n 'subkey1' => 'value2',\n ],\n 'key2' => [\n 'subkey2' => 'value3',\n ],\n]\nRESULT;\n $data[] = [$var, $expectedResult];\n // Objects :\n $var = new \\StdClass();\n $var->testField = 'Test Value';\n $expectedResult = \"unserialize('\" . serialize($var) . \"')\";\n $data[] = [$var, $expectedResult];\n $var = function () {return 2;};\n $expectedResult = 'function () {return 2;}';\n $data[] = [$var, $expectedResult];\n return $data;\n }", "public static function export()\n {\n return null;\n }", "function create()\n\t{\n\t\t$names = $this->_fields;\n\t\t$object = new StdClass;\n\t\tforeach ($names as $name)\n\t\t\t$object->$name = \"\";\n\t\treturn $object;\n\t}", "public function construct()\n {\n return $this->object;\n }", "public function metaExport($object = false);", "public function vars()\n {\n \n return new ArrayWrapper(get_object_vars($this->object));\n \n }", "public function getValuesObject()\n {\n $obj = new \\stdClass;\n\n foreach ( $this->keyValues as $key => $value )\n {\n $obj->$key = $value;\n }\n\n return $obj;\n }", "public function getObject();", "public function getObject();", "function newDataObject() {\n\t\t$ofrPlugin =& PluginRegistry::getPlugin('generic', $this->parentPluginName);\n\t\t$ofrPlugin->import('classes.ObjectForReviewPerson');\n\t\treturn new ObjectForReviewPerson();\n\t}", "public function __construct(VariableExportInterface $variableExport)\n {\n $this->serialized = $variableExport->toSerialize();\n }", "public function as_object($class = TRUE, $arguments = array());", "function var_export($expression, $return = false)\n{\n}", "function getObject();", "function getObject();", "abstract public function object();", "public function __construct()\r\n {\r\n $this->_internalObject = new stdClass();\r\n\t\t$a=serialize($this->_internalObject);\r\n\t\t\"echo $a<br>\";\r\n }", "abstract protected function createObject();", "function &getInstance($module_srl)\n\t{\n\t\treturn new ExtraVar($module_srl);\n\t}", "abstract function exportData();", "function createProduct($name,$price,$qty,$id):stdClass\n{\n$product=new stdClass();\n$product->name=$name;\n$product->price=$price;\n$product->quantity= $qty;\n$product->id=$id;\n\nreturn $product;\n}", "abstract protected function exportFunctions();", "public static function factory()\n {\n $class = get_called_class();\n $object = new $class();\n foreach (static::getDefaults() as $field => $value) {\n $object->{$field} = $value;\n }\n return $object;\n }", "public function &__invoke()\r\n\t{\r\n\t\t$result = new stdClass();\r\n\t\tAdhoc::eachTrap('Registry',\r\n\t\t\tfunction ($trap) use (&$result)\r\n\t\t\t{\r\n\t\t\t\t$data =& $trap->GetList();\r\n\t\t\t\tforeach ($data as $k=>$v)\r\n\t\t\t\t{\r\n\t\t\t\t\tif (!isset($result->$k) and isset($v))\r\n\t\t\t\t\t{\r\n\t\t\t\t\t\t$result->$k = $v;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t);\r\n\t\t\r\n\t\treturn $result;\r\n\t}", "public static function instantation($the_record){\n\n // can be used to retrieve a string with the name of the called class and static:: introduces its scope.\n $calling_class = get_called_class();\n\n $the_object = new $calling_class;\n\n\n // doing a loop to get all of the values in the object ]\n foreach($the_record as $key => $value) {\n\n if($the_object->has_the_key($key)){\n $the_object->$key = $value;\n \n }\n }\n\n return $the_object;\n }", "public static function get_object() {\n\t\treturn self::$object;\n\t}", "function adminer_object() {\r\n include_once \"./plugins/plugin.php\";\r\n \r\n // autoloader\r\n foreach (glob(\"plugins/*.php\") as $filename) {\r\n include_once \"./$filename\";\r\n }\r\n \r\n $plugins = array(\r\n // specify enabled plugins here\r\n // new AdminerDumpXml,\r\n // new AdminerTinymce,\r\n // new AdminerFileUpload(\"data/\"),\r\n // new AdminerSlugify,\r\n // new AdminerTranslation,\r\n // new AdminerForeignSystem,\r\n // new AdminerLoginPasswordLess(password_hash(\"\", PASSWORD_DEFAULT)),\r\n );\r\n \r\n /* It is possible to combine customization and plugins:\r\n class AdminerCustomization extends AdminerPlugin {\r\n }\r\n return new AdminerCustomization($plugins);\r\n */\r\n class AdminerCustomization extends AdminerPlugin {\r\n function login($login, $password) {\r\n // validate user submitted credentials\r\n return true;\r\n }\r\n }\r\n return new AdminerCustomization($plugins);\r\n \r\n // return new AdminerPlugin($plugins);\r\n}", "public function ExportItem() {\n // Init object\n $submission = new stdClass();\n \n // Set values\n $submission->Id = $this->Id;\n $submission->DateTime = $this->DateTime;\n $submission->ImportDateTime = $this->ImportDateTime;\n $submission->User = $this->User;\n $submission->Good = $this->Good;\n $submission->Bad = $this->Bad;\n $submission->Strange = $this->Strange;\n $submission->GitHash = $this->GitHash;\n $submission->SequenceNumber = $this->SequenceNumber;\n \n // Return result\n return $submission;\n }", "private static function _instantiateThisObject() {\r\n $className = get_called_class();\r\n return new $className();\r\n }", "function instance($obj) {\n\tif (is_string($obj)) {\n\t\t$obj = new $obj;\n\t}\n\treturn $obj;\n}", "function ctools_var_export($var, $prefix = '') {\r\n if (is_array($var)) {\r\n if (empty($var)) {\r\n $output = 'array()';\r\n }\r\n else {\r\n $output = \"array(\\n\";\r\n foreach ($var as $key => $value) {\r\n $output .= $prefix . \" \" . ctools_var_export($key) . \" => \" . ctools_var_export($value, $prefix . ' ') . \",\\n\";\r\n }\r\n $output .= $prefix . ')';\r\n }\r\n }\r\n else if (is_object($var) && get_class($var) === 'stdClass') {\r\n // var_export() will export stdClass objects using an undefined\r\n // magic method __set_state() leaving the export broken. This\r\n // workaround avoids this by casting the object as an array for\r\n // export and casting it back to an object when evaluated.\r\n $output = '(object) ' . ctools_var_export((array) $var, $prefix);\r\n }\r\n else if (is_bool($var)) {\r\n $output = $var ? 'TRUE' : 'FALSE';\r\n }\r\n else {\r\n $output = var_export($var, TRUE);\r\n }\r\n\r\n return $output;\r\n}", "public function getOutputObject()\n {\n $baseObject = parent::getOutputObject();\n $baseObject->name = $this->getName();\n\n return $baseObject;\n }", "public function init_objects() {\n $this->controller_oai = new \\Tainacan\\OAIPMHExpose\\OAIPMH_Expose();\n $this->list_sets = new \\Tainacan\\OAIPMHExpose\\OAIPMH_List_Sets();\n $this->list_metadata_formats = new \\Tainacan\\OAIPMHExpose\\OAIPMH_List_Metadata_Formats();\n $this->list_records = new \\Tainacan\\OAIPMHExpose\\OAIPMH_List_Records();\n $this->get_record = new \\Tainacan\\OAIPMHExpose\\OAIPMH_Get_Record();\n $this->identify = new \\Tainacan\\OAIPMHExpose\\OAIPMH_Identify();\n $this->identifiers = new \\Tainacan\\OAIPMHExpose\\OAIPMH_List_Identifiers();\n }", "public function _construct(){\n\t\treturn $this->data;\n\t}", "public function _construct(){\n\t\treturn $this->data;\n\t}", "public function regularNew() {}", "public function newInstance()\n {\n return $this->newInstanceArgs(func_get_args());\n }", "function data2Object($data) { \n\t\t\t$class_object = new getData($data); \n\t\t\treturn $class_object; \n\t\t}", "function _construct(){ }", "function ctools_export_object($table, $object, $indent = '', $identifier = NULL, $additions = array(), $additions2 = array()) {\r\n $schema = ctools_export_get_schema($table);\r\n if (!isset($identifier)) {\r\n $identifier = $schema['export']['identifier'];\r\n }\r\n\r\n $output = $indent . '$' . $identifier . ' = new ' . get_class($object) . \"();\\n\";\r\n\r\n if ($schema['export']['can disable']) {\r\n $output .= $indent . '$' . $identifier . '->disabled = FALSE; /* Edit this to true to make a default ' . $identifier . ' disabled initially */' . \"\\n\";\r\n }\r\n if (!empty($schema['export']['api']['current_version'])) {\r\n $output .= $indent . '$' . $identifier . '->api_version = ' . $schema['export']['api']['current_version'] . \";\\n\";\r\n }\r\n\r\n // Put top additions here:\r\n foreach ($additions as $field => $value) {\r\n $output .= $indent . '$' . $identifier . '->' . $field . ' = ' . ctools_var_export($value, $indent) . \";\\n\";\r\n }\r\n\r\n $fields = $schema['fields'];\r\n if (!empty($schema['join'])) {\r\n foreach ($schema['join'] as $join) {\r\n if (!empty($join['load'])) {\r\n foreach ($join['load'] as $join_field) {\r\n $fields[$join_field] = $join['fields'][$join_field];\r\n }\r\n }\r\n }\r\n }\r\n\r\n // Go through our schema and joined tables and build correlations.\r\n foreach ($fields as $field => $info) {\r\n if (!empty($info['no export'])) {\r\n continue;\r\n }\r\n if (!isset($object->$field)) {\r\n if (isset($info['default'])) {\r\n $object->$field = $info['default'];\r\n }\r\n else {\r\n $object->$field = '';\r\n }\r\n }\r\n\r\n // Note: This is the *field* export callback, not the table one!\r\n if (!empty($info['export callback']) && function_exists($info['export callback'])) {\r\n $output .= $indent . '$' . $identifier . '->' . $field . ' = ' . $info['export callback']($object, $field, $object->$field, $indent) . \";\\n\";\r\n }\r\n else {\r\n $value = $object->$field;\r\n if ($info['type'] == 'int') {\r\n if (isset($info['size']) && $info['size'] == 'tiny') {\r\n $info['boolean'] = (!isset($info['boolean'])) ? $schema['export']['boolean'] : $info['boolean'];\r\n $value = ($info['boolean']) ? (bool) $value : (int) $value;\r\n }\r\n else {\r\n $value = (int) $value;\r\n }\r\n }\r\n\r\n $output .= $indent . '$' . $identifier . '->' . $field . ' = ' . ctools_var_export($value, $indent) . \";\\n\";\r\n }\r\n }\r\n\r\n // And bottom additions here\r\n foreach ($additions2 as $field => $value) {\r\n $output .= $indent . '$' . $identifier . '->' . $field . ' = ' . ctools_var_export($value, $indent) . \";\\n\";\r\n }\r\n\r\n return $output;\r\n}", "public function createValidObject() : object {\n\t\treturn (object) [\"tweetContent\" => bin2hex(random_bytes(12))];\n\t}", "public function _init_obj()\n {\n // dummy\n }", "protected function make_object( \\stdClass $data ) {\n\t\treturn new Purchase( $data );\n\t}", "public function as_object()\n {\n $this->return_as = 'object';\n return $this;\n }", "static public function fromObj($anObj) {\n\t\t$theClassName = get_called_class();\n\t\t$o = new $theClassName();\n\t\treturn $o->setDataFrom($anObj);\n\t}", "function adminer_object() {\n\t\tinclude_once \"plugins/plugin.php\";\n\t\t// autoloader\n\t\tforeach (glob(\"plugins/*.php\") as $filename) {\n\t\t\tinclude_once $filename;\n\t\t}\n\t\t$plugins = array(\n\t\t\t// specify enabled plugins here\n\t\t\tnew AdminerDatabaseHide(array('information_schema', 'mysql', 'performance_schema')),\n\t\t\t//new AdminerDumpJson,\n\t\t\t//new AdminerDumpBz2,\n\t\t\t//new AdminerDumpZip,\n\t\t\t//new AdminerDumpXml,\n\t\t\t//new AdminerDumpAlter,\n\t\t\t//~ new AdminerSqlLog(\"past-\" . rtrim(`git describe --tags --abbrev=0`) . \".sql\"),\n\t\t\t//new AdminerFileUpload(\"\"),\n\t\t\t//new AdminerJsonColumn,\n\t\t\t//new AdminerSlugify,\n\t\t\t//new AdminerTranslation,\n\t\t\t//new AdminerForeignSystem,\n\t\t\t//new AdminerEnumOption,\n\t\t\t//new AdminerTablesFilter,\n\t\t\t//new AdminerEditForeign,\n\t\t);\n\n\t\treturn new AdminerPlugin($plugins);\n\t}", "public function newCObj() {}", "private function PREPARE_OBJECT_VARIABLE_METHOD()\r\r {\r\r if($this->_type === 'POST')\r\r {\r\r foreach($this->_fields as $key=>$field)\r\r {\r\r $this->_object[$key]['VALUE'] = isset($_POST[$key])?$_POST[$key]:false;\r\r } \r\r } \r\r else if($this->_type === 'GET')\r\r {\r\r foreach($this->_fields as $key=>$field)\r\r {\r\r $this->_object[$key]['VALUE'] = isset($_GET[$key])?$_GET[$key]:false;\r\r } \r\r } \r\r }", "public function toStdClass() {\n $stdClass = new stdClass();\n $stdClass->amountInsuranceBase = $this->_amountInsuranceBase;\n $stdClass->fragile = $this->_fragile;\n $stdClass->parcelsCount = $this->_parcelsCount;\n $stdClass->serviceTypeId = $this->_serviceTypeId;\n return $stdClass;\n }", "public function toStdClass() {\n $stdClass = new stdClass();\n $stdClass->billOfLading = $this->_billOfLading;\n $stdClass->secondaryPickingType = $this->_secondaryPickingType;\n return $stdClass;\n }", "abstract public function prepare_new_object(array $args);", "protected function getRealScriptUserObj() {}", "public function export(bool $private = FALSE, bool $meta = FALSE) {\n\t\t$keys = [];\n\t\t$ret = [];\n\n\t\tif ($private) {\n\t\t\t$keys = static::$PRIVATE;\n\t\t} else {\n\t\t\t$keys = static::$PUBLIC;\n\t\t}\n\n\t\tif (!empty(array_intersect(EXP_RESERVED, $keys))) {\n\t\t\tthrow new ExportableException(\n\t\t\t\t\"Reserved key '\".EXP_CLASSNAME.\"' used in object.\"\n\t\t\t);\n\t\t}\n\n\t\tif ($meta) { // Add metadata.\n\t\t\t$ret[EXP_CLASSNAME] = get_class($this);\n\t\t\t$ret[EXP_VISIBILITY] = $private ? 'private' : 'public';\n\t\t}\n\n\t\tforeach ($keys as $k) {\n\t\t\t$current = $this->__exportable_get($k);\n\t\t\tswitch (gettype($current)) {\n\t\t\t\tcase 'object':\n\t\t\t\t\t$ret[$k] = $this->exp_obj(\n\t\t\t\t\t\t$current, $private, $meta\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\t\t\t\tcase 'array':\n\t\t\t\t\t$ret[$k] = $this->exp_array(\n\t\t\t\t\t\t$current, $private, $meta\n\t\t\t\t\t);\n\t\t\t\t\tbreak;\n\t\t\t\tdefault:\n\t\t\t\t\t$ret[$k] = $current;\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t\treturn $ret;\n\t}", "public static function & GetInstance ();", "public function getInstance(): mixed;", "public function convertToUserIntObject() {}", "function FetchObj() {}" ]
[ "0.6951056", "0.69235533", "0.6576406", "0.6377145", "0.61438453", "0.6123597", "0.60555947", "0.60385406", "0.5922576", "0.5922576", "0.5922576", "0.5922576", "0.5922576", "0.5859328", "0.58386916", "0.58126146", "0.5800945", "0.5715804", "0.571534", "0.5712997", "0.5688761", "0.5658427", "0.5640244", "0.56017965", "0.5525057", "0.5512275", "0.54624516", "0.54065686", "0.54065686", "0.5402593", "0.53759634", "0.5372155", "0.5371501", "0.5371501", "0.53698903", "0.5342519", "0.5334929", "0.5315758", "0.5307627", "0.5297458", "0.5262869", "0.5260146", "0.5248292", "0.5244241", "0.52275795", "0.51874787", "0.51795346", "0.5150348", "0.5141145", "0.513255", "0.5131906", "0.5117587", "0.5117587", "0.5117466", "0.5112706", "0.51077455", "0.50988156", "0.50935", "0.50935", "0.5078365", "0.50393796", "0.50392556", "0.5032243", "0.500829", "0.500578", "0.50021815", "0.49989748", "0.4986421", "0.4985877", "0.49773422", "0.49751663", "0.49675283", "0.4957486", "0.49566287", "0.49518955", "0.49497175", "0.49412116", "0.49269983", "0.49269983", "0.4919096", "0.4918042", "0.49162993", "0.4907476", "0.49073106", "0.48962304", "0.48928276", "0.4889555", "0.48821777", "0.48817694", "0.4876133", "0.48756412", "0.48639464", "0.48624778", "0.48621023", "0.48483175", "0.4845858", "0.48404086", "0.48386553", "0.48385635", "0.48351642", "0.4834503" ]
0.0
-1
Method returning the class name
public function __toString() { return __CLASS__; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getClassName();", "public function getClassName();", "public function getClassName() ;", "public function getClassName() {}", "public function getClassName() {}", "public function getClassName() {}", "public function getClassName() {}", "public function getClassName()\n {\n return __CLASS__;;\n }", "private function get_class_name() {\n\t\t\treturn !is_null($this->class_name) ? $this->class_name : get_class($this);\n\t\t}", "public function getClassName() {\r\n\t\treturn($this->class_name);\r\n\t}", "public static function get_class_name() {\r\n\t\treturn __CLASS__;\r\n\t}", "public function getClassName() { return __CLASS__; }", "public static function getClassName() {\n\t\treturn get_called_class();\n\t}", "public function getClassName(): string\n {\n return $this->get(self::CLASS_NAME);\n }", "public static function getClassName()\n\t{\n\t\treturn get_called_class();\n\t}", "public static function getClassName()\n {\n return get_called_class();\n }", "public function getClassName()\n {\n return $this->class;\n }", "public function getClassName()\n {\n return $this->class;\n }", "public static function className() : string {\n return get_called_class();\n }", "public function getName()\n {\n return __CLASS__;\n }", "public function getName()\n\t{\n\t\treturn str_replace('\\\\', '_', __CLASS__);\n\t}", "public function getClassName()\n {\n return $this->class_name;\n }", "public function class_name() {\n\t\treturn strtolower(get_class($this));\n\t}", "public function getName(): string\n {\n return __CLASS__;\n }", "public static function getClassName() {\n return get_called_class();\n }", "public function getClassname(){\n\t\treturn $this->classname;\n\t}", "public function getClassname()\n\t{\n\t\treturn $this->classname;\n\t}", "public function getClassName()\n {\n return $this->_sClass;\n }", "public function get_just_class_name() {\n\n\t\t$full_path = $this->get_called_class();\n\n\t\treturn substr( strrchr( $full_path, '\\\\' ), 1 );\n\n\t}", "protected function getClassName(): string\n {\n return $this->className;\n }", "public static function getClassName() {\n return self::$className;\n }", "public function getClassName(): string;", "public function getClassName() : string;", "public function getName() {\r\n $parsed = Parser::parseClassName(get_class());\r\n return $parsed['className'];\r\n }", "public function getClassName() : string\n {\n return $this->className;\n }", "public function getClassName()\n {\n $fullClass = get_called_class();\n $exploded = explode('\\\\', $fullClass);\n\n return end($exploded);\n }", "public static function getClassName()\n {\n $classNameArray = explode('\\\\', get_called_class());\n\n return array_pop($classNameArray);\n }", "public function getClassName(): string\n {\n return $this->className;\n }", "public function getClassName(): string\n {\n return $this->className;\n }", "public function getClassName() {\t\t\n\t\treturn MemberHelper::getClassName($this->classNumber);\n\t}", "public function getName()\n\t{\n\t\treturn substr(__CLASS__, 7);\n\t}", "public function getName()\n\t{\n\t\treturn substr(__CLASS__, 7);\n\t}", "public function getClassName() {\r\n\t\treturn $this->strClassName;\r\n\t}", "public function getClassName() : string\n {\n\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public function getClassName()\n {\n return $this->className;\n }", "public static function staticGetClassName()\n {\n return __CLASS__;\n }", "public function getClassName() {\n return $this->className;\n }", "public function getClassName() {\n\t\treturn $this->className;\n\t}", "public function getClassName(): string\n {\n return $this->makeClassFromFilename($this->filename);\n }", "public function getClassName() {\n\t\treturn $this->_className;\n\t}", "public function getClassName() {\n return $this->className;\n }", "public function getClassName() {\n return $this->className;\n }", "public function getClassName ()\n {\n $className = explode('\\\\', get_class($this));\n\n return array_pop($className);\n }", "function getClassName()\n {\n // TODO: Implement getClassName() method.\n }", "public static function getClassName(){\n $parts = explode('\\\\', static::class);\n return end($parts);\n }", "function getClassName(){\n echo __CLASS__ . \"<br><br>\"; \n }", "public function name()\n {\n $name = get_class($this);\n\n return substr($name, strrpos($name, '\\\\') + 1);\n }", "public function class()\n {\n // @codingStandardsIgnoreLine\n return $this->class ?? \"\";\n }", "public function getClass()\n {\n return $this->_className;\n }", "private function getClassName() {\n return (new \\ReflectionClass(static::class))->getShortName();\n }", "public function getName() {\n\t\t\n\t\t// cut last part of class name\n\t\treturn substr( get_class( $this ), 0, -11 );\n\t\t\n\t}", "public function getClassNm()\r\n {\r\n\t\t$tabInfo = $this->getPathInfo();\r\n\t\treturn $tabInfo[1];\r\n }", "public function className()\n {\n $full_path = explode('\\\\', get_called_class());\n return end($full_path);\n }", "private function className () {\n $namespacedClass = explode(\"\\\\\", get_class($this));\n\n return end($namespacedClass);\n }", "public function getClass(): string\n {\n return $this->class;\n }", "public static function getFullyQualifiedClassName() {\n $reflector = new \\ReflectionClass(get_called_class());\n return $reflector->getName();\n }", "public function getClassName()\n\t{\n\t\tif (null === $this->_className) {\n\t\t\t$this->setClassName(get_class($this));\n\t\t}\n\t\t\n\t\treturn $this->_className;\n\t}", "public function getClassName() : string {\n if ($this->getType() != Router::CLOSURE_ROUTE) {\n $path = $this->getRouteTo();\n $pathExplode = explode(DS, $path);\n\n if (count($pathExplode) >= 1) {\n $fileNameExplode = explode('.', $pathExplode[count($pathExplode) - 1]);\n\n if (count($fileNameExplode) == 2 && $fileNameExplode[1] == 'php') {\n return $fileNameExplode[0];\n }\n }\n }\n\n return '';\n }", "public function getName(){\n\t\treturn get_class($this);\n\t}", "public function getClassName() {\r\n return $this->myCRUD()->getClassName();\r\n }", "public static function className()\n\t{\n\t\treturn static::class;\n\t}", "public function toClassName(): string\n {\n return ClassName::full($this->name);\n }", "public function getName()\n {\n return static::CLASS;\n }", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "public function getClass(): string;", "function getName()\n {\n return get_class($this);\n }", "public function className(): string\n {\n return $this->taskClass->name();\n }", "public static function getClassName($class)\n {\n return static::splitClassName($class)[1];\n }", "function getName()\r\n\t{\r\n\t\treturn get_class($this);\r\n\t}", "public function getName() {\n return get_class($this);\n }", "public function getName() {\n return get_class($this);\n }", "public function toString()\n {\n return __CLASS__;\n }", "public function getName()\n\t{\n\t\treturn $this->name ?: class_basename($this);\n\t}", "public function getNamespacedName()\n {\n return get_class();\n }", "protected function name() {\n\t\treturn strtolower(str_replace('\\\\', '_', get_class($this)));\n\t}", "protected function getClassName()\n {\n return ucwords(camel_case($this->getNameInput())) . 'TableSeeder';\n }", "function getClassName($name)\n{\n return str_replace('_', ' ', snake_case(class_basename($name)));\n}", "public function getClassName(): ?string {\n\t\treturn Hash::get($this->_config, 'className');\n\t}", "public function __toString() {\n\t\treturn $this->className();\n\t}", "public static function name()\n {\n return lcfirst(self::getClassShortName());\n }" ]
[ "0.87522393", "0.87522393", "0.8751158", "0.87397957", "0.87397957", "0.87397957", "0.87397957", "0.8731564", "0.8696754", "0.8673495", "0.8638432", "0.8615335", "0.8603119", "0.8566906", "0.8562364", "0.8555002", "0.85503733", "0.85503733", "0.85425884", "0.8533183", "0.8529981", "0.85237026", "0.8502733", "0.8493115", "0.8491238", "0.8488943", "0.8484194", "0.847459", "0.8441478", "0.8418852", "0.8399611", "0.83950585", "0.83949184", "0.83853173", "0.8378261", "0.837777", "0.8372544", "0.8355432", "0.8355432", "0.83479965", "0.8325877", "0.8325877", "0.8312873", "0.83027107", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.8272631", "0.82474744", "0.8242934", "0.8202995", "0.8185409", "0.8184752", "0.81829107", "0.81829107", "0.8176191", "0.81761754", "0.8162896", "0.8142928", "0.81323636", "0.8062757", "0.80528253", "0.8045769", "0.8033823", "0.8026215", "0.8001116", "0.79949147", "0.79779136", "0.79672754", "0.7957633", "0.790449", "0.78617185", "0.7860126", "0.7847096", "0.78195953", "0.7817044", "0.780094", "0.780094", "0.780094", "0.780094", "0.780094", "0.780094", "0.77821547", "0.7761565", "0.77588034", "0.7747239", "0.77409905", "0.77409905", "0.7710985", "0.76808393", "0.7670475", "0.76640886", "0.76514393", "0.76499707", "0.76323646", "0.76005036", "0.75937456" ]
0.0
-1
/ Save tgram after check
function save_edit_details($post) { $last_tgram_id = $this->mdl_common->save_tgram_by_user($post); if ($last_tgram_id) { $post['tgrmid'] = $last_tgram_id; } $this->mdl_common->save_pm_by_user($post); $insert_data = array( 'tgrmid' => $post['tgrmid'], 'tgram_id' => $post['tgram_id'], 'account_name' => $post['account_name'], 'received_date' => $post['received_date'], 'revision' => $post['revision'], 'account_type_id' => $post['account_type_id'], 'pm_id' => $post['pm_id'], 'pages_worked' => $post['pages_worked'], 'plp' => $post['plp'], 'billing_hour' => $post['billing_hour'], 'total_hour' => $post['billing_hour'], 'actual_hour' => $post['billing_hour'], 'comments' => $post['comments'], 'user_id' => $post['user_id'], 'submit_time' => date("Y-m-d G:i:s", time()) ); $this->db->insert('tbl_edit', $insert_data); $post['edit_id'] = $this->db->insert_id(); $inserted_rows = $this->db->affected_rows(); if ($post['plp'] == 'Yes') { $post['account_type_id'] = $post['plp_account_type']; $post['error_details_plp'] = $post['error_details_plp']; $post['comments'] = $post['comments_plp']; $post['billing_hour'] = $post['billing_hour_plp']; $this->save_plp_details($post); } if ($inserted_rows > 0) { return 1; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function savtb() {\n\t\tif (strlen($this->haslo)<40) $this->haslo=sha1($this->haslo);\n\t\t$this->llog=time();\n\t\tif (!$this->id) {\n\t\t\t$qstr='INSERT INTO users VALUES (NULL,\\''.$this->login.'\\',\\''.$this->haslo.'\\',\\''.$this->email.'\\',time())';\n\t\t\t$ret=db_exec($qstr);\n\t\t\t$id = db_lastInsertID();\n\t\t}\n\t\tif ($ret) return true;\n\t\treturn false;\n\t}", "private function saveRobotsTxtAction()\n\t{\n\t\tinclude_once(ISC_BASE_PATH.'/lib/class.file.php');\n\t\t$fc = new FileClass();\n\t\t$content = $_POST['robotstxtFileContent'];\n\t\t$success = 'RobotsSaveSuccess';\n\n\t\tif (isset($_POST['robotstxtRevertButton'])) {\n\t\t\t// Revert button is clicked instead.\n\t\t\t$content = $this->defaultContent;\n\t\t\t$success = 'RobotsRevertSuccess';\n\t\t}\n\n\t\t$res = $fc->writeToFile($content, $this->filePath);\n\t\tif ($res == true) {\n\t\t\tFlashMessage(GetLang($success), MSG_SUCCESS, $this->mainUrl);\n\t\t} else {\n\t\t\tFlashMessage(GetLang('RobotsSaveError'), MSG_ERROR, $this->mainUrl);\n\t\t}\n\t}", "function saveVister()\n {\n \n }", "public function save() {\n\t\tif ($this->is_bad == true) {\n\t\t\treturn false;\n\t\t}\n\t\tif (!mb_strlen($this->ga_headline, 'utf-8')) {\n\t\t\techo \"NO head\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\t\tif (!mb_strlen($this->ga_description1, 'utf-8')) {\n\t\t\techo \"NO description1\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\t\tif (!mb_strlen($this->ga_description2, 'utf-8')) {\n\t\t\techo \"NO description2\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\n\t\treturn parent::save();\n\t}", "function save();", "function save();", "function updateData() {\n global $rundata, $pagebuffer, $spambotDataLoc;\n return ( file_put_contents( $spambotDataLoc.'rundata', serialize($rundata) ) && file_put_contents( $spambotDataLoc.'pagebuffer', serialize( $pagebuffer ) ) );\n \n}", "public function saveNewTxtFile()\r\n {\r\n\r\n $fileName = date(\"Y-m-d\") . '-' . rand(0, 512) . \"Question\";\r\n\r\n $file = new StorageFileSaver($fileName);\r\n\r\n foreach ($this->fileContent as $content) {\r\n $file->write($content);\r\n }\r\n\r\n $file->saveAndCloseFile();\r\n }", "public function save()\n {\n return FALSE;\n }", "function save() {\n\t\t// If every question is answered, save to the db. Otherwise, to session.\n\t\tif($this->isComplete()) {\n\t\t\t$this->saveToRecord();\n\t\t} else {\n\t\t\t$this->saveToSession();\n\t\t}\n\t}", "public function save() {\t\t\t\t\n\t\tif (file_put_contents($this->filename, $this->objects)) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "private function save() {\n $this->state->get()['score'] += $this->dice->sum();\n $this->state->get()['round'] += 1;\n\n if ($this->state->get()['score'] >= 100) {\n $this->message = \"Grattis! Du vann!\";\n $this->cleardice = TRUE;\n $this->cleargame = TRUE;\n }\n\n $this->dice->clear();\n }", "private function save() \n {\n $content = \"<?php\\n\\nreturn\\n[\\n\";\n\n foreach ($this->arrayLang as $this->key => $this->value) \n {\n $content .= \"\\t'\".$this->key.\"' => '\".$this->value.\"',\\n\";\n }\n\n $content .= \"];\";\n\n file_put_contents($this->path, $content);\n\n }", "public final function save() {\n }", "function SaveAfspraak()\n{\n //zoniet, return false\n\n //afspraak opslaan en return true\n\n}", "function save_debug($txt,$file) {\n\n// ECRITURE FICHIER\n\t// ENREGISTREMENT LOG\n\tif ($fp=fopen($file, \"a\")) {\n\t\tfwrite($fp, \"\\n---------------------------------------------------------\\n\");\n\t\tfwrite($fp, $txt);\n\t\tfwrite($fp, \"\\n---------------------------------------------------------\\n\\n\");\n\t\tfclose($fp);\n\t} else {\n\t\techo \"Erreur d'ouverture de \".$file;\n\t}\n}", "public static function save($webRadio){\n // sérialisation de l'objet\n $serialized_webradio = serialize($webRadio);\n $filename=\"../webRadio.txt\";\n if(file_put_contents($filename, $serialized_webradio.\"\\n\",FILE_APPEND)!=FALSE){\n return 1;\n }else{\n return 0;\n }\n \n }", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save() {\n\t\t\t\n\t\t}", "function Save();", "protected function _saveTry()\n {\n $this->_history[] = $this->_number;\n }", "function save() {\n \tfile_put_contents(\"threads/{$this->id}\", serialize($this));\n }", "public final function save()\n {\n }", "function save() {\r\n\t\t$this->log .= \"save() called<br />\";\r\n\t\tif (count($this->data) < 1) {\r\n\t\t\t$this->log .= \"Nothing to save.<br />\";\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t//create file pointer\r\n\t\tif (!$fp=@fopen($this->filename,\"w\")) {\r\n\t\t\t$this->log .= \"Could not create or open \".$this->filename.\"<br />\";\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t//write to file\r\n\t\tif (!@fwrite($fp,serialize($this->data))) {\r\n\t\t\t$this->log .= \"Could not write to \".$this->filename.\"<br />\";\r\n\t\t\tfclose($fp);\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t//close file pointer\r\n\t\tfclose($fp);\r\n\t\treturn true;\r\n\t}", "public function save():void;", "public function saveData()\r\n {\r\n \r\n }", "function loot($flag,$data){\n $file=\"loot/loot.txt\"; // make sure of the permissions on file.\n $content= file_get_contents($file);\n if ($flag == 0) {\n $content .= \"[[DATA]] \".$data.\"\\n\";\n //echo \"all good\";\n } else {\n $content .= \"[[ERROR]] invalid token\".\"\\n\";\n //echo \"bad\";\n }\n file_put_contents($file,$content);\n}", "public function save()\r\n {\r\n \r\n }", "function save() {\n $this->log .= \"save() called<br />\";\n if (count($this->data) < 1) {\n $this->log .= \"Nothing to save.<br />\";\n return false;\n }\n //create file pointer\n $this->log .= \"Save file name: \".$this->filename.\"<br />\";\n if (!$fp=@fopen($this->filename,\"w\")) {\n $this->log .= \"Could not create or open \".$this->filename.\"<br />\";\n return false;\n }\n //write to file\n if (!@fwrite($fp,serialize($this->data))) {\n $this->log .= \"Could not write to \".$this->filename.\"<br />\";\n fclose($fp);\n return false;\n }\n //close file pointer\n fclose($fp);\n return true;\n }", "function save()\n {\n }", "function save()\n {\n }", "protected function savedraft()\n {\n global $INFO, $ID, $INPUT, $conf;\n\n if (class_exists('\\\\dokuwiki\\\\Draft', false)) {\n /* Release Hogfather (and above) */\n\n $draft = new \\dokuwiki\\Draft($ID, $INFO['client']);\n if (!$draft->saveDraft()) {\n $errors = $draft->getErrors();\n foreach ($errors as $error) {\n msg(hsc($error), -1);\n }\n }\n\n } else {\n /* Release Greebo and below */\n\n if (!$conf['usedraft']) return;\n if (!$INPUT->post->has('wikitext')) return;\n\n // ensure environment (safeguard when used via AJAX)\n assert(isset($INFO['client']), 'INFO.client should have been set');\n assert(isset($ID), 'ID should have been set');\n\n $draft = array(\n 'id' => $ID,\n 'prefix' => substr($INPUT->post->str('prefix'), 0, -1),\n 'text' => $INPUT->post->str('wikitext'),\n 'suffix' => $INPUT->post->str('suffix'),\n 'date' => $INPUT->post->int('date'),\n 'client' => $INFO['client'],\n );\n $cname = getCacheName($draft['client'] . $ID, '.draft');\n if (io_saveFile($cname, serialize($draft))) {\n $INFO['draft'] = $cname;\n }\n }\n }", "public function save()\n {\n if ($this->tid)\n {\n $query = sprintf('UPDATE %sTASK SET TASK_STAT=\"%s\", TASK_NOTE=\"%s\" WHERE TASK_ID=%d',\n DB_TBL_PREFIX,\n mysql_real_escape_string($this->taskstate, $GLOBALS['DB']),\n mysql_real_escape_string($this->note, $GLOBALS['DB']),\n $this->tid);\n // print_r($query); \n mysql_query($query, $GLOBALS['DB']);\n \n }\n }", "public function save()\n\t{\n\n\t}", "private function _saveExt() {\r\n\r\n }", "abstract public function save();", "abstract public function save();", "abstract public function save();", "abstract public function save();", "abstract public function save();", "function checkSaveButtons() {\n if ($this->arrTableParameters['savedok'] || $this->arrTableParameters['saveandclosedok']) {\n $tce = GeneralUtility::makeInstance('t3lib_TCEmain');\n $tce->stripslashes_values=0;\n if (count($this->arrTableParameters['grps'])) {\n\t $arrSave['grps'] = $this->arrTableParameters['grps'];\n\t $arrData[$this->arrWizardParameters['table']][$this->arrWizardParameters['uid']][$this->arrWizardParameters['field']] = serialize($arrSave);\n } else {\n \t$arrData[$this->arrWizardParameters['table']][$this->arrWizardParameters['uid']][$this->arrWizardParameters['field']] = '';\n }\n $tce->start($arrData,array());\n\t $tce->process_datamap();\n if ($this->arrTableParameters['saveandclosedok']) {\n header('Location: ' . GeneralUtility::locationHeaderUrl($this->arrWizardParameters['returnUrl']));\n\t\t\t\texit;\n }\n }\n }", "public function save() {}", "public function save() {}", "function savetxt($code, $titre){\n\t\t$fichier = fopen(\"save_code/\".$titre.'.txt', 'a+');\n\t\tfwrite($fichier, $code);\n\t\tfclose($fichier);\n\t\t$this->saved_txt = $titre;\n\t}", "public function save() {}", "public function save()\n\t {\n\t\tif (isset($this->_advert->date) === true && isset($this->_advert->phone) === true)\n\t\t {\n\t\t\t$bigfile = new BigFile(\"base-\" . $this->_advert->phone, 10);\n\t\t\t$bigfile->addrecord($this->_advert->date);\n\t\t } //end if\n\n\t }", "public function save()\n\t{\n\t\treturn false;\n\t}", "protected function save()\n\t{\n\t\t$this->saveItems();\n\t\t//$this->saveAssignments();\n\t\t//$this->saveRules();\n\t}", "public\tfunction\tsave()\n\t\t{\n\t\t}", "public function save(): bool;", "public function save(): bool;", "public function save()\n {\n $_SESSION['quiz'][$this->_testId] = serialize($this->_answers);\n }", "private function save_hash_file(){\n\n $file = MD5_HASHER_DIR.$this->file_check;\n if(is_file($file) && is_writable($file)){\n $fh = fopen($file, 'w');\n fwrite($fh, json_encode($this->md5_gen_output));\n fclose($fh);\n return true;\n }\n\n return false;\n }", "public function save(): bool\n {\n\n $bytes_written = file_put_contents($this->file_name, json_encode($this->getData()));\n\n if ($bytes_written === FALSE) {\n return false;\n }\n\n return true;\n }", "public function save()\n {\n try {\n $testRunCache = new CTM_Test_Run_Cache();\n $testRun = $testRunCache->getById($this->testRunId);\n\n if ( $testRun->testRunStateId == $this->testRunStateId ) {\n // if the state is already set save the trouble of the save()\n } else if ( $testRun->testRunStateId == 5 ) {\n // If the test run has failed we cannot undo a failure.\n } else {\n $testRun->testRunStateId = $this->testRunStateId;\n $testRun->save();\n }\n\n } catch ( Exception $e ) {\n }\n\n // do the default save method.\n return parent::save();\n }", "private static function save() {\n\t\tif(self::$data===null) throw new Excepton('Save before load!');\n\t\t$fp=fopen(self::$datafile,'w');\n\t\tif(!$fp) throw new Exception('Could not write data file!');\n\t\tforeach (self::$data as $item) {\n\t\t\tfwrite($fp,$item); // we use the __toString() here\n\t\t}\n\t\tfclose($fp);\n\t}", "private function writeTextToFile() {\n\t\t$text = $this -> pm -> getText($this -> padid);\n\t\t$path = sprintf('%s/%s.tex', $this -> directory, $this -> name);\n\t\tfile_put_contents($path, $text);\n\t}", "public function autosaved()\n {\n }", "public function save()\n {\n }", "public function saveTindakanKomponen(){\n\t\t\t$tindakankomponentersimpan = true;\n\t\t\t\n\t\t\treturn $tindakankomponentersimpan;\n\t\t}", "function save($b){\r\n\techo \"<b>SOMETHING WENT WRONG.</b> Saving to _junk.txt<P>\";\t\r\n\t$fp = fopen(\"_junk.txt\", \"w\");\r\n\tfwrite($fp, $b); \r\n\tfclose($fp);\t\r\n}", "public function saveDataToFile()\n {\n\n }", "public function saveToFile() {\n\n $file = $this->getExtractedFile();\n\n $file->close();\n\n $this->extractedFile = false;\n }", "private function saveFixture($name) {\n file_put_contents(\n $this->fixturePath() . '/' . $name . '.txt',\n serialize($this->{$name})\n );\n }", "function save($objet) {\n\t// Random code for subject\n\t\t$code = substr(str_shuffle(\"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\"), 0, 5);\n\n\t\t$sql = \"INSERT INTO cat_materia(vchCodigoMateria, vchMateria)\n\t\t\t\tVALUES\t('\".$code.\"', '\".$objet['name'].\"')\";\n\t\t$result = $this -> query($sql);\n\t\t\n\t\treturn $result;\n\t}", "public function save()\n {\n return file_put_contents($this->getFilepath(), $this->read());\n }", "protected function onSaved()\n {\n return true;\n }", "private function saveData(): void\n {\n $this->tab_chat_call->call_update = gmdate(\"Y-m-d H:i:s\"); //data e hora UTC\n $result = $this->tab_chat_call->save();\n\n if ($result) {\n $this->Result = true;\n $this->Error = [];\n $this->Error['msg'] = \"Sucesso!\";\n $this->Error['data']['call'] = $this->tab_chat_call->call_id;\n } else {\n $this->Result = false;\n $this->Error = [];\n $this->Error['msg'] = $this->tab_chat_call->fail()->getMessage();\n $this->Error['data'] = null;\n }\n }", "public function save()\n {\n $settings = Yii::$app->getModule('termsbox')->settings;\n $settings->set('title', $this->title);\n $settings->set('statement', $this->statement);\n $settings->set('content', $this->content);\n $settings->set('active', (boolean) $this->active);\n $settings->set('showAsModal', (boolean) $this->showAsModal);\n $settings->set('hideUnaccepted', (boolean) $this->hideUnaccepted);\n\n if ($setting = Setting::findByName('content')) {\n RichText::postProcess($this->content, $setting);\n }\n\n if ($this->reset) {\n User::updateAll(['termsbox_accepted' => false]);\n if (!Yii::$app->user->isGuest) {\n Yii::$app->user->getIdentity()->termsbox_accepted = false;\n }\n }\n\n return true;\n }", "function backup($bf, $preferences, $question, $level = 6) {\n //print('backup()');\n $status = true;\n $multichoices = get_records(\"question_turprove\", \"question\", $question, \"id\");\n //If there are multichoices\n if ($multichoices) {\n //Iterate over each multichoice\n foreach ($multichoices as $multichoice) {\n $status = fwrite($bf, start_tag(\"turprove\", $level, true));\n //Print multichoice contents\n fwrite($bf, full_tag(\"LAYOUT\", $level + 1, false, $multichoice->layout));\n fwrite($bf, full_tag(\"ANSWERS\", $level + 1, false, $multichoice->answers));\n fwrite($bf, full_tag(\"SINGLE\", $level + 1, false, $multichoice->single));\n fwrite($bf, full_tag(\"SHUFFLEANSWERS\", $level + 1, false, $multichoice->shuffleanswers));\n fwrite($bf, full_tag(\"CORRECTFEEDBACK\", $level + 1, false, $multichoice->correctfeedback));\n fwrite($bf, full_tag(\"PARTIALLYCORRECTFEEDBACK\", $level + 1, false, $multichoice->partiallycorrectfeedback));\n fwrite($bf, full_tag(\"INCORRECTFEEDBACK\", $level + 1, false, $multichoice->incorrectfeedback));\n\n fwrite($bf, full_tag(\"QUESTIONSOUND\", $level + 1, false, $multichoice->questionsound));\n fwrite($bf, full_tag(\"AUTOPLAY\", $level + 1, false, $multichoice->autoplay));\n fwrite($bf, full_tag(\"QDIFFICULTY\", $level + 1, false, $multichoice->qdifficulty));\n\n $status = fwrite($bf, end_tag(\"turprove\", $level, true));\n }\n\n //Now print question_answers\n // $status = backup_answers();\n // $status = question_backup_answers_tur($bf,$preferences,$question);\n $answers = get_records(\"question_answers\", \"question\", $question, \"id\");\n //If there are answers\n if ($answers) {\n\n\n $status = $status && fwrite($bf, start_tag(\"ANSWERS\", $level, true));\n //Iterate over each answer\n foreach ($answers as $answer) {\n $status = $status && fwrite($bf, start_tag(\"ANSWER\", $level + 1, true));\n //Print answer contents\n fwrite($bf, full_tag(\"ID\", $level + 2, false, $answer->id));\n fwrite($bf, full_tag(\"ANSWER_TEXT\", $level + 2, false, $answer->answer));\n fwrite($bf, full_tag(\"FRACTION\", $level + 2, false, $answer->fraction));\n fwrite($bf, full_tag(\"FEEDBACK\", $level + 2, false, $answer->feedback));\n\n if ($answer->answersound == null) {\n fwrite($bf, full_tag(\"ANSWERSOUND\", $level + 2, false, ''));\n } else {\n fwrite($bf, full_tag(\"ANSWERSOUND\", $level + 2, false, $answer->answersound));\n }\n\n if ($answer->feedbacksound == null) {\n fwrite($bf, full_tag(\"FEEDBACKSOUND\", $level + 2, false, ''));\n } else {\n fwrite($bf, full_tag(\"FEEDBACKSOUND\", $level + 2, false, $answer->feedbacksound));\n }\n\n if ($answer->tur_answer_truefalse == null) {\n fwrite($bf, full_tag(\"TUR_ANSWER_TRUEFALSE\", $level + 2, false, ''));\n } else {\n fwrite($bf, full_tag(\"TUR_ANSWER_TRUEFALSE\", $level + 2, false, $answer->tur_answer_truefalse));\n }\n\n $status = $status && fwrite($bf, end_tag(\"ANSWER\", $level + 1, true));\n }\n $status = $status && fwrite($bf, end_tag(\"ANSWERS\", $level, true));\n }\n\n //Now print question_answers\n // $status = question_backup_answers($bf, $preferences, $question);\n }\n return $status;\n }", "public abstract function save();", "public function testSave() {\n\t\t$temaBuscar = new Tema;\n\t\t$temaBuscar->nombre = 'Prueba';\n\t\t$this->assertEquals( count( $temaBuscar->search()->getData() ), 0 );\n\t\n\t\t// guarda el tema\n\t\t$tema = new Tema;\n\t\t$tema->nombre = 'Prueba';\n\t\t$tema->responsable = 1;\n\t\t$tema->save();\n\t\n\t\t$this->assertEquals( count( $temaBuscar->search()->getData() ), 1 );\n\t}", "public function save()\r\n {\r\n //\r\n }", "function beforeSaveLoop()\r\n {\r\n }", "public function save(){\n return parent::writeFile( $this->outputFile, $this->template);\n }", "private function check_DB() {\n $this->record_progress(\n \"Step 4: Identifying which mutations are already in database\");\n\n $path_valid = $this->path_valid;\n $path_new_input = $this->path_new_input;\n\n $table = \"NewSpliceman\";\n\n $this->record_progress(\"1\");\n\n $read_valid = fopen($path_valid, \"r\") or \n die (\"Unable to open file!\");\n $write_new_input = fopen($path_new_input, \"a\") or \n die (\"Unable to open file!\");\n\n $this->record_progress(\"2\");\n\n $valid_mutations = false;\n\n while (! feof($read_valid)) {\n $this->record_progress(\"3\");\n $mutation = fgets($read_valid);\n if (ctype_space($mutation)) {\n break;\n }\n $mutation_data = explode(\"\\t\", $mutation);\n $this->record_progress(\"4\");\n if ($this->is_valid($mutation_data)) {\n $this->record_progress(\"5\");\n $db_key = \n $mutation_data[0].\"_\".$mutation_data[5].\"_\".\n $mutation_data[6].\"_\".$mutation_data[7].\"_\".\n $mutation_data[11].\"_\".$mutation_data[12];\n // Removes newline characters, if they are present\n $db_key = str_replace(\"\\n\", \"\", $db_key);\n $this->record_progress(\"6\");\n $result = DB::table($table)->\n where('chr_loc_wild_mut_transcript_exon', $db_key)->\n first();\n $valid_mutations = true;\n $this->record_progress(\"8\");\n if (count($result) == 0) {\n fwrite($write_new_input, $mutation);\n }\n $this->record_progress(\"9\");\n } \n } \n\n $this->record_progress(\"10\");\n fclose($read_valid);\n fclose($write_new_input);\n\n $this->record_progress(\"11\");\n }", "public function Save()\r\n {\r\n return false;\r\n }", "protected function saveData()\n {\n // TODO: データ保存\n\n // 一次データ削除\n $this->deleteStore();\n\n drupal_set_message($this->t('The form has been saved.'));\n }", "public function save()\n {\n // For V2.0\n }", "function persist() ;", "public function save()\n {\n return false;\n }", "function saveTxT($chatId, $from, $message){\r\r\n $myfile = \"fichero.txt\";\r\r\n //$fichero = file_get_contents($myfile);\r\r\n $txt = $chatId.\"-\".$message.\"-\".$from. \" \\n\";\r\r\n //$fichero.= $txt;\r\r\n\r\r\n file_put_contents($myfile, $txt, FILE_APPEND | LOCK_EX); \r\r\n \r\r\n}", "function save()\n {\n /* remove objectclass GOhard if this is an ogroup tab */\n if(isset($this->parent->by_object['ogroup'])){\n $this->objectclasses = array();\n }\n\n plugin::save();\n\n /* Strip out 'default' values */\n foreach(array(\"gotoXMethod\",\"gotoXDriver\", \"gotoXResolution\", \"gotoXColordepth\",\n \"gotoLpdServer\", \"gotoXKbModel\", \"gotoXKbLayout\",\n \"gotoXKbVariant\", \"gotoXMouseType\", \"gotoXMouseport\") as $val){\n\n if ($this->attrs[$val] == \"default\"){\n $this->attrs[$val]= array();\n }\n }\n\n if($this->gotoXMethod == \"default\"){\n $this->attrs['gotoXdmcpServer'] = array();\n $this->attrs['gotoXMethod'] = array();\n }else{\n $this->attrs['gotoXdmcpServer'] = array_values($this->selected_xdmcp_servers);\n }\n\n\n if($this->AutoSync){\n $this->attrs['gotoXHsync'] = \"30+55\";\n $this->attrs['gotoXVsync'] = \"50+70\";\n }\n\n /* Write back to ldap */\n $ldap= $this->config->get_ldap_link();\n $ldap->cd($this->dn);\n $this->cleanup();\n $ldap->modify ($this->attrs); \n new log(\"modify\",\"terminal/\".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());\n\n if (!$ldap->success()){\n msg_dialog::display(_(\"LDAP error\"), msgPool::ldaperror($ldap->get_error(), $this->dn, LDAP_MOD, get_class()));\n }\n $this->handle_post_events(\"modify\");\n\n /* Send goto reload event */\n if(count($this->attrs)){\n $this->send_goto_reload();\n }\n }", "public static function Guardar($unAuto)\n {\n//var_dump($unAuto);\n $archivo = fopen(\"Archivos/estacionados.txt\", \"a\");\n $renglon = $unAuto->patente.\"--\".$unAuto->fechIngreso.\"\\n\";\n \n fwrite($archivo, $renglon);\n fclose($archivo);\n }" ]
[ "0.6235355", "0.6001607", "0.5981118", "0.5953967", "0.59170145", "0.59170145", "0.5859388", "0.58337224", "0.5832184", "0.5781754", "0.5767901", "0.57483494", "0.56978834", "0.5679583", "0.5669856", "0.56463945", "0.5623309", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56205744", "0.56169724", "0.5596745", "0.55925655", "0.55856293", "0.55534434", "0.55400544", "0.5528456", "0.55241466", "0.5518528", "0.5514843", "0.5509972", "0.5509972", "0.55047214", "0.5488083", "0.54768497", "0.54685104", "0.54631245", "0.54631245", "0.54631245", "0.54631245", "0.54631245", "0.5458759", "0.5457468", "0.5457468", "0.545722", "0.5456213", "0.5435363", "0.54196465", "0.54078287", "0.5380466", "0.53797674", "0.53797674", "0.53712034", "0.5361019", "0.5359859", "0.5359556", "0.5356831", "0.53560615", "0.53506726", "0.53433245", "0.53344697", "0.5330188", "0.53145325", "0.53143454", "0.5302848", "0.52948487", "0.5291777", "0.5283259", "0.527963", "0.5276262", "0.52710086", "0.5257396", "0.5252445", "0.5246335", "0.52327543", "0.5228348", "0.52275366", "0.52264315", "0.5224937", "0.5216576", "0.5215499", "0.5212072", "0.5202544", "0.52021486", "0.51957726" ]
0.0
-1
/ Save tgram after check
function update_edit_details_by_user($post) { $last_tgram_id = $this->mdl_common->save_tgram_by_user($post); if ($last_tgram_id) { $post['tgrmid'] = $last_tgram_id; } $this->mdl_common->save_pm_by_user($post); $edit_data = array( 'tgrmid' => $post['tgrmid'], 'tgram_id' => $post['tgram_id'], 'account_name' => $post['account_name'], 'received_date' => $post['received_date'], 'revision' => $post['revision'], 'account_type_id' => $post['account_type_id'], 'pm_id' => $post['pm_id'], 'pages_worked' => $post['pages_worked'], 'plp' => $post['plp'], 'billing_hour' => $post['billing_hour'], 'total_hour' => $post['billing_hour'], 'actual_hour' => $post['billing_hour'], 'comments' => $post['comments'], 'user_id' => $post['user_id'], 'submit_time' => date("Y-m-d G:i:s", time()) ); $this->db->where('id', $post['edit_id']); $this->db->update('tbl_edit', $edit_data); if ($post['plp'] == 'Yes') { $plp_data = array( 'tgrmid' => $post['tgrmid'], 'tgram_id' => $post['tgram_id'], 'account_name' => $post['account_name'], 'cid' => $post['cid'], 'error_details_plp' => $post['error_details_plp'], 'received_date' => $post['received_date'], 'account_type_id' => $post['plp_account_type'], 'pm_id' => $post['pm_id'], 'billing_hour' => $post['billing_hour_plp'], 'total_hour' => $post['billing_hour_plp'], 'actual_hour' => $post['billing_hour_plp'], 'comments' => $post['comments_plp'], 'user_id' => $post['user_id'], 'submit_time' => date("Y-m-d G:i:s", time()) ); $this->db->where('id', $post['plp_id']); $this->db->update('tbl_plp', $plp_data); } return 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function savtb() {\n\t\tif (strlen($this->haslo)<40) $this->haslo=sha1($this->haslo);\n\t\t$this->llog=time();\n\t\tif (!$this->id) {\n\t\t\t$qstr='INSERT INTO users VALUES (NULL,\\''.$this->login.'\\',\\''.$this->haslo.'\\',\\''.$this->email.'\\',time())';\n\t\t\t$ret=db_exec($qstr);\n\t\t\t$id = db_lastInsertID();\n\t\t}\n\t\tif ($ret) return true;\n\t\treturn false;\n\t}", "private function saveRobotsTxtAction()\n\t{\n\t\tinclude_once(ISC_BASE_PATH.'/lib/class.file.php');\n\t\t$fc = new FileClass();\n\t\t$content = $_POST['robotstxtFileContent'];\n\t\t$success = 'RobotsSaveSuccess';\n\n\t\tif (isset($_POST['robotstxtRevertButton'])) {\n\t\t\t// Revert button is clicked instead.\n\t\t\t$content = $this->defaultContent;\n\t\t\t$success = 'RobotsRevertSuccess';\n\t\t}\n\n\t\t$res = $fc->writeToFile($content, $this->filePath);\n\t\tif ($res == true) {\n\t\t\tFlashMessage(GetLang($success), MSG_SUCCESS, $this->mainUrl);\n\t\t} else {\n\t\t\tFlashMessage(GetLang('RobotsSaveError'), MSG_ERROR, $this->mainUrl);\n\t\t}\n\t}", "function saveVister()\n {\n \n }", "public function save() {\n\t\tif ($this->is_bad == true) {\n\t\t\treturn false;\n\t\t}\n\t\tif (!mb_strlen($this->ga_headline, 'utf-8')) {\n\t\t\techo \"NO head\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\t\tif (!mb_strlen($this->ga_description1, 'utf-8')) {\n\t\t\techo \"NO description1\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\t\tif (!mb_strlen($this->ga_description2, 'utf-8')) {\n\t\t\techo \"NO description2\\r\\n\";\n\t\t\treturn false;\n\t\t}\n\n\t\treturn parent::save();\n\t}", "function save();", "function save();", "function updateData() {\n global $rundata, $pagebuffer, $spambotDataLoc;\n return ( file_put_contents( $spambotDataLoc.'rundata', serialize($rundata) ) && file_put_contents( $spambotDataLoc.'pagebuffer', serialize( $pagebuffer ) ) );\n \n}", "public function saveNewTxtFile()\r\n {\r\n\r\n $fileName = date(\"Y-m-d\") . '-' . rand(0, 512) . \"Question\";\r\n\r\n $file = new StorageFileSaver($fileName);\r\n\r\n foreach ($this->fileContent as $content) {\r\n $file->write($content);\r\n }\r\n\r\n $file->saveAndCloseFile();\r\n }", "public function save()\n {\n return FALSE;\n }", "function save() {\n\t\t// If every question is answered, save to the db. Otherwise, to session.\n\t\tif($this->isComplete()) {\n\t\t\t$this->saveToRecord();\n\t\t} else {\n\t\t\t$this->saveToSession();\n\t\t}\n\t}", "public function save() {\t\t\t\t\n\t\tif (file_put_contents($this->filename, $this->objects)) {\n\t\t\treturn true;\n\t\t}\n\t\treturn false;\n\t}", "private function save() {\n $this->state->get()['score'] += $this->dice->sum();\n $this->state->get()['round'] += 1;\n\n if ($this->state->get()['score'] >= 100) {\n $this->message = \"Grattis! Du vann!\";\n $this->cleardice = TRUE;\n $this->cleargame = TRUE;\n }\n\n $this->dice->clear();\n }", "private function save() \n {\n $content = \"<?php\\n\\nreturn\\n[\\n\";\n\n foreach ($this->arrayLang as $this->key => $this->value) \n {\n $content .= \"\\t'\".$this->key.\"' => '\".$this->value.\"',\\n\";\n }\n\n $content .= \"];\";\n\n file_put_contents($this->path, $content);\n\n }", "public final function save() {\n }", "function SaveAfspraak()\n{\n //zoniet, return false\n\n //afspraak opslaan en return true\n\n}", "function save_debug($txt,$file) {\n\n// ECRITURE FICHIER\n\t// ENREGISTREMENT LOG\n\tif ($fp=fopen($file, \"a\")) {\n\t\tfwrite($fp, \"\\n---------------------------------------------------------\\n\");\n\t\tfwrite($fp, $txt);\n\t\tfwrite($fp, \"\\n---------------------------------------------------------\\n\\n\");\n\t\tfclose($fp);\n\t} else {\n\t\techo \"Erreur d'ouverture de \".$file;\n\t}\n}", "public static function save($webRadio){\n // sérialisation de l'objet\n $serialized_webradio = serialize($webRadio);\n $filename=\"../webRadio.txt\";\n if(file_put_contents($filename, $serialized_webradio.\"\\n\",FILE_APPEND)!=FALSE){\n return 1;\n }else{\n return 0;\n }\n \n }", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save();", "public function save() {\n\t\t\t\n\t\t}", "function Save();", "protected function _saveTry()\n {\n $this->_history[] = $this->_number;\n }", "function save() {\n \tfile_put_contents(\"threads/{$this->id}\", serialize($this));\n }", "public final function save()\n {\n }", "function save() {\r\n\t\t$this->log .= \"save() called<br />\";\r\n\t\tif (count($this->data) < 1) {\r\n\t\t\t$this->log .= \"Nothing to save.<br />\";\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t//create file pointer\r\n\t\tif (!$fp=@fopen($this->filename,\"w\")) {\r\n\t\t\t$this->log .= \"Could not create or open \".$this->filename.\"<br />\";\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t//write to file\r\n\t\tif (!@fwrite($fp,serialize($this->data))) {\r\n\t\t\t$this->log .= \"Could not write to \".$this->filename.\"<br />\";\r\n\t\t\tfclose($fp);\r\n\t\t\treturn false;\r\n\t\t}\r\n\t\t//close file pointer\r\n\t\tfclose($fp);\r\n\t\treturn true;\r\n\t}", "public function save():void;", "public function saveData()\r\n {\r\n \r\n }", "function loot($flag,$data){\n $file=\"loot/loot.txt\"; // make sure of the permissions on file.\n $content= file_get_contents($file);\n if ($flag == 0) {\n $content .= \"[[DATA]] \".$data.\"\\n\";\n //echo \"all good\";\n } else {\n $content .= \"[[ERROR]] invalid token\".\"\\n\";\n //echo \"bad\";\n }\n file_put_contents($file,$content);\n}", "public function save()\r\n {\r\n \r\n }", "function save() {\n $this->log .= \"save() called<br />\";\n if (count($this->data) < 1) {\n $this->log .= \"Nothing to save.<br />\";\n return false;\n }\n //create file pointer\n $this->log .= \"Save file name: \".$this->filename.\"<br />\";\n if (!$fp=@fopen($this->filename,\"w\")) {\n $this->log .= \"Could not create or open \".$this->filename.\"<br />\";\n return false;\n }\n //write to file\n if (!@fwrite($fp,serialize($this->data))) {\n $this->log .= \"Could not write to \".$this->filename.\"<br />\";\n fclose($fp);\n return false;\n }\n //close file pointer\n fclose($fp);\n return true;\n }", "function save()\n {\n }", "function save()\n {\n }", "protected function savedraft()\n {\n global $INFO, $ID, $INPUT, $conf;\n\n if (class_exists('\\\\dokuwiki\\\\Draft', false)) {\n /* Release Hogfather (and above) */\n\n $draft = new \\dokuwiki\\Draft($ID, $INFO['client']);\n if (!$draft->saveDraft()) {\n $errors = $draft->getErrors();\n foreach ($errors as $error) {\n msg(hsc($error), -1);\n }\n }\n\n } else {\n /* Release Greebo and below */\n\n if (!$conf['usedraft']) return;\n if (!$INPUT->post->has('wikitext')) return;\n\n // ensure environment (safeguard when used via AJAX)\n assert(isset($INFO['client']), 'INFO.client should have been set');\n assert(isset($ID), 'ID should have been set');\n\n $draft = array(\n 'id' => $ID,\n 'prefix' => substr($INPUT->post->str('prefix'), 0, -1),\n 'text' => $INPUT->post->str('wikitext'),\n 'suffix' => $INPUT->post->str('suffix'),\n 'date' => $INPUT->post->int('date'),\n 'client' => $INFO['client'],\n );\n $cname = getCacheName($draft['client'] . $ID, '.draft');\n if (io_saveFile($cname, serialize($draft))) {\n $INFO['draft'] = $cname;\n }\n }\n }", "public function save()\n {\n if ($this->tid)\n {\n $query = sprintf('UPDATE %sTASK SET TASK_STAT=\"%s\", TASK_NOTE=\"%s\" WHERE TASK_ID=%d',\n DB_TBL_PREFIX,\n mysql_real_escape_string($this->taskstate, $GLOBALS['DB']),\n mysql_real_escape_string($this->note, $GLOBALS['DB']),\n $this->tid);\n // print_r($query); \n mysql_query($query, $GLOBALS['DB']);\n \n }\n }", "public function save()\n\t{\n\n\t}", "private function _saveExt() {\r\n\r\n }", "abstract public function save();", "abstract public function save();", "abstract public function save();", "abstract public function save();", "abstract public function save();", "function checkSaveButtons() {\n if ($this->arrTableParameters['savedok'] || $this->arrTableParameters['saveandclosedok']) {\n $tce = GeneralUtility::makeInstance('t3lib_TCEmain');\n $tce->stripslashes_values=0;\n if (count($this->arrTableParameters['grps'])) {\n\t $arrSave['grps'] = $this->arrTableParameters['grps'];\n\t $arrData[$this->arrWizardParameters['table']][$this->arrWizardParameters['uid']][$this->arrWizardParameters['field']] = serialize($arrSave);\n } else {\n \t$arrData[$this->arrWizardParameters['table']][$this->arrWizardParameters['uid']][$this->arrWizardParameters['field']] = '';\n }\n $tce->start($arrData,array());\n\t $tce->process_datamap();\n if ($this->arrTableParameters['saveandclosedok']) {\n header('Location: ' . GeneralUtility::locationHeaderUrl($this->arrWizardParameters['returnUrl']));\n\t\t\t\texit;\n }\n }\n }", "public function save() {}", "public function save() {}", "function savetxt($code, $titre){\n\t\t$fichier = fopen(\"save_code/\".$titre.'.txt', 'a+');\n\t\tfwrite($fichier, $code);\n\t\tfclose($fichier);\n\t\t$this->saved_txt = $titre;\n\t}", "public function save() {}", "public function save()\n\t {\n\t\tif (isset($this->_advert->date) === true && isset($this->_advert->phone) === true)\n\t\t {\n\t\t\t$bigfile = new BigFile(\"base-\" . $this->_advert->phone, 10);\n\t\t\t$bigfile->addrecord($this->_advert->date);\n\t\t } //end if\n\n\t }", "public function save()\n\t{\n\t\treturn false;\n\t}", "protected function save()\n\t{\n\t\t$this->saveItems();\n\t\t//$this->saveAssignments();\n\t\t//$this->saveRules();\n\t}", "public\tfunction\tsave()\n\t\t{\n\t\t}", "public function save(): bool;", "public function save(): bool;", "public function save()\n {\n $_SESSION['quiz'][$this->_testId] = serialize($this->_answers);\n }", "private function save_hash_file(){\n\n $file = MD5_HASHER_DIR.$this->file_check;\n if(is_file($file) && is_writable($file)){\n $fh = fopen($file, 'w');\n fwrite($fh, json_encode($this->md5_gen_output));\n fclose($fh);\n return true;\n }\n\n return false;\n }", "public function save(): bool\n {\n\n $bytes_written = file_put_contents($this->file_name, json_encode($this->getData()));\n\n if ($bytes_written === FALSE) {\n return false;\n }\n\n return true;\n }", "public function save()\n {\n try {\n $testRunCache = new CTM_Test_Run_Cache();\n $testRun = $testRunCache->getById($this->testRunId);\n\n if ( $testRun->testRunStateId == $this->testRunStateId ) {\n // if the state is already set save the trouble of the save()\n } else if ( $testRun->testRunStateId == 5 ) {\n // If the test run has failed we cannot undo a failure.\n } else {\n $testRun->testRunStateId = $this->testRunStateId;\n $testRun->save();\n }\n\n } catch ( Exception $e ) {\n }\n\n // do the default save method.\n return parent::save();\n }", "private static function save() {\n\t\tif(self::$data===null) throw new Excepton('Save before load!');\n\t\t$fp=fopen(self::$datafile,'w');\n\t\tif(!$fp) throw new Exception('Could not write data file!');\n\t\tforeach (self::$data as $item) {\n\t\t\tfwrite($fp,$item); // we use the __toString() here\n\t\t}\n\t\tfclose($fp);\n\t}", "private function writeTextToFile() {\n\t\t$text = $this -> pm -> getText($this -> padid);\n\t\t$path = sprintf('%s/%s.tex', $this -> directory, $this -> name);\n\t\tfile_put_contents($path, $text);\n\t}", "public function autosaved()\n {\n }", "public function save()\n {\n }", "public function saveTindakanKomponen(){\n\t\t\t$tindakankomponentersimpan = true;\n\t\t\t\n\t\t\treturn $tindakankomponentersimpan;\n\t\t}", "function save($b){\r\n\techo \"<b>SOMETHING WENT WRONG.</b> Saving to _junk.txt<P>\";\t\r\n\t$fp = fopen(\"_junk.txt\", \"w\");\r\n\tfwrite($fp, $b); \r\n\tfclose($fp);\t\r\n}", "public function saveDataToFile()\n {\n\n }", "public function saveToFile() {\n\n $file = $this->getExtractedFile();\n\n $file->close();\n\n $this->extractedFile = false;\n }", "private function saveFixture($name) {\n file_put_contents(\n $this->fixturePath() . '/' . $name . '.txt',\n serialize($this->{$name})\n );\n }", "function save($objet) {\n\t// Random code for subject\n\t\t$code = substr(str_shuffle(\"0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ\"), 0, 5);\n\n\t\t$sql = \"INSERT INTO cat_materia(vchCodigoMateria, vchMateria)\n\t\t\t\tVALUES\t('\".$code.\"', '\".$objet['name'].\"')\";\n\t\t$result = $this -> query($sql);\n\t\t\n\t\treturn $result;\n\t}", "public function save()\n {\n return file_put_contents($this->getFilepath(), $this->read());\n }", "protected function onSaved()\n {\n return true;\n }", "private function saveData(): void\n {\n $this->tab_chat_call->call_update = gmdate(\"Y-m-d H:i:s\"); //data e hora UTC\n $result = $this->tab_chat_call->save();\n\n if ($result) {\n $this->Result = true;\n $this->Error = [];\n $this->Error['msg'] = \"Sucesso!\";\n $this->Error['data']['call'] = $this->tab_chat_call->call_id;\n } else {\n $this->Result = false;\n $this->Error = [];\n $this->Error['msg'] = $this->tab_chat_call->fail()->getMessage();\n $this->Error['data'] = null;\n }\n }", "public function save()\n {\n $settings = Yii::$app->getModule('termsbox')->settings;\n $settings->set('title', $this->title);\n $settings->set('statement', $this->statement);\n $settings->set('content', $this->content);\n $settings->set('active', (boolean) $this->active);\n $settings->set('showAsModal', (boolean) $this->showAsModal);\n $settings->set('hideUnaccepted', (boolean) $this->hideUnaccepted);\n\n if ($setting = Setting::findByName('content')) {\n RichText::postProcess($this->content, $setting);\n }\n\n if ($this->reset) {\n User::updateAll(['termsbox_accepted' => false]);\n if (!Yii::$app->user->isGuest) {\n Yii::$app->user->getIdentity()->termsbox_accepted = false;\n }\n }\n\n return true;\n }", "function backup($bf, $preferences, $question, $level = 6) {\n //print('backup()');\n $status = true;\n $multichoices = get_records(\"question_turprove\", \"question\", $question, \"id\");\n //If there are multichoices\n if ($multichoices) {\n //Iterate over each multichoice\n foreach ($multichoices as $multichoice) {\n $status = fwrite($bf, start_tag(\"turprove\", $level, true));\n //Print multichoice contents\n fwrite($bf, full_tag(\"LAYOUT\", $level + 1, false, $multichoice->layout));\n fwrite($bf, full_tag(\"ANSWERS\", $level + 1, false, $multichoice->answers));\n fwrite($bf, full_tag(\"SINGLE\", $level + 1, false, $multichoice->single));\n fwrite($bf, full_tag(\"SHUFFLEANSWERS\", $level + 1, false, $multichoice->shuffleanswers));\n fwrite($bf, full_tag(\"CORRECTFEEDBACK\", $level + 1, false, $multichoice->correctfeedback));\n fwrite($bf, full_tag(\"PARTIALLYCORRECTFEEDBACK\", $level + 1, false, $multichoice->partiallycorrectfeedback));\n fwrite($bf, full_tag(\"INCORRECTFEEDBACK\", $level + 1, false, $multichoice->incorrectfeedback));\n\n fwrite($bf, full_tag(\"QUESTIONSOUND\", $level + 1, false, $multichoice->questionsound));\n fwrite($bf, full_tag(\"AUTOPLAY\", $level + 1, false, $multichoice->autoplay));\n fwrite($bf, full_tag(\"QDIFFICULTY\", $level + 1, false, $multichoice->qdifficulty));\n\n $status = fwrite($bf, end_tag(\"turprove\", $level, true));\n }\n\n //Now print question_answers\n // $status = backup_answers();\n // $status = question_backup_answers_tur($bf,$preferences,$question);\n $answers = get_records(\"question_answers\", \"question\", $question, \"id\");\n //If there are answers\n if ($answers) {\n\n\n $status = $status && fwrite($bf, start_tag(\"ANSWERS\", $level, true));\n //Iterate over each answer\n foreach ($answers as $answer) {\n $status = $status && fwrite($bf, start_tag(\"ANSWER\", $level + 1, true));\n //Print answer contents\n fwrite($bf, full_tag(\"ID\", $level + 2, false, $answer->id));\n fwrite($bf, full_tag(\"ANSWER_TEXT\", $level + 2, false, $answer->answer));\n fwrite($bf, full_tag(\"FRACTION\", $level + 2, false, $answer->fraction));\n fwrite($bf, full_tag(\"FEEDBACK\", $level + 2, false, $answer->feedback));\n\n if ($answer->answersound == null) {\n fwrite($bf, full_tag(\"ANSWERSOUND\", $level + 2, false, ''));\n } else {\n fwrite($bf, full_tag(\"ANSWERSOUND\", $level + 2, false, $answer->answersound));\n }\n\n if ($answer->feedbacksound == null) {\n fwrite($bf, full_tag(\"FEEDBACKSOUND\", $level + 2, false, ''));\n } else {\n fwrite($bf, full_tag(\"FEEDBACKSOUND\", $level + 2, false, $answer->feedbacksound));\n }\n\n if ($answer->tur_answer_truefalse == null) {\n fwrite($bf, full_tag(\"TUR_ANSWER_TRUEFALSE\", $level + 2, false, ''));\n } else {\n fwrite($bf, full_tag(\"TUR_ANSWER_TRUEFALSE\", $level + 2, false, $answer->tur_answer_truefalse));\n }\n\n $status = $status && fwrite($bf, end_tag(\"ANSWER\", $level + 1, true));\n }\n $status = $status && fwrite($bf, end_tag(\"ANSWERS\", $level, true));\n }\n\n //Now print question_answers\n // $status = question_backup_answers($bf, $preferences, $question);\n }\n return $status;\n }", "public abstract function save();", "public function testSave() {\n\t\t$temaBuscar = new Tema;\n\t\t$temaBuscar->nombre = 'Prueba';\n\t\t$this->assertEquals( count( $temaBuscar->search()->getData() ), 0 );\n\t\n\t\t// guarda el tema\n\t\t$tema = new Tema;\n\t\t$tema->nombre = 'Prueba';\n\t\t$tema->responsable = 1;\n\t\t$tema->save();\n\t\n\t\t$this->assertEquals( count( $temaBuscar->search()->getData() ), 1 );\n\t}", "public function save()\r\n {\r\n //\r\n }", "function beforeSaveLoop()\r\n {\r\n }", "public function save(){\n return parent::writeFile( $this->outputFile, $this->template);\n }", "private function check_DB() {\n $this->record_progress(\n \"Step 4: Identifying which mutations are already in database\");\n\n $path_valid = $this->path_valid;\n $path_new_input = $this->path_new_input;\n\n $table = \"NewSpliceman\";\n\n $this->record_progress(\"1\");\n\n $read_valid = fopen($path_valid, \"r\") or \n die (\"Unable to open file!\");\n $write_new_input = fopen($path_new_input, \"a\") or \n die (\"Unable to open file!\");\n\n $this->record_progress(\"2\");\n\n $valid_mutations = false;\n\n while (! feof($read_valid)) {\n $this->record_progress(\"3\");\n $mutation = fgets($read_valid);\n if (ctype_space($mutation)) {\n break;\n }\n $mutation_data = explode(\"\\t\", $mutation);\n $this->record_progress(\"4\");\n if ($this->is_valid($mutation_data)) {\n $this->record_progress(\"5\");\n $db_key = \n $mutation_data[0].\"_\".$mutation_data[5].\"_\".\n $mutation_data[6].\"_\".$mutation_data[7].\"_\".\n $mutation_data[11].\"_\".$mutation_data[12];\n // Removes newline characters, if they are present\n $db_key = str_replace(\"\\n\", \"\", $db_key);\n $this->record_progress(\"6\");\n $result = DB::table($table)->\n where('chr_loc_wild_mut_transcript_exon', $db_key)->\n first();\n $valid_mutations = true;\n $this->record_progress(\"8\");\n if (count($result) == 0) {\n fwrite($write_new_input, $mutation);\n }\n $this->record_progress(\"9\");\n } \n } \n\n $this->record_progress(\"10\");\n fclose($read_valid);\n fclose($write_new_input);\n\n $this->record_progress(\"11\");\n }", "public function Save()\r\n {\r\n return false;\r\n }", "protected function saveData()\n {\n // TODO: データ保存\n\n // 一次データ削除\n $this->deleteStore();\n\n drupal_set_message($this->t('The form has been saved.'));\n }", "public function save()\n {\n // For V2.0\n }", "function persist() ;", "public function save()\n {\n return false;\n }", "function saveTxT($chatId, $from, $message){\r\r\n $myfile = \"fichero.txt\";\r\r\n //$fichero = file_get_contents($myfile);\r\r\n $txt = $chatId.\"-\".$message.\"-\".$from. \" \\n\";\r\r\n //$fichero.= $txt;\r\r\n\r\r\n file_put_contents($myfile, $txt, FILE_APPEND | LOCK_EX); \r\r\n \r\r\n}", "function save()\n {\n /* remove objectclass GOhard if this is an ogroup tab */\n if(isset($this->parent->by_object['ogroup'])){\n $this->objectclasses = array();\n }\n\n plugin::save();\n\n /* Strip out 'default' values */\n foreach(array(\"gotoXMethod\",\"gotoXDriver\", \"gotoXResolution\", \"gotoXColordepth\",\n \"gotoLpdServer\", \"gotoXKbModel\", \"gotoXKbLayout\",\n \"gotoXKbVariant\", \"gotoXMouseType\", \"gotoXMouseport\") as $val){\n\n if ($this->attrs[$val] == \"default\"){\n $this->attrs[$val]= array();\n }\n }\n\n if($this->gotoXMethod == \"default\"){\n $this->attrs['gotoXdmcpServer'] = array();\n $this->attrs['gotoXMethod'] = array();\n }else{\n $this->attrs['gotoXdmcpServer'] = array_values($this->selected_xdmcp_servers);\n }\n\n\n if($this->AutoSync){\n $this->attrs['gotoXHsync'] = \"30+55\";\n $this->attrs['gotoXVsync'] = \"50+70\";\n }\n\n /* Write back to ldap */\n $ldap= $this->config->get_ldap_link();\n $ldap->cd($this->dn);\n $this->cleanup();\n $ldap->modify ($this->attrs); \n new log(\"modify\",\"terminal/\".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());\n\n if (!$ldap->success()){\n msg_dialog::display(_(\"LDAP error\"), msgPool::ldaperror($ldap->get_error(), $this->dn, LDAP_MOD, get_class()));\n }\n $this->handle_post_events(\"modify\");\n\n /* Send goto reload event */\n if(count($this->attrs)){\n $this->send_goto_reload();\n }\n }", "public static function Guardar($unAuto)\n {\n//var_dump($unAuto);\n $archivo = fopen(\"Archivos/estacionados.txt\", \"a\");\n $renglon = $unAuto->patente.\"--\".$unAuto->fechIngreso.\"\\n\";\n \n fwrite($archivo, $renglon);\n fclose($archivo);\n }" ]
[ "0.6235355", "0.6001607", "0.5981118", "0.5953967", "0.59170145", "0.59170145", "0.5859388", "0.58337224", "0.5832184", "0.5781754", "0.5767901", "0.57483494", "0.56978834", "0.5679583", "0.5669856", "0.56463945", "0.5623309", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56231767", "0.56205744", "0.56169724", "0.5596745", "0.55925655", "0.55856293", "0.55534434", "0.55400544", "0.5528456", "0.55241466", "0.5518528", "0.5514843", "0.5509972", "0.5509972", "0.55047214", "0.5488083", "0.54768497", "0.54685104", "0.54631245", "0.54631245", "0.54631245", "0.54631245", "0.54631245", "0.5458759", "0.5457468", "0.5457468", "0.545722", "0.5456213", "0.5435363", "0.54196465", "0.54078287", "0.5380466", "0.53797674", "0.53797674", "0.53712034", "0.5361019", "0.5359859", "0.5359556", "0.5356831", "0.53560615", "0.53506726", "0.53433245", "0.53344697", "0.5330188", "0.53145325", "0.53143454", "0.5302848", "0.52948487", "0.5291777", "0.5283259", "0.527963", "0.5276262", "0.52710086", "0.5257396", "0.5252445", "0.5246335", "0.52327543", "0.5228348", "0.52275366", "0.52264315", "0.5224937", "0.5216576", "0.5215499", "0.5212072", "0.5202544", "0.52021486", "0.51957726" ]
0.0
-1