<< | Index | >>
Total coverage: 86.49%
Commit
Problem
Check
ch.oddb> self.registrations.values.select{|r| r.iksnr == '00277'}[0].name_base -> Coeur-Vaisseaux Sérocytol ch.oddb> self.registrations.values.select{|r| r.iksnr == '00277'}[0].production_science -> Blutprodukte ch.oddb> self.registrations.values.select{|r| r.iksnr == '00277'}[0].vaccine ->
Cause
Solution
Check all heilmittelcode (src/util/oddbapp.rb)
def all_heilmittelcode open("/home/masa/work/heilmittelcode.dat", "w") do |out| @registrations.values.select{|r| r.production_science =~ /Blutprodukte/ or r.production_science =~ /Impfstoffe/}.sort_by{|r| r.iksnr}.each do |reg| out.print reg.iksnr, ", ", reg.production_science, ", ", reg.vaccine, "\n" end end end
Result
Consider
Experiment (src/plugin/swissmedic.rb#update_registration)
def update_registration(row, opts = {}) first_day = Date.new(today.year,
today.month, 1) opts = {:date => first_day, :create_only => false}.update(opts) opts[:date] ||= first_day group = cell(row, column(:production_science)) if(group != 'Tierarzneimittel') iksnr = cell(row, column(:iksnr)) return if (filter = opts[:iksnr]) && iksnr != filter return if (filter = opts[:iksnrs]) && !filter.include?(iksnr) science = cell(row, column(:production_science)) ptr = if(registration = @app.registration(iksnr)) return registration if opts[:create_only] registration.pointer else Persistence::Pointer.new([:registration, iksnr]).creator end expiration = date_cell(row, column(:expiry_date)) reg_date = date_cell(row, column(:registration_date))vaccine = if science =~ /Blutprodukte/ or science =~ /Impfstoffe/
true
else
nil
end
args = { :ith_swissmedic => cell(row, column(:index_therapeuticus)), :production_science => science,:vaccine => vaccine,
:registration_date => reg_date, :expiration_date => expiration, :renewal_flag => false, :renewal_flag_swissmedic => false, :inactive_date => nil, :export_flag => nil, }
Run
Result
ODDB::SwissmedicPlugin - Report 31.05.2011 Created Packages: 385 Updated Packages: 18238 Deleted Packages: 78 (0 Replaced) Deleted Sequences: 216 Deactivated Registrations: 473 Updated new Export-Registrations: 7181 Updated existing Export-Registrations: 423 Updated new Export-Sequences: 10730 Updated existing Export-Sequences: 597 Total Sequences without ATC-Class: 12 http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,57441!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,57525!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,58550!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,59080!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,59290!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,59338!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,60413!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61207!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61408!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61436!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61471!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61540!sequence,01.
Run
masa@masa ~/ywesee/oddb.org $ bin/admin ch.oddb> all_heilmittelcode
Result
Note
Next
Experiment
Run
Result
ODDB::SwissmedicPlugin - Report 31.05.2011 Created Packages: 4 Updated Packages: 0 Deleted Packages: 0 (0 Replaced) Deleted Sequences: 0 Deactivated Registrations: 0 Updated new Export-Registrations: 2 Updated existing Export-Registrations: 7602 Updated new Export-Sequences: 2 Updated existing Export-Sequences: 11325 Total Sequences without ATC-Class: 12 http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,57441!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,57525!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,58550!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,59080!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,59290!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,59338!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,60413!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61207!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61408!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61436!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61471!sequence,01. http://oddb.masa.org/de/gcc/resolve/pointer/:!registration,61540!sequence,01.
masa@masa ~/work $ diff heilmittelcode.dat heilmittelcode.dat.org 1,2c1,2 < 00274, Blutprodukte, true < 00277, Blutprodukte, true --- > 00274, Blutprodukte, nil > 00277, Blutprodukte, nil
Next
Commit