<?php
/* Smarty version 3.1.33, created on 2022-01-28 15:02:42
  from '/home/recursosspa/public_html/testlink/gui/templates/testcases/containerNew.tpl' */

/* @var Smarty_Internal_Template $_smarty_tpl */
if ($_smarty_tpl->_decodeProperties($_smarty_tpl, array (
  'version' => '3.1.33',
  'unifunc' => 'content_61f40592950612_60200617',
  'has_nocache_code' => false,
  'file_dependency' => 
  array (
    'd506c61f3c2dd1691766d3de85429f7ed3715228' => 
    array (
      0 => '/home/recursosspa/public_html/testlink/gui/templates/testcases/containerNew.tpl',
      1 => 1643038976,
      2 => 'file',
    ),
  ),
  'includes' => 
  array (
    'file:inc_head.tpl' => 1,
    'file:inc_del_onclick.tpl' => 1,
    'file:inc_update.tpl' => 1,
    'file:testcases/inc_testsuite_viewer_rw.tpl' => 1,
    'file:opt_transfer.inc.tpl' => 1,
  ),
),false)) {
function content_61f40592950612_60200617 (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',),));
?>

<?php
$_smarty_tpl->smarty->ext->configLoad->_loadConfigFile($_smarty_tpl, "input_dimensions.conf", "containerEdit", 0);
?>

<?php 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_create,tc_keywords,
             warning,btn_create_testsuite,btn_save,cancel,warning_unsaved"),$_smarty_tpl ) );?>


<?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"), 0, false);
?>

<?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 $_smarty_tpl->_subTemplateRender("file:inc_del_onclick.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array(), 0, false);
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;
    }
  }
  
  return true;
}
<?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 $_smarty_tpl->tpl_vars['parent_info']->value['description'];
echo @constant('TITLE_SEP');
echo htmlspecialchars($_smarty_tpl->tpl_vars['parent_info']->value['name'], ENT_QUOTES, 'UTF-8', true);?>
</h1>
<div class="workBack">
<h1 class="title"><?php echo $_smarty_tpl->tpl_vars['labels']->value['title_create'];?>
 <?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>
<?php $_smarty_tpl->_subTemplateRender("file:inc_update.tpl", $_smarty_tpl->cache_id, $_smarty_tpl->compile_id, 0, $_smarty_tpl->cache_lifetime, array('result'=>$_smarty_tpl->tpl_vars['sqlResult']->value,'user_feedback'=>$_smarty_tpl->tpl_vars['user_feedback']->value,'item'=>$_smarty_tpl->tpl_vars['level']->value,'action'=>"add",'name'=>$_smarty_tpl->tpl_vars['name']->value,'refresh'=>$_smarty_tpl->tpl_vars['gui']->value->refreshTree), 0, false);
?>


<form method="post" action="<?php echo $_smarty_tpl->tpl_vars['basehref']->value;?>
lib/testcases/containerEdit.php?containerID=<?php echo $_smarty_tpl->tpl_vars['containerID']->value;?>
"
        name="container_new" id="container_new"
        onSubmit="javascript:return validateForm(this);">

  <div style="font-weight: bold;">
    <div>
      <input type="hidden" name="containerType" id="containerType" value="<?php echo $_smarty_tpl->tpl_vars['gui']->value->containerType;?>
"/>
      <input type="hidden" name="add_testsuite" id="add_testsuite" />
      <input type="submit" name="add_testsuite_button" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['btn_save'];?>
"
             onclick="show_modified_warning = false;" />
  
      <input type="button" name="go_back" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['cancel'];?>
" 
             onclick="show_modified_warning=false; 
                     javascript: <?php if (isset($_smarty_tpl->tpl_vars['gui']->value->cancelActionJS)) {
echo $_smarty_tpl->tpl_vars['gui']->value->cancelActionJS;?>
 <?php } else { ?> history.back() <?php }?>;"/>



    </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 != '') {?>
     <br />
     <div id="cfields_design_time" class="custom_field_container">
     <?php echo $_smarty_tpl->tpl_vars['cf']->value;?>

     </div>
   <?php }?>
   
     <br />
   <div>
   <?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));?>
   <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>
   <br />
  <div>
    <input type="submit" name="add_testsuite_button" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['btn_save'];?>
" 
           onclick="show_modified_warning = false;" />

    <input type="button" name="go_back" value="<?php echo $_smarty_tpl->tpl_vars['labels']->value['cancel'];?>
" 
           onclick="show_modified_warning=false; 
                    javascript: <?php if (isset($_smarty_tpl->tpl_vars['gui']->value->cancelActionJS)) {
echo $_smarty_tpl->tpl_vars['gui']->value->cancelActionJS;?>
 <?php } else { ?> history.back() <?php }?>;"/>
  </div>  

</div>
</form>
</body>
</html><?php }
}
