$sViewListID = 'Genes_SubmitVOT' . ($_GET['target'] ? '_' . $_GET['target'] : ''); $aOptionsList = array('width' => 600); $aOptionsList['options'][0]['onclick'] = 'javascript:$(\'#container\').toggle(); lovd_stretchInputs(\'' . $sViewListID . '\');'; $aOptionsList['options'][0]['option_text'] = '<B>A variant that is located within a gene »»</B>'; $aOptionsList['options'][1]['onclick'] = 'variants?create&reference=Genome' . ($_GET['target'] ? '&target=' . $_GET['target'] : ''); $aOptionsList['options'][1]['option_text'] = '<B>A variant that was only described on genomic level »»</B>'; if ($_AUTH['level'] >= LEVEL_MANAGER) { $aOptionsList['options'][2]['onclick'] = 'variants/upload?create' . ($_GET['target'] ? '&target=' . $_GET['target'] : ''); $aOptionsList['options'][2]['option_text'] = '<B>I want to upload a file with genomic variant data »»</B>'; } print ' What kind of variant would you like to submit?<BR><BR>' . "\n\n"; print lovd_buildOptionTable($aOptionsList); require ROOT_PATH . 'class/object_genes.php'; $_GET['page_size'] = 10; $_DATA = new LOVD_Gene(); $_DATA->setRowLink($sViewListID, 'variants?create&reference=Transcript&geneid=' . $_DATA->sRowID . ($_GET['target'] ? '&target=' . $_GET['target'] : '')); $_GET['search_transcripts'] = '>0'; print ' <DIV id="container" style="display : none;">' . "\n"; // Extra div is to prevent "No entries in the database yet!" error to show up if there are no genes in the database yet. lovd_showInfoTable('Please find the gene for which you wish to submit this variant below, using the search fields if needed. <B>Click on the gene to proceed to the variant entry form</B>.<BR>If a gene is not shown in this display, but it does exist in this LOVD, then it does not have a transcript configured yet.', 'information', 600); $_DATA->viewList($sViewListID, array('transcripts', 'variants', 'diseases_', 'updated_date_')); print ' </DIV>' . "\n" . (!$bSubmit ? '' : ' <INPUT type="submit" value="Cancel" onclick="window.location.href=\'' . lovd_getInstallURL() . 'submit/screening/' . $_POST['screeningid'] . '\'; return false;" style="border : 1px solid #FF4422;">' . "\n"); $_T->printFooter(); exit; } elseif (!in_array($_GET['reference'], array('Genome', 'Transcript')) || $_GET['reference'] == 'Transcript' && empty($_GET['geneid'])) { exit; } // URL: /variants?create&reference=('Genome'|'Transcript') // Create a variant on the genome. if ($_GET['reference'] == 'Transcript') { // On purpose not checking for format of $_GET['geneid']. If it's not right, we'll automatically get to the error message below.