Exemplo n.º 1
0
    def find_analysis(self, labnumber, aliquot, step):
        db = self.db
        with db.session_ctx():
            dbrec = db.get_analysis(labnumber, aliquot, step)
            rec = MassSpecAnalysis()
            rec.sync(dbrec)

            return rec
Exemplo n.º 2
0
    def find_analysis(self, labnumber, aliquot, step):
        db = self.db
        with db.session_ctx():
            dbrec = db.get_analysis(labnumber, aliquot, step)
            if dbrec:
                rec = MassSpecAnalysis()
                rec.sync(dbrec)
                irradpos = db.get_irradiation_position(dbrec.IrradPosition)
                r = irradpos.IrradiationLevel
                n, l = r[:-1], r[-1:]

                dbirrad = db.get_irradiation_level(n, l)

                rec.sync_irradiation(dbirrad)

                return rec