Profile cover photo
Profile photo
Απόστολος Βλαχόπουλος
About
Απόστολος's posts

Hello to the great community. I did an upgrade from 13.10 to 14.04 final beta, without fresh install. As expected it deactivated some of my ppa's but now i can't seem to be able to re-activate them. One of them is the ubuntu-sdk ppa which if I am not mistaken there is one for Trusty. It let's me choose it i enter password but it won't activate. How can I solve this?

Post has attachment
Any help in this? There are some test picture links for testing in the comments

Post has attachment
Thought I might get some answers here. Basically I want to use SessionAuthentication with tastypie. But django uses csrf_token. Tastypie views won't provide me with one. How can I use a valid token to post data on tastypie views?

is it possible to add the already there admin functionality (like filtering, ordering,  the javascript calendar in datetime fields etc) in the front pages of a django project?

suppose you have something like this. 
a url like   /teacher/add/ and url /student/add. And teacher and student are models in the same app. Is there a way to have one url.py for both teacher and student?How would it work?
e.g.
main urls.py
urlpatterns = patterns('',   
    url(r'^desknet/teacher/', include('app.urls')),
    url(r'^desknet/student/', include('app.urls')),
)

office/urls.py
urlpatterns = patterns(' ', 
    url(r'^add/$ ', 'add_teacher_view')
    url(r'^add/$ ', 'add_student_view')

Obviously this one wouldn't work right? Is there a django way to make it work?Or is the only way to change the urls?

Post has attachment

The qt Creator installed using ubuntu-sdk I installed doesn't contain the help docs of qt....Can i install them after installing ubuntu-sdk somehow?

I get this error when trying to launch either ubuntu or plain qt creator. It worked since the last updates. Any help? Ubuntu 12.10.

ubuntu-qtcreator 
qtcreator: symbol lookup error: /usr/lib/i386-linux-gnu/qt5/plugins/platforms/libqxcb.so: undefined symbol: _ZN15QPlatformWindow17formatWindowTitleERK7QStringS2

I want to override the save method of a model. 
I have a customer model and a project model. Project model has a propery model which is a ForeignKey to customer

class Project(models.Model):
      ........more properties........
      customer = models.ForeignKey(Customer)

I want to override the save method of the Project model so when a new project is created it should also change the value of a property of  customer. 

I tried this:
 def save(self, *args, **kwargs):
        self.customer.current_amount_owed += self.cost
        self.customer.save()
        super(Project, self).save(*args, **kwargs)

for testing purposes but didn't work at all. It is not even called(i tried to print something from inside save and the message did not appear on the console)

Any suggestions or good reading?

Not trying to "fish" for advertisments...but could anyoneone suggest some webhosting that is veeeery django friendly?And i mean either installing django on the host or maybe like uploading your files after you have developed locally?
Wait while more posts are being loaded