Code reformattingand code layout beautying.

This commit is contained in:
Martin Edenhofer 2013-06-12 17:59:58 +02:00
parent b0ffaf1e5a
commit c2010124f5
102 changed files with 1014 additions and 811 deletions

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class ActivityController < ApplicationController class ActivityController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class ApplicationController < ActionController::Base class ApplicationController < ActionController::Base
# http_basic_authenticate_with :name => "test", :password => "ttt" # http_basic_authenticate_with :name => "test", :password => "ttt"

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class ChannelsController < ApplicationController class ChannelsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class EmailAddressesController < ApplicationController class EmailAddressesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class GettingStartedController < ApplicationController class GettingStartedController < ApplicationController
=begin =begin

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class GroupsController < ApplicationController class GroupsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class InitController < ApplicationController class InitController < ApplicationController
# GET /init # GET /init

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class LinksController < ApplicationController class LinksController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class LongPollingController < ApplicationController class LongPollingController < ApplicationController
# GET /api/message_send # GET /api/message_send

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class NetworksController < ApplicationController class NetworksController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class OrganizationsController < ApplicationController class OrganizationsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class OverviewsController < ApplicationController class OverviewsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class PackagesController < ApplicationController class PackagesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class PostmasterFiltersController < ApplicationController class PostmasterFiltersController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class RecentViewedController < ApplicationController class RecentViewedController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class RolesController < ApplicationController class RolesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class RssController < ApplicationController class RssController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class SearchController < ApplicationController class SearchController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
module ExtraCollection module ExtraCollection
def session( collections, user ) def session( collections, user )

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
module ExtraCollection module ExtraCollection
def session( collections, user ) def session( collections, user )

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
module ExtraCollection module ExtraCollection
def session( collections, user ) def session( collections, user )

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class SessionsController < ApplicationController class SessionsController < ApplicationController
# def create # def create
# render :text => request.env['rack.auth'].inspect # render :text => request.env['rack.auth'].inspect

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class SettingsController < ApplicationController class SettingsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class SignaturesController < ApplicationController class SignaturesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class SlasController < ApplicationController class SlasController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TagsController < ApplicationController class TagsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TaskbarController < ApplicationController class TaskbarController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TemplatesController < ApplicationController class TemplatesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TestsController < ApplicationController class TestsController < ApplicationController
# GET /test # GET /test

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TextModulesController < ApplicationController class TextModulesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TicketArticlesController < ApplicationController class TicketArticlesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,9 +1,10 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TicketOverviewsController < ApplicationController class TicketOverviewsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check
# GET /api/tickets # GET /api/tickets
def show def show
#sleep 2
# get navbar overview data # get navbar overview data
if !params[:view] if !params[:view]

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TicketPrioritiesController < ApplicationController class TicketPrioritiesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TicketStatesController < ApplicationController class TicketStatesController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TicketsController < ApplicationController class TicketsController < ApplicationController
before_filter :authentication_check before_filter :authentication_check

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TranslationsController < ApplicationController class TranslationsController < ApplicationController
before_filter :authentication_check, :except => [:load] before_filter :authentication_check, :except => [:load]

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class UsersController < ApplicationController class UsersController < ApplicationController
before_filter :authentication_check, :except => [:create, :password_reset_send, :password_reset_verify] before_filter :authentication_check, :except => [:create, :password_reset_send, :password_reset_verify]

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'cache' require 'cache'
require 'user_info' require 'user_info'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Authorization < ApplicationModel class Authorization < ApplicationModel
belongs_to :user belongs_to :user
after_create :delete_user_cache after_create :delete_user_cache

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Channel < ApplicationModel class Channel < ApplicationModel
store :options store :options

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'mail' require 'mail'
class Channel::EmailBuild class Channel::EmailBuild

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
# encoding: utf-8 # encoding: utf-8
require 'mail' require 'mail'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
#require 'rubygems' #require 'rubygems'
#require 'twitter' #require 'twitter'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
# process all database filter # process all database filter
module Channel::Filter::Database module Channel::Filter::Database

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
# delete all X-Zammad header if channel is not trusted # delete all X-Zammad header if channel is not trusted
module Channel::Filter::Trusted module Channel::Filter::Trusted

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'net/imap' require 'net/imap'
class Channel::IMAP < Channel::EmailParser class Channel::IMAP < Channel::EmailParser

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Channel::MailStdin < Channel::EmailParser class Channel::MailStdin < Channel::EmailParser
def initialize def initialize
puts "read main from STDIN" puts "read main from STDIN"

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'net/pop' require 'net/pop'
class Channel::POP3 < Channel::EmailParser class Channel::POP3 < Channel::EmailParser

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Channel::Sendmail < Channel::EmailBuild class Channel::Sendmail < Channel::EmailBuild
def send(attr, channel, notification = false) def send(attr, channel, notification = false)

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Channel::SMTP < Channel::EmailBuild class Channel::SMTP < Channel::EmailBuild
def send(attr, channel, notification = false) def send(attr, channel, notification = false)

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'twitter' require 'twitter'
class Channel::Twitter2 class Channel::Twitter2

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class EmailAddress < ApplicationModel class EmailAddress < ApplicationModel
has_many :groups, :after_add => :cache_update, :after_remove => :cache_update has_many :groups, :after_add => :cache_update, :after_remove => :cache_update
validates :realname, :presence => true validates :realname, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Group < ApplicationModel class Group < ApplicationModel
has_and_belongs_to_many :users, :after_add => :cache_update, :after_remove => :cache_update has_and_belongs_to_many :users, :after_add => :cache_update, :after_remove => :cache_update
belongs_to :email_address belongs_to :email_address

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class History < ApplicationModel class History < ApplicationModel
self.table_name = 'histories' self.table_name = 'histories'
belongs_to :history_type, :class_name => 'History::Type' belongs_to :history_type, :class_name => 'History::Type'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Link < ApplicationModel class Link < ApplicationModel
belongs_to :link_type, :class_name => 'Link::Type' belongs_to :link_type, :class_name => 'Link::Type'
belongs_to :link_object, :class_name => 'Link::Object' belongs_to :link_object, :class_name => 'Link::Object'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Network < ApplicationModel class Network < ApplicationModel
# belongs_to :group # belongs_to :group
# belongs_to :ticket_state, :class_name => 'Ticket::State' # belongs_to :ticket_state, :class_name => 'Ticket::State'

View file

@ -1,2 +1,4 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Notifications < ActiveRecord::Base class Notifications < ActiveRecord::Base
end end

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'history' require 'history'
class Observer::History < ActiveRecord::Observer class Observer::History < ActiveRecord::Observer

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'history' require 'history'
class Observer::Tag::TicketHistory < ActiveRecord::Observer class Observer::Tag::TicketHistory < ActiveRecord::Observer

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::Article::CommunicateEmail < ActiveRecord::Observer class Observer::Ticket::Article::CommunicateEmail < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::Article::CommunicateFacebook < ActiveRecord::Observer class Observer::Ticket::Article::CommunicateFacebook < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::Article::CommunicateTwitter < ActiveRecord::Observer class Observer::Ticket::Article::CommunicateTwitter < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::Article::FillupFromEmail < ActiveRecord::Observer class Observer::Ticket::Article::FillupFromEmail < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::Article::FillupFromGeneral < ActiveRecord::Observer class Observer::Ticket::Article::FillupFromGeneral < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::ArticleCounter < ActiveRecord::Observer class Observer::Ticket::ArticleCounter < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::ArticleSenderType < ActiveRecord::Observer class Observer::Ticket::ArticleSenderType < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::CloseTime < ActiveRecord::Observer class Observer::Ticket::CloseTime < ActiveRecord::Observer
observe 'ticket' observe 'ticket'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::EscalationCalculation < ActiveRecord::Observer class Observer::Ticket::EscalationCalculation < ActiveRecord::Observer
observe 'ticket', 'ticket::_article' observe 'ticket', 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::FirstResponse < ActiveRecord::Observer class Observer::Ticket::FirstResponse < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::LastContact < ActiveRecord::Observer class Observer::Ticket::LastContact < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'notification_factory' require 'notification_factory'
class Observer::Ticket::Notification < ActiveRecord::Observer class Observer::Ticket::Notification < ActiveRecord::Observer

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::ResetNewState < ActiveRecord::Observer class Observer::Ticket::ResetNewState < ActiveRecord::Observer
observe 'ticket::_article' observe 'ticket::_article'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Observer::Ticket::UserTicketCounter < ActiveRecord::Observer class Observer::Ticket::UserTicketCounter < ActiveRecord::Observer
observe 'ticket' observe 'ticket'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Organization < ApplicationModel class Organization < ApplicationModel
has_and_belongs_to_many :users has_and_belongs_to_many :users
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Overview < ApplicationModel class Overview < ApplicationModel
store :condition store :condition
store :order store :order

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'rexml/document' require 'rexml/document'
class Package < ApplicationModel class Package < ApplicationModel
@@root = Rails.root.to_s @@root = Rails.root.to_s

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class PostmasterFilter < ApplicationModel class PostmasterFilter < ApplicationModel
store :perform store :perform
store :match store :match

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class RecentView < ApplicationModel class RecentView < ApplicationModel
belongs_to :recent_view_object, :class_name => 'RecentView::Object' belongs_to :recent_view_object, :class_name => 'RecentView::Object'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Role < ApplicationModel class Role < ApplicationModel
has_and_belongs_to_many :users, :after_add => :cache_update, :after_remove => :cache_update has_and_belongs_to_many :users, :after_add => :cache_update, :after_remove => :cache_update
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Scheduler < ApplicationModel class Scheduler < ApplicationModel
def self.run( worker, worker_count ) def self.run( worker, worker_count )

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Setting < ApplicationModel class Setting < ApplicationModel
store :options store :options
store :state store :state

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Signature < ApplicationModel class Signature < ApplicationModel
has_many :groups, :after_add => :cache_update, :after_remove => :cache_update has_many :groups, :after_add => :cache_update, :after_remove => :cache_update
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'cache' require 'cache'
class Sla < ApplicationModel class Sla < ApplicationModel

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'digest/md5' require 'digest/md5'
class Store < ApplicationModel class Store < ApplicationModel

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Tag < ApplicationModel class Tag < ApplicationModel
belongs_to :tag_object, :class_name => 'Tag::Object' belongs_to :tag_object, :class_name => 'Tag::Object'
belongs_to :tag_item, :class_name => 'Tag::Item' belongs_to :tag_item, :class_name => 'Tag::Item'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Taskbar < ApplicationModel class Taskbar < ApplicationModel
store :state store :state
store :params store :params

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Template < ApplicationModel class Template < ApplicationModel
store :options store :options
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TextModule < ApplicationModel class TextModule < ApplicationModel
validates :name, :presence => true validates :name, :presence => true
validates :content, :presence => true validates :content, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
require 'time_calculation' require 'time_calculation'
require 'sla' require 'sla'

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Ticket::Article < ApplicationModel class Ticket::Article < ApplicationModel
after_create :attachment_check after_create :attachment_check
belongs_to :ticket belongs_to :ticket

View file

@ -1,2 +1,4 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Ticket::Counter < ApplicationModel class Ticket::Counter < ApplicationModel
end end

View file

@ -1,2 +1,4 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Ticket::Flag < ApplicationModel class Ticket::Flag < ApplicationModel
end end

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
module Ticket::Number::Date module Ticket::Number::Date
extend self extend self

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
module Ticket::Number::Increment module Ticket::Number::Increment
extend self extend self

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Ticket::Priority < ApplicationModel class Ticket::Priority < ApplicationModel
self.table_name = 'ticket_priorities' self.table_name = 'ticket_priorities'
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Ticket::State < ApplicationModel class Ticket::State < ApplicationModel
belongs_to :state_type, :class_name => 'Ticket::StateType' belongs_to :state_type, :class_name => 'Ticket::StateType'
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Ticket::StateType < ApplicationModel class Ticket::StateType < ApplicationModel
has_many :states, :class_name => 'Ticket::State' has_many :states, :class_name => 'Ticket::State'
validates :name, :presence => true validates :name, :presence => true

View file

@ -1,2 +1,4 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class TimeAccounting < ActiveRecord::Base class TimeAccounting < ActiveRecord::Base
end end

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Token < ActiveRecord::Base class Token < ActiveRecord::Base
before_create :generate_token before_create :generate_token

View file

@ -1,3 +1,5 @@
# Copyright (C) 2012-2013 Zammad Foundation, http://zammad-foundation.org/
class Translation < ApplicationModel class Translation < ApplicationModel
before_create :set_initial before_create :set_initial

Some files were not shown because too many files have changed in this diff Show more