@@ 739-745 (lines=7) @@ | ||
736 | */ |
|
737 | public function create_model_query_params( $model, $query_parameters ) { |
|
738 | $model_query_params = array( ); |
|
739 | if ( isset( $query_parameters[ 'where' ] ) ) { |
|
740 | $model_query_params[ 0 ] = Model_Data_Translator::prepare_conditions_query_params_for_models( |
|
741 | $query_parameters[ 'where' ], |
|
742 | $model, |
|
743 | $this->get_model_version_info()->requested_version() |
|
744 | ); |
|
745 | } |
|
746 | if ( isset( $query_parameters[ 'order_by' ] ) ) { |
|
747 | $order_by = $query_parameters[ 'order_by' ]; |
|
748 | } elseif ( isset( $query_parameters[ 'orderby' ] ) ) { |
|
@@ 766-772 (lines=7) @@ | ||
763 | if( $group_by !== null ){ |
|
764 | $model_query_params[ 'group_by' ] = $group_by; |
|
765 | } |
|
766 | if ( isset( $query_parameters[ 'having' ] ) ) { |
|
767 | $model_query_params[ 'having' ] = Model_Data_Translator::prepare_conditions_query_params_for_models( |
|
768 | $query_parameters[ 'having' ], |
|
769 | $model, |
|
770 | $this->get_model_version_info()->requested_version() |
|
771 | ); |
|
772 | } |
|
773 | if ( isset( $query_parameters[ 'order' ] ) ) { |
|
774 | $model_query_params[ 'order' ] = $query_parameters[ 'order' ]; |
|
775 | } |