* task #7126, refactor all project/create btn to program/createguide.

This commit is contained in:
Catouse
2020-05-11 10:27:50 +08:00
parent f005903fd7
commit 80c1978afa
9 changed files with 13 additions and 13 deletions
@@ -190,7 +190,7 @@ $(function()
</div>
<?php else:?>
<div class="actions">
<?php common::printLink('project', 'create', '', "<i class='icon icon-plus'></i>" . $lang->project->create, '', "class='btn btn-info'");?>
<?php common::printLink('program', 'createguide', '', "<i class='icon icon-plus'></i>" . $lang->project->create, '', "class='btn btn-info' data-toggle='modal' data-type='ajax'");?>
</div>
<?php endif;?>
<div class="type-info">
+1 -1
View File
@@ -11,7 +11,7 @@
*/
?>
<?php if(empty($projectStats)): ?>
<div class='empty-tip'><?php common::printLink('project', 'create', '', "<i class='icon-plus'></i> " . $lang->project->create, '', "class='btn btn-primary'")?></div>
<div class='empty-tip'><?php common::printLink('program', 'createguide', '', "<i class='icon-plus'></i> " . $lang->project->create, '', "class='btn btn-primary' data-toggle='modal' data-type='ajax'")?></div>
<?php else:?>
<div class="panel-body has-table scrollbar-hover">
<table class='table table-borderless table-hover table-fixed table-fixed-head tablesorter block-projects tablesorter'>
+3 -3
View File
@@ -16,7 +16,7 @@
<span class='btn btn-link btn-active-text'><span class='text'><?php echo $lang->my->myProject;?></span></span>
</div>
<div class="btn-toolbar pull-right">
<?php if(common::hasPriv('project', 'create')) echo html::a(helper::createLink('project', 'create'), "<i class='icon-plus'></i> " . $lang->my->home->createProject, '', "class='btn btn-primary'") ?>
<?php if(common::hasPriv('program', 'createguide')) echo html::a(helper::createLink('program', 'createguide'), "<i class='icon-plus'></i> " . $lang->my->home->createProject, '', "class='btn btn-primary' data-toggle='modal' data-type='ajax'") ?>
</div>
</div>
<div id="mainContent" class='main-table'>
@@ -24,8 +24,8 @@
<div class="table-empty-tip">
<p>
<span class="text-muted"><?php echo $lang->project->noProject;?></span>
<?php if(common::hasPriv('project', 'create')):?>
<?php echo html::a($this->createLink('project', 'create'), "<i class='icon icon-plus'></i> " . $lang->my->home->createProject, '', "class='btn btn-info'");?>
<?php if(common::hasPriv('program', 'createguide')):?>
<?php echo html::a($this->createLink('program', 'createguide'), "<i class='icon icon-plus'></i> " . $lang->my->home->createProject, '', "class='btn btn-info' data-toggle='modal' data-type='ajax'");?>
<?php endif;?>
</p>
</div>
+2 -2
View File
@@ -23,8 +23,8 @@
<div class="table-empty-tip">
<p>
<span class="text-muted"><?php echo $lang->project->noProject;?></span>
<?php if(common::hasPriv('project', 'create')):?>
<?php echo html::a($this->createLink('project', 'create'), "<i class='icon icon-plus'></i> " . $lang->project->create, '', "class='btn btn-info'");?>
<?php if(common::hasPriv('program', 'createguide')):?>
<?php echo html::a($this->createLink('program', 'createguide'), "<i class='icon icon-plus'></i> " . $lang->project->create, '', "class='btn btn-info' data-toggle='modal' data-type='ajax'");?>
<?php endif;?>
</p>
</div>
+1 -1
View File
@@ -117,7 +117,7 @@
</td>
<td class='c-actions'>
<?php
if(common::hasPriv('project', 'create')) echo html::a(helper::createLink('project', 'create', "projectID=&copyProjectID=&planID=$plan->id"), '<i class="icon-plus"></i>', '', "class='btn' title='{$lang->project->create}'");
if(common::hasPriv('program', 'createguide')) echo html::a(helper::createLink('program', 'createguide', "projectID=&copyProjectID=&planID=$plan->id"), '<i class="icon-plus"></i>', '', "class='btn' title='{$lang->project->create}' data-toggle='modal' data-type='ajax'");
if(common::hasPriv('productplan', 'linkStory')) echo html::a(inlink('view', "planID=$plan->id&type=story&orderBy=id_desc&link=true"), '<i class="icon-link"></i>', '', "class='btn' title='{$lang->productplan->linkStory}'");
if(common::hasPriv('productplan', 'linkBug') and $config->global->flow != 'onlyStory') echo html::a(inlink('view', "planID=$plan->id&type=bug&orderBy=id_desc&link=true"), '<i class="icon-bug"></i>', '', "class='btn' title='{$lang->productplan->linkBug}'");
common::printIcon('productplan', 'edit', "planID=$plan->id", $plan, 'list');
+1 -1
View File
@@ -45,7 +45,7 @@ class project extends control
if($this->app->viewType != 'mhtml') unset($this->lang->project->menu->index);
$this->commonAction($projectID);
if(common::hasPriv('project', 'create')) $this->lang->modulePageActions = html::a($this->createLink('project', 'createguide'), "<i class='icon icon-sm icon-plus'></i> " . $this->lang->project->create, '', "class='btn btn-primary'");
if(common::hasPriv('program', 'createguide')) $this->lang->modulePageActions = html::a($this->createLink('project', 'createguide'), "<i class='icon icon-sm icon-plus'></i> " . $this->lang->project->create, '', "class='btn btn-primary' data-toggle='modal' data-type='ajax'");
$this->view->title = $this->lang->project->index;
$this->view->position[] = $this->lang->project->index;
+2 -2
View File
@@ -114,7 +114,7 @@ class projectModel extends model
}
else
{
if(common::hasPriv('project', 'create')) $projectIndex .= '<li>' . html::a(helper::createLink('project', 'create'), '<i class="icon icon-plus"></i> ' . $this->lang->project->create) . '</li>';
if(common::hasPriv('program', 'createguide')) $projectIndex .= '<li>' . html::a(helper::createLink('program', 'createguide'), '<i class="icon icon-plus"></i> ' . $this->lang->project->create, '', " data-toggle='modal' data-type='ajax'") . '</li>';
}
$projectIndex .= '</ul></div></div>';
@@ -364,7 +364,7 @@ class projectModel extends model
}
}
if(!dao::isError()) $this->loadModel('score')->create('project', 'create', $projectID);
if(!dao::isError()) $this->loadModel('score')->create('program', 'createguide', $projectID);
return $projectID;
}
}
+1 -1
View File
@@ -22,7 +22,7 @@
</div>
<div class='btn-toolbar pull-right'>
<?php common::printLink('project', 'export', "status=$status&productID=$productID&orderBy=$orderBy", "<i class='icon-export muted'> </i>" . $lang->export, '', "class='btn btn-link export'")?>
<?php common::printLink('project', 'create', '', "<i class='icon-plus'></i> " . $lang->project->create, '', "class='btn btn-primary'")?>
<?php common::printLink('program', 'createguide', '', "<i class='icon-plus'></i> " . $lang->project->create, '', "class='btn btn-primary' data-toggle='modal' data-type='ajax'")?>
</div>
</div>
<div id='mainContent'>
+1 -1
View File
@@ -12,7 +12,7 @@
<?php include '../../common/view/header.html.php';?>
<?php if(empty($projects)):?>
<div class="table-empty-tip">
<p><span class="text-muted"><?php echo $lang->project->noProject;?></span> <?php common::printLink('project', 'create', '', "<i class='icon icon-plus'></i> " . $lang->project->create, '', "class='btn btn-info'");?></p>
<p><span class="text-muted"><?php echo $lang->project->noProject;?></span> <?php common::printLink('program', 'createguide', '', "<i class='icon icon-plus'></i> " . $lang->project->create, '', "class='btn btn-info' data-toggle='modal' data-type='ajax'");?></p>
</div>
<?php else:?>
<?php echo $this->fetch('block', 'dashboard', 'module=project');?>