* adjust the code.

This commit is contained in:
chencongzhi520@gmail.com
2013-07-06 03:00:01 +00:00
parent 8386fa93a7
commit bcf35c4b7b
20 changed files with 84 additions and 86 deletions

View File

@@ -8,11 +8,11 @@
<td><?php echo html::select('assignedTo', $users, $bug->resolvedBy, 'class=select-3');?></td>
</tr>
<tr>
<td class='w-80px'><?php echo $lang->bug->openedBuild;?></td>
<td><?php echo $lang->bug->openedBuild;?></td>
<td><?php echo html::select('openedBuild[]', $builds, $bug->openedBuild, 'size=4 multiple=multiple class=select-3');?></td>
</tr>
<tr>
<td class='w-80px'><?php echo $lang->comment;?></td>
<td><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '');?></td>
</tr>
<tr>

View File

@@ -24,14 +24,6 @@
<div data-role='navbar'>
<ul>
<?php
if($this->session->bugList)
{
$browseLink = $this->session->bugList;
}
else
{
$browseLink = $this->createLink('my', 'bug');
}
common::printIcon('bug', 'confirmBug', "bugID=$bug->id", $bug, 'button', '', '', 'iframe');
common::printIcon('bug', 'assignTo', "bugID=$bug->id", '', 'button', '', '', 'iframe');
common::printIcon('bug', 'resolve', "bugID=$bug->id", $bug, 'button', '', '', 'iframe');

View File

@@ -300,7 +300,7 @@ class common extends control
{
if($app->getViewType() == 'mhtml')
{
echo html::a($link, $title, $target, "class='$extraClass' data-role='button' data-mini='true' data-inline='true' ", true);
echo html::a($link, $title, $target, "class='$extraClass' data-role='button' data-mini='true' data-inline='true' data-theme='b'", true);
return;
}
if($type == 'button')

View File

@@ -60,6 +60,8 @@ $lang->fold = '-';
$lang->selectAll = 'All';
$lang->selectReverse = 'Inverse';
$lang->notFound = 'Sorry, the object not found.';
$lang->showAll = '[[Show all projects]]';
$lang->hideClosed = '[[Show projects going]]';
$lang->future = 'Future';
$lang->year = 'Year';

View File

@@ -60,6 +60,8 @@ $lang->fold = '-';
$lang->selectAll = '全选';
$lang->selectReverse = '反选';
$lang->notFound = '抱歉,您访问的对象并不存在!';
$lang->showAll = '[[全部显示]]';
$lang->hideClosed = '[[显示进行中]]';
$lang->future = '未来';
$lang->year = '年';

View File

@@ -23,14 +23,6 @@
<div id='item<?php echo $bug->id;?>'></div>
<div data-role='content' class='a-center'>
<?php
if($this->session->bugList)
{
$browseLink = $this->session->bugList;
}
else
{
$browseLink = $this->createLink('my', 'bug');
}
common::printIcon('bug', 'confirmBug', "bugID=$bug->id", $bug, 'button', '', '', 'iframe');
common::printIcon('bug', 'assignTo', "bugID=$bug->id", '', 'button', '', '', 'iframe');
common::printIcon('bug', 'resolve', "bugID=$bug->id", $bug, 'button', '', '', 'iframe');

View File

@@ -25,16 +25,15 @@
<div data-role="collapsible" data-collapsed="true">
<?php if($this->session->storyID == $story->id) echo "<script>showDetail('story', $story->id);</script>";?>
<h1 onClick="showDetail('story', <?php echo $story->id;?>)"><?php echo $story->title;?></h1>
<div id='item<?php echo $story->id;?>'></div>
<div data-role='content' class='a-center'>
<?php
if(!$story->deleted)
{
common::printIcon('story', 'review', "storyID=$story->id", $story);
common::printIcon('story', 'close', "storyID=$story->id", $story);
common::printIcon('story', 'activate', "storyID=$story->id", $story);
common::printIcon('story', 'delete', "storyID=$story->id", '', '', '', 'hiddenwin');
common::printIcon('story', 'review', "storyID=$story->id", $story);
common::printIcon('story', 'close', "storyID=$story->id", $story);
common::printIcon('story', 'activate', "storyID=$story->id", $story);
common::printIcon('story', 'delete', "storyID=$story->id", '', '', '', 'hiddenwin');
}
?>
</div>

View File

@@ -20,7 +20,7 @@
</ul>
</div>
</div>
<?php foreach($todos as $todo):?>
<?php foreach($todos as $todo):?>
<?php if(!$todo->private or ($todo->private and $todo->account == $app->user->account)):?>
<div data-role="collapsible-set">
<div data-role="collapsible" data-collapsed="true" class='collapsible'>

View File

@@ -87,4 +87,4 @@ $lang->product->aclList['private'] = '私有产品(只有项目团队成员才
$lang->product->aclList['custom'] = '自定义白名单(团队成员和白名单的成员可以访问)';
$lang->product->storySummary = "本页共 <strong>%s</strong> 个需求,预计 <strong>%s</strong> 个工时。";
$lang->product->noMatchedProduct = '找不到包含"%s"的产品';
$lang->product->noMatchedProduct = '找不到"%s"相关的产品';

View File

@@ -145,6 +145,7 @@ class productModel extends model
public function getPairs($mode = '')
{
$orderBy = !empty($this->config->product->orderBy) ? $this->config->product->orderBy : 'isClosed';
$mode .= $this->cookie->productMode;
$products = $this->dao->select('*, IF(INSTR(" closed", status) < 2, 0, 1) AS isClosed')
->from(TABLE_PRODUCT)
->where('deleted')->eq(0)

View File

@@ -2,25 +2,25 @@ function setModal4List(colorboxClass, replaceID)
{
replaceID = 'bugList';
$('.' + colorboxClass).colorbox(
{
width:900,
height:500,
iframe:true,
transition:'none',
onCleanup:function()
{
width:900,
height:500,
iframe:true,
transition:'none',
saveWindowSize();
onCleanup:function()
var link = self.location.href;
$.get(link, {onlybody: "yes"}, function(data)
{
saveWindowSize();
$('#' + replaceID).replaceWith(data)
setModal4List(colorboxClass, replaceID)
var link = self.location.href;
$.get(link, {onlybody: "yes"}, function(data)
{
$('#' + replaceID).replaceWith(data)
setModal4List(colorboxClass, replaceID)
$('.colored').colorize();
$('tfoot td').css('background', 'white').unbind('click').unbind('hover');
});
}
});
$('.colored').colorize();
$('tfoot td').css('background', 'white').unbind('click').unbind('hover');
});
}
});
}

View File

@@ -178,7 +178,7 @@ $lang->project->whyNoStories = "看起来没有需求可以关联。请检
$lang->project->doneProjects = '已结束';
$lang->project->unDoneProjects = '未结束';
$lang->project->copyTeam = '复制团队';
$lang->product->noMatchedProject = '找不到包含"%s"的项目';
$lang->product->noMatchedProject = '找不到"%s"相关的项目';
/* 交互提示。*/
$lang->project->confirmDelete = '您确定删除项目[%s]吗?';

View File

@@ -89,6 +89,12 @@ class projectModel extends model
$moduleName = $this->app->getModuleName();
$methodName = $this->app->getMethodName();
if($this->cookie->projectMode == 'noclosed' and $project->status == 'done')
{
setcookie('projectMode', 'all');
$this->cookie->projectMode = 'all';
}
$selectHtml = $this->select($projects, $projectID, $moduleName, $methodName, $extra);
foreach($this->lang->project->menu as $key => $menu)
{
@@ -433,7 +439,8 @@ class projectModel extends model
*/
public function getPairs($mode = '')
{
$orderBy = !empty($this->config->project->orderBy) ? $this->config->project->orderBy : 'isDone, status';
$orderBy = !empty($this->config->project->orderBy) ? $this->config->project->orderBy : 'isDone, status';
$mode .= $this->cookie->projectMode;
/* Order by status's content whether or not done */
$projects = $this->dao->select('*, IF(INSTR(" done", status) < 2, 0, 1) AS isDone')->from(TABLE_PROJECT)
->where('iscat')->eq(0)

View File

@@ -2,18 +2,17 @@
</div>
<form method='post' target='hiddenwin' onsubmit='return checkLeft();'>
<h3><?php echo $lang->task->activate . $this->lang->colon . $task->name;?></h3>
<table class='table-1'>
<tr>
<td class="w-70px"><?php echo $lang->task->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $task->openedBy);?>
</tr>
<tr>
<td class="w-70px"><?php echo $lang->task->left;?></td>
<td><?php echo $lang->task->left;?></td>
<td><?php echo html::input('left', '');?>
</div>
<tr>
<td class='w-70px'><?php echo $lang->comment;?></td>
<td><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "data-mini='true'");?></td>
</tr>
<tr class="a-center">

View File

@@ -2,18 +2,17 @@
</div>
<form method='post' target='hiddenwin'>
<h3><?php echo $lang->task->assignTo . $this->lang->colon . $task->name;?></h3>
<table class='table-1'>
<tr>
<td class="w-70px"><?php echo $lang->task->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $task->openedBy);?>
</tr>
<tr>
<td class="w-70px"><?php echo $lang->task->left;?></td>
<td><?php echo $lang->task->left;?></td>
<td><?php echo html::input('left', $task->left);?></td>
</tr>
<tr>
<td class='w-70px'><?php echo $lang->comment;?></td>
<td><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "data-mini='true'");?></td>
</tr>
<tr class='a-center'>

View File

@@ -2,22 +2,27 @@
</div>
<form method='post' target='hiddenwin' onsubmit='return checkLeft();'>
<h3><?php echo $lang->task->finish . $this->lang->colon . $task->name;?></h3>
<table class='table-1'>
<tr>
<td class="w-70px"><?php echo $lang->task->consumed;?></td>
<td><?php echo html::input('consumed', $task->consumed);?></td>
</tr>
<tr>
<td class="w-70px"><?php echo $lang->task->assignedTo;?></td>
<td><?php echo $lang->task->assignedTo;?></td>
<td><?php echo html::select('assignedTo', $users, $task->openedBy);?></td>
</tr>
<tr>
<td class='w-70px'><?php echo $lang->comment;?></td>
<td><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "data-mini='true'");?></td>
</tr>
<tr class='a-center'>
<td colspan="2"><?php echo html::submitButton('', 'data-inline="true" data-theme="b"') . html::backButton("data-inline='true'") . html::hidden('finishedDate', $date);?></td>
<td colspan="2">
<?php
echo html::submitButton('', 'data-inline="true" data-theme="b"');
echo html::backButton("data-inline='true'");
echo html::hidden('finishedDate', $date);
?>
</td>
</tr>
</table>
</form>

View File

@@ -7,8 +7,8 @@
$allLeft = 0;
foreach($estimates as $estimate)
{
$allConsumed += $estimate->consumed;
$allLeft = $estimate->left;
$allConsumed += $estimate->consumed;
$allLeft = $estimate->left;
}
?>
<table class='table-1'>

View File

@@ -2,22 +2,27 @@
</div>
<form method='post' target='hiddenwin' onsubmit='return checkLeft();'>
<h3><?php echo $lang->task->start . $this->lang->colon . $task->name;?></h3>
<table class='table-1'>
<tr>
<td class='w-70px'><?php echo $lang->task->consumed;?></td>
<td><?php echo html::input('consumed', $task->consumed);?></td>
</tr>
<tr>
<td class='w-70px'><?php echo $lang->task->left;?></td>
<td><?php echo $lang->task->left;?></td>
<td><?php echo html::input('left', $task->left);?></td>
</tr>
<tr>
<td class='w-70px'><?php echo $lang->comment;?></td>
<td><?php echo $lang->comment;?></td>
<td><?php echo html::textarea('comment', '', "data-mini='true'");?></td>
</tr>
<tr class="a-center">
<td colspan="2"><?php echo html::submitButton('', 'data-inline="true" data-theme="b"') . html::backButton("data-inline='true'") . html::hidden('realStarted', helper::today());?></td>
<td colspan="2">
<?php
echo html::submitButton('', 'data-inline="true" data-theme="b"');
echo html::backButton("data-inline='true'");
echo html::hidden('realStarted', helper::today());
?>
</td>
</tr>
</table>
</form>

View File

@@ -13,22 +13,23 @@
<?php include '../../common/view/m.header.html.php';?>
</div>
<form method='post' target='hiddenwin'>
<?php echo html::hidden("date", date('Y-m-d'));?>
<?php for($i = 1; $i <= 5; $i++):?>
<?php
echo html::input("names[$i]", '', "placeholder='{$lang->todo->common}{$lang->todo->name}'");
echo html::hidden("types[$i]", 'custom');
echo html::hidden("pris[$i]", 3);
echo html::hidden("descs[$i]", '');
echo html::hidden("begins[$i]", '2400');
echo html::hidden("ends[$i]", '2400');
?>
<?php endfor;?>
<?php
echo html::hidden("date", date('Y-m-d'));
for($i = 1; $i <= 5; $i++)
{
echo html::input("names[$i]", '', "placeholder='{$lang->todo->common}{$lang->todo->name}'");
echo html::hidden("types[$i]", 'custom');
echo html::hidden("pris[$i]", 3);
echo html::hidden("descs[$i]", '');
echo html::hidden("begins[$i]", '2400');
echo html::hidden("ends[$i]", '2400');
}
?>
<p class='a-center'>
<?php
echo html::submitButton('', "data-inline='true' data-theme='b'");
echo html::backButton("data-inline='true'");
?>
<?php
echo html::submitButton('', "data-inline='true' data-theme='b'");
echo html::backButton("data-inline='true'");
?>
</p>
</form>
<?php include '../../common/view/m.footer.html.php';?>

View File

@@ -8,23 +8,17 @@
* @package ZenTaoPMS
* @version $Id: login.html.php 4612 2013-03-18 07:46:16Z wwccss $
*/
include '../../common/view/m.header.lite.html.php';
?>
<?php include '../../common/view/m.header.lite.html.php';?>
<div data-role="header" data-position="fixed">
<h1><?php echo $lang->user->mobileWeb->login;?></h1>
</div>
<div data-role="content" >
<form method='post' target='hiddenwin'>
<table align='center'>
<tr>
<td><input type='text' name='account' id='account' placeholder='<?php echo $lang->user->account?>' /></td>
</tr>
<tr>
<td><input type='password' name='password' placeholder='<?php echo $lang->user->password?>' /></td>
</tr>
<tr>
<td><?php echo html::select('lang', $config->langs, $this->app->getClientLang(), 'class=select-2 onchange=selectLang(this.value)');?></td>
</tr>
<tr><td><input type='text' name='account' id='account' placeholder='<?php echo $lang->user->account?>' /></td></tr>
<tr><td><input type='password' name='password' placeholder='<?php echo $lang->user->password?>' /></td></tr>
<tr><td><?php echo html::select('lang', $config->langs, $this->app->getClientLang(), 'class=select-2 onchange=selectLang(this.value)');?></td></tr>
<tr>
<td align='center'>
<?php