code
stringlengths
1
1.72M
language
stringclasses
1 value
# -*- coding:UTF-8 -*- from select_ import select from insert_ import insert from insert_ import insertLog from exp import Warning_ from types import StringType from types import UnicodeType from staff import upperLevel from update_ import update from public import addZero from public import getOperType from twisted...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle import xml.etree.ElementTree as ElementTree from select_ import select from insert_ import insert from insert_ import insertLog from update_ import update from exp import Warning_ def getBssOrgID(oracle): '''给出最小的一个还未用的bss_org_id''' select_colums = ['bss_org_id']...
Python
#!/usr/bin/python #encoding=utf-8 #file_name = get_tax.py from select_ import select from oracle import Oracle def getTax(oracle, staff_id): where = {'staff_id':staff_id, 'state':'instance'} from_sql = ''' from (select * ...
Python
# -*- coding:UTF-8 -*- #from types import * from staff import upperLevel from update_ import update from public import addZero from public import getOperType from distri import getDistriInfo from distri import checkBeginEndNbr from distri import insertDistriLog from distri import insertDistriAsSplit from distri impor...
Python
#!/usr/bin/python #encoding=utf-8 #file_name=public.py def addZero(length, short): value = str(short) while(len(value)<length): value = '0'+value return value def getOperType(tax_begin_nbr, tax_end_nbr, hold_tax_begin_nbr, hold_tax_end_nbr): '''取得号段类型 in: tax_begin_nbr, tax_end_nbr, hol...
Python
# -*- coding:UTF-8 -*- import hashlib from select_ import select from update_ import update from insert_ import insert from insert_ import insertLog from exp import Warning_ def upperLevel(oracle,upper_staff,lower_staff): ''' 判断工号是否为上下级''' sql = ''' select * from staff where staff_id...
Python
# -*- coding:UTF-8 -*- def right(values, oracle = None): if(oracle != None): oracle.commit() return values def error(failure, oracle = None): if(oracle != None): oracle.rollback() return failure
Python
# -*- coding:UTF-8 -*- from select_ import select from update_ import update from insert_ import insert from insert_ import insertLog from datetime import datetime import threading from exp import Warning_ from delete import delete def getUpdateInfo(oracle): '''查询信息''' select_colums = ['id', 'table_name', 'par...
Python
#!/usr/bin/env python #encoding=utf-8 #file_name=abstract_tax.py from insert_ import insertLog from insert_ import insert from update_ import update from distri import getNextVal from delete import delete class AbstractTax: def __init__(self, oracle, **args): self.oracle = oracle self.tax_begin_nb...
Python
#!/usr/bin/python #encoding=utf-8 #file_name = use_tax.py from update_ import update from insert_ import insertLog from get_tax import getTax from oracle import Oracle class UseTax: def __init__(s, oracle, **args): s.oracle = oracle s.staff_id = args['staff_id'] s.tax_code = args['tax_code']...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle from exp import Warning_ def select(oracle, select_colums, sql, where_dic = None, and_the = None, bind_dic = None): '''select_colums list 要查的值 sql where_dic 哪个字段什么条件 ''' values = [] if(len(select_colums) == 0): raise Exception, '未...
Python
# -*- coding:UTF-8 -*- import traceback import sys from twisted.python import log def getExcInfo(): #记录twited 日志 log.err() info = sys.exc_info() #print type(info[0]) exp_type = str(info[0]) if(info[0] == Warning_): '是waring' print type(info[0]) print exp_type exc_...
Python
#! /usr/bin/env python # ptags # # Create a tags file for Python programs, usable with vi. # Tagged are: # - functions (even inside other defs or classes) # - classes # - filenames # Warns about files it cannot open. # No warnings about duplicate tags. import sys, re, os tags = [] # Modified global variable! def...
Python
# -*- coding:UTF-8 -*- import xml.etree.ElementTree as ElementTree def getPrivilege(oracle, staff_id): '''从数据库中获取所有权限信息''' privilege_dic = {} dic = {'privilege_id':'1', 'staff_id':staff_id} sql = ''' select p.privilege_id, p.parent_privilegeid, ...
Python
#! /usr/bin env python #encoding=utf-8 #file_name = print.py from select_ import select from oracle import Oracle def getSeq(oracle, seq_name): '''get seq use seq_name''' select_colums = ['%s.nextval id'%seq_name] sql = ' from dual' return select(oracle, select_colums, sql)[0]['id'] if __name__ == ...
Python
# -*- coding:UTF-8 -*- from insert_ import insert from insert_ import insertLog from distri import insertDistriLog from update_ import update from distri import getDistriInfo from public import getOperType from public import addZero import pool from oracle import Oracle from exp import Warning_ def instanceTax(oracle,...
Python
# -*- coding:UTF-8 -*- from select_ import select from update_ import update from insert_ import insert from insert_ import insertLog from exp import Warning_ from delete import delete def addRole(oracle, **args): '''增加角色 dic: role_id''' select_colums = ['role_id','name'] where_dic = {} where_dic['role_...
Python
# -*- coding:UTF-8 -*- from twisted.internet import defer from hello import hello from get_tax import * from staff import * from retail import * from hand import handPrint from staff_role import addStaffRole from staff_role import delStaffRole from oracle import Oracle from call_back import right,error from exp imp...
Python
#!/usr/bin/python #encoding=utf-8 #file_name=oracle.py import os import cx_Oracle import sys from read_ini import read_db_info class Oracle(): ''' open oracle connetction get table_name and index info ''' pool = None def __init__(self): if(Oracle.pool is None): getPool() self.db ...
Python
# -*- coding:UTF-8 -*- from select_ import select from insert_ import insertLog def selectPool(oracle, select_colums, where_dic): '''查询pool表''' sql = "from pool " return select(oracle, select_colums, sql, where_dic) def updatePool(oracle, update_dic, where_dic): '''更新pool表''' sql = "update pool set ...
Python
# -*- coding:UTF-8 -*- from select_ import select def initStaffId(oracle, bss_org_id): sql = ''' insert into staff_report select staff_id from staff where bss_org_id in (select bss_org_id from bss_org connect by prior bss_org_id = bss_parent_org_id start with bss_org...
Python
# -*- coding:UTF-8 -*- from twisted.web import resource, server from pyamf.remoting.gateway.twisted import TwistedGateway from pyamf.remoting.gateway import expose_request from exp import getExcInfo from oracle import Oracle from call_back import right,error from twisted.internet import defer from twisted.internet ...
Python
# -*- coding:UTF-8 -*- ''' 发票作废 ''' from oracle import Oracle from pool import selectPool from pool import updatePool from select_ import select from update_ import update from datetime import datetime from insert_ import insertLog def nullifyTax(oracle, dic): ''' 发票作废 tax_code tax_nbr oper...
Python
#!/usr/bin/env python #encoding=utf-8 #file_name=abstract_tax.py from insert_ import insertLog from insert_ import insert from update_ import update from distri import getNextVal from delete import delete class AbstractTax: def __init__(self, oracle, **args): self.oracle = oracle self.tax_begin_nb...
Python
#!/usr/bin/python #encoding=utf-8 #file_name=public.py def addZero(length, short): value = str(short) while(len(value)<length): value = '0'+value return value def getOperType(tax_begin_nbr, tax_end_nbr, hold_tax_begin_nbr, hold_tax_end_nbr): '''取得号段类型 in: tax_begin_nbr, tax_end_nbr, hol...
Python
#! /usr/bin/env python # ptags # # Create a tags file for Python programs, usable with vi. # Tagged are: # - functions (even inside other defs or classes) # - classes # - filenames # Warns about files it cannot open. # No warnings about duplicate tags. import sys, re, os tags = [] # Modified global variable! def...
Python
#!/usr/bin/env python #encoding=utf-8 import hashlib from select_ import select from update_ import update from insert_ import insert from insert_ import insertLog from exp import Warning_ def login(oracle, **args): '''登录工号 staff_id, passwd''' for k, v in args.items(): exec "%s = '%s'"%(k,v) sele...
Python
#!/usr/bin/python #encoding=utf-8 #file_name = hand.py from seq import getSeq from oracle import Oracle from get_tax import getTax from insert_ import insert from use_tax import useTax def handPrint(oracle, **args): '''手工发票''' hand = Hand(oracle, **args) hand.recordHandPrint() args['sys_type'] = 'H' ...
Python
#!/usr/bin/python #encoding=utf-8 #file_name = use_tax.py from update_ import update from insert_ import insertLog from get_tax import getTax from oracle import Oracle class UseTax: def __init__(s, oracle, **args): s.oracle = oracle s.staff_id = args['staff_id'] s.tax_code = args['tax_code']...
Python
#!/usr/bin/python #encoding=utf-8 #file_name=oracle.py import os import cx_Oracle import sys from read_ini import read_db_info class Oracle(): ''' open oracle connetction get table_name and index info ''' pool = None def __init__(self): if(Oracle.pool is None): getPool() self.db ...
Python
#!/usr/bin/python #encoding=utf-8 #file_name = get_tax.py from select_ import select from oracle import Oracle def getTax(oracle, staff_id): where = {'staff_id':staff_id, 'state':'instance'} from_sql = ''' from (select * ...
Python
#!/usr/bin/env python #encoding=utf-8 import pyamf from pyamf.amf3 import ByteArray from twisted.internet.protocol import Protocol from twisted.internet.protocol import Factory from twisted.internet import reactor from oracle import Oracle from login import login from exp import getExcInfo from exp import getWa...
Python
global bigzhu def hello(): return 'hello %s'%bigzhu
Python
# -*- coding:UTF-8 -*- from select_ import select from update_ import update from insert_ import insert from insert_ import insertLog from exp import Warning_ from delete import delete def addStaffRole(oracle, **args): '''增加工号角色 dic: role_id, staff_id, oper_staff_id''' insert_value = args.copy() del insert...
Python
# -*- coding:UTF-8 -*- ''' 发票回滚 ''' from oracle import Oracle from pool import selectPool from datetime import datetime from insert_ import insertLog def roll(oracle, **args): ''' 发票回滚 tax_code tax_nbr oper_staff_id remark ''' sql = '''update pool p ...
Python
# -*- coding:UTF-8 -*- from select_ import select from insert_ import insertLog from update_ import update from exp import Warning_ class AdjustError: def __init__(self, oracle, **args): self.oracle = oracle self.args = args self.tax_code = args['tax_code'] self.tax_nbr = args['tax...
Python
# -*- coding:UTF-8 -*- from pyamf.remoting.client import RemotingService import logging logging.basicConfig( level = logging.DEBUG, format = '%(asctime)s %(levelname)-5.5s [%(name)s] %(message)s' ) url = 'http://127.0.0.1:8001' #url = 'http://135.33.9.54:8002' client = RemotingService(url, logger = logging)...
Python
# The default ``config.py`` def set_prefs(prefs): """This function is called before opening the project""" # Specify which files and folders to ignore in the project. # Changes to ignored resources are not added to the history and # VCSs. Also they are not returned in `Project.get_files()`. # No...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle def update(oracle, table_name, update_dic, where_dic = {}, and_the = ' ', count = 1, need_lock = False): '''更新表''' #时间 temp_dic = update_dic.copy() sysdate = [] for k, v in temp_dic.iteritems(): if(v == '/sysdate'): del update_d...
Python
# -*- coding:UTF-8 -*- import sys if(len(sys.argv) == 1): raise Exception,'要输入表名' table_name = sys.argv[1] print '' print 'create table %s_log as select * from %s where \ rownum<0;' % (table_name,table_name) print ''' -- Add/modify columns alter table %s_LOG add oper_staff_id NUMBER(12); alter table %s_LOG add ope...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle def delete(oracle, table_name, where_dic = {}, and_the = ' ', count = 1): '''更新表''' sql = "delete from %s " % table_name where = ' where 1 = 1 ' wheres = ["and %s = :%s" % (k, k) for k in where_dic.keys()] where += ' '.join(wheres) where += ' '+an...
Python
# -*- coding:UTF-8 -*- import os import re import sys def get_pid(pid_name): file_name = pid_name+'.pid' f = open(file_name) pid = f.read() print "get %s's pid = %s"%(file_name,pid) f.close() return pid def kill(pid,type = ''): cmd = "kill %s %s"%(type,pid) print cmd os.system(cmd) d...
Python
#!/usr/bin/env python #encoding=utf-8 import pyamf from pyamf.amf3 import ByteArray from twisted.internet.protocol import Protocol from twisted.internet.protocol import Factory from twisted.internet import reactor from oracle import Oracle from login import login from exp import getExcInfo from exp import getWa...
Python
# -*- coding:UTF-8 -*- import ConfigParser def read_db_info(): config = ConfigParser.ConfigParser() dic = {} cfg_file = open('im.ini','r') config.readfp(cfg_file) dic['user'] = config.get('db_info','user') dic['password'] = config.get('db_info','password') dic['tns'] = config.get('db_info','...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle import xml.etree.ElementTree as ElementTree from twisted.internet import defer from select_ import select from insert_ import insert from insert_ import insertLog from datetime import datetime from update_ import update from exp import Warning_ def getOrg(oracle, dic): ...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle import cx_Oracle #cx_Oracle.CLOB def addBbs(oracle, dic): cursor = oracle.db.cursor() cursor.setinputsizes(bbs_content = cx_Oracle.CLOB) dic['bbs_content'] = str(dic['bbs_content']) update_sql = "update bbs b set b.bbs_content = b.bbs_content||:bbs_cont...
Python
# -*- coding:UTF-8 -*- ''' 入库发票作废 ''' from oracle import Oracle from update_ import update from datetime import datetime from insert_ import insertLog def nullifyDistri(oracle, **args): ''' 入库发票作废 distri_id oper_staff_id remark ''' for k, v in args.items(): exec "%s = '%s'"%...
Python
#! /usr/bin env python #encoding=utf-8 #file_name = print.py from oracle import Oracle import seq def getPrintSeq(): '''get print seq from ''' print_seq = seq.getSeq('print_seq')
Python
# -*- coding:UTF-8 -*- from select_ import select from types import StringType from types import ListType def insert(oracle, table_name, insert_value, count = 1): ''' insert sql 是根据第一行的內容来拼的. 如果一次插入多行,且插入列与第一行不同(有更的或者更少列插入),那么不要用这个函数. ''' is_list = False if(type(insert_value) == ListType): ...
Python
#!/usr/bin/env python #encoding=utf-8 import hashlib from select_ import select from update_ import update from insert_ import insert from insert_ import insertLog from exp import Warning_ def login(oracle, **args): '''登录工号 staff_id, passwd''' for k, v in args.items(): exec "%s = '%s'"%(k,v) sele...
Python
# -*- coding:UTF-8 -*- from pyamf.remoting.gateway.wsgi import WSGIGateway from pyamf.remoting.gateway import expose_request from twisted.web import server from twisted.web.wsgi import WSGIResource from twisted.python.threadpool import ThreadPool from twisted.internet import reactor from twisted.application import ser...
Python
#!/usr/bin/python #encoding=utf-8 #file_name = hand.py from seq import getSeq from oracle import Oracle from get_tax import getTax from insert_ import insert from use_tax import useTax def handPrint(oracle, **args): '''手工发票''' hand = Hand(oracle, **args) hand.recordHandPrint() args['sys_type'] = 'H' ...
Python
# -*- coding:UTF-8 -*- from twisted.web import static, server from twisted.application import service, internet from twisted.application import service, strports path = '/acct/flex4/bin' root = static.File("/invoice/flex4/bin/") root.putChild("InvoiceSysOperateHelp.doc", static.File(path+"/InvoiceSysOperateHelp.doc"))...
Python
# -*- coding:UTF-8 -*- from select_ import select from insert_ import insert from insert_ import insertLog from exp import Warning_ from types import StringType from types import UnicodeType from staff import upperLevel from update_ import update from public import addZero from public import getOperType from twisted...
Python
# -*- coding:UTF-8 -*- from oracle import Oracle import xml.etree.ElementTree as ElementTree from select_ import select from insert_ import insert from insert_ import insertLog from update_ import update from exp import Warning_ def getBssOrgID(oracle): '''给出最小的一个还未用的bss_org_id''' select_colums = ['bss_org_id']...
Python
#!/usr/bin/env python from distutils.core import setup setup(name = "FlickrWall", version = "0.1.0", author = "Michael Kania", author_email = "mkania@umail.ucsb.edu", url = "http://flickr.com/mkania", description = "Download awesome wallpapers from Flickr.com", scripts = ["src/FlickrWall"], ...
Python
#!/usr/bin/env python from distutils.core import setup setup(name = "FlickrWall", version = "0.1.0", author = "Michael Kania", author_email = "mkania@umail.ucsb.edu", url = "http://flickr.com/mkania", description = "Download awesome wallpapers from Flickr.com", scripts = ["src/FlickrWall"], ...
Python
""" flickr.py Copyright 2004-2006 James Clarke <james@jamesclarke.info> Portions Copyright 2007-2008 Joshua Henderson <joshhendo@gmail.com> THIS SOFTWARE IS SUPPLIED WITHOUT WARRANTY OF ANY KIND, AND MAY BE COPIED, MODIFIED OR DISTRIBUTED IN ANY WAY, AS LONG AS THIS NOTICE AND ACKNOWLEDGEMENT OF AUTHORSHIP...
Python
#!/usr/bin/python ##=============================================================================== # # flickr.py # Copyright 2004-2006 James Clarke <james@jamesclarke.info> # Portions Copyright 2007-2008 Joshua Henderson <joshhendo@gmail.com> # flickr_tray.py # Copyright 2008 Michael Kania <mkania@umail.ucs...
Python
#!/usr/bin/python ##=============================================================================== # # flickr.py # Copyright 2004-2006 James Clarke <james@jamesclarke.info> # Portions Copyright 2007-2008 Joshua Henderson <joshhendo@gmail.com> # flickr_tray.py # Copyright 2008 Michael Kania <mkania@umail.ucs...
Python
print("")
Python
from django.db import models # Create your models here.
Python
""" This file demonstrates writing tests using the unittest module. These will pass when you run "manage.py test". Replace this with more appropriate tests for your application. """ from django.test import TestCase class SimpleTest(TestCase): def test_basic_addition(self): """ Tests that 1 + 1 a...
Python
from django.conf import settings from django.conf.urls.defaults import * from django.contrib.auth.decorators import login_required urlpatterns = patterns('home.views', url(r'^jobs$', 'jobs', name='home_display'), url(r'^$', 'home', name='home_display'), )
Python
from django.http import HttpResponseRedirect, Http404, HttpResponse, HttpResponseForbidden from django.shortcuts import render_to_response, get_object_or_404 from django.core.cache import cache from django.utils import simplejson as simplejson def home(request): return render_to_response('home/home.html',None) def ...
Python
#!/usr/bin/env python from django.core.management import execute_manager import imp try: imp.find_module('settings') # Assumed to be in the same directory. except ImportError: import sys sys.stderr.write("Error: Can't find the file 'settings.py' in the directory containing %r. It appears you've customized t...
Python
from django.conf.urls.defaults import patterns, include, url # Uncomment the next two lines to enable the admin: from django.contrib import admin admin.autodiscover() urlpatterns = patterns('', (r'', include('home.urls')), (r'helpdesk/', include('helpdesk.urls')), url(r'^admin/', include(admin.site.urls)), ...
Python
# Django settings for coordinate_ticketing project. #export PYTHONPATH="$PYTHONPATH:/usr/local/google/home/zachn/Documents/code/coordinate_ticketing/google_appengine:/usr/local/google/home/zachn/Documents/code/coordinate_ticketing/google_appengine/lib/django_1_3" import os PROJECT_PATH = os.path.abspath(os.path.dirname...
Python
#!/usr/bin/env python import os import optparse import subprocess import sys here = os.path.dirname(__file__) def main(): usage = "usage: %prog [file1..fileN]" description = """With no file paths given this script will automatically compress all jQuery-based files of the admin app. Requires the Google Closure...
Python
import os import sys from distutils.util import convert_path from fnmatch import fnmatchcase from setuptools import setup, find_packages version = '0.1.7b' # Provided as an attribute, so you can append to these instead # of replicating them: standard_exclude = ('*.py', '*.pyc', '*$py.class', '*~', '.*', '*.bak') stan...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. views/public.py - All public facing views, eg non-staff (no authentication required) views. """ from datetime import datetime from django.core.urlreso...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. views/staff.py - The bulk of the application - provides most business logic and renders all staff-facing views. """ from datetime import datetime import...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. views/feeds.py - A handful of staff-only RSS feeds to provide ticket details to feed readers or similar software. """ from django.contrib.auth.models im...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. views/kb.py - Public-facing knowledgebase views. The knowledgebase is a simple categorised question/answer system to show common resolutions t...
Python
from django.http import HttpResponseRedirect, Http404, HttpResponse, HttpResponseForbidden from django.shortcuts import render_to_response, get_object_or_404 from django.core.cache import cache from helpdesk.models import Ticket, Queue from helpdesk.coordinate import Coordinate def coordinatesync(request): c = Coo...
Python
""" .. django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. api.py - Wrapper around API calls, and core functions to provide complete API to third party applications. The API docume...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. forms.py - Definitions of newforms-based forms for creating and maintaining tickets. """ from datetime import datetime from StringIO import StringIO from dja...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. models.py - Model (and hence database) definitions. This is the core of the helpdesk structure. """ from datetime import datetime from django.contrib.auth.mo...
Python
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'CustomField.ordering' db.add_column('helpdesk_customfield', 'ordering', self.gf('django.db...
Python
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models from helpdesk.settings import HAS_TAG_SUPPORT class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'Ticket.tags' if HAS_TAG_SUPPORT is True if HAS...
Python
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'Ticket.due_date' db.add_column('helpdesk_ticket', 'due_date', self.gf('django.db.models.fi...
Python
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding field 'CustomField.empty_selection_list' db.add_column('helpdesk_customfield', 'empty_selection_l...
Python
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'Queue' db.create_table('helpdesk_queue', ( ('id', self.gf('django.db.models.fi...
Python
# encoding: utf-8 import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'TicketDependency' db.create_table('helpdesk_ticketdependency', ( ('id', self.g...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. urls.py - Mapping of URL's to our various views. Note we always used NAMED views for simplicity in linking later on. """ from django.conf import settings from ...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. templatetags/load_helpdesk_settings.py - returns the settings as defined in django-helpdesk/helpdesk/settings.py """ from django.template import Library from helpdesk import settings as helpdesk_settings_c...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. templatetags/ticket_to_link.py - Used in ticket comments to allow wiki-style linking to other tickets. Including text such ...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. templatetags/saved_queries.py - This template tag returns previously saved queries. Therefore you don't need to modify any views. """ from django.template import Library from dj...
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. templatetags/in_list.py - Very simple template tag to allow us to use the equivilent of 'if x in y' in templates. eg: Assuming 'food' = 'pizza'...
Python
""" Default settings for django-helpdesk. """ from django.conf import settings # check for django-tagging support HAS_TAG_SUPPORT = 'tagging' in settings.INSTALLED_APPS try: import tagging except ImportError: HAS_TAG_SUPPORT = False try: DEFAULT_USER_SETTINGS = settings.HELPDESK_DEFAULT_SETTING...
Python
''' Google Coordinate Ticket Integration ''' import httplib2 import settings from apiclient.discovery import build from oauth2client.file import Storage from oauth2client.client import OAuth2WebServerFlow from oauth2client.tools import run from google.appengine.ext import db from google.appengine.api import memcache ...
Python
from django.contrib import admin from helpdesk.models import Queue, Ticket, FollowUp, PreSetReply, KBCategory from helpdesk.models import EscalationExclusion, EmailTemplate, KBItem from helpdesk.models import TicketChange, Attachment, IgnoreEmail from helpdesk.models import CustomField class QueueAdmin(admin.ModelAdmi...
Python
#!/usr/bin/python """ django-helpdesk - A Django powered ticket tracker for small enterprise. See LICENSE for details. create_usersettings.py - Easy way to create helpdesk-specific settings for users who don't yet have them. """ from django.utils.translation import ugettext as _ from django.core.management.base imp...
Python
#!/usr/bin/python """ Jutda Helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. scripts/get_email.py - Designed to be run from cron, this script checks the POP and IMAP boxes defined for the queues within a ...
Python
#!/usr/bin/python """ django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. scripts/escalate_tickets.py - Easy way to escalate tickets based on their age, designed to be run from Cron or similar. ""...
Python
#!/usr/bin/python """ Jutda Helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. scripts/create_escalation_exclusion.py - Easy way to routinely add particular days to the list of days on which ...
Python
#from coordinate import Coordinate #c = Coordinate() #c.__auth__()
Python
""" django-helpdesk - A Django powered ticket tracker for small enterprise. (c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details. lib.py - Common functions (eg multipart e-mail) """ chart_colours = ('80C65A', '990066', 'FF9900', '3399CC', 'BBCCED', '3399CC', 'FFCC33') try: from base64 import u...
Python
# Version 0.2.0 # 2009/06/18 # Copyright Michael Foord 2005-2009 # akismet.py # Python interface to the akismet API # E-mail fuzzyman@voidspace.org.uk # http://www.voidspace.org.uk/python/modules.shtml # http://akismet.com # Released subject to the BSD License # See http://www.voidspace.org.uk/python/license.shtml ...
Python
''' Created on 2010-1-26 @author: fangtian ''' import os import urllib.request import urllib.parse import re import sqlite3 import time import copy import http import datetime import flickrapi class CmdFramework: def __SampleCommandHandler(self, argVector): print('This is a sample c...
Python