* Add skip method page form stash.
This commit is contained in:
@@ -75,7 +75,7 @@ html[lang^='zh-'] .operatorWidth {width: 90px !important;}
|
||||
<i class='icon icon-angle-left'></i>
|
||||
</div>
|
||||
<?php endif;?>
|
||||
<form method='post' action='<?php echo $this->createLink('search', 'buildQuery');?>' target='hiddenwin' id='<?php echo $formId;?>' class='search-form<?php if($style == 'simple') echo ' search-form-simple';?>'>
|
||||
<form method='post' action='<?php echo $this->createLink('search', 'buildQuery');?>' target='hiddenwin' id='<?php echo $formId;?>' class='search-form no-stash<?php if($style == 'simple') echo ' search-form-simple';?>'>
|
||||
<div class='hidden'>
|
||||
<?php
|
||||
/* Print every field as an html object, select or input. Thus when setFiled is called, copy it's html to build the search form. */
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.lite.html.php';?>
|
||||
<form target='hiddenwin' method='post' style='padding: 15px 70px 15px 15px'>
|
||||
<form target='hiddenwin' method='post' class='no-stash' style='padding: 15px 70px 15px 15px'>
|
||||
<div class='input-group'>
|
||||
<input name='title' id='title' class="form-control" autocomplete="off" type="text">
|
||||
<span class='input-group-addon'>
|
||||
|
||||
+10
-2
@@ -21,14 +21,22 @@
|
||||
*/
|
||||
function handleSaveFormDraft()
|
||||
{
|
||||
if(config.currentMethod === 'login' || config.currentModule === 'repo' || config.currentMethod.indexOf('edit') != -1 || config.currentMethod.indexOf('import') != -1) return;
|
||||
if(config.currentModule === 'repo') return;
|
||||
|
||||
var skipMethods = ['edit', 'import', 'login', 'export', 'finish', 'confirm', 'resolve', 'start', 'pause', 'cancel', 'report', 'close', 'activate', 'restart', 'suspend', 'putoff', 'browse', 'hangup', 'track', 'index', 'reply'];
|
||||
for(var i = 0; i < skipMethods.length; i++)
|
||||
{
|
||||
if(config.currentMethod.indexOf(skipMethods[i]) === 0) return;
|
||||
};
|
||||
|
||||
setTimeout(function()
|
||||
{
|
||||
var form = $('form[method=post]');
|
||||
if(form.length)
|
||||
{
|
||||
if($(form).hasClass('no-stash') || $(form).data('ride') == 'table') return;
|
||||
if($(form).attr('target') == 'hiddenwin' && config.currentModule.indexOf('program') != -1 && config.currentModule.indexOf('project') != -1 && config.currentModule.indexOf('testcase') != -1) return;
|
||||
if($(form).attr('target') == 'hiddenwin' && config.currentModule.indexOf('program') != -1 && config.currentModule.indexOf('project') != -1 && config.currentModule.indexOf('testcase') != -1) return;
|
||||
|
||||
var formID = config.currentMethod + '-' + config.currentModule + '-' + $(form).attr("id");
|
||||
var formDataStored = $.zui.store.get(formID);
|
||||
setTimeout(function() {
|
||||
|
||||
Reference in New Issue
Block a user