<?php
namespace Modules\Cad_institucional\Models;

use App\Models\BaseModel;

class Model_cad_institucional extends BaseModel {
	public function alterar() {	
		$table 		= "cad_institucional";
		$builder  = $this->db->table($table)->where('id', 1);
		$query    = $builder->get();

		return $query->getRow();
	}

	public function alterando() {
		$table 		= "cad_institucional";
		$builder  = $this->db->table($table);
		
		$builder->set('data_alteracao', date("Y-m-d H:i:s"));
		$builder->where('id', 1);
		$builder->update($_POST);

		return 1;
	}
}