Merge branch 'master' of github.com:easysoft/zentaopms

This commit is contained in:
wangyidong
2016-03-04 13:08:31 +08:00
6 changed files with 104 additions and 44 deletions

View File

@@ -4,3 +4,10 @@ select {border:1px solid #ccc}
.row .col-sm-8{width:76%}
.row .col-sm-2{padding-left:0px; padding-right:0px; width:12%}
#dataform .input-group-btn > .btn + .btn {margin-left: -1px;}
#dataform .input-group-addon > .checkbox-inline {padding-right: 10px;}
#dataform .input-group .chosen-container-single .chosen-single {border-top-right-radius: 0; border-bottom-right-radius: 0}
#title.form-control {border-top-right-radius: 0; border-bottom-right-radius: 0}
.dropdown-pris > .btn {background-color: #fff;}

View File

@@ -9,17 +9,21 @@ $(function()
$('#assignedTo').removeAttr('disabled');
}
$('#assignedTo').trigger("chosen:updated");
})
$('#needNotReview').change(function()
{
if($('#needNotReview').prop('checked'))
$('#needNotReview').change(function()
{
$('#assignedTo').attr('disabled', 'disabled');
}
else
{
$('#assignedTo').removeAttr('disabled');
}
$('#assignedTo').trigger("chosen:updated");
})
if($('#needNotReview').prop('checked'))
{
$('#assignedTo').attr('disabled', 'disabled');
}
else
{
$('#assignedTo').removeAttr('disabled');
}
$('#assignedTo').trigger("chosen:updated");
});
$('[data-toggle=tooltip]').tooltip();
});

View File

@@ -55,10 +55,10 @@
echo html::select('plan', $plans, $planID, "class='form-control chosen'");
if(count($plans) == 1)
{
echo "<span class='input-group-addon'>";
echo html::a($this->createLink('productplan', 'create', "productID=$productID&branch=$branch"), $lang->productplan->create, '_blank');
echo "<span class='input-group-btn'>";
echo html::a($this->createLink('productplan', 'create', "productID=$productID&branch=$branch"), "<i class='icon icon-plus'></i>", '_blank', "class='btn' data-toggle='tooltip' title='{$lang->productplan->create}'");
echo '&nbsp; ';
echo html::a("javascript:loadProductPlans($productID)", $lang->refresh);
echo html::a("javascript:loadProductPlans($productID)", "<i class='icon icon-refresh'></i>", '', "class='btn' data-toggle='tooltip' title='{$lang->refresh}'");
echo '</span>';
}
?>
@@ -83,19 +83,21 @@
<tr>
<th><?php echo $lang->story->title;?></th>
<td colspan='2'>
<div class='row'>
<div class='col-sm-8'>
<div class='row-table'>
<div class='col-table'>
<?php echo html::input('title', $storyTitle, "class='form-control'");?>
</div>
<div class='col-sm-2'>
<div class='input-group'>
<span class='input-group-addon fix-border'><?php echo $lang->story->pri?></span>
<?php echo html::select('pri', (array)$lang->story->priList, $pri, "class='form-control'");?>
</div>
</div>
<div class='col-sm-2'>
<div class='input-group'>
<span class='input-group-addon'><?php echo $lang->story->estimateAB;?></span>
<div class='col-table w-250px'>
<div class="input-group">
<span class='input-group-addon fix-border br-0'><?php echo $lang->story->pri;?></span>
<div class='input-group-btn dropdown-pris' data-set='0,1,2,3,4'>
<button type='button' class='btn dropdown-toggle br-0' data-toggle='dropdown'>
<span class='pri-text'></span> &nbsp;<span class='caret'></span>
</button>
<ul class='dropdown-menu pull-right'></ul>
<?php echo html::select('pri', (array)$lang->story->priList, $pri, "class='hide'");?>
</div>
<span class='input-group-addon fix-border br-0'><?php echo $lang->story->estimateAB;?></span>
<?php echo html::input('estimate', $estimate, "class='form-control'");?>
</div>
</div>
@@ -119,11 +121,9 @@
if($contactLists) echo html::select('', $contactLists, '', "class='form-control chosen' onchange=\"setMailto('mailto', this.value)\"");
if(empty($contactLists))
{
echo '<span class="input-group-addon">';
echo '<a href="' . $this->createLink('company', 'browse') . '" target="_blank">' . $lang->user->contacts->manage . '</a>';
echo '</span>';
echo '<span class="input-group-addon">';
echo '<a href="###" onclick="ajaxGetContacts(this)">' . $lang->refresh . '</a>';
echo '<span class="input-group-btn">';
echo '<a data-toggle="tooltip" title="' . $lang->user->contacts->manage . '" href="' . $this->createLink('company', 'browse') . '" target="_blank" class="btn"><i class="icon icon-cog"></i></a>';
echo '<a data-toggle="tooltip" title="' . $lang->refresh . '" href="###" class="btn" onclick="ajaxGetContacts(this)"><i class="icon icon-refresh"></i></a>';
echo '</span>';
}
?>

View File

@@ -46,9 +46,9 @@ include '../../common/view/header.lite.html.php';
<td>
<?php
echo html::submitButton($lang->login);
if($app->company->guest) echo html::linkButton($lang->user->asGuest, $this->createLink($config->default->module));
echo html::hidden('referer', $referer);
echo html::a(inlink('reset'), $lang->user->resetPassword);
if($app->company->guest) echo '&nbsp; ' . html::linkButton($lang->user->asGuest, $this->createLink($config->default->module));
echo '&nbsp; ' . html::hidden('referer', $referer);
echo '&nbsp; ' . html::a(inlink('reset'), $lang->user->resetPassword);
?>
</td>
</tr>

View File

@@ -1470,6 +1470,46 @@ function fixedTheadOfList(tableID)
});
}
/**
* Init prioprity selectors
* @return void
*/
function initPrioritySelector()
{
$('.dropdown-pris').each(function()
{
var $dropdown = $(this);
var $select = $dropdown.find('select');
var selectVal = parseInt($select.val());
var $menu = $dropdown.children('.dropdown-menu');
if(!$menu.length)
{
$menu = $('<ul class="dropdown-menu"></ul>');
$dropdown.append($menu);
}
if(!$menu.children('li').length)
{
var set = $dropdown.data('set').split(',') || [0,1,2,3,4];
for(var i = 0; i < set.length; ++i)
{
$menu.append('<li><a href="###" data-pri="' + i + '"><span class="pri' + i + '">' + (i ? i : '') + '</span></a></li>');
}
}
$menu.find('a[data-pri="' + selectVal + '"]').parent().addClass('active');
$dropdown.find('.pri-text').html('<span class="pri' + selectVal + '">' + (selectVal ? selectVal : '') + '</span>');
$dropdown.on('click', '.dropdown-menu > li > a', function()
{
var $a = $(this);
$menu.children('li.active').removeClass('active');
$a.parent().addClass('active');
selectVal = $a.data('pri');
$select.val(selectVal);
$dropdown.find('.pri-text').html('<span class="pri' + selectVal + '">' + (selectVal ? selectVal : '') + '</span>');
});
});
}
/* Ping the server every some minutes to keep the session. */
needPing = true;
@@ -1517,6 +1557,8 @@ $(document).ready(function()
if(checkeds != '') checkeds = checkeds.substring(0, checkeds.length - 1);
$.cookie('checkedItem', checkeds, {expires:config.cookieLife, path:config.webRoot});
});
initPrioritySelector();
});
/* CTRL+g, auto focus on the search box. */

View File

@@ -13,7 +13,7 @@
/* Width definitions */
.w-p5 {width: 5%} .w-p10 {width: 10%} .w-p15 {width: 15%} .w-p20 {width: 20%} .w-p25 {width: 25%} .w-p30 {width: 30%} .w-p35 {width: 35%} .w-p40 {width: 40%} .w-p45 {width: 45%} .w-p50 {width: 50%} .w-p55 {width: 55%} .w-p60 {width: 60%} .w-p65 {width: 65%} .w-p70 {width: 70%} .w-p75 {width: 75%} .w-p80 {width: 80%} .w-p85 {width: 85%} .w-p90 {width: 90%} .w-p94 {width: 94%} .w-p95 {width: 95%} .w-p98 {width: 98%} .w-p99 {width: 99%} .w-p100{width: 100%}
.w-auto {width: auto} .w-20px {width:20px} .w-30px {width:30px} .w-35px {width:35px} .w-40px {width:40px} .w-45px {width:45px} .w-50px {width:50px} .w-60px {width:60px} .w-70px {width:70px} .w-80px {width:80px} .w-90px {width:90px} .w-100px {width:100px} .w-110px {width:110px} .w-120px {width:120px} .w-130px {width:130px} .w-140px {width:140px} .w-150px {width:150px} .w-160px {width:160px} .w-180px {width:180px} .w-200px {width:200px} .w-300px {width:300px} .w-400px {width:400px} .w-500px {width:500px} .w-600px {width:600px} .w-700px {width:700px} .w-800px {width:800px} .w-900px {width:900px}
.w-auto {width: auto} .w-20px {width:20px} .w-30px {width:30px} .w-35px {width:35px} .w-40px {width:40px} .w-45px {width:45px} .w-50px {width:50px} .w-60px {width:60px} .w-70px {width:70px} .w-80px {width:80px} .w-90px {width:90px} .w-100px {width:100px} .w-110px {width:110px} .w-120px {width:120px} .w-130px {width:130px} .w-140px {width:140px} .w-150px {width:150px} .w-160px {width:160px} .w-180px {width:180px} .w-200px {width:200px} .w-250px {width:250px} .w-300px {width:300px} .w-400px {width:400px} .w-500px {width:500px} .w-600px {width:600px} .w-700px {width:700px} .w-800px {width:800px} .w-900px {width:900px}
.mw-200px {max-width:200px!important} .mw-300px {max-width:300px!important} .mw-400px {max-width:400px!important} .mw-500px {max-width:500px!important} .mw-600px {max-width:600px!important} .mw-700px {max-width:700px!important} .mw-800px {max-width:800px!important} .mw-900px {max-width:900px!important} .mw-1400px {max-width:1400px!important}
.w-id {width:70px;} .w-pri {width:40px;} .w-severity {width:50px;} .w-hour {width:57px;} .w-date {width:90px;} .w-user {width:80px;} .w-status {width:60px} .w-type {width:80px} .w-resolution {width:70px}
@@ -32,6 +32,7 @@
.pdt-20 {padding-top: 20px !important}
/* borders */
.br-0 {border-radius: 0!important}
.bd-0, .borderless, .bd-none {border: none !important;}
/* backgrounds */
@@ -48,7 +49,7 @@ tr.text-center > td.text-right, tr.text-center > th.text-right {text-align: righ
/* columns */
.row-table {display: table; width: 100%}
.col-side, .col-main {padding: 0; display: table-cell; vertical-align: top;}
.col-side, .col-main, .col-table {padding: 0; display: table-cell; vertical-align: top;}
.col-side {width: 350px; max-width:350px; padding-left: 10px;}
.col-main, .row-table-swap .col-side {padding-right: 10px; padding-left: 0;}
.row-table-swap .col-main {padding-right: 0; padding-left: 10px;}
@@ -147,14 +148,20 @@ i[class^="icon-"],i[class*=" icon-"],.link-icon i[class^="icon-"],.link-icon i[c
.btn-icon.text-danger:hover {color: #7e0501!important}
/* priority icons. */
.pri1,.pri0,.pri2,.pri3,.pri4,.pri5,.pri6,.pri{display:inline-block;width: 18px;height: 18px;font-size: 12px;line-height: 14px;font-weight: bold; text-align: center; color: #272d68; -moz-border-radius:50%; -webkit-border-radius:50%; border-radius:50%;border: 2px solid #272d68; font-family: arial, helvetica, clean, sans-serif;}
.pri,.pri0{border-color: #ccc;color: #ccc;}
.pri:before{content: '?'}
.pri2{border-color: #25367e;color: #25367e}
.pri3{border-color: #2c4a9b;color: #2c4a9b}
.pri4{border-color: #475da8;color: #475da8}
.pri5{border-color: #6989c5;color: #6989c5}
.pri6{border-color: #9ebee5;color: #9ebee5}
.pri1,.pri0,.pri2,.pri3,.pri4,.pri5,.pri6,.pri{display:inline-block;width: 18px;height: 18px;font-size: 12px;line-height: 14px;font-weight: bold; text-align: center; color: #ccc; -moz-border-radius:50%; -webkit-border-radius:50%; border-radius:50%;border: 2px solid #ccc; font-family: arial, helvetica, clean, sans-serif; background-color: #fff}
.pri:before, .pri0:before{content: '?'}
.pri1{border-color: #EA644A;color: #EA644A;}
.pri2{border-color: #F1A325;color: #F1A325;}
.pri3{border-color: #BD7B46;color: #BD7B46;}
.pri4{border-color: #8666B8;color: #8666B8;}
.pri5{border-color: #03B8CF;color: #03B8CF}
.pri6{border-color: #38B03F;color: #38B03F}
.dropdown-pris > .dropdown-menu {padding: 0 5px;}
.dropdown-pris > .dropdown-menu > li {display: table-cell;}
.dropdown-pris > .dropdown-menu > li > a {opacity: 0.6; transition: all .2s; padding: 6px 5px; display: block}
.dropdown-pris > .dropdown-menu > li.active > a {opacity: 1}
.dropdown-pris > .dropdown-menu > li.active > a:before {display: none}
.dropdown-pris > .dropdown-menu > li > a:hover {background-color: #f5f5f5; opacity: 1}
/* bug severity icons. */
.severity,.severity1,.severity2,.severity3,.severity4,.severity5,.severity6{display:inline-block;width: 16px;height: 16px;line-height: 16px;font-weight: bold; text-align: center; font-size: 12px; color: #fff; -moz-border-radius:50%; -webkit-border-radius:50%; border-radius:50%;font-family: arial, helvetica, clean, sans-serif;}