Changeset 13184 for trunk/src/bp-groups/classes/class-bp-groups-group.php
- Timestamp:
- 12/12/2021 02:09:02 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-groups/classes/class-bp-groups-group.php
r13129 r13184 1020 1020 * @since 2.8.0 Changed `$search_terms` parameter handling and added `$search_columns` parameter. 1021 1021 * @since 2.9.0 Added `$slug` parameter. 1022 * @since 10.0.0 Added `$date_query` parameter. 1022 1023 * 1023 1024 * @param array $args { … … 1054 1055 * @type array $meta_query Optional. An array of meta_query conditions. 1055 1056 * See {@link WP_Meta_Query::queries} for description. 1057 * @type array $date_query Optional. Filter results by group last activity date. See first 1058 * paramter of {@link WP_Date_Query::__construct()} for syntax. Only 1059 * applicable if $type is either 'newest' or 'active'. 1056 1060 * @type array|string $value Optional. Array or comma-separated list of group IDs. Results 1057 1061 * will be limited to groups within the list. Default: false. … … 1126 1130 'group_type__not_in' => '', 1127 1131 'meta_query' => false, 1132 'date_query' => false, 1128 1133 'include' => false, 1129 1134 'parent_id' => null, … … 1314 1319 } 1315 1320 1321 // Process date query for 'date_created' and 'last_activity' sort. 1322 if ( 'date_created' === $orderby || 'last_activity' === $orderby ) { 1323 $date_query_sql = BP_Date_Query::get_where_sql( $r['date_query'], self::convert_orderby_to_order_by_term( $orderby ) ); 1324 1325 if ( ! empty( $date_query_sql ) ) { 1326 $where_conditions['date'] = $date_query_sql; 1327 } 1328 } 1329 1316 1330 // Sanitize 'order'. 1317 1331 $order = bp_esc_sql_order( $order ); … … 1439 1453 1440 1454 /** 1441 * Get the SQL for the 'meta_query' param in BP_ Activity_Activity::get()1455 * Get the SQL for the 'meta_query' param in BP_Groups_Group::get() 1442 1456 * 1443 1457 * We use WP_Meta_Query to do the heavy lifting of parsing the
Note: See TracChangeset
for help on using the changeset viewer.