+[task#131956,doing,1.5h,1.5h] Add ui function of create kanban project.

This commit is contained in:
lihuifang
2024-11-12 16:52:32 +08:00
committed by 李阳
parent 42e918a97a
commit 766e8a7a30
@@ -0,0 +1,20 @@
<?php
include dirname(__FILE__, 5) . '/test/lib/ui.php';
class createKanbanTester extends tester
{
/**
* 创建看板项目时检查页面输入。
* Check the page input when creating the kanban project.
*
* @param array $kanban
* @access public
*/
public function checkInput($kanban = array())
{
$form = $this->initForm('project', 'create', array('model' => 'kanban'));
if(isset($kanban['parent'])) $form->dom->parent->picker($kanban['parent']);
$categoryLang = (array)$this->lang->project->projectTypeList;
if(isset($kanban['type'])) $form->dom->btn($categoryLang[$kanban['type']])->click();
if(isset($kanban['name'])) $form->dom->name->setValue($kanban['name']);
if(isset($kanban['end'])) $form->dom->end->datepicker($kanban['end']);
else $form->dom->longTime->click(); //如果设置了end时间就选择,没有设置就选择长期