<style>
    img {
        max-width: 100%;
        height: auto;
    }
</style> 
<div class="card panel-fcs-border shadow-sm">
    <div class="card-header">
        <h2 class="card-title-fcs">                    
            [% $user->gettext('Knowledgebase') %]
        </h2>
    </div>
    <div class="card-body">
        <div class="row">
            <div class="col-md-6 offset-md-3">

                <div class="card panel-info shadow-sm rounded">
                    <div class="card-body text-center">
                            <div class="btn-group">
                                [% if $event == 'create' %]
                                <a href="index.php?module=knowledgebase&event=create&NoDefaultCategories=1" class="btn btn-outline-secondary">[% $user->gettext('Zurück') %]</a>
                                [% else if $event == 'edit' %]
                                <input type="button" class="btn btn-outline-secondary" value="[% $user->gettext('Zurück') %]" onclick="window.location = window.location" />
                                [% /if %]                          
                            </div>
                    </div>
                </div>                     
                <div class="card panel-info shadow-sm rounded">
                    <div class="card-header">
                        <h3 class="card-title">

                            [% $user->gettext('Vorschau') %]

                        </h3>
                    </div>
                    <div class="card-body">          


                        <p>
                        <h3>[% $ShortDescription %]</h3>

                        <div>[% $Description %]</div>


                        </p>
                        <div class="row">
                            <div class="col-sm-6">
                                <strong>[% $user->gettext('Letzte Änderung') %]:</strong> [% $smarty.now|date_format:"%d.%m.%Y %H:%M:%S" %]                   
                            </div>
                            <div class="col-sm-6 text-end">
                                <strong>[% $user->gettext('Verfasser') %]:</strong> [% $Autor %]
                            </div>
                        </div>
                        <div class="row">
                            <div class="col-sm-6">
                            </div>
                            <div class="col-sm-6 text-end">
                                <strong>[% $user->gettext('Letzte Änderung von') %]:</strong> [% $user->FullName %]                      
                            </div>
                        </div>   

                        [% if $Categories %]
                             <div class="card panel-fcs-content">
                                <div class="card-header">
                                    [% $user->gettext('Rubriken zu diesem Artikel') %]
                                </div>
                                <div class="card-body">
                                      <ul>
                                            [% foreach from=$Categories item=category %]
                                                [% foreach from=$FAQCategories item=cat %]
                                                    [% if $cat->FAQCategoryID == $category %]
                                                        <li><a href="#" class="NoClick" >[% $cat->Name %]</a></li>
                                                        [% /if %]
                                                    [% /foreach %]
                                                [% /foreach %]
                                        </ul>
                                </div>
                            </div>
                           
                        [% /if %]
                        [% if $showRating %]
                            <div class="card panel-fcs-content">
                                <div class="card-header">
                                    [% $user->gettext('Bewertung der N&uuml;tzlichkeit dieses Artikels') %]
                                </div>
                                <div class="card-body">
                                     <div>
                                            <b>[% $user->gettext('Durchschnittliche Bewertung') %]:</b> 0 [% $user->gettext('von') %] 5 (0 [% $user->gettext('Bewertungen') %])
                                        </div>

                                        [% if $FAQEntry.voting.voted == 0 %]
                                            <div>
                                                [% $user->gettext('vollkommen &uuml;berflüssig') %]
                                                <input type="radio" name="voting" value="1"> 1
                                                <input type="radio" name="voting" value="2"> 2
                                                <input type="radio" name="voting" value="3"> 3
                                                <input type="radio" name="voting" value="4"> 4
                                                <input type="radio" name="voting" value="5"> 5
                                                [% $user->gettext('sehr wertvoll') %]
                                            </div>
                                        [% /if %]
                                </div>
                            </div>
                        [% /if %]
                    </div>
                </div> 
            </div>
        </div> 
    </div>
</div>

<script>
    $('a.NoClick').click(function(e)
    {
        e.preventDefault();
    });
</script>
