<?php
/* Smarty version 3.1.33, created on 2022-01-28 17:14:38
  from '/home/recursosspa/public_html/testlink/gui/templates/testcases/containerEdit.tpl' */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '3.1.33',
  'unifunc' => 'content_61f4247ee86684_93347669',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    'da1d4bd652a55e92f7b4e02d80d27f578b3bd79b' => 
    array (
      0 => '/home/recursosspa/public_html/testlink/gui/templates/testcases/containerEdit.tpl',
      1 => 1643038975,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
    'file:inc_head.tpl' => 1,
    'file:inc_del_onclick.tpl' => 1,
    'file:testcases/inc_testsuite_viewer_rw.tpl' => 1,
    'file:opt_transfer.inc.tpl' => 1,
  ),
),false)) {
function content_61f4247ee86684_93347669 (Smarty_Internal_Template $_smarty_tpl) {
$_smarty_tpl->_checkPlugins(array(0=>array('file'=>'/home/recursosspa/public_html/testlink/vendor/smarty/smarty/libs/plugins/modifier.replace.php','function'=>'smarty_modifier_replace',),));
echo call_user_func_array( $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['lang_get'][0], array( array('var'=>"labels",'s'=>'warning_empty_testsuite_name,title_edit_level,btn_save,tc_keywords,cancel,warning,
          warning_unsaved'),$_smarty_tpl ) );?>

<?php $_smarty_tpl->_assignInScope('cfg_section', smarty_modifier_replace(call_user_func_array($_smarty_tpl->registered_plugins[ 'modifier' ][ 'basename' ][ 0 ], array( basename($_smarty_tpl->source->filepath) )),".tpl",''));
$_smarty_tpl->smarty->ext->configLoad->_loadConfigFile($_smarty_tpl, "input_dimensions.conf", $_smarty_tpl->tpl_vars['cfg_section']->value, 0);
?>


<?php $_smarty_tpl->_subTemplateRender("file:inc_head.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array('openHead'=>'yes','jsValidate'=>"yes",'editorType'=>$_smarty_tpl->tpl_vars['editorType']->value), 0, false);
$_smarty_tpl->_subTemplateRender("file:inc_del_onclick.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0, false);
?>

<?php echo '<script'; ?>
 language="javascript" src="gui/javascript/ext_extensions.js" type="text/javascript"><?php echo '</script'; ?>
>

<?php if ($_smarty_tpl->tpl_vars['gui']->value->hasKeywords) {?> 
<?php echo '<script'; ?>
 language="JavaScript" src="gui/javascript/OptionTransfer.js" type="text/javascript"><?php echo '</script'; ?>
>
<?php echo '<script'; ?>
 language="JavaScript" type="text/javascript">
var <?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
 = new OptionTransfer("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->from->name;?>
","<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->to->name;?>
");
<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.saveRemovedLeftOptions("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
_removedLeft");
<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.saveRemovedRightOptions("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
_removedRight");
<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.saveAddedLeftOptions("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
_addedLeft");
<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.saveAddedRightOptions("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
_addedRight");
<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.saveNewLeftOptions("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
_newLeft");
<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.saveNewRightOptions("<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
_newRight");
<?php echo '</script'; ?>
>
<?php }?>

<?php echo '<script'; ?>
 type="text/javascript">
var alert_box_title = "<?php echo strtr($_smarty_tpl->tpl_vars['labels']->value['warning'], array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
";
var warning_empty_container_name = "<?php echo strtr($_smarty_tpl->tpl_vars['labels']->value['warning_empty_testsuite_name'], array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
";
function validateForm(f)
{
  if (isWhitespace(f.container_name.value)) 
  {
      alert_message(alert_box_title,warning_empty_container_name);
      selectField(f, 'container_name');
      return false;
  }
  
  /* Validation of a limited type of custom fields */
  var cf_designTime = document.getElementById('cfields_design_time');
  if (cf_designTime)
  {
    var cfields_container = cf_designTime.getElementsByTagName('input');
    var cfieldsChecks = validateCustomFields(cfields_container);
    if(!cfieldsChecks.status_ok)
    {
      var warning_msg = cfMessages[cfieldsChecks.msg_id];
      alert_message(alert_box_title,warning_msg.replace(/%s/, cfieldsChecks.cfield_label));
      return false;
    }

    cfields_container = cf_designTime.getElementsByTagName('textarea');
    cfieldsChecks = validateCustomFields(cfields_container);
    if(!cfieldsChecks.status_ok)
    {
      var warning_msg = cfMessages[cfieldsChecks.msg_id];
      alert_message(alert_box_title,warning_msg.replace(/%s/, cfieldsChecks.cfield_label));
      return false;
    }
  }

  // Found minor issue, if submit is done with input of type submit, the php script
  // will not receive it
  // 
  return Ext.ux.requireSessionAndSubmit(f);
}
<?php echo '</script'; ?>
>

<?php if ($_smarty_tpl->tpl_vars['tlCfg']->value->gui->checkNotSaved) {?>
  <?php echo '<script'; ?>
 type="text/javascript">
  var unload_msg = "<?php echo strtr($_smarty_tpl->tpl_vars['labels']->value['warning_unsaved'], array("\\" => "\\\\", "'" => "\\'", "\"" => "\\\"", "\r" => "\\r", "\n" => "\\n", "</" => "<\/" ));?>
";
  var tc_editor = "<?php echo $_smarty_tpl->tpl_vars['editorType']->value;?>
";
  <?php echo '</script'; ?>
>
  <?php echo '<script'; ?>
 src="gui/javascript/checkmodified.js" type="text/javascript"><?php echo '</script'; ?>
>
<?php }?>

</head>

<body onLoad="<?php echo $_smarty_tpl->tpl_vars['opt_cfg']->value->js_ot_name;?>
.init(document.forms[0]);focusInputField('name')">
<h1 class="title"><?php echo call_user_func_array( $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['lang_get'][0], array( array('s'=>$_smarty_tpl->tpl_vars['level']->value),$_smarty_tpl ) );
echo @constant('TITLE_SEP');
echo htmlspecialchars($_smarty_tpl->tpl_vars['name']->value, ENT_QUOTES, 'UTF-8', true);?>
</h1> 

<div class="workBack">
  <h1 class="title"><?php echo $_smarty_tpl->tpl_vars['labels']->value['title_edit_level'];?>
 <?php echo call_user_func_array( $_smarty_tpl->smarty->registered_plugins[Smarty::PLUGIN_FUNCTION]['lang_get'][0], array( array('s'=>$_smarty_tpl->tpl_vars['level']->value),$_smarty_tpl ) );?>
</h1> 
  <form method="post" action="<?php echo $_smarty_tpl->tpl_vars['basehref']->value;?>
lib/testcases/containerEdit.php?testsuiteID=<?php echo $_smarty_tpl->tpl_vars['containerID']->value;?>
" 
        name="container_edit" id="container_edit"
        onSubmit="javascript:return validateForm(this);">
  
  <div>
    <input type="hidden" name="containerType" id="containerType" value="testsuite" />
    <input type="hidden" name="doAction" value="" />
    <input type="submit" name="update_testsuite" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['btn_save'];?>
" 
           onclick="show_modified_warning = false; doAction.value='update_testsuite'" />
    <input type="button" name="go_back" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['cancel'];?>
" 
           onclick="javascript: show_modified_warning = false; history.back();"/>
  </div>
   
  <?php $_smarty_tpl->_subTemplateRender("file:testcases/inc_testsuite_viewer_rw.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0, false);
?>

      <?php if ($_smarty_tpl->tpl_vars['cf']->value != '') {?>
     <p>
     <div id="cfields_design_time" class="custom_field_container">
     <?php echo $_smarty_tpl->tpl_vars['cf']->value;?>

     </div>
     <p>
   <?php }?>
  
  <?php if ($_smarty_tpl->tpl_vars['gui']->value->hasKeywords) {?>
  <?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));?> 
  <div>
   <a href=<?php echo $_smarty_tpl->tpl_vars['kwView']->value;?>
><?php echo $_smarty_tpl->tpl_vars['labels']->value['tc_keywords'];?>
</a>
   <?php $_smarty_tpl->_subTemplateRender("file:opt_transfer.inc.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array('option_transfer'=>$_smarty_tpl->tpl_vars['opt_cfg']->value), 0, false);
?>
  </div>
  <?php }?>
  
  <br></br>
  
  <div>
    <input type="submit" name="update_testsuite" id="update_testsuite_bottom" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['btn_save'];?>
" 
           onclick="show_modified_warning = false; doAction.value='update_testsuite'" />
    <input type="button" name="go_back" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['cancel'];?>
" 
           onclick="javascript: show_modified_warning = false; history.back();"/>
  </div>
  </form>
</div>

</body>
</html><?php }
}
