<?php
namespace Modules\Conf_gerais\Models;

use App\Models\BaseModel;

class Model_conf_gerais extends BaseModel {
	public function alterar() {
		$table 		= "conf_gerais";
		$builder  = $this->db->table($table);
		$query    = $builder->get();

		return $query->getRow();
	}

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