Explorar el Código

fix #17. do not multi-count proposals when different organizations have the same solicitation names

George C. Privon hace 2 semanas
padre
commit
c58f4fd32b
Se han modificado 2 ficheros con 8 adiciones y 0 borrados
  1. 4 0
      CHANGELOG.md
  2. 4 0
      proposal_database.rkt

+ 4 - 0
CHANGELOG.md

@@ -2,6 +2,10 @@
 
 ## v0.3.x
 
+### v0.3.2 (in progress)
+
+- Bufix for --list-open-calls to avoid incorrect proposal counts when different organizations have the same solicitation name.
+
 ### v0.3.1 (21 August 2025)
 
 - Annotate example configuration file with guidance.

+ 4 - 0
proposal_database.rkt

@@ -293,11 +293,15 @@ resultdate TEXT DEFAULT '')")
          (define Nprop (query-value conn (string-append get_prop_count_base
                                                         "WHERE status='submitted' AND solicitation='"
                                                         (vector-ref call-entry 1)
+                                                        "' AND organization='"
+                                                        (vector-ref call-entry 0)
                                                         "'")))
          (define Nprop-PI
            (query-value conn (string-append get_prop_count_base
                                             "WHERE status='submitted' AND solicitation='"
                                             (vector-ref call-entry 1)
+                                            "' AND organization='"
+                                            (vector-ref call-entry 0)
                                             "' AND PI LIKE '%"
                                             PIname
                                             "%'")))