<?php
/* Smarty version 3.1.33, created on 2025-10-17 09:20:54
  from 'C:\php5.6\htdocs\testlink-1.9.20\gui\templates\tl-classic\testcases\object_keywords.inc.tpl' */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '3.1.33',
  'unifunc' => 'content_68f1ee56b46c11_83874315',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    'eaf81304baea1b62ef8b6402c0d56e8580a872ee' => 
    array (
      0 => 'C:\\php5.6\\htdocs\\testlink-1.9.20\\gui\\templates\\tl-classic\\testcases\\object_keywords.inc.tpl',
      1 => 1579460696,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
  ),
),false)) {
function content_68f1ee56b46c11_83874315 (Smarty_Internal_Template $_smarty_tpl) {
$_smarty_tpl->_checkPlugins(array(0=>array('file'=>'C:\\php5.6\\htdocs\\testlink-1.9.20\\vendor\\smarty\\smarty\\libs\\plugins\\modifier.replace.php','function'=>'smarty_modifier_replace',),1=>array('file'=>'C:\\php5.6\\htdocs\\testlink-1.9.20\\vendor\\smarty\\smarty\\libs\\plugins\\function.html_options.php','function'=>'smarty_function_html_options',),));
?>

<?php echo call_user_func_array( $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['lang_get'][0], array( array('var'=>'kw_labels','s'=>'btn_add,btn_add_to_testsuites_deep,
            keywords,img_title_remove_keyword,warning,none,select_keywords'),$_smarty_tpl ) );?>



<?php echo call_user_func_array( $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['lang_get'][0], array( array('s'=>'remove_kw_msgbox_msg','var'=>'remove_kw_msgbox_msg'),$_smarty_tpl ) );?>

<?php echo call_user_func_array( $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['lang_get'][0], array( array('s'=>'remove_kw_msgbox_title','var'=>'remove_kw_msgbox_title'),$_smarty_tpl ) );?>


<?php echo '<script'; ?>
 type="text/javascript">
var alert_box_title = "<?php echo strtr($_smarty_tpl->tpl_vars['kw_labels']->value['warning'], array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
";
var remove_kw_msgbox_msg = '<?php echo strtr($_smarty_tpl->tpl_vars['remove_kw_msgbox_msg']->value, array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
';
var remove_kw_msgbox_title = '<?php echo strtr($_smarty_tpl->tpl_vars['remove_kw_msgbox_title']->value, array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
';

/**
 * 
 *
 */
function keyword_remove_confirmation(item_id, kw_link_id, keyword, title, msg, pFunction) {
  var my_msg = msg.replace('%i',keyword);
  var safe_title = escapeHTML(title);
  Ext.Msg.confirm(safe_title, my_msg,
                  function(btn, text) { 
                    pFunction(btn,text,item_id,kw_link_id);
                  });
}


/**
 * 
 *
 */
function remove_keyword(btn, text, item_id, kw_link_id) {
  var my_action = fRoot + 'lib/testcases/containerEdit.php?doAction=removeKeyword&item_id='
                     + item_id + '&kw_link_id=' + kw_link_id;
  if( btn == 'yes' ) {
    window.location=my_action;
  }
}

var pF_remove_keyword = remove_keyword;

<?php echo '</script'; ?>
>

<form method="post" id="kwf" name="kwf" action="<?php echo $_smarty_tpl->tpl_vars['basehref']->value;?>
lib/testcases/containerEdit.php">
  <input type="hidden" id="kwf_doAction" name="doAction" value="removeKeyword" />
  <input type="hidden" name="item_id" id="item_id" value="<?php echo $_smarty_tpl->tpl_vars['args_item_id']->value;?>
" />
  <input type="hidden" name="containerType" id="containerType" 
    value="<?php echo $_smarty_tpl->tpl_vars['gui']->value->level;?>
" />


  <?php $_smarty_tpl->_assignInScope('kwView', smarty_modifier_replace($_smarty_tpl->tpl_vars['gsmarty_href_keywordsView']->value,'%s%',$_smarty_tpl->tpl_vars['gui']->value->tproject_id));?>

  <table cellpadding="0" cellspacing="0" style="font-size:100%;">
    <tr>
      <td width="15%" style="vertical-align:top;"><a href=<?php echo $_smarty_tpl->tpl_vars['kwView']->value;?>
><?php echo $_smarty_tpl->tpl_vars['kw_labels']->value['keywords'];?>
</a>: &nbsp;
      </td>
      <td style="vertical-align:top;">
          <?php
$_from = $_smarty_tpl->smarty->ext->_foreach->init($_smarty_tpl, $_smarty_tpl->tpl_vars['args_keywords_map']->value, 'kw_link_item');
if ($_from !== null) {
foreach ($_from as $_smarty_tpl->tpl_vars['kw_link_item']->value) {
?>
                <?php echo htmlspecialchars($_smarty_tpl->tpl_vars['kw_link_item']->value['keyword'], ENT_QUOTES, 'UTF-8', true);?>

            <?php if ($_smarty_tpl->tpl_vars['args_edit_enabled']->value && $_smarty_tpl->tpl_vars['gui']->value->assign_keywords) {?>
            <a href="javascript:keyword_remove_confirmation(<?php echo $_smarty_tpl->tpl_vars['gui']->value->item_id;?>
,
                     <?php echo $_smarty_tpl->tpl_vars['kw_link_item']->value['kw_link'];?>
,
                     '<?php echo strtr($_smarty_tpl->tpl_vars['kw_link_item']->value['keyword'], array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
', 
                     remove_kw_msgbox_title, remove_kw_msgbox_msg, 
                     pF_remove_keyword);">
           <img src="<?php echo $_smarty_tpl->tpl_vars['tlImages']->value['delete'];?>
" title="<?php echo $_smarty_tpl->tpl_vars['kw_labels']->value['img_title_remove_keyword'];?>
"  style="border:none" /></a>
           <?php }?>
            <br />
                <?php
}
} else {
?>
                  <?php echo $_smarty_tpl->tpl_vars['kw_labels']->value['none'];?>

            <?php
}
$_smarty_tpl->smarty->ext->_foreach->restore($_smarty_tpl, 1);?>
      </td>      
    </tr>
    <tr>
      <td>
       &nbsp;
      </td> 
    </tr>
    <tr>
      <?php if ($_smarty_tpl->tpl_vars['args_edit_enabled']->value && null != $_smarty_tpl->tpl_vars['gui']->value->freeKeywords) {?> 
      <td>
       &nbsp;
      </td> 
      <td>
        <select id="free_keywords" name="free_keywords[]"
          data-placeholder="<?php echo $_smarty_tpl->tpl_vars['kw_labels']->value['select_keywords'];?>
"
          class="chosen-add-keywords" multiple="multiple">
          <?php echo smarty_function_html_options(array('options'=>$_smarty_tpl->tpl_vars['gui']->value->freeKeywords),$_smarty_tpl);?>

        </select>
        <br>
        <input type="submit" value="<?php echo $_smarty_tpl->tpl_vars['kw_labels']->value['btn_add'];?>
"
          onclick="doAction.value='addKeyword'">
        <input type="submit" value="<?php echo $_smarty_tpl->tpl_vars['kw_labels']->value['btn_add_to_testsuites_deep'];?>
"
          onclick="doAction.value='addKeywordTSDeep'">

      </td>  

      <?php echo '<script'; ?>
>
      jQuery( document ).ready(
        function() { 
          jQuery(".chosen-add-keywords").chosen({ width: "75%", allow_single_deselect: true }); 
        }
      );
      <?php echo '</script'; ?>
>  
      <?php }?>
    </tr>
  </table>  
</form><?php }
}
