Browse Source

Merge branch 'develop' into future_在线问诊

gjh 2 weeks ago
parent
commit
9e14e04914
1 changed files with 6 additions and 1 deletions
  1. 6 1
      lib/pages/history/select_history_page.dart

+ 6 - 1
lib/pages/history/select_history_page.dart

@@ -270,13 +270,18 @@ class _SelectHistoryPageState extends ConsumerState<SelectHistoryPage> {
270
 
270
 
271
   ///点击
271
   ///点击
272
   void _onTap(BuildContext context, HistoryItemInfo info) {
272
   void _onTap(BuildContext context, HistoryItemInfo info) {
273
+    if(info.isSelected)
274
+    {
275
+      ref.read(historyListProvider.notifier).select(info, false);
276
+      return;
277
+    }
273
     if (widget.isMultiSelect) {
278
     if (widget.isMultiSelect) {
274
       if (widget.maxCount > 0 &&
279
       if (widget.maxCount > 0 &&
275
           ref.read(historySelectedCountProvider) >= widget.maxCount) {
280
           ref.read(historySelectedCountProvider) >= widget.maxCount) {
276
         showToast(text: getS().maxSelectCountXx(widget.maxCount));
281
         showToast(text: getS().maxSelectCountXx(widget.maxCount));
277
         return;
282
         return;
278
       }
283
       }
279
-      ref.read(historyListProvider.notifier).select(info, !info.isSelected);
284
+      ref.read(historyListProvider.notifier).select(info, true);
280
       return;
285
       return;
281
     }
286
     }
282
     _onSelected(context, [info]);
287
     _onSelected(context, [info]);