private void AutosKoLY_Attach(Autoskoly entity)
		{
			entity.Uzivatele = this;
		}
		private void AutosKoLY_Detach(Autoskoly entity)
		{
			entity.Uzivatele = null;
		}
        public JObject Post(JObject o)
        {
            Autoskoly a;

            using (var db = DrivingScoolContextHelper.CreateDataContext2())
            {
                try
                {                                        
                    db.Autoskoly.InsertOnSubmit(a = new Autoskoly()
                    {
                        //AutoskolaID = o.Value<uint>("autoskola_id"),
                        Nazev = o.Value<string>("nazev"),
                        AdresaMesto = o.Value<string>("adresa_mesto"),
                        AdresaUlice = o.Value<string>("adresa_ulice"),
                        AdresaCP = o.Value<int>("adresa_cp"),
                        AdresaPSC = o.Value<int>("adresa_psc"),
                        UzivatelID = (uint)1
                    });
                    db.SubmitChanges();

                }
                catch (SqlException)
                {
                    throw new HttpResponseException(HttpStatusCode.InternalServerError);
                }
            }

            return Get((int?)a.AutoskolaID);
        }