随笔分类 -  python

摘要:``` coding: utf 8 from __future__ import unicode_literals from django.http import JsonResponse import json from django.shortcuts import render from ba 阅读全文
posted @ 2018-05-02 11:51 我的大金金 阅读(136) 评论(0) 推荐(0)
摘要:``` pyrcc4 -o images.py images.qrc self.setWindowIcon(QIcon(':img/background.ico')) ``` 阅读全文
posted @ 2017-09-19 14:20 我的大金金 阅读(904) 评论(0) 推荐(0)
摘要:··· 新建一个对象的方法有以下几种: Person.objects.create(name=name,age=age) p = Person(name="WZ", age=23) p.save() p = Person(name="TWZ") p.age = 23 p.save() Person. 阅读全文
posted @ 2017-07-08 15:58 我的大金金 阅读(1847) 评论(0) 推荐(0)
摘要:``` #!/usr/bin/env python # -*- coding: utf-8 -*- """ @version: 001 @author: jianpan @file: MyQThread.py @time: 2017/6/3 11:54 """ from PyQt4.QtCore import * import Tkinter as tk import multiprocessin... 阅读全文
posted @ 2017-06-04 17:45 我的大金金 阅读(262) 评论(0) 推荐(0)
摘要:``` #!/usr/bin/env python # -*- coding: utf-8 -*- """ @version: 001 @author: jianpan @file: test1.py @time: 2017/6/4 16:14 """ # coding: utf-8 import multiprocessing import time import os import psu... 阅读全文
posted @ 2017-06-04 17:35 我的大金金 阅读(191) 评论(0) 推荐(0)
摘要:``` #!/usr/bin/env python # -*- coding: utf-8 -*- """ @version: 001 @author: jianpan @file: MySocketServer.py @time: 2017/6/3 11:00 """ # -*- coding:utf-8 -*- from SocketServer import ThreadingTCPSe... 阅读全文
posted @ 2017-06-03 11:47 我的大金金 阅读(277) 评论(0) 推荐(0)
摘要:``` # coding:utf-8 import socket import sys import os reload(sys) sys.setdefaultencoding("utf-8") # set host and port HOST, PORT = '10.72.80.141', 8088 class SocketFromServer(): def __init__(s... 阅读全文
posted @ 2017-06-02 19:19 我的大金金 阅读(138) 评论(0) 推荐(0)