Gio
hey guys, I am asking again here, I am looking for a full stack django developer interested in a remote full time job, anyone interested? please PM me
007
What are the requirements..
Anonymous
How do I paginate my API using pure Django
Mohit
How do I paginate my API using pure Django
If you are using django rest framework, then it has inbuilt pagination with 2 options : page number pagination and limit offset pagination
pino@mastrobirraio ~$
How do I paginate my API using pure Django
https://www.django-rest-framework.org/api-guide/pagination/
Ooha
wtf
Then how to do it? I mean i want to open webcam and it must appear in a html page..how to do???
George
Opencv is not intended for that
George
Look for django channels and webrtc
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Is there a perticular way to set up a model that collects other models and a number. Im back to dynamic fields, I need a kit containing a number of models, kind of like a shopping cart.
George
https://djangopackages.org/grids/g/ecommerce/
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
I need to add kits of products.
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
i. e. a model that conatins a cirtain number of products(model).
Mirco
how is the model container linked to "products" ?
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Look at it this way, I have products like bread and butter. Then I need a model to store a kit containing "x butters" and " x milk".
Ghorz
Payment
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Its an example of what i need of a model.
Ghorz
Its an example of what i need of a model.
I believe you want to save users order or cart. Give me some time. I build a shopping app and will share the source code with you
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Thank you for trying but its not what i want. I am trying ti store a collection of products.
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
A prefilled cart if you will.
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Lets sat you wanted a home detection kit. Then you would need maybe a "recorder", 2 "cameras", and some "software". I want to store that in a model = "kit". The problem is the X number of products.
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
maybe if you share your current model it will help us
https://pastebin.com/Rhhmyate Go nuts :)
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
The one in question here is the "Kit" class. I need it to store numbers i pararell with product_items
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Inside your ManyToMany ?
What do you meen?, i just need the kit to be able to link a number to the product_item so a kit can contain many of the same product.
inchidi
https://pastebin.com/Rhhmyate Go nuts :)
class ProductItemKit(Model): product=FK(ProductItem) kit=FK(Kit) total=PositiveIntegerFields() is this what you are looking for?
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
This would be the intermidiate model then
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
Thats what I am stuck on, an intermediate to hold product_items / number
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
But I think i will just make a json field in the kit then map the ID of the product_items together with a number and present this is a vue app of sorts.
Anders (izzno / gooood) ๐Ÿ‡ณ๐Ÿ‡ด
as you can see, this model already have fk to product item
yes, but what if i need a kit to contain several product_items
inchidi
thats model/table not a row tho
H
I start make my django projects
H
And i got stuck
cj
And i got stuck
where and why?
H
Can someone tell me how to get data from html and send it to another view
H
No perfect i found on internet plzz help
cj
No perfect i found on internet plzz help
did you follow the tutorial?
H
Yup from YouTube the new boston
Guillermo
Can someone tell me how to get data from html and send it to another view
You can pass the data as url parameters or as POST/GET data, check the official docs, its all there
H
And some others to
cj
Yup from YouTube the new boston
I mean, the official tutorial
H
Nope
cj
where they teach you step by step how to use basics of Django
cj
Nope
follow it: https://docs.djangoproject.com/en/2.1/intro/tutorial01/
Guillermo
Nope
You are missing out one of the best parts of working with Django, the docs are a work of art
cj
follow them patiently, read everything carefully and have fun 🙂
H
Thanks admin
H
Thanks Guillermo
cj
don't skip anything, even if you feel you already know that
Guillermo
Harsh no problem
H
I have to submit my project tomorrow morning does it possible to complete it in 1 night
Guillermo
oh boy
H
Okay gotta go think so I'm in trouble
inchidi
I have to submit my project tomorrow morning does it possible to complete it in 1 night
its possible if you dont sleep and complete the official tuts less than 3 hours. you can trust me coz i've been there
Anonymous
Whats your project
H
I have to take matrix input size from user and data and convert it into the encrypted form and give it to the user
H
That's one part