* adjust the save user template feature.
This commit is contained in:
+13
-11
@@ -523,25 +523,19 @@ class bug extends control
|
||||
}
|
||||
}
|
||||
|
||||
/* 获得用户的bug列表。*/
|
||||
public function ajaxGetUserBugs($account = '')
|
||||
{
|
||||
if($account == '') $account = $this->app->user->account;
|
||||
$bugs = $this->bug->getUserBugPairs($account);
|
||||
die(html::select('bug', $bugs, '', 'class=select-1'));
|
||||
}
|
||||
|
||||
/* 保存模板。*/
|
||||
public function saveTemplate()
|
||||
{
|
||||
$this->bug->saveUserBugTemplate();
|
||||
if(dao::isError()) die(js::error(dao::getError()));
|
||||
die($this->fetch('bug', 'createTPLS'));
|
||||
die($this->fetch('bug', 'buildTemplates'));
|
||||
}
|
||||
|
||||
public function createTPLS()
|
||||
/* 生成模板选择页面。*/
|
||||
public function buildTemplates()
|
||||
{
|
||||
$this->view->templates = $this->bug->getUserBugTemplates($this->app->user->account);
|
||||
$this->display('bug', 'createTPLS');
|
||||
$this->display('bug', 'buildTemplates');
|
||||
}
|
||||
|
||||
/* 删除一个bug模板。*/
|
||||
@@ -551,6 +545,14 @@ class bug extends control
|
||||
die();
|
||||
}
|
||||
|
||||
/* 获得用户的bug列表。*/
|
||||
public function ajaxGetUserBugs($account = '')
|
||||
{
|
||||
if($account == '') $account = $this->app->user->account;
|
||||
$bugs = $this->bug->getUserBugPairs($account);
|
||||
die(html::select('bug', $bugs, '', 'class=select-1'));
|
||||
}
|
||||
|
||||
/* 发送邮件。*/
|
||||
private function sendmail($bugID, $actionID)
|
||||
{
|
||||
|
||||
@@ -177,7 +177,7 @@ $(function() {
|
||||
<table class='w-p100 bd-none'>
|
||||
<tr class='bd-none' valign='top'>
|
||||
<td class='w-p85 bd-none padding-zero'><?php echo html::textarea('steps', $steps, "class='w-p100' rows='6'");?></td>
|
||||
<td class='bd-none pl-10px' id='tplBox'><?php echo $this->fetch('bug', 'createTPLS');?></td>
|
||||
<td class='bd-none pl-10px' id='tplBox'><?php echo $this->fetch('bug', 'buildTemplates');?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
Reference in New Issue
Block a user