private void JIZDy_Attach(Jizdy entity)
		{
			entity.Vozidla = this;
		}
		private void JIZDy_Detach(Jizdy entity)
		{
			entity.Vozidla = null;
		}
		private void JIZDy_Attach(Jizdy entity)
		{
			entity.Ucitele = this;
		}
		private void JIZDy_Detach(Jizdy entity)
		{
			entity.Ucitele = null;
		}
		private void JIZDy_Detach(Jizdy entity)
		{
			entity.Studenti = null;
		}
		private void JIZDy_Attach(Jizdy entity)
		{
			entity.Studenti = this;
		}
		private void JIZDy_Detach(Jizdy entity)
		{
			entity.Kurzy = null;
		}
		private void JIZDy_Attach(Jizdy entity)
		{
			entity.Kurzy = this;
		}
        public JObject Post(JObject o)
        {
            Jizdy j;

            using (var db = DrivingScoolContextHelper.CreateDataContext2())
            {
                try
                {
                    db.Jizdy.InsertOnSubmit(j = new Jizdy()
                    {
                        //JizdaID = o.Value<uint>("jizda_id"),
                        VozidloID = o.Value<uint>("vozidlo_id"),
                        UcitelID = o.Value<uint>("ucitel_id"),
                        StudentID = o.Value<uint>("student_id"),
                        Od = o.Value<DateTime>("cas_od"),
                        Do = o.Value<DateTime>("cas_do"),
                        Najeto = o.Value<double>("najeto"),
                        Spotreba = o.Value<double>("spotreba"),
                        KurzID = o.Value<uint>("kurz_id")
                    });
                    db.SubmitChanges();
                }
                catch (AggregateException)
                {
                    throw new HttpResponseException(HttpStatusCode.InternalServerError);
                }
            }

            return Get(null, null, null, (int?)j.JizdaID);
        }