query
stringlengths
11
3.13k
ru_query
stringlengths
9
3.91k
document
stringlengths
18
71k
metadata
dict
negatives
listlengths
0
100
negative_scores
listlengths
0
100
document_score
stringlengths
5
10
document_rank
stringclasses
2 values
Get all agency songs query
Запрос на получение всех песен агентства
public function listAgencySongs($options = array()) { $this->logger->info('get all agency songs'); if (isset($options['filterBy'])) { if ($options['filterBy'] != '0') { $status = $this->getContainer()->get('status.manager')->getStatusByName($options['filterBy']); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getAllSongs()\n {\n $sql = \"SELECT id, artist, track, link FROM song\";\n $query = $this->db->prepare($sql);\n $query->execute();\n\n // fetchAll() is the PDO method that gets all result rows, here in object-style because we defined this in\n // core/controlle...
[ "0.72431135", "0.71882904", "0.7057298", "0.6884623", "0.66123635", "0.63870215", "0.6308103", "0.63077956", "0.6215603", "0.61579037", "0.61378616", "0.61351913", "0.6083352", "0.6068459", "0.60426927", "0.6042515", "0.60332626", "0.6000224", "0.5998828", "0.59642494", "0.59...
0.7238977
1
$data = "zaaaabbbz"; echo ''; print_r(count_chars($data, 1)); die; apple Complete the sherlockAndAnagrams function below.
$data = "zaaaabbbz"; echo ''; print_r(count_chars($data, 1)); die; apple Завершите функцию sherlockAndAnagrams ниже.
function sherlockAndAnagrams($s) { $stringSize=strlen($s); $data=[]; for($i=0;$i<$stringSize;$i++){ for($j=$i;$j<$stringSize;$j++){ for($t=$i;$t<=$j;$t++){ $data[$t][]=countchars($s[$t]); } } } echo '<pre>'; print_r($data); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function mb_count_chars($input) {\r\n\t\t$l = mb_strlen($input);\r\n\t\t$unique = array();\r\n\t\tfor($i = 0; $i < $l; $i++) {\r\n\t\t\t$char = mb_substr($input, $i, 1);\r\n\t\t\tif(!array_key_exists($char, $unique))\r\n\t\t\t\t$unique[$char] = 0;\r\n\t\t\t$unique[$char]++;\r\n\t\t}\r\n\t\treturn $unique;\r\n\t}",...
[ "0.70529413", "0.69130886", "0.68048847", "0.679945", "0.675338", "0.6726997", "0.6604129", "0.6516947", "0.6382625", "0.63605124", "0.6256747", "0.6214705", "0.6211156", "0.6205713", "0.6164726", "0.614443", "0.61122096", "0.6111797", "0.6110231", "0.6066406", "0.6034416", ...
0.79782844
0
Get verses from a version and a book.
Получить стихи из версии и книги.
public function getVersesFromBook($version, $book) { $this->currentVersion = $version; $this->currentBook = $book; $key_version_book = $this->currentVersion . '.' . $this->currentBook; if (empty($this->verses[$key_version_book])) { $path = $this->root . '/' . self::SOURCE_D...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getVersesFromSearch($pattern, $version = '', $book = '', $chapter = '') {\n return [];\n }", "public function getVerses($languages, $book, $chapter, $start=1, $end=1000)\n\t{\n\t\tif (!is_array($languages))\n\t\t{\n\t\t\t$languages = array($languages);\n\t\t}\n\t\t$escaped_languages = a...
[ "0.70361674", "0.66012734", "0.6377102", "0.5879556", "0.55549663", "0.5376883", "0.53600425", "0.5263525", "0.52581066", "0.5256107", "0.5256107", "0.5256107", "0.50677586", "0.5066135", "0.4978401", "0.4974996", "0.4914546", "0.48928523", "0.48465762", "0.4835752", "0.48335...
0.77417
0
Get specific verse from version, book, chapter and verse num.
Получить конкретный стих из версии, книги, главы и номера стиха.
public function getVerse($version, $book, $chapter, $num_verse) { $verse = ''; $verses = $this->getVersesFromBook($version, $book); if (!empty($verses[$chapter])) { $this->currentChapter = $chapter; if (empty($verses[$chapter][$num_verse])) { if (intval(...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getVersesFromBook($version, $book) {\n $this->currentVersion = $version;\n $this->currentBook = $book;\n\n $key_version_book = $this->currentVersion . '.' . $this->currentBook;\n\n if (empty($this->verses[$key_version_book])) {\n $path = $this->root . '/' . se...
[ "0.6401741", "0.5493571", "0.5457608", "0.54396063", "0.5380094", "0.53511435", "0.53470546", "0.53080356", "0.52973187", "0.52934057", "0.5283502", "0.527333", "0.5223513", "0.5205335", "0.51704603", "0.5128763", "0.5127185", "0.5126973", "0.5124589", "0.5104931", "0.5080846...
0.74903554
0
Generated from protobuf field uint32 k1 = 1;
Сгенерировано из поля protobuf uint32 k1 = 1;
public function setK1($var) { GPBUtil::checkUint32($var); $this->k1 = $var; return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getK1()\n {\n return $this->k1;\n }", "function readInt1(): int {\n return \\ord($this->read(1));\n }", "public function readS1(): int {\n return unpack(\"c\", $this->readBytes(1))[1];\n }", "public function getGcId1()\n {\n return $this->gc_id_1;\n ...
[ "0.65307266", "0.5384124", "0.5113928", "0.5039523", "0.5018321", "0.49934477", "0.49183547", "0.48937824", "0.48714194", "0.4863486", "0.48521677", "0.48301703", "0.47981957", "0.47853425", "0.47028795", "0.46365845", "0.4597094", "0.45903552", "0.4585363", "0.4583517", "0.4...
0.7497993
0
Generated from protobuf field uint32 k2 = 2;
Сгенерировано из поля protobuf uint32 k2 = 2;
public function setK2($var) { GPBUtil::checkUint32($var); $this->k2 = $var; return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getK2()\n {\n return $this->k2;\n }", "public function getShntkey2()\n {\n return $this->shntkey2;\n }", "function readInt2(): int {\n return \\unpack('v', $this->read(2))[1];\n }", "public function getType2()\n {\n return $this->type2;\n }", ...
[ "0.68140364", "0.60437846", "0.59764814", "0.58666843", "0.5634133", "0.5634133", "0.5633348", "0.5633348", "0.5622412", "0.5508606", "0.54635984", "0.5410077", "0.5399563", "0.5360213", "0.5345197", "0.5292951", "0.52767813", "0.52758634", "0.5261033", "0.52203816", "0.52189...
0.7691903
0
Delete all previously compiled JMESPath files from the JP_COMPILE_DIR directory or sys_get_temp_dir().
Удалите все ранее скомпилированные файлы JMESPath из каталога JP_COMPILE_DIR или sys_get_temp_dir().
public static function cleanCompileDir() { $total = 0; $compileDir = self::getEnvVariable(self::COMPILE_DIR) ?: sys_get_temp_dir(); foreach (glob("{$compileDir}/jmespath_*.php") as $file) { $total++; unlink($file); } return $total; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function clearCompileDir();", "public function emptyCompileDir()\n {\n $this->console(\"Deleting compiled assets\");\n $dir = $this->compilePath() . $this->prefix();\n if (is_dir($dir)) {\n Rails\\Toolbox\\FileTools::emptyDir($dir);\n }\n }", "protected funct...
[ "0.67920256", "0.6744104", "0.66824263", "0.6404778", "0.63608074", "0.63010216", "0.6222713", "0.6214783", "0.61654854", "0.6157714", "0.61537755", "0.60848224", "0.6013993", "0.5975246", "0.59653705", "0.59628814", "0.59578073", "0.5910919", "0.58898413", "0.5869812", "0.58...
0.7789213
0
Remove a stat from the stats list
Удалить стат из списка статов
public function removeStat($stat) { if (isset($this->stats[$stat])) { unset($this->stats[$stat]); } return $this; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function remove();", "public function remove();", "public function remove();", "public function remove();", "public static function decrement($stat, $sampleRate = 1)\n\t{\n\t\tif (self::$instance)\n\t\t{\n\t\t\tself::$instance->decrement($stat, $sampleRate);\n\t\t}\n\t}", "public function remove()...
[ "0.60061944", "0.60061944", "0.60061944", "0.60061944", "0.5805825", "0.57828605", "0.5781403", "0.5676479", "0.5674141", "0.5579617", "0.5556414", "0.55489117", "0.554565", "0.551013", "0.5489859", "0.54619896", "0.54619896", "0.54619896", "0.5451993", "0.53886235", "0.53651...
0.75766253
0
===================================================================================================================================== Script to show keywords for edit_category.php by taking the 's through long_description and pulling them from their and echoing them on the page.JC
===================================================================================================================================== Скрипт для отображения ключевых слов для edit_category.php, используя 's из long_description и извлекая их, а затем отображая на странице.JC
function h_keywords($cat_id){ connect(); $cp_id = clean_input($cat_id); // if(!empty($_GET['cat_id'])){ $xyquery = "SELECT cat_desc_long FROM categories WHERE cat_id = '$cp_id'"; $xyresult = mysql_query($xyquery) or die(mysql_error()); list($cat_desc_long)= mysql_fetch_row($...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function keywords_and_description($submit_keywords, $keywords, $seo_desc){\n\t\tif( isset($_POST[$submit_keywords]) ){\n\t\t\t$key_words = $_POST[$keywords];\n\t\t\t$short_desc = $_POST[$seo_desc]; \n\t\t\tuser::update_key_words($key_words, $short_desc);\n\n\t\t\t\theader(\"location: ../../basic_info.php\");\n\t\...
[ "0.6753122", "0.6101297", "0.5853824", "0.58054376", "0.57933336", "0.57817376", "0.5715765", "0.57138956", "0.5708326", "0.5692844", "0.56768507", "0.5667813", "0.5647166", "0.56318337", "0.56032556", "0.5586414", "0.55723566", "0.55543685", "0.553143", "0.5517482", "0.54197...
0.7296867
0
Get the admin user currently the first user
Получить администратора пользователя, который сейчас первый пользователь
public static function getAdminUser() { return User::find(1); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getAdminUser()\n {\n return $this->registry->registry('current_admin_user');\n }", "public function getUser()\n {\n if ($this->_user === null) {\n $this->_user = Admin::findByUsernameOrEmail($this->username);\n }\n\n return $this->_user;\n }", ...
[ "0.84018886", "0.7727872", "0.76227933", "0.7606734", "0.75470734", "0.7527008", "0.75168604", "0.7466795", "0.7459963", "0.74101293", "0.7361626", "0.7313079", "0.73081994", "0.7253888", "0.72390807", "0.72266114", "0.722531", "0.7208659", "0.7200034", "0.71588975", "0.71550...
0.8079319
1
Return User ID given the uid
Вернуть идентификатор пользователя по uid
public static function idByUID($uid=NULL) { if($uid!=NULL) { try { $count = User::where('uid', $uid)->count(); if($count > 0) { $user = User::where('uid', $uid)->orderBy('uid', 'asc')->first(); return $user->id; } else { return ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function get_user_id();", "public function getUserID() {\n\t\tif (is_numeric($this->user_id)) {\n\t\t\treturn $this->user_id;\n\t\t} else {\n\t\t\treturn 0;\n\t\t}\n\t}", "public function user_id()\n {\n if($this->logged_in())\n {\n $this->uid = $this->fb->getUser();\n\n ...
[ "0.76118904", "0.7504404", "0.7483609", "0.7463698", "0.7408067", "0.74007976", "0.74007976", "0.7382242", "0.73641473", "0.73273796", "0.72995555", "0.7286024", "0.72808284", "0.72765416", "0.72366446", "0.7208425", "0.7203845", "0.72033554", "0.72033554", "0.7191575", "0.71...
0.77616596
0
Check if user is County Coordinator
Проверить, является ли пользователь координатором округа
public function isCountyCoordinator() { if($this->hasRole('County Coordinator')) return true; else return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isSubCountyCoordinator()\n {\n if($this->hasRole('Sub-County Coordinator'))\n return true;\n else\n return false;\n }", "public function isCoordinator()\n {\n return true;\n }", "function isLocationowner(){\r\n\t\tif($this->user_type == 'Lo...
[ "0.7535716", "0.6053562", "0.6044405", "0.58115023", "0.5796062", "0.5751929", "0.5730707", "0.5690006", "0.5671106", "0.5658872", "0.56588477", "0.5642403", "0.5589372", "0.5577614", "0.5566498", "0.55545264", "0.5549765", "0.5530778", "0.5524514", "0.5519866", "0.55149513",...
0.8210573
0
Check if user is SubCounty Coordinator
Проверьте, является ли пользователь координатором подконтрольного района
public function isSubCountyCoordinator() { if($this->hasRole('Sub-County Coordinator')) return true; else return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isCountyCoordinator()\n {\n if($this->hasRole('County Coordinator'))\n return true;\n else\n return false;\n }", "public function authorize()\n {\n $user = Auth::user();\n $vendor = $user->vendor->first();\n $isOwner = AvailableFac...
[ "0.7882251", "0.5668685", "0.5636365", "0.5611596", "0.5592822", "0.55721277", "0.55383396", "0.5533039", "0.5505834", "0.54478776", "0.54244983", "0.54087293", "0.5400777", "0.53915703", "0.5390536", "0.53847206", "0.5359399", "0.53287935", "0.53170514", "0.5308279", "0.5304...
0.8661962
0
Check if user is Facility Incharge
Проверьте, является ли пользователь ответственным за объект
public function isFacilityInCharge() { if($this->hasRole('Facility Incharge')) return true; else return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function is_surveillant() {\n return $this->session->get(\"niveau_acces\") >= 1;\n }", "public function authorize()\n {\n $user = Auth::user();\n $vendor = $user->vendor->first();\n $isOwner = AvailableFacility::where(array(\n 'id' => $this->id,\n 'v...
[ "0.630462", "0.6184805", "0.5872232", "0.5842067", "0.575935", "0.57426095", "0.5719446", "0.5679371", "0.5669482", "0.56660146", "0.56546515", "0.5571567", "0.5567748", "0.55671775", "0.55530953", "0.554833", "0.55293983", "0.54921997", "0.5484075", "0.5470004", "0.54687905"...
0.8117545
0
Check if user is Participant
Проверьте, является ли пользователь участником
public function isParticipant() { if($this->hasRole('Participant')) return true; else return false; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isParticipant(UserInterface $user);", "public function isParticipant(ParticipantInterface $participant): bool;", "public function hasParticipant() {\n return $this->_has(1);\n }", "public function isParticipating($id_user, $id_event) {\n \t//$participants = Participant::where('id_u...
[ "0.84697646", "0.72232485", "0.7168724", "0.6786317", "0.64915764", "0.6464204", "0.6382016", "0.6237943", "0.6220379", "0.6180759", "0.61654156", "0.61654156", "0.61565167", "0.6146793", "0.61284125", "0.61182296", "0.61182296", "0.6090114", "0.6076919", "0.6066084", "0.6058...
0.8032927
1
================================================================================================================= CREATE (GLOBAL) Attempts to INSERT this Endpoint object, using the class's annotated information via a HTTP POST Request.
================================================================================================================= CREATE (GLOBAL) Пытается ВСТАВИТЬ этот объект Endpoint, используя аннотированную информацию класса через HTTP-запрос POST.
public function insert(): self { /** @var self $data */ $data = $this; if(!$this->validate("post", $missing)) { throw new \Exception("[MVQN\REST\Endpoints\Endpoint] Annotations for the '".get_class($this)."' class require valid values be set ". "on all of...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create() {\n $this->operationsModel->create($_POST);\n $this->response('',200,'Success');\n }", "public function create()\n {\n // handled by client\n }", "public function create()\n {\n //Not Used because using API Route\n }", "public function creat...
[ "0.6362813", "0.6316869", "0.6229014", "0.61709535", "0.60957533", "0.6064938", "0.6052681", "0.6050523", "0.6050523", "0.6050523", "0.6050523", "0.6050359", "0.60379225", "0.60379225", "0.60379225", "0.60379225", "0.60379225", "0.60379225", "0.60379225", "0.60379225", "0.603...
0.72158885
0
================================================================================================================= UPDATE (GLOBAL) Attempts to UPDATE this Endpoint object, using the class's annotated information via a HTTP PATCH Request.
================================================================================================================= ОБНОВЛЕНИЕ (ГОЛОБАЛЬНО) Попытка обновить объект Endpoint с использованием аннотированной информации класса через HTTP-запрос PATCH.
public function update(): self { /** @var self $data */ $data = $this; if(!$this->validate("patch", $missing)) { throw new \Exception("[MVQN\REST\Endpoints\Endpoint] Annotations for the '".get_class($this)."' class require valid values be set ". "on all o...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function update() {}", "public function update($params = []) {\n\t\tif(is_null($this->update_endpoint)) {\n\t\t\tthrow new BadMethodCallException('method not supported on this resource');\n\t\t}\n\n\t\t$params = array_merge($this->data,$params);\n\t\t$uri = $this->substitute($this->update_endpoint,$par...
[ "0.6512929", "0.65069854", "0.63918966", "0.63918966", "0.6364106", "0.63241416", "0.62941736", "0.62679046", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", "0.62506187", ...
0.7217586
0
Genera una clave y la almacena en el objeto.
Создает ключ и сохраняет его в объекте.
function GenerarClave() { $this->Clave = CifradorCodigo::generarNumero( CifradorCodigo::LongitudBitsClaveMaximo ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function generaClave()\n {\n do {\n $clave = '';\n for ($i = 0; $i < 3; $i++) {\n $clave .= strtoupper(substr(uniqid(), -5));\n $clave .= $i != 2 ? '-' : '';\n }\n } while (!$this->claveValida($clave) && !$this->claveUnica($clav...
[ "0.67522526", "0.641119", "0.6335741", "0.62332034", "0.6222211", "0.6185842", "0.6154997", "0.59090173", "0.5885199", "0.5865318", "0.5865029", "0.5772361", "0.5770268", "0.57503283", "0.5741449", "0.56955296", "0.5679185", "0.56678635", "0.5667105", "0.56306636", "0.5602636...
0.75056225
0
Genera un serial y lo almacena en el objeto.
Генерирует серийный номер и сохраняет его в объекте.
function GenerarSerial() { $this->Serial = CifradorCodigo::generarNumero( CifradorCodigo::LongitudBitsSerialMaximo ); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __toString() : string\n {\n return 'Serial';\n }", "public function serial() : string;", "function serialise(): string;", "public function toSerial() {\n\t\treturn serialize($this->toArray());\n\t}", "public function serialize() {}", "public function serialize() {}", "publi...
[ "0.7486921", "0.7181321", "0.64285606", "0.64146084", "0.61375004", "0.61375004", "0.61375004", "0.61375004", "0.61375004", "0.61375004", "0.6136791", "0.6136791", "0.6068175", "0.6063336", "0.6048051", "0.599123", "0.5935636", "0.5935636", "0.5935636", "0.5875295", "0.587529...
0.8095854
0
Get the panels that are available for the given create request.
Получить панели, доступные для заданного запроса на создание.
public function availablePanelsForCreate($request) { $panels = parent::availablePanelsForCreate($request); $fields = parent::availableFields($request); return $this->mergePanels($panels, $this->findAllContainers($fields)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getPanels() {\n\n $panels = $this->entityManager->getRepository(Panel::class)\n ->findBy([], ['dateCreated' => 'DESC']);\n\n return $panels;\n }", "public function getAvailableTemplate()\r\n {\r\n $panels = $this->_panel->getCollection()\r\n ->addF...
[ "0.70014787", "0.66321355", "0.6572467", "0.61088884", "0.5950702", "0.58218896", "0.57105553", "0.5700029", "0.5680483", "0.5599626", "0.55915666", "0.5574343", "0.55282253", "0.5487623", "0.5411618", "0.5398025", "0.5357091", "0.53320366", "0.5261625", "0.52290255", "0.5226...
0.7844133
0
update email template Booking email
Обновить шаблон электронной почты Бронирование электронной почты
public function manage_email_template($template='') { $template = 'booking-mail'; $this->load->model('admin/admin_model'); $this->gen_contents['page_heading'] = 'Update Email Template'; if($this->input->post("update_et",true)){ $post_data['body'] = $this->input->post("bo...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function update_email_template(Request $request,$enc_id)\n\t{\n\t\t$id = base64_decode($enc_id);\n\t\t\n\t\t$arr_rules = $arr_data = array();\n\t\t$status = false;\n\n\t\t$arr_rules['template_name'] = \"required\";\n\t\t$arr_rules['template_from'] = \"required\";\n\t\t$arr_rules['te...
[ "0.6501877", "0.6321306", "0.6262786", "0.6184559", "0.61806756", "0.61783767", "0.6150989", "0.6146691", "0.61250514", "0.60922945", "0.6092086", "0.6052131", "0.6048267", "0.6039441", "0.6016308", "0.5987147", "0.5893937", "0.5874875", "0.5859097", "0.5845244", "0.58211404"...
0.7405727
0
Create a new user in the database. If $cert and $key are both omitted or NULL, no LGI credentials are setup for the user.
Создайте нового пользователя в базе данных. Если $cert и $key оба опущены или равны NULL, для пользователя не настраиваются учетные данные LGI.
static function create($userid, $password=NULL, $cert=NULL, $key=NULL) { if (!is_null($password)) { $hash = hash_password($password); lgi_mysql_query("INSERT INTO %t(users) SET `name`='%%', `passwd_hash`='%%'", $userid, $hash); } else { lgi_mysql_query("INSERT INTO %t(users) SET `name`='%%'", $userid); }...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private static function create()\n {\n getDb()->putUser(1, self::getDefaultAttributes());\n }", "public function newUser() {\n $this->checkValidUser();\n\n $this->db->sql = 'INSERT INTO '.$this->db->dbTbl['users'].' (username, salt, hash) VALUES (:username, :salt, :hash)';\n\n $salt = $...
[ "0.63251483", "0.6314534", "0.6307529", "0.6216024", "0.6112451", "0.6112451", "0.6112451", "0.6112451", "0.6106193", "0.6091009", "0.60597116", "0.6058162", "0.60116595", "0.59207475", "0.59185773", "0.59066355", "0.5871681", "0.5868075", "0.58477217", "0.57889557", "0.57886...
0.7599278
0
Returns an array with the user's groups. This is cached in the session.
Возвращает массив с группами пользователя. Это значение кэшируется в сессии.
function get_groups() { if (!isset($_SESSION['groups'])) lgi_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); return explode(',', $_SESSION['groups']); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function getCurrentUserGroups()\n {\n return self::getUserGroups();\n }", "private function getGroups()\n {\n $where = '';\n if ($this->userGroups)\n {\n $groups = explode(',', $this->userGroups);\n $where .= \" uid IN ('\" . implode(\"','\", $grou...
[ "0.7811674", "0.7645229", "0.7606774", "0.75354856", "0.750342", "0.73998165", "0.73911107", "0.73485905", "0.7231788", "0.7219584", "0.7073178", "0.7031794", "0.70197296", "0.70110804", "0.699981", "0.6992379", "0.6965181", "0.6956397", "0.6956076", "0.6930042", "0.68494403"...
0.78920835
0
Returns whether the user has a set of fixed groups or can choose any. This is cached in the session.
Возвращает, имеет ли пользователь набор фиксированных групп или может выбрать любые. Это значение кэшируется в сессии.
function get_fixedgroups() { if (!isset($_SESSION['fixedgroups'])) lgi_mysql_fetch_session("SELECT `fixedgroups` AS `fixedgroups` FROM %t(usercerts) WHERE `user`='%%'", $this->userid); return (bool)$_SESSION['fixedgroups']; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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...
[ "0.7027887", "0.68472964", "0.6787906", "0.6720866", "0.66698563", "0.66224974", "0.6585423", "0.6558352", "0.6558352", "0.6496834", "0.6496834", "0.63555926", "0.63314337", "0.63291544", "0.6299951", "0.6237624", "0.6232342", "0.6210802", "0.6193716", "0.61904997", "0.615601...
0.7816075
0
Returns the user's current group
Возвращает текущую группу пользователя
function get_cur_group() { if (!isset($_SESSION['dfl_group'])) { // return comma-separated list of default groups from database lgi_mysql_fetch_session("SELECT GROUP_CONCAT(`name`) AS `dfl_group` FROM %t(usergroups) AS p, %t(usercerts) AS c WHERE p.`usercertid`=c.`id` AND c.`user`='%%' AND p.`dfl`=TRUE", $this-...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getGroup()\n {\n return $this->_getVar('user_group');\n }", "private function getUserGroup()\n {\n if (null !== $token = $this->tokenStorage->getToken()) {\n /** @var \\Ekyna\\Bundle\\UserBundle\\Model\\UserInterface $user */\n if (null !== $user = $to...
[ "0.82793844", "0.7987553", "0.7748155", "0.754359", "0.74784243", "0.7423361", "0.7394486", "0.73592705", "0.7294595", "0.7294595", "0.7294595", "0.7294595", "0.7294595", "0.7294595", "0.7254326", "0.72191596", "0.7179667", "0.71752506", "0.7166884", "0.71402174", "0.71249324...
0.81231874
1
Sets the user's current group
Устанавливает текущую группу пользователя
function set_cur_group($group) { lgi_mysql_query("UPDATE %t(usergroups) SET `dfl`=(`name`='%%') WHERE `usercertid`=(SELECT `id` FROM %t(usercerts) WHERE `user`='%%')", $group, $this->userid); $_SESSION['dfl_group'] = $group; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setGroup( $group )\r\n {\r\n if ( is_a( $group, \"eZUserGroup\" ) )\r\n {\r\n $this->GroupID = $group->id();\r\n }\r\n else if ( is_numeric( $group ) )\r\n {\r\n $this->GroupID = $group;\r\n }\r\n }", "final public function setGroup($...
[ "0.7004378", "0.7002371", "0.6969193", "0.6648605", "0.65929157", "0.6562774", "0.6428268", "0.64272016", "0.6405396", "0.63281244", "0.6280852", "0.62547666", "0.62267125", "0.62229794", "0.6190306", "0.6161342", "0.6151602", "0.6099979", "0.6090076", "0.6085804", "0.608226"...
0.75056934
0
Returns the user's current project
Возвращает текущий проект пользователя
function get_cur_project() { if (!isset($_SESSION['dfl_project'])) { lgi_mysql_fetch_session("SELECT `dfl_project` AS `dfl_project` FROM %t(users) WHERE `name`='%%'", $this->userid); // if not set, return first project found if (!isset($_SESSION['dfl_project'])) lgi_mysql_fetch_session("SELECT `name` AS ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getProject()\r\n {\r\n return $this->_params['project'];\r\n }", "public static function project()\n {\n return self::context()->project();\n }", "public function getProject() {\n return ProjectManager::getActiveProject();\n }", "public function getProject(...
[ "0.79913706", "0.77805257", "0.76155525", "0.7541076", "0.7541076", "0.7541076", "0.75371724", "0.7432717", "0.7420028", "0.72501874", "0.7245786", "0.7070865", "0.69555503", "0.69437224", "0.68691385", "0.6778098", "0.6631666", "0.6623381", "0.6623381", "0.66207707", "0.6484...
0.7934667
1
Test basic getter and setters.
Тестирование базовых getter и setters.
public function testGetterSetter() { $text = new Text('Foo bar', 100); $this->assertEquals($text->text, 'Foo bar'); $this->assertEquals($text->confidence, 100); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testGettersAndSetters()\n {\n $this->phone->setType('phone');\n $this->assertEquals('phone', $this->phone->getType());\n\n $this->phone->setValue('059 70 22 85');\n $this->assertEquals('059 70 22 85', $this->phone->getValue());\n }", "public function testGetValue...
[ "0.74504316", "0.71951616", "0.714431", "0.70956683", "0.70669264", "0.6911544", "0.68973434", "0.68753076", "0.68099713", "0.6793426", "0.6791523", "0.6785153", "0.67659104", "0.67606616", "0.67584157", "0.6753012", "0.67497337", "0.6746458", "0.67416674", "0.66931975", "0.6...
0.72710896
1
Test setting confidence to more than 100.
Тестирование установки доверительной вероятности более чем на 100.
public function testConfidenceMoreThan100() { new Text('Foo bar', 101); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testGetDiscountWithLimit()\n {\n $discountValue= $this->discountProvider->getDiscountValue(\"https://developer.github.com/v3/#http-redirects\",[12,7],60);\n $this->assertEquals(15,$discountValue);\n }", "public function setConfidence($var)\n {\n GPBUtil::checkFloat($...
[ "0.5690967", "0.5610204", "0.5610204", "0.55953085", "0.55367833", "0.5518459", "0.55069643", "0.55037606", "0.53721935", "0.53665745", "0.5363143", "0.5331845", "0.5283995", "0.5231396", "0.52021", "0.52021", "0.51882166", "0.5164025", "0.5156603", "0.5129358", "0.5112678", ...
0.70018923
0
return all fields in tl_module
вернуть все поля из tl_module
public function getModuleFields() { return $this->getOptionData('tl_module'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getAllFields();", "public function getFields();", "public function getFields();", "public function getFields();", "public function getFields();", "public function getFields();", "public function getFields();", "public function getFields() {}", "public function getFields() {}", "pu...
[ "0.78327423", "0.7811271", "0.7811271", "0.7811271", "0.7811271", "0.7811271", "0.7811271", "0.77162254", "0.77162254", "0.77162254", "0.7681421", "0.76534146", "0.76266927", "0.76266927", "0.76266927", "0.76266927", "0.76266927", "0.76114756", "0.75878096", "0.7536246", "0.7...
0.8013034
0
Check if value can be considered NOvalue
Проверить, можно ли значение считать NOvalue
protected function isNoValue($value) { return $value === false || $value === 'N' || $value === 'n' || $value === 'no'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testIsValidNoValue()\n {\n $this->assertTrue($this->uut->isValid());\n }", "public function isFalse()\n {\n \n return !$this->value;\n \n }", "public function getNoValue()\n\t{\n\t\treturn $this->getBehavior()->labelNoValue;\n\t}", "public function not_zero($value)\n\t...
[ "0.6760051", "0.6754908", "0.6752171", "0.6645197", "0.66421884", "0.6547066", "0.65082526", "0.6459386", "0.64541453", "0.64288884", "0.64242035", "0.6395459", "0.63883466", "0.6343351", "0.6269855", "0.62462604", "0.6243028", "0.6238384", "0.6224718", "0.62235284", "0.62230...
0.7951982
0
Check if value can be considered YESvalue
Проверьте, может ли значение считаться YESvalue
protected function isYesValue($value) { return $value === true || $value === 'Y' || $value === 'y' || $value === 'yes'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isTrue($value) {\r\n\treturn is_bool($value) ? $value : (bool)preg_match('/^(1|y|yes|true|on)$/i',(string)$value);\r\n}", "public function isTrue()\n {\n \n return !!$this->value;\n \n }", "public function isMandatory()\n {\n if ($this->value == 'yes') {\n return true;\...
[ "0.6877867", "0.6860067", "0.68411326", "0.6715909", "0.6688762", "0.6618538", "0.65606374", "0.65339494", "0.6529253", "0.6523695", "0.64915645", "0.6444542", "0.64318514", "0.64072347", "0.6359886", "0.63485664", "0.63303417", "0.6300431", "0.6299454", "0.629559", "0.626783...
0.7110595
0
Converting keys of a passed array to UPPER case
Преобразование ключей переданного массива в ВЕРХНИЙ регистр
protected function normalizeKeys(array $arr) { return array_change_key_case($arr, CASE_UPPER); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function arrayToUpper($array) {\r\n foreach ($array AS $key => $value) {\r\n if (is_string($value)) {\r\n $array[$key] = strtoupper(trim($value));\r\n }\r\n }\r\n return $array;\r\n}", "function array_keys_to_lower($array) {\n $rr = [];\n foreach ($array as $k =>...
[ "0.7856162", "0.7576917", "0.71910036", "0.7177122", "0.6877952", "0.6789434", "0.675938", "0.6758337", "0.6717736", "0.6691954", "0.66788363", "0.6676342", "0.65832996", "0.64239526", "0.62513936", "0.62465", "0.62066805", "0.6159514", "0.6097107", "0.605486", "0.600871", ...
0.7974417
0
Form constructor for the Settings / Default Email Address config page.
Конструктор формы для страницы настроек / адреса электронной почты по умолчанию.
function room_reservations_admin_settings_default_email($form, &$form_state) { $options = array( '0' => t('Do not set a default email address.'), '1' => t('Set the default email address equal to the user ID.'), '2' => t('Set the default email address equal to the user ID plus the domain name entered below...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function configure()\n\t{\n\t\t$ui = new FormUI( 'jambo_config' );\n\n\t\t// Add a text control for the address you want the email sent to\n\t\t$send_to = $ui->append( 'text', 'send_to', 'option:jambo__send_to', _t('Where To Send Email: ', 'jambo') );\n\t\t$send_to->add_validator( 'validate_required' );\n\n...
[ "0.6699589", "0.6668533", "0.6594744", "0.64387757", "0.64181954", "0.6314541", "0.62428", "0.61970025", "0.6150757", "0.6140132", "0.6130782", "0.6090605", "0.60899144", "0.60786504", "0.6051308", "0.602608", "0.59934527", "0.59756833", "0.5973216", "0.5963676", "0.5958532",...
0.70523286
0
Form validation for the Settings / Default Email Address config page.
Проверка формы для страницы настроек / адрес электронной почты по умолчанию.
function room_reservations_admin_settings_default_email_validate( $form_id, &$form_state) { if ($form_state['clicked_button']['#value'] == t('Save configuration')) { $option = $form_state['values']['options']; $domain = trim($form_state['values']['domain']); if (($option == 2) && (!$domain)) { $fi...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function room_reservations_admin_settings_email_validate($form_id, &$form_state) {\n if ($form_state['clicked_button']['#value'] == t('Save configuration')) {\n $from_address = $form_state['values']['from_address'];\n if (valid_email_address($from_address)) {\n // Valid.\n }\n else {\n $fiel...
[ "0.7399588", "0.72420967", "0.7083556", "0.6979335", "0.6875855", "0.6857015", "0.6760155", "0.66937315", "0.66867536", "0.6681443", "0.6606728", "0.65792143", "0.6546812", "0.65212375", "0.65184414", "0.6490989", "0.6388742", "0.63734674", "0.63684595", "0.63625747", "0.6309...
0.7834429
0
Form submission for the Settings / Default Email Address config page.
Форма отправки для страницы настроек / адрес электронной почты по умолчанию.
function room_reservations_admin_settings_default_email_submit($form_id, &$form_state) { if ($form_state['clicked_button']['#value'] == t('Save configuration')) { $option = $form_state['values']['options']; $domain = trim($form_state['values']['domain']); $confirmation = ROOM_RESERVATIONS_SAVE_CONFIRMATIO...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function room_reservations_admin_settings_default_email($form, &$form_state) {\n $options = array(\n '0' => t('Do not set a default email address.'),\n '1' => t('Set the default email address equal to the user ID.'),\n '2' => t('Set the default email address equal to the user ID plus the domain name ente...
[ "0.7559138", "0.6896598", "0.6653702", "0.65696615", "0.6522046", "0.6507575", "0.64880085", "0.646263", "0.6461662", "0.64456904", "0.64304125", "0.63851583", "0.63136375", "0.62911725", "0.6187509", "0.6167545", "0.615434", "0.614885", "0.6142799", "0.61229557", "0.6093253"...
0.80326813
0
Form submission for the Settings / Reminders configuration page.
Форма отправки для страницы настроек / напоминания.
function room_reservations_admin_settings_reminders_submit($form_id, &$form_state) { if ($form_state['clicked_button']['#value'] == t('Save configuration')) { $send_reminders = $form_state['values']['send_reminders']; $reminder_time = $form_state['values']['reminder_time']; $reminder_cutoff = $form_state[...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function room_reservations_admin_settings_email_submit($form_id, &$form_state) {\n if ($form_state['clicked_button']['#value'] == t('Save configuration')) {\n $from_address = $form_state['values']['from_address'];\n $confirmation_header = $form_state['values']['confirmation_header'];\n $confirmation_owne...
[ "0.68266284", "0.66509336", "0.65307397", "0.6522413", "0.65213937", "0.6459028", "0.6448973", "0.6420151", "0.6413463", "0.63649213", "0.63585955", "0.6334275", "0.6331288", "0.63168037", "0.6307329", "0.63059443", "0.62965363", "0.6257144", "0.62453884", "0.6241739", "0.620...
0.71838605
0
Form validation for the Settings / Reminders configuration page.
Проверка формы для страницы настроек / напоминаний.
function room_reservations_admin_settings_reminders_validate($form_id, &$form_state) { if ($form_state['clicked_button']['#value'] == t('Save configuration')) { $reminder_time = $form_state['values']['reminder_time']; $reminder_cutoff = $form_state['values']['reminder_cutoff']; if ($reminder_time < $remin...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function redmine_sso_admin_settings_validate($form, $form_state) {\n /**\n * TODO\n * check url\n * check if group exsists\n * check if project exsists\n */\n}", "function pdfbulletin_settings_form_validate(&$form, &$form_state) {\n // @todo SERIOUSLY\n}", "private function _validate_settings()\n\t...
[ "0.6922141", "0.6860822", "0.6790697", "0.6494389", "0.64720094", "0.64486766", "0.64100295", "0.6353603", "0.6254033", "0.62037575", "0.61633706", "0.61352056", "0.61334896", "0.6114142", "0.6101969", "0.60994273", "0.60917944", "0.60868746", "0.6064003", "0.6063941", "0.604...
0.70786077
0
Form submission for the Settings / Mobile config page.
Форма отправки для страницы Настройки / Мобильная конфигурация.
function room_reservations_admin_settings_mobile_submit($form_id, &$form_state) { if ($form_state['clicked_button']['#value'] == t('Save configuration')) { $mobile_url = trim($form_state['values']['mobile_url']); $main_database = trim($form_state['values']['main_database']); $confirmation = ROOM_RESERVATI...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ssbd_staticpage_settings_form($form, &$form_state) {\n $form['ssbd_staticpage_simulate_mobile'] = array(\n '#title' => t('Simulate Mobile'),\n '#type' => 'checkbox',\n '#required' => FALSE,\n '#default_value' => variable_get('ssbd_staticpage_simulate_mobile', NULL),\n );\n\n $form['submit']...
[ "0.76225555", "0.71850854", "0.70313656", "0.6904426", "0.67175114", "0.6703145", "0.6672524", "0.6624761", "0.6542768", "0.6539534", "0.6538537", "0.6537689", "0.6449808", "0.6436906", "0.6423973", "0.6415788", "0.6410898", "0.6377675", "0.6374519", "0.63722324", "0.63705724...
0.7458557
1
Form submission for the Hours / Daily Hours configuration page.
Форма отправки для страницы настройки часов / ежедневных часов.
function room_reservations_admin_settings_daily_hours_submit($form_id, &$form_state) { // Select month. if ($form_state['clicked_button']['#value'] == t('Select a month')) { $form_state['redirect'] = 'admin/config/system/room_reservations/hours/daily_hours/' . $form_state['values']['month']; } /...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function room_reservations_admin_settings_default_hours_submit($form_id, &$form_state) {\n $default_hours = array();\n if ($form_state['clicked_button']['#value'] == t('Save configuration')) {\n for ($day = 0; $day < 7; $day++) {\n $default_hours[] = $form_state['values']['day_' . $day]['first_shift_open...
[ "0.6567043", "0.65431494", "0.64769363", "0.6450958", "0.64235073", "0.6135308", "0.6070914", "0.59318346", "0.5770438", "0.5725858", "0.56991094", "0.567549", "0.5673166", "0.563734", "0.5528911", "0.5504294", "0.54557294", "0.5432114", "0.5431034", "0.5357269", "0.5344424",...
0.7169916
0
Form validation for the SMS / Add Carrier configuration page.
Проверка формы для страницы настройки SMS / Добавить оператора.
function room_reservations_admin_settings_sms_add_validate($form_id, &$form_state) { if ($form_state['clicked_button']['#value'] == t('Add')) { $carrier = $form_state['values']['carrier']; $domain = $form_state['values']['domain']; if (!$carrier) { $field = 'add_carrier][carrier'; $message = t...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function room_reservations_admin_settings_sms_delete_validate($form_id, &$form_state) {\n if ($form_state['clicked_button']['#value'] == t('Delete')) {\n $carrier = $form_state['values']['carrier'];\n if (!$carrier) {\n $field = 'delete_carrier][carrier';\n $message = t('Wireless carrier is requir...
[ "0.6272369", "0.6220238", "0.6210996", "0.6179887", "0.61575353", "0.6094786", "0.6086658", "0.60609907", "0.6034559", "0.60080296", "0.5986142", "0.5983774", "0.59793806", "0.5956614", "0.59499675", "0.59474665", "0.5930106", "0.592078", "0.591993", "0.5900628", "0.5896878",...
0.7387934
0
Return the attribute codes for all attributes currently used in configurable products.
Верните коды атрибутов для всех атрибутов, которые в настоящее время используются в продуктовых конфигурациях.
public function getConfigurableAttributes() { $connection = $this->_frameworkModelResource->getConnection("core_write"); $select = $connection->select(); $select->from( ["a" => $this->_frameworkModelResource->getTableName("eav_attribute")], ["attribute" => "a.attribut...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function getAvataxAttributesCode()\n {\n $store = $this->storeManager->getStore();\n $attributesCode = [];\n\n $attributesCode[] = $this->configHelper->getFirstReferenceCode($store);\n $attributesCode[] = $this->configHelper->getSecondReferenceCode($store);\n\n\n if ...
[ "0.75357944", "0.68951845", "0.68629783", "0.68481785", "0.6753887", "0.6734485", "0.6699742", "0.6541152", "0.65349275", "0.6433573", "0.63902277", "0.63902277", "0.63859546", "0.6385899", "0.63857967", "0.6375184", "0.6374667", "0.6345969", "0.63369465", "0.63369465", "0.63...
0.77876896
0
Return a list of all Magento attributes that are used by Product Sync when collecting product data.
Вернуть список всех атрибутов Magento, которые используются Product Sync при сборе данных о продуктах.
public function getUsedMagentoAttributes() { $attributeMapValues = array_values($this->getAttributeMap()); $flatAttributesArray = array_merge(...$attributeMapValues); $result = array_merge($flatAttributesArray, $this->getConfigurableAttributes()); return array_unique($result); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function listProductAttributes(): Collection\n {\n return $this->model->attributes()->get();\n }", "public function getProductAttributes()\n\t{\n\t\treturn $this->arrAttributes;\n\t}", "public function getAttributes()\n {\n /* @var $attributes Mage_Catalog_Model_Resource_Eav_Resou...
[ "0.76181275", "0.7313416", "0.7260181", "0.72260576", "0.71714866", "0.6969994", "0.6969994", "0.69243723", "0.69152033", "0.6913765", "0.69007015", "0.6891886", "0.6854286", "0.6847423", "0.68386906", "0.6798432", "0.6793431", "0.6694994", "0.66322535", "0.6611094", "0.65903...
0.7680629
0
chaque forme a sa propre fonction Draw() et recoit l'instance du SvgRenderer
каждая форма имеет свою собственную функцию Draw() и получает экземпляр SvgRenderer
public function draw($svgRenderer){ // la fonction draw appelle la fonction du renderer dont elle a besoin, en lui envoyant les parametres $svgRenderer->drawCircle($this->color, $this->x, $this->y, $this->opacity, $this->rayon); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function draw(SvgRenderer $renderer) {\n try {\n $renderer->drawRectangle($this->location->x,\n $this->location->y,\n $this->width,\n $this->height,\n ...
[ "0.69131064", "0.6903684", "0.68629116", "0.68629116", "0.67589456", "0.6624275", "0.64266956", "0.637072", "0.6326063", "0.6311773", "0.62690705", "0.62394583", "0.62074125", "0.601462", "0.60110205", "0.59837407", "0.5941463", "0.5929279", "0.59178126", "0.58853453", "0.582...
0.71809417
0
Return the Shoptimally server url
Верните URL-адрес сервера Shoptimally
public function getServerUrl() { return $this->_shoptimallyDomain; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getServerUrl() {\n return $this->conn->getServerUrl();\n }", "function create_short_server_url()\n\t{\n\t\t// usage: $server_url = create_short_server_url();\n\t\tglobal $config;\n\n\t\tif (!empty($config['short_site_url']))\n\t\t{\n\t\t\treturn $config['short_site_url'];\n\t\t}\n\n\t\t$serve...
[ "0.77528983", "0.7580038", "0.75591004", "0.75382996", "0.7468451", "0.72993666", "0.72095436", "0.71310747", "0.6994375", "0.698615", "0.69674164", "0.6932052", "0.690589", "0.68949014", "0.6890573", "0.68855315", "0.6883455", "0.6862323", "0.6847014", "0.6803953", "0.680374...
0.81760305
0
Return if the shoptimally js file should be loaded in async mode or not
Вернуть, следует ли загружать файл shoptimally js в асинхронном режиме
public function shouldLoadJsAsync() { return (!$this->_remoteConfig->get("javascript_synced")); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isAsync();", "public function isAsync(): bool\n {\n return $this->async;\n }", "public static function is_loading_fonts_async() {\n\t\treturn ! empty( get_option( static::ENABLE_ASYNC_FONTS_LOAD, 0 ) );\n\t}", "public function isAsync()\n {\n return $this->async;\n }...
[ "0.6862745", "0.6744029", "0.6712746", "0.67093897", "0.6676919", "0.63030076", "0.62526053", "0.61136675", "0.60864675", "0.59783345", "0.5844328", "0.5837579", "0.5824437", "0.5787508", "0.5773411", "0.57677233", "0.5690009", "0.5678609", "0.5645875", "0.5636723", "0.561094...
0.8186165
0
Clean value map mappings array from empty records when both value and newvalue are empty strings.
Очистить массив отображений карты значений от записей с пустыми значениями, когда и значение, и newvalue являются пустыми строками.
function cleanValueMapMappings(array $mappings) { $cleanedMappings = $mappings; foreach ($cleanedMappings as $key => $mapping) { if (zbx_empty($mapping['value']) && zbx_empty($mapping['newvalue'])) { unset($cleanedMappings[$key]); } } return $cleanedMappings; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function remove_empty_items($old_array, $mantain_keys=FALSE)\n{\n\t$new_array = array();\n\tforeach($old_array AS $key=>$value)\n\t{\n\t\tif(trim($value) != ''){\n\t\t\tif($mantain_keys)\n\t\t\t{\n\t\t\t\t$new_array[$key] = $value;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tarray_push($new_array, $value);\n\t\t\t}\n\t...
[ "0.6188501", "0.61120784", "0.61120784", "0.6060745", "0.6006872", "0.5983826", "0.5898763", "0.5881204", "0.5864059", "0.5776346", "0.573751", "0.55342996", "0.55290204", "0.5498653", "0.5417125", "0.5414063", "0.5380241", "0.53649914", "0.53649914", "0.53271174", "0.5304725...
0.722858
0
Add new mappings to value map.
Добавить новые отображения в карту значений.
function addValueMapMappings($valueMapId, array $mappings) { foreach ($mappings as &$mapping) { $mapping['valuemapid'] = $valueMapId; } unset($mapping); DB::insert('mappings', $mappings); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function addMapping($key, $value)\n {\n $this->mappings[] = array($key, $value);\n }", "function addValueMap(array $valueMap, array $mappings) {\n\t$mappings = cleanValueMapMappings($mappings);\n\tcheckValueMapMappings($mappings);\n\n\t// check duplicate name\n\t$sql = 'SELECT v.valuemapid'.\...
[ "0.73182076", "0.669279", "0.6224705", "0.60660446", "0.5949096", "0.591477", "0.5786055", "0.5690248", "0.568357", "0.56457406", "0.5631266", "0.55204934", "0.5512744", "0.55067956", "0.5459984", "0.5445905", "0.53500444", "0.53463924", "0.5346215", "0.53440773", "0.53285074...
0.7024002
1
Delete value map mappings.
Удалить отображения значений карты.
function deleteValueMapMappings(array $mappingIds) { DB::delete('mappings', array('mappingid' => $mappingIds)); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function deleteTagMaps()\n {\n foreach ($this->tags as $tag) {\n $tag->tagObjectMap->delete();\n }\n }", "function delete_map ($data) {\r\n\t\t$id = (int)$data['id'];\r\n\t\t$table = $this->get_table_name();\r\n\r\n\t\t$result = $this->wpdb->query(\"DELETE FROM {$table} WHERE id={$id}\");\r\n...
[ "0.6806786", "0.64383763", "0.6337173", "0.62842804", "0.61903334", "0.617208", "0.6073436", "0.6038076", "0.5989403", "0.5945934", "0.5913351", "0.5847852", "0.58337116", "0.5768562", "0.5741361", "0.57350725", "0.5716198", "0.5712116", "0.56711376", "0.5667968", "0.5663113"...
0.7379874
0
Apply value mapping to value. If value map or mapping is not found unchanged value returned, otherwise mapped value returned in format: " ()".
Применить отображение значений к значению. Если отображение значений или отображение не найдено, возвращается исходное значение, иначе возвращается отображённое значение в формате: " ()".
function applyValueMap($value, $valueMapId) { $mapping = getMappedValue($value, $valueMapId); return ($mapping === false) ? $value : $mapping.' ('.$value.')'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function applyValue($value);", "protected function transform($value)\n {\n if (null === $this->valueTransformer) {\n return null === $value ? '' : $value;\n }\n return $this->valueTransformer->transform($value);\n }", "function null2unknown($map, $key) {\n if...
[ "0.55988777", "0.5563938", "0.5532002", "0.548586", "0.54554796", "0.5446946", "0.53497505", "0.5325787", "0.5282259", "0.5274987", "0.52523035", "0.5205782", "0.51891816", "0.515676", "0.5149222", "0.51433116", "0.5126327", "0.5110513", "0.5101121", "0.509759", "0.50580055",...
0.7567082
0
Check, that checkEntitesChanged returns true, when cron was never executed.
Проверьте, что checkEntitesChanged возвращает true, когда cron никогда не выполнялся.
public function testNothingModified() { $check = $this->_cs->checkEntitiesChanged(rand(0, 9999), array(self::ENTITY_NAME)); $this->assertTrue($check); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testNothingModifiedLastRunSet()\n {\n $this->_cs->updateLastRun($this->_name);\n sleep(2);\n\n $check = $this->_cs->checkEntitiesChanged($this->_name, array(self::ENTITY_NAME));\n $this->assertFalse($check);\n }", "public function hasChangedEntries();", "public...
[ "0.7307526", "0.6636282", "0.6423879", "0.62041825", "0.6171108", "0.6171108", "0.61324227", "0.6088629", "0.6065275", "0.60222", "0.5993436", "0.5993436", "0.59595", "0.5943766", "0.593973", "0.59271514", "0.59005326", "0.5892808", "0.58417", "0.5815253", "0.57851183", "0....
0.71344936
1
Given a context this method serializes the current graph to nquads of the form .
Дан контекст, этот метод сериализует текущий граф в формат nquads.
function to_nquads($context) { if(empty($context)) { throw new \InvalidArgumentException("You must specify the context when serializing to nquads"); } $serializer = new NQuadSerializer(); return $serializer->getSerializedIndex($this->_index, $this->_labeller->qname_to_al...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function serialize(Context $context = null);", "public function serialize(Context $context = null);", "public function serialize(Context $context = null)\n {\n return serialize($context);\n }", "private function contextToString($context) {\n $export = '';\n foreach ($context...
[ "0.65871024", "0.65871024", "0.58459175", "0.5122658", "0.5101268", "0.5060301", "0.5042538", "0.5011205", "0.49751905", "0.49704677", "0.49523437", "0.49523437", "0.49452028", "0.4877312", "0.48759097", "0.48759097", "0.48759097", "0.4854968", "0.48272702", "0.48272702", "0....
0.71014583
0
Validate save/update jobFamily request.
Проверить запрос на сохранение/обновление jobFamily.
private function checkJobFamilyRequest(Request $request) { $this->validate($request, [ 'companyId' => 'required|integer|exists:companies,id', 'effBegin' => 'required|date|before_or_equal:effEnd', 'effEnd' => 'required|date', 'description' => 'present|max:255',...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function validateUpdateRequest( Request $request ) {\n\t\t$this->validate($request, [\n\t\t\t'book_id' => 'exists:books,id',\n\t\t\t'price' => 'numeric|min:1',\n\t\t],[\n\t\t\t'books_id.exists' => 'Not an existing book for this sale.',\n\t\t\t'min' => 'The :attribute field needs at least :min chars.',\n\t\...
[ "0.58357376", "0.58190745", "0.5662971", "0.56121886", "0.5590617", "0.5528992", "0.5528292", "0.55264735", "0.5493111", "0.5443351", "0.54126465", "0.5409019", "0.54027575", "0.53791666", "0.53451353", "0.53294027", "0.53190136", "0.53190136", "0.53169066", "0.5308811", "0.5...
0.71146524
0
Construct a jobFamily object (array).
Создайте объект jobFamily (массив).
private function constructJobFamily(Request $request) { $jobFamily = [ "tenant_id" => $this->requester->getTenantId(), "company_id" => $request->companyId, "eff_begin" => $request->effBegin, "eff_end" => $request->effEnd, "description" => $request-...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct(array $job_Family_Group = array())\n {\n $this\n ->setJob_Family_Group($job_Family_Group);\n }", "public function getFamilyObjects()\n {\n $familyObjects = [];\n\n foreach ($this->families as $code => $family) {\n $familyObject = new...
[ "0.62322813", "0.5693969", "0.52806205", "0.5211765", "0.5205587", "0.5170847", "0.5098012", "0.5050875", "0.50010294", "0.49415702", "0.4844303", "0.48430607", "0.48242843", "0.47815427", "0.47377852", "0.47377852", "0.47288948", "0.47154403", "0.47093543", "0.46740595", "0....
0.71052134
0
Test, that the method 'quote' works with null.
Тестирование того, чтобы метод 'quote' работал с null.
public function testQuoteWorksWithNull() { $quoted = $this->database->quote(null); $this->assertEquals("''", $quoted); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testQuoteWorksWithEmptyString()\n {\n $quoted = $this->database->quote('');\n\n $this->assertEquals(\"''\", $quoted);\n }", "public function testQuoteWorksWithAlreadyQuotedValue()\n {\n $quoted = $this->database->quote(\"NonEmptyValue\");\n $quoted = $this->da...
[ "0.7069636", "0.6617881", "0.65600824", "0.6297719", "0.6247287", "0.6083242", "0.58178574", "0.5784764", "0.57821524", "0.5776364", "0.5757122", "0.56762415", "0.5613706", "0.5597514", "0.5576952", "0.55647266", "0.55552584", "0.5509211", "0.54911363", "0.54777104", "0.54484...
0.8191858
0
Test, that the method 'quote' works with an empty string.
Тестирование метода 'quote' с пустой строкой.
public function testQuoteWorksWithEmptyString() { $quoted = $this->database->quote(''); $this->assertEquals("''", $quoted); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testQuoteWorksWithNonEmptyValue()\n {\n $quoted = $this->database->quote('NonEmptyValue');\n\n $this->assertEquals(\"'NonEmptyValue'\", $quoted);\n }", "public function testQuoteWorksWithAlreadyQuotedValue()\n {\n $quoted = $this->database->quote(\"NonEmptyValue\");\...
[ "0.7626525", "0.74592537", "0.72566724", "0.6786573", "0.63632715", "0.635894", "0.6331138", "0.6232039", "0.62147313", "0.6125124", "0.6114636", "0.6066547", "0.60434616", "0.59777987", "0.5887147", "0.58598226", "0.58598226", "0.5859166", "0.5805425", "0.5802791", "0.580266...
0.81545603
0
Test, that the method 'quote' works with a non empty value.
Тестирование того, что метод 'quote' работает с непустым значением.
public function testQuoteWorksWithNonEmptyValue() { $quoted = $this->database->quote('NonEmptyValue'); $this->assertEquals("'NonEmptyValue'", $quoted); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testQuoteWorksWithAlreadyQuotedValue()\n {\n $quoted = $this->database->quote(\"NonEmptyValue\");\n $quoted = $this->database->quote($quoted);\n\n $this->assertEquals(\"'\\'NonEmptyValue\\''\", $quoted);\n }", "public function testQuoteWorksWithEmptyString()\n {\n ...
[ "0.79104733", "0.75641", "0.7298691", "0.71054745", "0.66218436", "0.6510129", "0.6481575", "0.63827497", "0.63782746", "0.6306501", "0.604792", "0.60294026", "0.6005863", "0.60017484", "0.59420395", "0.5915872", "0.59061587", "0.58690095", "0.58325493", "0.5825457", "0.58228...
0.80302304
0
Test, that the method 'quote' works with an already quoted value.
Тестирование, чтобы убедиться, что метод 'quote' работает с уже процитированным значением.
public function testQuoteWorksWithAlreadyQuotedValue() { $quoted = $this->database->quote("NonEmptyValue"); $quoted = $this->database->quote($quoted); $this->assertEquals("'\'NonEmptyValue\''", $quoted); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "abstract public function quoteString($value);", "public function testQuoteOrNot()\n {\n // Prepare / Mock\n // The key is the expected output and the value is the input.\n $values = [\n \"'quoted_string'\" => 'quoted_string',\n '123' => 123,\n 'COUNT(id)' ...
[ "0.7531826", "0.74169225", "0.7311358", "0.72213227", "0.7098994", "0.70037824", "0.6971641", "0.6855499", "0.6769393", "0.6767682", "0.67640966", "0.67507625", "0.6731821", "0.6695234", "0.66736084", "0.66210836", "0.64541465", "0.64439815", "0.6431746", "0.64203745", "0.640...
0.831404
0
Test, that the method 'quoteArray' works with an empty array.
Тестирование метода 'quoteArray' на работу с пустым массивом.
public function testQuoteArrayWithEmptyArray() { $originalArray = array(); $quotedArray = $this->database->quoteArray($originalArray); $this->assertEquals($originalArray, $quotedArray); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testQuoteArrayWithFilledArray()\n {\n $originalArray = array('Hello', 'quoteThis');\n\n $quotedArray = $this->database->quoteArray($originalArray);\n\n $expectedQuotedArray = array(\"'Hello'\", \"'quoteThis'\");\n\n $this->assertEquals($expectedQuotedArray, $quotedArr...
[ "0.83158636", "0.70378566", "0.68605334", "0.6532251", "0.64105356", "0.63260376", "0.62478715", "0.6235537", "0.62222785", "0.62154603", "0.6164986", "0.61360985", "0.61207527", "0.61153096", "0.6115112", "0.6077848", "0.60670465", "0.60221696", "0.59983295", "0.5940904", "0...
0.8767763
0
Test, that the method 'quoteArray' works with a non empty array.
Тестирование, чтобы убедиться, что метод 'quoteArray' работает с не пустым массивом.
public function testQuoteArrayWithFilledArray() { $originalArray = array('Hello', 'quoteThis'); $quotedArray = $this->database->quoteArray($originalArray); $expectedQuotedArray = array("'Hello'", "'quoteThis'"); $this->assertEquals($expectedQuotedArray, $quotedArray); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testQuoteArrayWithEmptyArray()\n {\n $originalArray = array();\n\n $quotedArray = $this->database->quoteArray($originalArray);\n\n $this->assertEquals($originalArray, $quotedArray);\n }", "public function testImplodeArrayWithInnerArrayAndQuotes()\n {\n $this->...
[ "0.85830885", "0.72370136", "0.6765561", "0.6455984", "0.6429586", "0.63478357", "0.6231204", "0.622855", "0.6198356", "0.61176497", "0.61146164", "0.60594577", "0.59955674", "0.59897053", "0.5985017", "0.59737647", "0.5956799", "0.5951516", "0.5947273", "0.5912014", "0.59076...
0.8287438
1
get base file url
получить базовый URL файла
public function getFileBaseUrl() { return Mage::getBaseUrl('media').'family'.'/'.'file'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function get_base_url() : string {\n return plugin_dir_url( dirname( __FILE__, 2 ) );\n }", "public function base_url() {\n\t\t$protocol = ( ! empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off' || $_SERVER['SERVER_PORT'] == 443) ? 'https' : 'http';\n\t\t$host = $_SERVER['HTTP_HOST'];\n\t\t$s...
[ "0.80191344", "0.80082136", "0.79639703", "0.79058754", "0.7903817", "0.78937364", "0.78924215", "0.78374004", "0.765912", "0.7641377", "0.76127994", "0.7598394", "0.7596075", "0.75888634", "0.7558855", "0.7551855", "0.75413555", "0.75398713", "0.75356454", "0.753432", "0.752...
0.81894994
0
get attribute input types
получить типы атрибутов входных данных
public function getAttributeInputTypes($inputType = null) { $inputTypes = array( 'multiselect' => array( 'backend_model' => 'eav/entity_attribute_backend_array', 'source_model' => 'eav/entity_attribute_source_table' ), 'boolean' => arr...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "protected function _getAllowedAttributeFrontendInputTypes()\n {\n return array(\n 'text',\n 'textarea',\n 'select',\n 'multiselect',\n 'price',\n 'date',\n );\n }", "public function getAttributeInputTypes($inputType = null)\n ...
[ "0.7381745", "0.72468597", "0.7240387", "0.716304", "0.7095789", "0.6928327", "0.6919269", "0.6777201", "0.66418105", "0.6489073", "0.63454354", "0.63284594", "0.63149", "0.6284595", "0.6267661", "0.6252109", "0.6226967", "0.6199218", "0.6113599", "0.6098293", "0.60949606", ...
0.7347085
1
get the template processor
получить процессор шаблона
protected function _getTemplateProcessor() { if (null === $this->_templateProcessor) { $this->_templateProcessor = Mage::helper('catalog')->getPageTemplateProcessor(); } return $this->_templateProcessor; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getTemplateEngine() {\n\t\treturn parent::getTemplateEngine();\n\t}", "public function getProcessor($processor);", "public function getProcessor()\n {\n return $this->processor;\n }", "protected function template()\n\t{\n\t\treturn Phpfox::getLib('template');\t\n\t}", "abstract...
[ "0.6912399", "0.6747849", "0.6721066", "0.6661074", "0.6497452", "0.64640933", "0.64554274", "0.6454715", "0.6454715", "0.6433876", "0.6431964", "0.63840663", "0.63819057", "0.63723576", "0.6311399", "0.6286915", "0.6272647", "0.6272647", "0.6272647", "0.6272647", "0.6272647"...
0.83113146
1
Store a newly created Presentation in storage. POST /presentations
Храните ново созданную Презентацию в хранилище. POST /presentations
public function store(CreatePresentationAPIRequest $request) { $input = $request->all(); $presentations = $this->presentationRepository->create($input); return $this->sendResponse($presentations->toArray(), 'Presentation saved successfully'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function store()\n\t{\n\t\t$slide = new Slide;\n\t\t$slide->fill();\n\t\t$slide->save();\n\n\t\treturn $this->respondOK();\n\t}", "public function store()\n {\n $publication = $this->publicationRepo->newPost();\n\n $data = Input::all();\n\n $manager = new PublicationManager($public...
[ "0.715317", "0.67453045", "0.64882326", "0.6467261", "0.6437026", "0.6425936", "0.6332626", "0.626378", "0.6202378", "0.6184346", "0.61726147", "0.6153432", "0.6126967", "0.6122126", "0.61204916", "0.6074654", "0.6074197", "0.6041312", "0.60352933", "0.5972772", "0.59663916",...
0.774602
0
Initializes a new cancel invoice request object.
Инициализирует новый объект запроса на отмену счета.
public function build(): CancelInvoiceRequest { return CoreHelper::clone($this->instance); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public static function init(int $version): self\n {\n return new self(new CancelInvoiceRequest($version));\n }", "public function cancelInvoiceOrderRows()\n {\n $this->orderType = ConfigurationProvider::INVOICE_TYPE;\n\n return new CancelOrderRowsRequest($this);\n }", "function...
[ "0.7109145", "0.6703967", "0.64607155", "0.6283016", "0.60510397", "0.59354967", "0.589864", "0.58621365", "0.58344877", "0.5780325", "0.57569593", "0.57067686", "0.5648629", "0.56310797", "0.5623773", "0.5513731", "0.5497899", "0.5472397", "0.5448293", "0.5436929", "0.542168...
0.73137414
0
Validator check existing address as account in blockchain.
Проверяется существующий адрес как аккаунт в блокчейне.
public function validateAddress($attribute) { $web3BlockChainAdapter = new Web3BlockChainAdapter(Yii::$app->ethereumAPI); if ($this->network === CryptoCurrencyTypes::NETWORK_TYPE_ETHEREUM && !$web3BlockChainAdapter->isAccount($this->$attribute)) { $this->addError($attribute, 'The address...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function isValidAddress($address);", "public function testCheckAddress() {\n\t$this->assertTrue(Bitcoin::checkAddress(\"1pA14Ga5dtzA1fbeFRS74Ri32dQjkdKe5\"));\n\t$this->assertTrue(Bitcoin::checkAddress(\"1MU97wyf7msCVdaapneW2dW1uXP7oEQsFA\"));\n\t$this->assertTrue(Bitcoin::checkAddress(\"1F417eczAAbh41V4o...
[ "0.71650594", "0.70034206", "0.6879885", "0.68313944", "0.6782121", "0.6760822", "0.6639987", "0.6601004", "0.6573855", "0.64992744", "0.6492827", "0.6459363", "0.63669884", "0.6321514", "0.63187397", "0.62727505", "0.6261529", "0.61439997", "0.6137735", "0.6131908", "0.61259...
0.70157564
1
allows change of current set of templates templates will be loaded in that order : ptTplSwitcher_tplCurrent ptTplSwitcher_tplDefault symfony template dir
позволяет изменение текущего набора шаблонов, шаблоны будут загружаться в следующем порядке: ptTplSwitcher_tplCurrent ptTplSwitcher_tplDefault каталог шаблонов symfony
static public function setCurrentTpl($tpl) { $origin = __CLASS__.'::'.__FUNCTION__; $db = true; $ret = true; $enabled_modules = sfConfig::get('sf_enabled_modules'); if (in_array('switch', $enabled_modules) ) { // this allows for setting the current tpl "permanently" (for all sessions accessing the ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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;...
[ "0.66988117", "0.6542136", "0.6452914", "0.63796985", "0.63705105", "0.63204616", "0.62383723", "0.6216628", "0.61710274", "0.61352193", "0.6073736", "0.60563666", "0.60045666", "0.59754115", "0.59754115", "0.59754115", "0.59754115", "0.59754115", "0.59642917", "0.5925577", "...
0.7009998
0
Constructor for the pluggable theme handler.
Конструктор для плаггируемого обработчика тем.
public function __construct() { $this->setup_theme(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function __construct() {\n\t\tparent::__construct();\n\n\t\t//Prepare theme\n\t\t$this->theme_setup();\n\n\t}", "public function __construct() {\n\n\t\t// Setup empty class for the global $wpex_theme object\n\t\tglobal $wpex_theme;\n\t\t$wpex_theme = new stdClass;\n\n\t\t// Defines hooks and runs actions on init...
[ "0.76027495", "0.73549384", "0.72907364", "0.7160699", "0.7086468", "0.6991841", "0.6988804", "0.69554955", "0.68625504", "0.68606067", "0.685925", "0.6839064", "0.6831412", "0.6815193", "0.6812428", "0.6810435", "0.669928", "0.66859764", "0.66721094", "0.6656739", "0.6648308...
0.761716
0
Parse config for datasources
Парсинг конфигурации для источников данных
public static function parse($config) { $config = explode("\n", $config); $datasources = array(); while(!is_null($line = array_shift($config))) { if(!$line) continue; $bits = preg_split('`\s+`', $line, 2); $type = array_shift($bits); if(!in_array($type, array( 'member_include', 'include_file'...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function _parseDsn($dsn)\n {\n $dsn = parse_url($dsn);\n $cfg = [];\n\n //\n // Some drivers (a.k.a. PDO_PGSQL) complains if the port is set\n // without a value, even NULL\n if (isset($dsn['port'])) {\n $cfg['port'] = $dsn['port'];\n }\n\n ...
[ "0.5976217", "0.5721828", "0.5612049", "0.55250674", "0.5504623", "0.53913856", "0.5366601", "0.5362301", "0.5356582", "0.53168577", "0.53066975", "0.5237124", "0.52257097", "0.5206472", "0.5197289", "0.5191867", "0.5191433", "0.51863676", "0.5180018", "0.51752", "0.5163774",...
0.7190474
0
Commits the active transaction
Закрепляет активную транзакцию
public function commit() { if ($this->hasActiveTransaction) { parent::commit(); $this->hasActiveTransaction = false; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function commitTransaction() {\r\n\t\t// TODO: Implement transaction stuff.\r\n\t\t//$this->query('COMMIT TRANSACTION');\r\n\t}", "public function commit()\n {\n if ($this->transactions == 1) {\n $this->transaction->commit();\n }\n\n $this->transactions--;\n\n $th...
[ "0.84967434", "0.83242327", "0.8321", "0.8209178", "0.81601", "0.81048054", "0.80880034", "0.80426186", "0.804144", "0.8012363", "0.7977819", "0.7967638", "0.7955373", "0.79495883", "0.79378855", "0.7908791", "0.7892145", "0.7803367", "0.774375", "0.77212155", "0.77074707", ...
0.8331714
1
Return an array of ids from an array of Phlickr_Photos.
Вернуть массив идентификаторов из массива Phlickr_Photos.
static function idsFromPhotos($photos) { $ids = array(); foreach ($photos as $photo) { $ids[] = $photo->getId(); } return $ids; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function extractIdsArray($data)\n {\n return array_pluck($data['photoset'], 'id');\n }", "public function getImagesId()\n {\n $ids = array();\n foreach ($this->images as $image) {\n $ids[] = $image->getId();\n }\n return $ids;\n }", "function ge...
[ "0.7113198", "0.67401737", "0.6545396", "0.6365121", "0.6173614", "0.60859877", "0.599797", "0.599797", "0.59898245", "0.5986281", "0.59597653", "0.5945384", "0.5941317", "0.5913523", "0.5889665", "0.5882111", "0.5877648", "0.58672786", "0.5845231", "0.5748691", "0.5723924", ...
0.82969815
0
function to load contact us view
функция для загрузки представления "Связаться с нами"
public function contactUsView() { $this->load->view('contactusview' }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function contactUs() {\n\n require('view/contactUsView.php');\n\n}", "public function contactUs(){\n $this->load->view('contactUs');\n }", "public function contact()\n\t{\n\t\t$data ['footer'] = $this->page_model->getfooter();\n\n\t\t$this->load->view('templates/header');\n\t\t$this->load->view('hom...
[ "0.7662578", "0.76327574", "0.75723183", "0.7551234", "0.7521056", "0.7409518", "0.73617864", "0.7329589", "0.7291424", "0.72734326", "0.7239474", "0.72393703", "0.7190757", "0.7185839", "0.7182809", "0.7181831", "0.71703553", "0.71620095", "0.7134234", "0.71118784", "0.71087...
0.8090335
0
Initialize Social Media section and fields
Инициализация раздела Социальные сети и полей
private function initializeSocialMedia() { $this->ch->addSection($this->slug . '_social_media', 'Social Media', 130); foreach ($this->social as $media => $label) { $this->ch->addControl("social_{$media}", $this->slug . '_social_media', $label); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function __construct() {\n\t\t\t//\n\t\t\tparent::__construct(\n\t\t\t\t'zthemename_social_media',\n\t\t\t\tesc_html__( 'Social Media', 'zthemename' ),\n\t\t\t\tarray(\n\t\t\t\t\t'description' => esc_html__( \"Displays your business' social media links\", 'zthemename' ),\n\t\t\t\t\t'customiz...
[ "0.6914586", "0.6657351", "0.65713793", "0.640563", "0.63056916", "0.6113042", "0.60895747", "0.603586", "0.59583825", "0.5808742", "0.5768256", "0.5752925", "0.5752597", "0.5745953", "0.5743503", "0.5700099", "0.5679294", "0.56469387", "0.56257886", "0.5623103", "0.5615799",...
0.86034894
0
Initialize Footer Pages section and fields
Инициализация раздела Footer Pages и полей
private function initializeFooterPages() { $this->ch->addSection($this->slug . '_footer_pages', 'Footer Pages', 140); $this->ch->addPagesControl('footer_privacy_policy', $this->slug . '_footer_pages', 'Privacy Policy Page'); $this->ch->addPagesControl('footer_cookie_policy', $this->slug . '_...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function initPageFooter()\n\t{\n\t\tinclude_once('view/main_page_footer.php');\n\t}", "public function defineFooter()\n {\n $this->footer = new Footer();\n }", "public function init() {\n extract($this->data);\n\n $this->data['links'] = $this->addTargetToLinks($links);\n\n ...
[ "0.775897", "0.7186598", "0.6756386", "0.6712379", "0.6600335", "0.64397335", "0.6398717", "0.6383972", "0.6381415", "0.6379001", "0.63590825", "0.6307993", "0.6307993", "0.63023746", "0.62960213", "0.62868977", "0.62543774", "0.625065", "0.62491083", "0.62425166", "0.6223854...
0.8284984
0
This function will prepare all Admin functionality for the plugin
Этот функция подготовит все функциональность Admin для плагина
static function prepare() { // Check that we are in the admin area if (is_admin()) : // Add the sidebar Menu structure add_action('admin_menu', array('ProjectenPlugin_AdminController', 'addMenus')); endif; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function admin_setup()\n\t{\n\t\t\n\t}", "private function define_admin_hooks() {\n\t\t$plugin_admin = new Soisy_Pagamento_Rateale_Admin( $this->get_plugin_name(), $this->get_version() );\n\n\t\t$this->loader->add_action( 'admin_enqueue_scripts', $plugin_admin, 'enqueue_styles' );\n $this->loader->...
[ "0.72996587", "0.72607803", "0.72564346", "0.7247739", "0.71733993", "0.71392965", "0.71230614", "0.71088505", "0.70533216", "0.70327485", "0.70326614", "0.7030546", "0.7029993", "0.7004105", "0.6997376", "0.6955343", "0.6923973", "0.6889962", "0.6889035", "0.68272746", "0.68...
0.7788519
0
Create meta data entry
Создать запись метаданных
function createMetaData() { parent::createMetaData(); $this->saveAuthorToMetadata(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function add_metadata($meta_type, $object_id, $meta_key, $meta_value, $unique = \\false)\n {\n }", "function wp_create_initial_post_meta()\n {\n }", "function createAtomEntry() {\n\t\t$this->create();\n\t}", "public function add_meta( $key, $value, $unique = false );", "protected function save_...
[ "0.7083554", "0.6598917", "0.6539921", "0.63548154", "0.62541217", "0.6243179", "0.6236825", "0.62103033", "0.6195778", "0.61901003", "0.610156", "0.6097557", "0.6054699", "0.6049887", "0.60415405", "0.60309947", "0.60269785", "0.6017872", "0.5977798", "0.59730774", "0.595665...
0.7447418
0
Deletes the survey from the database
Удаляет опрос из базы данных
function deleteSurveyRecord() { global $ilDB; $affectedRows = $ilDB->manipulateF("DELETE FROM svy_svy WHERE survey_id = %s", array('integer'), array($this->getSurveyId()) ); $result = $ilDB->queryF("SELECT questionblock_fi FROM svy_qblk_qst WHERE survey_fi = %s", array('integer'), array($this->...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function testDeleteSurvey()\n {\n $survey = Survey::factory()->create();\n $surveyId = $survey->id;\n\n $response = $this->json('DELETE', \"survey/{$surveyId}\");\n\n $response->assertStatus(204);\n $this->assertDatabaseMissing('survey', ['id' => $surveyId]);\n }", ...
[ "0.76269424", "0.72986805", "0.7138512", "0.70225924", "0.6970275", "0.6942721", "0.6701194", "0.6668022", "0.6628398", "0.6584948", "0.65771836", "0.65684456", "0.65418535", "0.65418535", "0.65384054", "0.65351653", "0.65293497", "0.65052813", "0.6504968", "0.64957595", "0.6...
0.7320372
1
Deletes all user data of a survey
Удаляет все данные пользователя опроса
function deleteAllUserData() { global $ilDB; $result = $ilDB->queryF("SELECT finished_id FROM svy_finished WHERE survey_fi = %s", array('integer'), array($this->getSurveyId()) ); $active_array = array(); while ($row = $ilDB->fetchAssoc($result)) { array_push($active_array, $row["finished_id"]);...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function delete()\n {\n foreach ($this->users as $user) {\n $uid = $user->id;\n // delete whole website info for this user\n if ((bool)$this->delete) {\n $model = new FormUserClear($user);\n $model->comments = true;\n $m...
[ "0.6742145", "0.6682591", "0.6587738", "0.63381344", "0.62949795", "0.6282547", "0.6268381", "0.6268381", "0.6240806", "0.62358767", "0.6117296", "0.6115654", "0.6049379", "0.6047991", "0.60146284", "0.601251", "0.60046923", "0.60016185", "0.59653705", "0.5955393", "0.5947093...
0.7689275
0
Returns 1, if a survey is complete for use
Возвращает 1, если опрос завершен для использования
function isComplete() { if (($this->getTitle()) and (count($this->questions))) { return 1; } else { return 0; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function _isComplete($obj_id)\n\t{\n\t\t$survey = new ilObjSurvey($obj_id, false);\n\t\t$survey->loadFromDb();\n\t\tif (($survey->getTitle()) and (count($survey->questions)))\n\t\t{\n\t\t\treturn 1;\n\t\t} \n\t\t\telse \n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t}", "public function is_complete($survey_id)\n\t{\n\t\t$que...
[ "0.74926424", "0.66521484", "0.665213", "0.6617402", "0.65840304", "0.6520218", "0.64921725", "0.6483236", "0.63189656", "0.61956435", "0.6131194", "0.6110185", "0.6098907", "0.6092287", "0.6069003", "0.60374725", "0.6025306", "0.601311", "0.5991403", "0.59809124", "0.5972805...
0.745034
1
Returns 1, if a survey is complete for use
Возвращает 1, если опрос завершен для использования
function _isComplete($obj_id) { $survey = new ilObjSurvey($obj_id, false); $survey->loadFromDb(); if (($survey->getTitle()) and (count($survey->questions))) { return 1; } else { return 0; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isComplete()\n\t{\n\t\tif (($this->getTitle()) and (count($this->questions)))\n\t\t{\n\t\t\treturn 1;\n\t\t} \n\t\t\telse \n\t\t{\n\t\t\treturn 0;\n\t\t}\n\t}", "function isComplete() {\n\t\t$questions = $this->getQuestions();\n\t\t\n\t\tforeach((array) $questions as $question) {\n\t\t\tif(!$question->h...
[ "0.74526906", "0.6654149", "0.66524255", "0.6616924", "0.65860105", "0.6522615", "0.6495263", "0.64833015", "0.6320306", "0.6198287", "0.6133489", "0.61097217", "0.60994685", "0.6095202", "0.6071363", "0.60378426", "0.60249984", "0.6013118", "0.5994098", "0.5982669", "0.59758...
0.7493288
0
Saves the completion status of the survey
Сохраняет статус завершения опроса
function saveCompletionStatus() { global $ilDB; $complete = 0; if ($this->isComplete()) { $complete = 1; } if ($this->getSurveyId() > 0) { $affectedRows = $ilDB->manipulateF("UPDATE svy_svy SET complete = %s, tstamp = %s WHERE survey_id = %s", array('text','integer','integer'), arra...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "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 completeSurveyAction() {\n\t\tif (in_array(APPLICATION_ENV, array('development'...
[ "0.68383175", "0.6781291", "0.66322875", "0.65644103", "0.64687586", "0.62748706", "0.6216078", "0.61764437", "0.61506337", "0.61239", "0.60624427", "0.6021642", "0.60088193", "0.5989063", "0.5963104", "0.5909132", "0.5907373", "0.58487594", "0.58252394", "0.5802479", "0.5768...
0.8126283
0
Returns the content of all RTE enabled text areas in the test
Возвращает содержимое всех текстовых полей RTE в тесте
function getAllRTEContent() { $result = array(); array_push($result, $this->getIntroduction()); array_push($result, $this->getOutro()); return $result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getTextContent();", "public function textarea()\n {\n return $this->content(false, false, false, true);\n }", "function getRTETextWithMediaObjects()\n\t{\n\t\treturn parent::getRTETextWithMediaObjects();\n\t}", "function getRTETextWithMediaObjects()\n\t{\n\t\t$text = parent::getR...
[ "0.6343008", "0.6175572", "0.61345696", "0.6133691", "0.60925126", "0.6079329", "0.5953084", "0.5953084", "0.5953084", "0.5953084", "0.5953084", "0.59361285", "0.59264225", "0.5901187", "0.58684564", "0.5849754", "0.58427155", "0.5773082", "0.576314", "0.5734054", "0.57330006...
0.7268474
0
Cleans up the media objects for all text fields in a test which are using an RTE field
Очищает медиаобъекты для всех текстовых полей в тесте, которые используют поле RTE
function cleanupMediaobjectUsage() { include_once("./Services/RTE/classes/class.ilRTE.php"); $completecontent = ""; foreach ($this->getAllRTEContent() as $content) { $completecontent .= $content; } ilRTE::_cleanupMediaObjectUsage($completecontent, $this->getType() . ":html", $this->getId()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function cleanup() {\n $this->object->removeLock();\n $this->clearCache();\n\n $returnArray = $this->object->get(array_diff(array_keys($this->object->_fields), array('content','ta','introtext','description','link_attributes','pagetitle','longtitle','menutitle','articles_container_settin...
[ "0.61022234", "0.6075657", "0.6002784", "0.59121126", "0.5902467", "0.58489764", "0.58252573", "0.5776481", "0.5722186", "0.5719736", "0.5719532", "0.5719202", "0.57048184", "0.5586723", "0.55762815", "0.5574571", "0.55657905", "0.5507502", "0.5478062", "0.5444388", "0.542917...
0.732645
0
Saves the survey questions to the database
Сохраняет вопросы опроса в базу данных
function saveQuestionsToDb() { global $ilDB; // save old questions state $old_questions = array(); $result = $ilDB->queryF("SELECT * FROM svy_svy_qst WHERE survey_fi = %s", array('integer'), array($this->getSurveyId()) ); if ($result->numRows()) { while ($row = $ilDB->fetchAssoc($result)) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function save($answers);", "public function saveAction()\n {\n $user = Mage::getSingleton('admin/session')->getUser(); \n $post_data = $this->getRequest()->getPost();\n\n try {\n $survey = Mage::getModel('client/survey')->loadSurveyByEmail($user->getEmail());\n ...
[ "0.7209578", "0.71866274", "0.7149955", "0.7146203", "0.7129381", "0.71078825", "0.69727767", "0.68159145", "0.68080336", "0.6793641", "0.67273414", "0.67218655", "0.6706229", "0.6702066", "0.6701771", "0.66964024", "0.6691624", "0.65584666", "0.65310115", "0.6514063", "0.649...
0.78849113
0
Returns a question gui object to a given questiontype and question id
Возвращает объект GUI вопроса для заданного типа вопроса и идентификатора вопроса
function getQuestionGUI($questiontype, $question_id) { include_once "./Modules/SurveyQuestionPool/classes/class.SurveyQuestionGUI.php"; return SurveyQuestionGUI::_getQuestionGUI($questiontype, $question_id); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function create($question, $type = ObjectFactory::TEXT_QUESTION)\n\t{\n\t\t// echo $type;\n\t\t$newQuestion = $this->objectFactory->createQuestion($type);\n\t\t// if ($type == ObjectFactory::SINGLE_CHOICE_QUESTION) echo \"single\";\n\t\t// echo $question;\n\t\t$newQuestion->setQuestion($question);\n\t\t$thi...
[ "0.6430117", "0.63952506", "0.6327749", "0.62047935", "0.61353356", "0.60501885", "0.6023196", "0.60034496", "0.59641784", "0.5937594", "0.59087265", "0.5892983", "0.58288634", "0.5725175", "0.56953174", "0.5683468", "0.56814265", "0.5660137", "0.5648431", "0.5645041", "0.564...
0.8167861
0
Returns the question type of a question with a given id
Возвращает тип вопроса вопроса с заданным идентификатором
function getQuestionType($question_id) { global $ilDB; if ($question_id < 1) return -1; $result = $ilDB->queryF("SELECT type_tag FROM svy_question, svy_qtype WHERE svy_question.question_id = %s AND " . "svy_question.questiontype_fi = svy_qtype.questiontype_id", array('integer'), array($question_id) )...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getType($id)\n\t{\n\t\tif (empty($id)) //safe because we never use 0 as an id\n\t\t{\n\t\t\t$currentID = $this->getID();\n\t\t\tif (empty($currentID)) return false;\n\t\t\t$id = $currentID;\n\t\t}\n\t\t$result = $this->find('first', array(\n\t\t\t'conditions' => array('id' => $id),\n\t\t\t'fields' => arra...
[ "0.7716746", "0.73255116", "0.7051248", "0.6959651", "0.6747613", "0.66502106", "0.6642964", "0.65593237", "0.6532787", "0.651467", "0.6488503", "0.64779174", "0.6459869", "0.6445235", "0.6444707", "0.6393059", "0.6329177", "0.6304178", "0.6296919", "0.6266626", "0.6243975", ...
0.78216434
0
Returns the survey database id
Возвращает идентификатор базы данных опроса
function getSurveyId() { return $this->survey_id; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getDatabaseId();", "public function getDatabaseId()\n {\n return $this->database_id;\n }", "public function getIdDatabase()\n {\n return $this->idDatabase;\n }", "public function getDBID()\n {\n return $this->dbID;\n }", "function id_db() {\n\t\treturn mysql_...
[ "0.74579984", "0.6905449", "0.66557485", "0.65227187", "0.64569736", "0.6320144", "0.62798345", "0.6266429", "0.62555987", "0.61761063", "0.61424744", "0.61336404", "0.61072433", "0.61022955", "0.61021936", "0.60531694", "0.5993428", "0.59876806", "0.59876806", "0.59478873", ...
0.74900234
0
Checks if the survey results are to be anonymized
Проверяет, должны ли результаты опроса быть анонимизированы
function hasAnonymizedResults() { return ($this->getAnonymize() == self::ANONYMIZE_ON || $this->getAnonymize() == self::ANONYMIZE_FREEACCESS); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "private function shouldAnonymize(): bool\n {\n if (!$this->moduleSettings->get(ModuleName::fromString('Frontend'), 'consent_dialog_enabled', false)) {\n return true;\n }\n\n return $this->consentDialog->hasAgreedTo(ConsentDialog::CONSENT_DIALOG_ANALYTICS_TECHNICAL_NAME);\n }",...
[ "0.67653316", "0.608136", "0.5473786", "0.5248364", "0.52371323", "0.5225185", "0.52083075", "0.51993686", "0.5180244", "0.5165237", "0.5159649", "0.5105231", "0.5048006", "0.50256985", "0.50199974", "0.49694255", "0.49273774", "0.49112526", "0.49082047", "0.49020296", "0.486...
0.8105426
0
Loads a survey object from a database
Загружает объект опроса из базы данных
function loadFromDb() { global $ilDB; $result = $ilDB->queryF("SELECT * FROM svy_svy WHERE obj_fi = %s", array('integer'), array($this->getId()) ); if ($result->numRows() == 1) { $data = $ilDB->fetchAssoc($result); $this->setSurveyId($data["survey_id"]); $this->setAuthor($data["author"]); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function Load($surveyid)\n\t{\n\t\t$surveyid = (int)$surveyid;\n\t\t$prefix = $this->Db->TablePrefix;\n\t\t$query = \"SELECT * FROM {$prefix}surveys WHERE id = $surveyid\";\n\n\t\t$result = $this->Db->Query($query);\n\t\t$survey = $this->Db->Fetch($result);\n\n\t\treturn $this->_loadData($survey);\n\t}", ...
[ "0.6632753", "0.6607859", "0.62475055", "0.62163645", "0.6137934", "0.58923465", "0.58680713", "0.58397454", "0.5775227", "0.57651675", "0.57021284", "0.5612225", "0.55936867", "0.5482907", "0.5482907", "0.54653037", "0.5450741", "0.5440113", "0.5437204", "0.538706", "0.53532...
0.7186936
0
Loads the survey questions from the database
Загружает вопросы опроса из базы данных
function loadQuestionsFromDb() { global $ilDB; $this->questions = array(); $result = $ilDB->queryF("SELECT * FROM svy_svy_qst WHERE survey_fi = %s ORDER BY sequence", array('integer'), array($this->getSurveyId()) ); while ($data = $ilDB->fetchAssoc($result)) { $this->questions[$data["sequence"]]...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function Read(){\n if (isset($_SESSION['question'])) {\n unset($_SESSION['question']);\n\n }\n \n $model = Survey::getInstance();\n $questions = $model->get_questions();\n $answers = $model->get_answers();\n // var_dump($query);\n $...
[ "0.67539793", "0.6587562", "0.63316315", "0.6148872", "0.61152744", "0.61018825", "0.6098469", "0.60228795", "0.600011", "0.5993151", "0.5988139", "0.5935327", "0.59136033", "0.58983463", "0.5869252", "0.58491427", "0.5844125", "0.5832039", "0.5791797", "0.5788542", "0.578236...
0.8036829
0
Gets the status of the display_question_titles attribute
Получает статус атрибута display_question_titles
public function getShowQuestionTitles() { return ($this->display_question_titles) ? 1 : 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getStatusTitle() {\n return $this->statusTitle;\n }", "function showQuestionTitles() \n\t{\n\t\t$this->display_question_titles = 1;\n\t}", "public function getIsDisplayedInTitle()\n {\n return $this->isDisplayedInTitle;\n }", "public function getShowTitle()\n ...
[ "0.6631277", "0.654267", "0.65160114", "0.6498588", "0.60361296", "0.59949154", "0.59836763", "0.59099394", "0.5897096", "0.5858894", "0.5838655", "0.5804743", "0.5804071", "0.57996637", "0.57847244", "0.57734865", "0.5751254", "0.5728362", "0.572204", "0.5715896", "0.5693885...
0.7740462
0
Sets the question titles visible during the query
Устанавливает видимость заголовков вопросов во время запроса
function showQuestionTitles() { $this->display_question_titles = 1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hideQuestionTitles() \n\t{\n\t\t$this->display_question_titles = 0;\n\t}", "public function setShowQuestionTitles($a_show) \n\t{\n\t\t$this->display_question_titles = ($a_show) ? 1 : 0;\n\t}", "public function getShowQuestionTitles() \n\t{\n\t\treturn ($this->display_question_titles) ? 1 : 0;\n\t}", ...
[ "0.69881916", "0.67006606", "0.63948286", "0.59236485", "0.5748824", "0.57212085", "0.5632787", "0.55540633", "0.5497655", "0.5457179", "0.54351157", "0.53922266", "0.5385456", "0.5381919", "0.53488886", "0.533087", "0.53051996", "0.53051996", "0.53051996", "0.53051996", "0.5...
0.7820206
0
Sets the question titles hidden during the query
Устанавливает скрытые заголовки вопросов во время запроса
function hideQuestionTitles() { $this->display_question_titles = 0; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function showQuestionTitles() \n\t{\n\t\t$this->display_question_titles = 1;\n\t}", "public function askAndHideAnswer($question);", "public function setShowQuestionTitles($a_show) \n\t{\n\t\t$this->display_question_titles = ($a_show) ? 1 : 0;\n\t}", "public function getShowQuestionTitles() \n\t{\n\t\treturn ...
[ "0.7187662", "0.6403002", "0.6162864", "0.5874599", "0.5802312", "0.5789743", "0.5652537", "0.55891883", "0.5448816", "0.54063433", "0.53694487", "0.53691196", "0.53580666", "0.5331827", "0.53267765", "0.52546763", "0.5240285", "0.5230152", "0.5224002", "0.51709634", "0.51696...
0.8073319
0
Sets the invitation mode
Устанавливает режим приглашения
function setInvitationMode($invitation_mode = 0) { $this->invitation_mode = $invitation_mode; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setInvitationAndMode($invitation = 0, $invitation_mode = 0)\n\t{\n\t\t$this->invitation_mode = $invitation_mode;\n\t\t$this->setInvitation($invitation);\n\t}", "function setInvitation($invitation = 0) \n\t{\n\t\tglobal $ilDB, $ilAccess;\n\t\t\n\t\t$this->invitation = $invitation;\n\t\tif ($invitation ==...
[ "0.8270427", "0.69026", "0.6842384", "0.591527", "0.5771707", "0.56666994", "0.55834764", "0.5527616", "0.5438288", "0.54217654", "0.5356928", "0.5356928", "0.5263111", "0.5257753", "0.5226063", "0.5156962", "0.5099934", "0.5094766", "0.5085886", "0.5064742", "0.49838936", ...
0.87562764
0
Sets the invitation status and mode (a more performant solution if you change both)
Устанавливает статус и режим приглашения (более производительное решение, если вы меняете оба)
function setInvitationAndMode($invitation = 0, $invitation_mode = 0) { $this->invitation_mode = $invitation_mode; $this->setInvitation($invitation); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setInvitationMode($invitation_mode = 0) \n\t{\n\t\t$this->invitation_mode = $invitation_mode;\n }", "function setInvitation($invitation = 0) \n\t{\n\t\tglobal $ilDB, $ilAccess;\n\t\t\n\t\t$this->invitation = $invitation;\n\t\tif ($invitation == self::INVITATION_OFF)\n\t\t{\n\t\t\t$this->disinviteAllUse...
[ "0.7858737", "0.66267216", "0.63174635", "0.61480963", "0.607003", "0.6060196", "0.5803919", "0.5683074", "0.5574744", "0.55032754", "0.54401493", "0.5417763", "0.5355239", "0.5344447", "0.53327835", "0.53127724", "0.53045356", "0.53002936", "0.52984345", "0.52815634", "0.527...
0.7752064
1
Gets the invitation status
Получает статус приглашения
function getInvitation() { return ($this->invitation) ? $this->invitation : self::INVITATION_OFF; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function status()\n {\n return $this->UserAPI->request_status_check();\n }", "function get_status() {\n return $this->status;\n }", "public function get_status() {\n return $this->status;\n }", "public function status()\n {\n return $this->status->get($this->...
[ "0.66709155", "0.6628434", "0.6525393", "0.6509014", "0.64705664", "0.6468077", "0.64651036", "0.6437398", "0.6396965", "0.63882416", "0.63682395", "0.63659906", "0.63656074", "0.63656074", "0.63656074", "0.63656074", "0.63568264", "0.6355809", "0.634385", "0.634385", "0.6333...
0.71148944
0
Gets the invitation mode
Получает режим приглашения
function getInvitationMode() { include_once "./Services/Administration/classes/class.ilSetting.php"; $surveySetting = new ilSetting("survey"); $unlimited_invitation = $surveySetting->get("unlimited_invitation"); if (!$unlimited_invitation && $this->invitation_mode == self::MODE_UNLIMITED) { return self::...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getInvitation() \n\t{\n\t\treturn ($this->invitation) ? $this->invitation : self::INVITATION_OFF;\n\t}", "function getMode() {\n\t\treturn $this->get('mode');\n\t}", "public function getMode();", "public function getMode();", "public function getMode();", "public function getMode();", "public ...
[ "0.7388144", "0.6612674", "0.64337075", "0.64337075", "0.64337075", "0.64337075", "0.6428552", "0.6425317", "0.63013923", "0.62984306", "0.6289621", "0.628857", "0.6260656", "0.6257267", "0.6250272", "0.6250272", "0.6245971", "0.6237522", "0.62316996", "0.62177527", "0.619873...
0.84966975
0
Sets the end date of the survey
Устанавливает дату окончания опроса
function setEndDate($end_date = "") { $this->end_date = $end_date; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function setEndDate($date)\n\t\t{\n\t\t\t$this->end_date = $date;\n\t\t}", "public function setEndDate(DrupalDateTime $end_date = NULL);", "public function setEndDate($date)\n {\n\t\tif($date==null){\n\t\t\t$this->complete_at = null;\n\t\t\t$this->save();\n\t\t\t$this->fireModelEvent('end-refreshed')...
[ "0.7552366", "0.7495753", "0.73110354", "0.72710156", "0.71122223", "0.7094758", "0.70211405", "0.6998029", "0.69622046", "0.6887356", "0.6838195", "0.6836282", "0.67863035", "0.67216444", "0.6696273", "0.6645639", "0.6629302", "0.6628653", "0.65623134", "0.6527369", "0.65272...
0.75255376
1
Gets the outro text
Получает текст выходной части
function getOutro() { return (strlen($this->outro)) ? $this->outro : NULL; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getTELEFONOC()\r\n {\r\n return $this->TELEFONOC;\r\n }", "public function getPromoText()\n {\n return isset($this->promo_text) ? $this->promo_text : '';\n }", "public function getTexto() {\n return $this->texto;\n }", "function getRTETextWithMediaObjects()...
[ "0.61685777", "0.5809633", "0.56569386", "0.56552404", "0.56225187", "0.5616014", "0.5593915", "0.55923796", "0.55895823", "0.55877066", "0.5496914", "0.54765034", "0.54526955", "0.54436755", "0.5430024", "0.54265815", "0.5426262", "0.5425677", "0.5425677", "0.54237324", "0.5...
0.7135206
0
Gets the question id's of the questions which are already in the survey
Получает идентификаторы вопросов вопросов, которые уже находятся в опросе
function &getExistingQuestions() { global $ilDB; $existing_questions = array(); $result = $ilDB->queryF("SELECT svy_question.original_id FROM svy_question, svy_svy_qst WHERE " . "svy_svy_qst.survey_fi = %s AND svy_svy_qst.question_fi = svy_question.question_id", array('integer'), array($this->getSurvey...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "public function getQuestionIds(){\n\t\treturn array('todo'); // This will be moved to QuestionTemplate\n\t}", "public function getQuestionIds ($quiz=\"\") \n {\n \tglobal $debug;\n \t\n \t// if $quiz not specified get all questions in db (even those with no quiz)\n \t// Initial sql without where -...
[ "0.675986", "0.66616476", "0.6490877", "0.6422709", "0.6293247", "0.61073726", "0.5989688", "0.5893872", "0.58531857", "0.5794064", "0.5775117", "0.5752679", "0.57375944", "0.5723745", "0.56815803", "0.5681364", "0.5671463", "0.5641371", "0.5634838", "0.56335217", "0.5630901"...
0.75862706
0