* @package ai * @link https://www.zentao.net */ ?> ai->isExecutable($prompt); $published = $prompt->status == 'active'; if($this->config->edition != 'open') { /* Design button. */ if(common::hasPriv('ai', 'promptassignrole')) $html .= html::a(helper::createLink('ai', 'promptassignrole', "prompt=$prompt->id"), '', '', "class='btn" . ($published ? ' disabled' : '') . "' title='{$lang->ai->prompts->action->design}'"); /* Test / audit button. */ if(common::hasPriv('ai', 'promptaudit')) $html .= html::a($executable ? $this->ai->getTestingLocation($prompt) : '#', '', '', "id='prompt-audit-button-$prompt->id' class='prompt-audit-btn btn" . ($executable && !$published ? '' : ' disabled') . "' title='{$lang->ai->prompts->action->test}'" . ($executable ? '' : " data-toggle='modal' data-target='#designConfirmModal'")); /* Edit button. */ if(common::hasPriv('ai', 'promptedit')) $html .= html::a(helper::createLink('ai', 'promptedit', "prompt=$prompt->id"), '', '', "class='btn' title='{$lang->ai->prompts->action->edit}'"); /* Divider. */ if(common::hasPriv('ai', 'promptpublish') || common::hasPriv('ai', 'promptunpublish')) $html .= '
'; } /* Publish button. */ if(common::hasPriv('ai', 'promptpublish')) $html .= html::a(!$published && $executable ? "javascript:togglePromptStatus($prompt->id)" : '#', '', '', "class='btn" . (!$published && $executable ? '' : ' disabled') . "' title='{$lang->ai->prompts->action->publish}'" . ($executable ? '' : " data-toggle='modal' data-target='#designConfirmModal'")); /* Unpublish button. */ if(common::hasPriv('ai', 'promptunpublish')) $html .= html::a('#', '', '', "class='btn" . (!$published || !$executable ? ' disabled' : '') . "' title='{$lang->ai->prompts->action->unpublish}'" . (!$published ? '' : " data-toggle='modal' data-target='#draftConfirmModal'")); echo $html; } ?>

ai->prompts->emptyList;?> config->edition != 'open' && common::hasPriv('ai', 'createprompt')) echo html::a($this->createLink('ai', 'createprompt'), " " . $lang->ai->prompts->create, '', "class='btn btn-info iframe'");?>

recTotal}&recPerPage={$pager->recPerPage}";?>
ai->prompts->id);?> ai->prompts->name);?> ai->prompts->stage);?> ai->prompts->createdBy);?> ai->prompts->createdDate);?> ai->prompts->targetForm);?> actions;?>
id;?> id"), $prompt->name, '_self', "title='$prompt->name'") : $prompt->name;?> ai->prompts->statuses[$prompt->status];?> createdBy);?> createdDate;?> targetForm) { $targetFormPath = explode('.', $prompt->targetForm); if(count($targetFormPath) == 2) echo $lang->ai->targetForm[$targetFormPath[0]]['common'] . ' / ' . $lang->ai->targetForm[$targetFormPath[0]][$targetFormPath[1]]; } ?>