Subversion Repositories SmartDukaan

Rev

Blame | Last modification | View Log | RSS feed

<!DOCTYPE html PUBLIC 
    "-//W3C//DTD XHTML 1.1 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Synonyms</title>
<link rel="stylesheet" href="css/colorbox.css" type="text/css" />
<link rel="stylesheet" href="css/datatable.css" type="text/css" />
<link type="text/css" href="jquery/jqueryui/themes/ui-lightness/jquery.ui.all.css" rel="stylesheet" />
<style type="text/css">
        
        * { font-family: Verdana; font-size: 96%; }
fieldset.label { width: 10em; float: left; }
label.error { float: none; color: red; padding-left: .5em; vertical-align: top; }
p { clear: both; }
.submit { margin-left: 12em; }
em { font-weight: bold; padding-right: 1em; vertical-align: top; }

        table {
    background-color: white;
    border-collapse: separate;
    border-color: gray;
    border-spacing: 2px;
    border-style: outset;
    border-width: 1px;
}
th {
    background-color: white;
    border-color: gray;
    border-radius: 0 0 0 0;
    border-style: inset;
    border-width: 1px;
    padding: 1px;
}
td {
    background-color: white;
    border-color: gray;
    border-radius: 0 0 0 0;
    border-style: inset;
    border-width: 1px;
    padding: 1px;
}
</style>
<script type="text/javascript" src="jquery/jquery-1.4.2.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.core.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.widget.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.position.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.autocomplete.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.dialog.js"></script>
<script type="text/javascript" src="jquery/validation/jquery.validate.js"></script>

<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.mouse.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.draggable.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.ui.resizable.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.effects.core.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.effects.blind.js"></script>
<script type="text/javascript" src="jquery/jqueryui/ui/jquery.effects.drop.js"></script>
<script type="text/javascript" src="jquery/jquery.chained.js"></script>
<script type="text/javascript" src="jquery/jquery.tablesorter.js"></script>
<script type="text/javascript" src="jquery/thirdparty/jquery.colorbox-min.js"></script>
<script type="text/javascript" src="js/common.js"></script>
<script type="text/javascript" src="js/events.js"></script>
<script type="text/javascript" src="js/synonym-index.js"></script>
<body>
        <div>
                <span align="right"> Welcome $action.getUsername()   <a href="$request.contextPath/logout">logout</a></span>
        </div>
        <div>
                <h1>Synonyms</h1>    
    </div>
    <label for="type">Select Type</label>
        <select id="type">
        <option value="brand">Brand</option>
        <option value="subcategory">Sub Category</option>
    </select>
        <div id="brand">
        #drawAllSynonyms($synonymmap.get("brand") $brands)
        </div>
        <div id="category" style="display:none">
        #drawAllSynonyms($synonymmap.get("subcategory") $leafcategories.values())
        </div>
    
    
</div>

</body>
</html>
</body>
        
#macro (drawAllSynonyms $synonymMap $typeList)
    <table style="width:100%" border cellspacing=1>
                <thead>
                        <tr>
                                <th style="width:17%">Name</th>
                                <th style="width:65%">Synonyms</th>
                                <th style="width:8%">Action</th>
            </tr>
        </thead>
                <tbody>
        #set( $count = 0)
        #foreach ( $type in $typeList )
                #set($count = $count + 1)
                <tr>
            <td class="key">$type</td>
            <td class="synonyms">#if($synonymMap.get($type))$synonymMap.get($type)#end</td>
            <td><a class="edit-link" href="#">edit</a>&nbsp;
            <a class="edit-cancel" style="display:none" href="#">cancel</a></td>
                </tr>
        #end
        </tbody>
        </table>
#end