core/api/modules/a_bib_edit/index.php

16 lines
765 B
PHP
Executable File

<?php
ini_set('display_errors', 0 );
if ( $_SESSION['dostup'] != 'a' && $_SESSION['dostup'] != 'e' && $_SESSION['dostup'] != 'c' ) header( 'Location: /login/' );// && $dostup!='m'
/* ----------------------------------------------------------------------
26.07.2023
Получаем список категорий
---------------------------------------------------------------------- */
$all_cat=\DB::getAll("SELECT * FROM `bib_category` WHERE `status`=1");
$smarty -> assign( 'all_cat', $all_cat );
if ($_GET['id'])$book=\DB::getRow("SELECT * FROM `bib` WHERE `id`=? LIMIT 1", $_GET['id']);
assign( 'book', $book);
//$smarty -> assign( 'list_books', $list_books );
//$smarty -> assign( 'list', 'api/modules/' . MOD . '/list.html' );
?>