* Finish task #9096.

This commit is contained in:
tianshujie98
2021-01-25 13:35:29 +08:00
parent 5b53075640
commit eb6de62f11
4 changed files with 9 additions and 11 deletions
+1 -3
View File
@@ -361,9 +361,7 @@ class custom extends control
{
/* Load module and get the data from the post. */
$this->loadModel('setting');
$data = fixer::input('post')
->setIF(!isset($_POST['efficiency']), 'efficiency', 1)
->get();
$data = fixer::input('post')->get();
/* Judgment of required items. */
if(($unit != $_POST['hourPoint']) and empty($_POST['scaleFactor']))
+2 -2
View File
@@ -18,13 +18,13 @@ $(document).ready(function()
$('#scaleFactor + span').text(workingHours);
$('#efficiency + span').text(workingHours);
$('#efficiency').val("1");
$('#efficiency').attr('disabled', 'diabled');
$('.efficiency').addClass('hidden');
}
if($(this).val() == 1 || $(this).val() == 2)
{
$('#efficiency').val('');
$('#efficiency').removeAttr('disabled');
$('.efficiency').removeClass('hidden');
if($(this).val() == 1)
{
$('#scaleFactor + span').text(storyPoint);
+3 -3
View File
@@ -37,13 +37,13 @@ $lang->custom->system[] = 'estimate';
</td>
<td></td>
</tr>
<tr>
<?php $hidden = $unit == 0 ? 'hidden' : '';?>
<tr class="efficiency <?php echo $hidden;?>">
<th class='w-150px'><?php echo $lang->custom->estimateEfficiency;?></th>
<td>
<div class='input-group w-300px'>
<?php
$disabled = $unit == 0 ? 'disabled' : '';
echo html::input('efficiency', $efficiency, "class='form-control' $disabled");
echo html::input('efficiency', $efficiency, "class='form-control'");
?>
<span class='input-group-addon unify-padding'>
<?php
+3 -3
View File
@@ -32,12 +32,12 @@
<td></td>
<td></td>
</tr>
<tr>
<?php $hidden = $hourPoint == 0 ? 'hidden' : '';?>
<tr class="efficiency <?php echo $hidden?>">
<th><?php echo $lang->workestimation->productivity;?></th>
<td>
<div class='input-group'>
<?php $disabled = $hourPoint == 0 ? 'disabled' : '';?>
<?php echo html::input('productivity', zget($budget, 'productivity', ''), "class='form-control' $disabled");?>
<?php echo html::input('productivity', zget($budget, 'productivity', ''), "class='form-control'");?>
<span class='input-group-addon unify-padding'>
<?php
if($hourPoint == 0) echo $lang->hourCommon;