Hi guys, hope you can help me.
I have 2 models and i want to make a count query on them. I need a count on
how many articles i have in every category.
Models:
class Vendors(models.Model):
id = models.AutoField(db_column='id', primary_key=True, blank=False,
unique=True)
name = models.Cha
e.now is allways available in any python file you are
> working on it, and also request and request.user
>
> What do you want to do exactly?
>
> On Wednesday, February 13, 2019 at 1:45:46 PM UTC+3:30, Ivan Martić wrote:
>>
>> Hi all,
>>
>> where can i find mor
Hi all,
where can i find more info regarding passing values in views/forms/url.
What I need is to pass value from form in previous url page to the form in
next url page(also prefilling with data like timezone.now, request,user)
Thank you in advance.
Ivan
--
You received this message because yo
resolved.
Microsoft ODBC driver was missing, download it from MS official web page
and all is working perfect now
On Monday, February 11, 2019 at 11:21:37 AM UTC+1, Ivan Martić wrote:
>
> Hi all,
>
> I am migrating to from development to prod server and getting this error
>
Hi all,
I am migrating to from development to prod server and getting this error
app.
Error started to show after installation of allauth library.
I cant find anything on google related to this topic so I hope you can help
me out.
Traceback is saying:
Exception Type: ImproperlyConfigured at /
t;
> thanks in advance.
> waiting for a reply
>
> On Mon, Feb 4, 2019 at 5:18 PM Ivan Martić > wrote:
>
>> Hi all,
>>
>> I need help.
>> I keep getting this issue, NoReverseMatch at /
>> Reverse for 'productsgrouping-update' with arguments
Hi all,
I need help.
I keep getting this issue, NoReverseMatch at /
Reverse for 'productsgrouping-update' with arguments '('',)' not found. 1
pattern(s) tried: ['update/(?P[0-9]+)/$']
not sure what am doing wrong. Any time I put url tag {% url
'productsgrouping-update' lista.id%} in html i get
Can you elaborate a bit, i have the same issue with noreverse error
ned, 3. velj 2019. u 15:08 poOya mOsaddegh
napisao je:
> Hi
> You may use include in urls.py
>
> urlpatterns = [
> path('', views.club_home, name='club_home'),
> path('/', include(club_home_urls, namespace='club_home')),
i think i found the issue, problem was in the html url tag..
i should look like this
href="{ url 'update_group' list_all.url_id }">
not like this
href="{ url 'update_group' item.id }">
thank you all
pet, 1. velj 2019. u 09:26 Ivan Martić napisao je
Hi guys, any help on this matter? i still have noreverse issue. There is
something wrong with my url nameing
sri, 30. sij 2019. u 10:55 Ivan Martić napisao je:
> Bok Nebojša, jel možeš uletit i pogledati molim te što radim krivo.
>>>
>>> Znači, imam 2 aplikacije, prva abc
>
> Bok Nebojša, jel možeš uletit i pogledati molim te što radim krivo.
>>
>> Znači, imam 2 aplikacije, prva abc radi a druga product groups ne radi..
>> Sve je kopirano u 2 privitka.
>>
>> Da li imaš vremena pogledati pliz?
>>
> Šta god napravim, No reverse mi se javlja...
--
You received th
gde je greška
>
> уто, 29. јан 2019. у 13:51 Ivan Martić је
> написао/ла:
>
>> napravio sam točno kako si rekao i dalje nece, isti error ...vec danima
>> se mucim sa ovime..nešto drugo je posrijedi.
>>
>>
>>
>>
>>
>> uto, 29. sij 2019. u 12:16
view(request, url_id):
> assigned = get_object_or_404(Material, pk=url_id)
>
>
> naravno prvo moraš da importuješ get object or 404:
>
> from django.shortcuts import get_object_or_404
>
>
> уто, 29. јан 2019. у 12:00 Ivan Martić је
> написао/ла:
>
>> Bok N
gt; https://docs.djangoproject.com/en/2.1/ref/class-based-views/generic-editing/
>
> Ako hoćeš preko funkcije ja radim sa get_object_or_404, ovako:
> def productsgrouping_update_view(request, url_id):
> product_lista = get_object_or_404(MaterialGroup, pk=url_id)
>
>
> уто, 29.
not sure what to say
čet, 24. sij 2019. u 13:53 Ivan Martić napisao je:
> Hi Andréas,
> sorry for misspeling in codes. All is working ok except when i try to put
> url tag for 'update_productsgrouping'.
> I need to update group with new products but It does not argument
t; You may mean:
> {{ item }} - {{
> item.id}}
> ?
>
> Regards,
>
> Andréas
>
>
> Den tors 24 jan. 2019 kl 13:28 skrev Ivan Martić :
>
>> Hi all,
>>
>> i am having issue with url tag, every time i put url tag like --{% url
>> 'p
Hi all,
i am having issue with url tag, every time i put url tag like --{% url
'productsgrouping' item.id%}-- i get no reverse error.
Can you help me figure it out on what am i doing wrong?
view:
def productsgrouping_view(request):
queryset = MaterialGroup.objects.all()
context = {"list" : query
er Laudrup napisao
je:
> Hi Ivan,
>
> On 1/18/19 10:59 AM, Ivan Martić wrote:
> > Thank you Kasper,
> >
>
> You're welcome.
>
> > i have copied that model after doing inspectdb. So it should be set by
> > default from django that way. Usually all was ok..
Thank you Kasper,
i have copied that model after doing inspectdb. So it should be set by
default from django that way. Usually all was ok..
Also, i have tried that change now and got the same result.
Any other idea where i gone wrong?
--
You received this message because you are subscribed t
Hi all,
i am having trouble to get this query on db table right.
I am always getting error.
Please check shell erorr attached.
I appreciate your help!
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop
st.POST or None,
> initial={'supplier_name':request.user})
> if prepoznaj_form.is_valid():
> prepoznaj_form.save()
>
> context = {
> 'prepoznaj_form': prepoznaj_form
> }
>
> return render(request, 'prepoznaj/forma.html
P/1.1" 200 8939
[15/Jan/2019 13:01:33] "GET /performance/ HTTP/1.1" 200 14799
[15/Jan/2019 13:01:39] "POST /performance/ HTTP/1.1" 200 14811
Da li ovi podaci mogu što pomoći?
uto, 15. sij 2019. u 12:54 Ivan Martić napisao je:
> Nažalost, iz nekog razloga ne prolazi
form = PerformanceForm[request.POST]
> if form.is_valid():
> form.save()
> return render(request, 'qif/performance.html', {"form" : form})
>
> ovako nekako bi trebalo da radi
>
> уто, 15. јан 2019. у 12:49 Ivan Martić је
> написао/ла:
>
>> Ej
ni sad sam u nekoj bas velikoj guzvi, evo ti otprilike kako sam ja na
> drugoj formi uradio, ako ne uspes ispisacu ti malo kasnije
> [image: image.png]
>
> уто, 15. јан 2019. у 12:26 Ivan Martić је
> написао/ла:
>
>> Bravo! radi!
>> Samo što sad neradi spremanje (reque
Bravo! radi!
Samo što sad neradi spremanje (request.POST)...kako da to sad
implementiram, jel može savjet?
uto, 15. sij 2019. u 12:22 Nebojsa Hajdukovic
napisao je:
> Obrisi ovo request.post or none
>
> uto, 15. jan 2019. 12:19 Ivan Martić je
> napisao/la:
>
>> Bok Neboj
dodaj ovako u views.py:
> view:
> def performance_view(request):
> form = PerformanceForm({'supplier_name':request.user})
> if form.is_valid():
> form.save()
> return render(request, 'qif/performance.html', {"form" : form})
>
> уто, 15. јан 2019. у 09
Hi all,
can someone assist me.
I cant get the modelform field get populated with active username.
Does any one have a good advice?
view:
def performance_view(request):
form = PerformanceForm(request.POST or None)
if form.is_valid():
form.save()
return render(request, 'qif/performance.html', {"f
Hi mate,
I had the same issue with MS SQL.
This worked for me:
DATABASES = {
'default': {
'ENGINE': 'sql_server.pyodbc',
'HOST': 'xxx',
'PORT': '1433',
'USER': 'xxx',
'PASSWORD': 'xxx',
'NAME': 'xx',#table name
'CONN_MAX_AGE': 0,
Hi Mate,
I had the same issues with connecting to MS SQL.
This is the configuration which worked for me...
DATABASES = {
'default': {
'ENGINE': 'sql_server.pyodbc',
'HOST': 'XXX',
'PORT': '1433',
'USER': 'XXX',
'PASSWORD': 'XXX',
'NAME': 'XXX',
29 matches
Mail list logo