✨ feat: Add endpoint type filter to model pricing system
- Create PricingEndpointTypes.jsx component for endpoint type filtering - Add filterEndpointType state management in useModelPricingData hook - Integrate endpoint type filtering logic in filteredModels computation - Update PricingSidebar.jsx to include endpoint type filter component - Update PricingFilterModal.jsx to support endpoint type filtering on mobile - Extend resetPricingFilters utility function to include endpoint type reset - Support filtering models by endpoint types (OpenAI, Anthropic, Gemini, etc.) - Display model count for each endpoint type with localized labels - Ensure filter state resets to first page when endpoint type changes This enhancement allows users to filter models by their supported endpoint types, providing more granular control over model selection in the pricing interface.
This commit is contained in:
@@ -682,6 +682,7 @@ export const resetPricingFilters = ({
|
||||
setViewMode,
|
||||
setFilterGroup,
|
||||
setFilterQuotaType,
|
||||
setFilterEndpointType,
|
||||
setCurrentPage,
|
||||
}) => {
|
||||
// 重置搜索
|
||||
@@ -728,6 +729,11 @@ export const resetPricingFilters = ({
|
||||
setFilterQuotaType('all');
|
||||
}
|
||||
|
||||
// 重置端点类型筛选
|
||||
if (typeof setFilterEndpointType === 'function') {
|
||||
setFilterEndpointType('all');
|
||||
}
|
||||
|
||||
// 重置当前页面
|
||||
if (typeof setCurrentPage === 'function') {
|
||||
setCurrentPage(1);
|
||||
|
||||
Reference in New Issue
Block a user