Ejemplo n.º 1
0
        public Entities.manufacturer Add(Entities.manufacturer Manufacturer)
        {
            long?idAux = Manufacturer.id;

            Manufacturer.id = null;
            RestRequest request = this.RequestForAdd("manufacturers", Manufacturer);

            Entities.manufacturer aux = this.Execute <Entities.manufacturer>(request);
            Manufacturer.id = idAux;
            return(this.Get((long)aux.id));
        }
Ejemplo n.º 2
0
        public Entities.manufacturer Add(Entities.manufacturer Manufacturer)
        {
            long?idAux = Manufacturer.id;

            Manufacturer.id = null;
            List <PrestaSharp.Entities.PrestaShopEntity> Entities = new List <PrestaSharp.Entities.PrestaShopEntity>();

            Entities.Add(Manufacturer);
            RestRequest request = this.RequestForAdd("manufacturers", Entities);

            Entities.manufacturer aux = this.Execute <Entities.manufacturer>(request);
            Manufacturer.id = idAux;
            return(this.Get((long)aux.id));
        }
Ejemplo n.º 3
0
 public void Delete(Entities.manufacturer Manufacturer)
 {
     this.Delete((long)Manufacturer.id);
 }
Ejemplo n.º 4
0
        public void Update(Entities.manufacturer Manufacturer)
        {
            RestRequest request = this.RequestForUpdate("manufacturers", Manufacturer.id, Manufacturer);

            this.Execute <Entities.manufacturer>(request);
        }