$sql = array('id_project_task_items' => $rsItem['id_project_task_items'], 'status' => '1');
$fields = array('id_member');
$model = new ProjectTaskItemsMemberSet();
$model->fields = $fields;
$rsItemMembers = $model->get($sql);
$sql = array('id_project_task' => $rsItem['id_project_task'], 'status' => '1');
$fields = array('id_project');
$model = new ProjectTask();
$model->fields = $fields;
$rs = $model->get($sql);
$rs = $rs[0];
$sql = array('id_project' => $rs['id_project'], 'status' => '2');
$fields = array('id_member');
$model = new ProjectMemberSet();
$model->fields = $fields;
$rs = $model->get($sql);
?>
<div class="modal-content">
	<div class="modal-header">
		<button class="close" onclick="boss.removeClass('modal_dialog', 'active')">x</button>
		<h3 class="modal-title font-open-sans">Adicionar membro a tarefa</h3>
	</div>
	<form action="/app/task/create_item_member/" method="post" target="iframesubmit">
		<input type="hidden" id="pk" name="pk" value="<?php 
echo $pk;
?>
">
		<input type="hidden" id="pk_member" name="pk_member" value="">
		<input type="hidden" id="remove" name="remove" value="0">
		<div class="modal-body">
			<div class="container">
Exemplo n.º 2
0
<?php

require_once 'init.php';
use Agil\Session\Session;
$logado = Session::get('logado');
$id_admin = $logado['id_member'];
$project = new Project();
$project->fields = array('id_project', 'title', 'slug');
$rs = $project->get(array('id_admin' => $id_admin, 'status' => '1'));
$projectMember = new ProjectMemberSet();
$projectMember->fields = array('id_project_member_set', 'id_member', 'id_project');
$memberRow = $projectMember->get(array('id_member' => $id_admin, 'status' => '2'));
foreach ($memberRow as $index => $member) {
    $response = $project->get(array('id_project' => $member['id_project'], 'status' => '1'));
    $rs[] = $response[0];
}
?>
<div class="app-pane">
	<div class="app-pane-header">
		<div class="col-6 pull-left">
			<div id="btn_group" class="btn-group">
				<a href="javascript: void(0);" class="btn" onclick="boss.bookmark.set('tab', '/app/user/view_overview/');boss.ajax.load('/app/user/view_overview/', '#app_conteiner');">Visão Geral</a>
				<a href="javascript: void(0);" class="btn btn-primary" onclick="boss.bookmark.set('tab', '/app/project/view_project/');boss.ajax.load('/app/project/view_project/', '#app_conteiner');">Projetos</a>
			</div>
		</div>
		<div class="col-6 pull-left">
			<div class="col-6 pull-left text-right">
				<buttom id="btn_new_project" onclick="boss.ajax.load('/app/project/form_create/', '#modal_dialog', 'active');" class="btn btn-success">
					<b>+</b> Novo projeto
				</buttom>
			</div>
$model = new Project();
$sql = array('id_admin' => $logado['id_member'], 'status' => 1);
$count = $model->count($sql);
if ($count > 0) {
    $fields = array("id_project");
    $model->fields = $fields;
    $projects = $model->get($sql);
    $project = $projects[0];
} else {
    $model = new ProjectMemberSet();
    $sql = array('id_member' => $logado['id_member'], 'status' => 2);
    $count = $model->count($sql);
    if ($count > 0) {
        $fields = array("id_project");
        $model->fields = $fields;
        $projects = $model->get($sql);
    }
}
?>
<div class="app-pane">
	<div class="app-pane-header">
		<div class="btn-group">
			<a href="javascript: void(0);" class="btn btn-primary" onclick="boss.bookmark.set('tab', '/app/user/view_overview/');boss.ajax.load('/app/user/view_overview/', '#app_conteiner');">Visão Geral</a>
			<a href="javascript: void(0);" class="btn" onclick="boss.bookmark.set('tab', '/app/project/view_project/');boss.ajax.load('/app/project/view_project/', '#app_conteiner');">Projetos</a>
		</div>
	</div>
	<div class="app-pane-body" style="background-color:#F9F9F9;">
		<div class="col-12">
			<div class="col-4 pull-left">
				<div class="card bleed-top bleed-bottom">
					<div class="card-content text-center">