Page 1 of 1

[IMPLEMENTED] Feature enhancement to mosDBTable

Posted: Sat Jan 13, 2007 9:01 am
by acalderon

As I continue my component development I found that mosDBTable::save is such a grate method, but I spot the need of an extra parameter, $ignore. It performs the following routine:
  • bind
  • check
  • store
  • checkin and
  • updateOrder
Which is grate. But, the bind method takes two parameters $array and $ignore. And if you need to use the $ignore parameter you cannot use the save method because it does not provide a third parameter to accommodate the bind's second parameter. So, I suggest to perform the following change:

Code: Select all

function save( $source, $order_filter='', $ignore='' ) {
	if (!$this->bind( $source, $ignore )) {
		return false;
	// rest of the code
Basically edit the first two lines of the function. Although, one can just extend the class and change such method, it is best to have the core files provide this functionality.

What do you think?
Perhaps it could also be implemented for 1.5?

Re: [IMPLEMENTED] Feature enhancement to mosDBTable

Posted: Mon Aug 06, 2007 10:12 am
by masterchief
Implemented in the 1.5 SVN.  Thanks.