public override string ToString() { Gabriel.Cat.text toString = ""; toString += "\nId ingredient: " + PrimaryKey; toString += "\nId recepta: "; if (Recepta == null) { toString += IdReceptaPerPosar; } else { toString += Recepta.PrimaryKey; } toString += "\nId producte: "; if (Producte == null) { toString += IdProductePerPosar; } else { toString += Producte.PrimaryKey; } toString += "\nQuantitat: " + Quantitat; return(toString); }
public override string ToString() { Gabriel.Cat.text toString = "Productes en estoc\n"; foreach (Producte producte in this) { toString += "\n" + producte; toString += "\nEs poden fer: " + producte.EsPodenFer(this); toString += "\nCom a maxim pot haver: " + producte.MaximQuePotHaver(this); } return(toString); }
public override string ToString() { Gabriel.Cat.text toString = ""; toString += "\nId recepta: " + PrimaryKey; toString += "\nIngredients:"; if (ingredients.Count != 0) { foreach (Ingredient ingredient in this) { toString += "\n" + ingredient; } } else { toString += "\nNo te ingredients"; } return(toString); }
public override string ToString() { Gabriel.Cat.text toString = ""; toString += "\nId unitat: " + PrimaryKey; toString += "\nId producte: " + Producte.PrimaryKey; toString += "\nId recepta: " + Recepta.PrimaryKey + " recepta"; if (!FetAmbReceptaOriginal) { toString += " " + " NO "; } toString += " original"; toString += "\nQuantitat: " + Quantitat; toString += "\nData Caducitat: " + DataCaducitat; toString += "\nData Que es va obrir: "; if (Obert) { toString += DataQueEsVaObrir; } return(toString); }
private void RedueixIDessa(string rutaImatge) { if (File.Exists(rutaImatge)) { var img = new System.Drawing.Bitmap(rutaImatge); var imgR = gabriel.cat.Imagen.Escala(img, Convert.ToDecimal((img.Height % 100) / 100.0)); if (!Directory.Exists(Environment.CurrentDirectory + "\\imatges")) { Directory.CreateDirectory(Environment.CurrentDirectory + "\\imatges"); } rutaImatge = "\\imatges\\" + PrimaryKey + ".png"; imgR.Save(Environment.CurrentDirectory + rutaImatge, System.Drawing.Imaging.ImageFormat.Png); Gabriel.Cat.text rt = rutaImatge; rt.Replace('\\', ';'); this.rutaImatge = rt; } else { rutaImatge = ""; } }
public override string ToString() { Gabriel.Cat.text toString = ""; toString += "\nId producte: " + PrimaryKey; toString += "\nTaula SQL: " + Taula; toString += "\nCategoria: " + Categoria; toString += "\nUnitat: " + Unitat; toString += "\nRuta Imatge: " + RutaImatge; toString += "\nInformació EXTRA: " + InfoExtra; toString += "\nRecepta: " + ReceptaOriginal.PrimaryKey; toString += "\nQuantitat minima en estoc: " + QuantitatMinimaEstoc; toString += "\nQuantitat normal en estoc: " + QuantitatNormalEstoc; toString += "\nTemps avis per caducar: " + TempsAvisPerCaducar; toString += "\nTemps un cop Obert: " + TempsUnCopObert; toString += "\nTemps un cop Fet: " + TempsUnCopFet; toString += "\nUnitats fetes amb la recepta original: " + UnitatsFetesAmbLaRecepteOriginal; toString += "\nQuantitat: " + QuantitatReceptaOriginal; toString += "\nUnitats no fetes amb la recepta original: " + UnitatsNoFetesAmbLaRecepteOriginal; toString += "\nQuantitat: " + QuantitatNoFetaAmbReceptaOriginal; toString += "\nUnitats Total: " + unitats.Count; toString += "\nQuantitat total: " + QuantitatTotal; return(toString); }