Find Jobs
Hire Freelancers

Print Object List with ManyToManyField

$10-50 USD

ที่ทำเสร็จแล้ว
โพสต์ เกือบ 5 ปีที่ผ่านมา

$10-50 USD

ชำระเงินเมื่อส่งงาน
I am trying to create a project and I have two databases, linked by a ManyToManyField, but I cannot get the actual field value to print on the html form. It just says [login to view URL] no matter what I do. I need assistance completing my code. It is a tiny app, I just can't get past this one snag. Here is my Model: class Enrollment([login to view URL]): Enroll_Student = [login to view URL](Student) Put_Student_Here = [login to view URL](Course, on_delete=[login to view URL]) def get_delete_url(self): return f"/withdraw/{[login to view URL]}/delete" def __str__(self): return '%s %s' % (self.Put_Student_Here, self.Enroll_Student,) Here is my Form: class EnrollmentModelForm([login to view URL]): class Meta: model = Enrollment fields = ['Enroll_Student','Put_Student_Here'] labels = { 'Enroll_Student':'Student', 'Put_Student_Here':'Course', } Here is my view: def roster_list_view(request): qs = [login to view URL]() #list out objects, this is a search view template_name = '[login to view URL]' context = {'object_list': qs} return render (request, template_name, context) HTML Form: {% extends "[login to view URL]" %} {% block content %} Course Roster {% for object in object_list%} {% include '[login to view URL]'%} {% endfor %} {% endblock %} In-Line Form: {‌{object.Put_Student_Here}}, {‌{object.Enroll_Student}} Withdraw Student When I run this, the display on the screen says: History Kristen Disney, [login to view URL] As you can see, it's the "ManyToManyField(Student)" value that's not coming out on the list. The ForeignKey field is coming over just fine.
รหัสโปรเจกต์: 20092010

เกี่ยวกับโปรเจกต์

3 ข้อเสนอ
โปรเจกต์ระยะไกล
ใช้งานอยู่ 5 ปีที่ผ่านมา

กำลังมองหาการสร้างรายได้ใช่ไหม?

ประโยชน์ของการประมูลกับ Freelancer

กำหนดงบประมาณและกรอบเวลาของคุณ
รับเงินจากการงานของคุณ
อธิบายข้อเสนอของคุณในภาพรวม
ลงทะเบียนและเสนอราคาฟรี
หมอบหมายให้:
รูปอวาตาร์ของผู้ใช้
Hello, {‌{object.Enroll_Student}} is a queryset and not an object. I am a Python Backend Developer | DevOps Engineer | SRE. I am proficient with tools such as Docker, Kubernetes, Istio, Terraform, Gitlab CI/CD, Travis CI, Google Cloud Platform, IBM Cloud, AWS, etc I also have experience working on backend technologies such as Python, Django, Redis, celery, ActiveMQ, PostgreSQL, PostGIS, etc I am passionate about software development and learning about new technologies/skills in the same domain. I am self-motivated, diligent and a great team player. I focus on the following when working on projects: ● Following recommended standards. ● Proper logging and Exception Handling. ● Proper Documentation. ● Test Driven Development. etc I value the following, not just in software development but also all aspects of life: - Constant improvement. - Transparency and honesty. - Collaboration and friendliness. - Flexibility and open-mindedness. I am positive that I can bring the project many benefits with my experience, background, and forward thinking. I look forward to working with you. Sincerely, Samwel
$50 USD ใน 1 วัน
4.8 (10 รีวิว)
4.3
4.3
3 freelancers are bidding on average $43 USD for this job
รูปอวาตาร์ของผู้ใช้
Hi, I have 5+years Experience in Website/Software Design & Website Development. I'm an Expert in: -Frontend & Backend Development -Python -Data Science -Machine Learning -JVM technologies -Jquery, PHP -Ionic - Hybrid Mobile Applications -Angular, Node.js -Ruby on Rails -C++ Who Knows the value of time. Very hard working and always delivers the work on time. I will finish your tasks in a timely and efficient manner, I aspire to help others reach their goals through the use of my knowledge and experience, I am available 24 hours support. I am available for the weekend also. If you are looking for website design and development I am the right person for you.
$30 USD ใน 7 วัน
4.9 (8 รีวิว)
4.0
4.0

เกี่ยวกับลูกค้า

ปักธงของ UNITED STATES
Oklahoma City, United States
0.0
0
ยืนยันวิธีการชำระเงินแล้ว
เป็นสมาชิกตั้งแต่ มิ.ย. 24, 2019

การยืนยันลูกค้า

ขอบคุณ! เราได้ส่งลิงก์สำหรับเครดิตฟรีให้คุณทางอีเมลแล้ว
เกิดข้อผิดพลาดขณะส่งอีเมลของคุณ กรุณาลองอีกครั้ง
โลโก้ Freelancer Thailand / ภาษาไทย ช่วยเหลือและสนับสนุน FreelancerประเภทโปรเจคการประกวดFreelancerองค์กรแพ็กเกจสมาชิกโครงการ Freelancer ชั้นแนวหน้าการจัดการโปรเจคงานในพื้นที่Photo Anywhereหน้าจัดแสดงผลงานAPI สำหรับนักพัฒนาได้รับการยืนยันDesktop App เกี่ยวกับเกี่ยวกับเราวิธีใช้งานความปลอดภัยนักลงทุนแผนผังเว็บไซต์เรื่องราวข่าวออกสื่อทีมรางวัลข่าวประชาสัมพันธ์ร่วมงานกับเรา ข้อกำหนดนโยบายความเป็นส่วนตัวข้อกำหนดและเงื่อนไขนโยบายลิขสิทธิ์ข้อพึงปฏิบัติค่าธรรมเนียมและค่าบริการหุ้นส่วนEscrow.comLoadshiftWarrior Forum แอปโลโก้ Apple App Store โลโก้ Google Play
ไม่สามารถคัดลอกไปยังคลิปบอร์ดได้ โปรดลองอีกครั้งหลังปรับเปลี่ยนการอนุญาต
คัดลอกไปยังคลิปบอร์ดแล้ว
ผู้ใช้ที่ลงทะเบียน งานที่มีการโพสต์ทั้งหมด
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
กำลังโหลดตัวอย่าง
ได้รับอนุญาตสำหรับตำแหน่งทางภูมิศาสตร์
เซสชั่นการเข้าสู่ระบบของคุณหมดอายุและคุณได้ออกจากระบบแล้ว กรุณาเข้าสู่ระบบอีกครั้ง