<?php
//===DO==
class AppSmtaToUm extends Database {

	protected $mSqlFile= 'module/smta/business/appsmtatoum.sql.php';
	
	function __construct($connectionNumber=4) {
		parent::__construct($connectionNumber);
		
	}	
	function DoAddSmta($kodeSmta,$kodeKota,$namaSmta) {
		$result = $this->Execute($this->mSqlQueries['do_add_smta'], array($kodeSmta,$namaSmta,$kodeKota));
		#print($this->GetLastError());
      return $result;
      
	}
	
	function DoUpdateSmta($kodeSmta,$kodeKota, $namaSmta,$smtaId) {
	
		$result = $this->Execute($this->mSqlQueries['do_update_smta'], array($kodeSmta, $namaSmta,$kodeKota,$smtaId));
		return $result;
	}
	
	function DoDeleteSmtaById($idSmta) {
		$result=$this->Execute($this->mSqlQueries['do_delete_smta_by_id'], array($idSmta));
		return $result;
	}

	function DoDeleteSmtaByArrayId($arrIdSmta) {
		$idSmta = implode("', '", $arrIdSmta);
		$result=$this->Execute($this->mSqlQueries['do_delete_smta_by_array_id'], array($idSmta));
		return $result;
	}
}
?>