Skip to content

Commit 5a1465e

Browse files
committed
fix pull #25
1 parent 528fc7c commit 5a1465e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

SortableGridBehavior.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public function beforeInsert()
8282
call_user_func($this->scope, $query);
8383
}
8484

85-
$maxOrder = $query->max('{{' . $model::tableName() . '}}.[[' . $this->sortableAttribute . ']]');
85+
$maxOrder = $query->max('{{' . trim($model::tableName(), '{}') . '}}.[[' . $this->sortableAttribute . ']]');
8686
$model->{$this->sortableAttribute} = $maxOrder + 1;
8787
}
8888
}

0 commit comments

Comments
 (0)