From 66719399392605b2eca60407c5607640d940108b Mon Sep 17 00:00:00 2001 From: marcelcosta Date: Mon, 4 Jul 2022 10:58:27 +0200 Subject: [PATCH 1/5] =?UTF-8?q?Cambiar=20sistema=20de=20pedir=20contrase?= =?UTF-8?q?=C3=B1a.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BDAccess/app.R | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/BDAccess/app.R b/BDAccess/app.R index 96c9229..1909ddd 100644 --- a/BDAccess/app.R +++ b/BDAccess/app.R @@ -144,15 +144,15 @@ server <- function(input, output) { print(CCfile) if (input$dbtype == "UM"){ dta<<-odbcConnectAccess2007(access.file = UMfile, - pwd = .rs.askForPassword("Enter password:")) + pwd = getPass::getPass("Enter password:")) } if (input$dbtype == "OV"){ dta<<-odbcConnectAccess2007(access.file = OVfile, - pwd = .rs.askForPassword("Enter password:")) + pwd = getPass::getPass("Enter password:")) } if (input$dbtype == "CC"){ dta<<-odbcConnectAccess2007(access.file = CCfile, - pwd = .rs.askForPassword("Enter password:")) + pwd = getPass::getPass("Enter password:")) } print(dta) if (input$backup == T){ From cb38ea347d156e1cf341b348192bf34345562fe2 Mon Sep 17 00:00:00 2001 From: marcelcosta Date: Mon, 4 Jul 2022 11:08:45 +0200 Subject: [PATCH 2/5] =?UTF-8?q?A=C3=B1adir=20notificaci=C3=B3n=20de=20sinc?= =?UTF-8?q?ronizaci=C3=B3n=20y=20backup=20de=20nitr=C3=B3geno.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BDAccess/app.R | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/BDAccess/app.R b/BDAccess/app.R index 1909ddd..703156a 100644 --- a/BDAccess/app.R +++ b/BDAccess/app.R @@ -754,6 +754,7 @@ server <- function(input, output) { sqlFetch(dta, "NITROGEN"), file=paste0(NitroRoute, format(Sys.time(), format="%Y%m%d"),"-","UM-Nitrogen.xlsx") ) + print("Backup Creado.") table<-read.xlsx(paste0(gsub("/BU_NITRO/", "", NitroRoute),"/Nitrogen_ICO.xlsx")) @@ -784,6 +785,7 @@ server <- function(input, output) { sqlDrop(dta, "NITROGEN") sqlSave(dta, table.um %>% select(-FECHA) %>% filter(!is.na(CODIGO)), tablename="NITROGEN", rownames=F) + print("Tabla Actualizada.") } if (input$dbtype == "OV"){ ## Copia de backup @@ -797,6 +799,7 @@ server <- function(input, output) { sqlFetch(dta, "NITROGEN"), file=paste0(NitroRoute, format(Sys.time(), format="%Y%m%d"),"-","OV-Nitrogen.xlsx") ) + print("Backup Creado.") ## Lectura del excel table<-read.xlsx(paste0(gsub("/BU_NITRO/", "", NitroRoute),"/Nitrogen_ICO.xlsx")) @@ -822,6 +825,7 @@ server <- function(input, output) { sqlDrop(dta, "NITROGEN") sqlSave(dta, table.ov, tablename="NITROGEN", rownames=F) + print("Tabla Actualizada.") } }) From 43b807cc636cc748293b7e41480be670c962dbb1 Mon Sep 17 00:00:00 2001 From: marcelcosta Date: Mon, 4 Jul 2022 11:09:20 +0200 Subject: [PATCH 3/5] =?UTF-8?q?Correcci=C3=B3n=20de=20la=20funci=C3=B3n=20?= =?UTF-8?q?de=20backup.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BDAccess/app.R | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/BDAccess/app.R b/BDAccess/app.R index 703156a..e6f03af 100644 --- a/BDAccess/app.R +++ b/BDAccess/app.R @@ -157,11 +157,15 @@ server <- function(input, output) { print(dta) if (input$backup == T){ if (! input$dbtype %in% c("UM","OV")){ - sqlBackUp(bu.dir="CC_BU") - }else{ - sqlBackUp() + sqlBackUp(dbfile = CCfile, bu.dir="CC_BU") } - + if (input$dbtype == "UM"){ + sqlBackUp(dbfile = UMfile) + } + if (input$dbtype == "OV"){ + sqlBackUp(dbfile = OVfile) + } + print("Back up realizado.") } }) From bd52e8c452449c1d0c1d80da7932880966df12f0 Mon Sep 17 00:00:00 2001 From: marcelcosta Date: Thu, 2 Feb 2023 16:54:09 +0100 Subject: [PATCH 4/5] =?UTF-8?q?Correcci=C3=B3n=20nombre=20de=20fecha=20de?= =?UTF-8?q?=20extracci=C3=B3n.=20Soluci=C3=B3n=20de=20bug.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- BDAccess/app.R | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/BDAccess/app.R b/BDAccess/app.R index e6f03af..9218c14 100644 --- a/BDAccess/app.R +++ b/BDAccess/app.R @@ -384,7 +384,7 @@ server <- function(input, output) { new.samp.df<-data.frame("NHC"=values[["DF"]]$NHC, "samples"=new.samp) %>% merge(sqlFetch(dta,"OVID"), all.x=T) %>% arrange(samples) samples.exp<-merge(samples %>% slice(0), new.samp.df %>% select(-NHC), all=T) %>% select(colnames(samples)) %>% arrange(samples) if (today==TRUE){ - samples.exp$IQ_date<-format(Sys.Date(), "%d/%m/%y") + samples.exp$Date_extraction<-format(Sys.Date(), "%d/%m/%y") } nhc.table<-values[["DF"]] From 560540cf1ae05a11bb105a7873892fa819bc8581 Mon Sep 17 00:00:00 2001 From: marcelcosta Date: Tue, 10 Oct 2023 12:35:43 +0200 Subject: [PATCH 5/5] Commit in cytometry. --- BDAccess/app.R | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/BDAccess/app.R b/BDAccess/app.R index 9218c14..5490731 100644 --- a/BDAccess/app.R +++ b/BDAccess/app.R @@ -931,10 +931,15 @@ server <- function(input, output) { g_IC<-g1 pops<-sqlFetch(dta, "POPULATIONS") - - g_pop<-pops %>% dplyr::filter(samples == input$id) %>% gather(pop,value,-samples) %>% - mutate(pop=factor(pop, levels=c("CD45pos_Alive","T_cells","CD8","CD4","DN","NK", "B_cells", - "CD45neg_LDneg","EpCAMneg_HLAIneg","EpCAMneg_HLAIpos","EpCAMpos_HLAIpos"))) %>% + + g_pop<-pops %>% + dplyr::filter(sample == input$id) %>% + gather(pop,value,-sample, -code, -fc_time) %>% + # mutate(pop=factor(pop, levels=c("CD45pos_Alive","T_cells","CD8","CD4","DN","NK", "B_cells", + # "CD45neg_LDneg","EpCAMneg_HLAIneg","EpCAMneg_HLAIpos","EpCAMpos_HLAIpos"))) %>% + # mutate(pop=factor(pop, levels=c("CD45pos_Alive","T_cells","CD8","CD4","DN","NK", "B_cells", + # "CD45neg_LDneg","EpCAMneg_HLAIneg","EpCAMneg_HLAIpos","EpCAMpos_HLAIpos"))) %>% + mutate(value=as.numeric(gsub(",",".",value))) %>% ggplot(aes(pop, value))+ geom_bar(stat="identity", color="black", fill="grey70")+ labs(title = input$id, y="% parent", x="")+