Commit Graph

1542 Commits (4b37a249c79b74e8f28ae90669c77a3bb3ddd44c)
 

Author SHA1 Message Date
Christian Boltz 313270c00a PFAHandler.php:
- add getPagebrowser() (returns an array of pagebrowser keys)

AliasHandler.php:
- change getList() to work with empty $condition
- add getPagebrowser() to filter out mailboxes

list-virtual.php:
- replace $alias_pagebrowser_query and the create_page_browser() call
  with $handler->getPagebrowser()



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1757 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 28fe7042e8 PFAHandler.php:
- split off build_select_query() from read_from_db() as preparation for
  using build_select_query() to generate the pagebrowser query



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1756 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 46d807c83d DomainHandler.php:
- initStruct():
  - don't display domain_quota if $CONF[quota] == NO or $CONF[domain_quota] is NO
  - drop 'total_quota' column which seems to be unused (and had a non-existing label)



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1755 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz dd43f12e9b delete list-admin.php and its template, use list.php instead
git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1754 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz add12b9fb4 AdminHandler.php:
- initStruct():
  - link username to domain list
  - hide superadmin, domain list and created columns in list view
  - add label to domain_count to make it visible in list view
- read_from_db_postprocess(): if user is a superadmin, replace domain
  count with "superadmin"



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1753 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 63d9b45dc7 list.php:
- the 'simulate admin' dropdown doesn't make sense for superadmin-only
  modules, therefore don't fill/display it in this case
  (usecase: AdminHandler)



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1752 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 64c6e9f0a0 list.tpl:
- fix displaying list and txtl fields


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1751 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz eb7e40cf94 PFAHandler, editform.tpl:
- add support for 'b64p' fields (passwords stored base64-encoded)
  as preparation to migrate fetchmail.php to FetchmailHandler


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1750 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz cc2b157d59 *Handler:
- add $msg['confirm'] (confirmation message when attemping to delete an
  item, displayed by list.php)

*.lang:
- add various confirm_delete_* texts needed by *Handler
- rename confirm_domain to confirm_delete_domain


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1749 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 86dc74fd86 menu.tpl:
- display "view log" menu entry only if logging is enabled
  https://sourceforge.net/p/postfixadmin/patches/127/


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1748 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 6e82a41121 delete list-domain.php and its templates
git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1747 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz a154c65c47 list-virtual.php:
- replace redirects to list-domain.php with list.php


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1746 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 1d35ba80ab model/DomainHandler.php:
- initStruct():
  - add optical quota indicators for aliases, mailboxes, domain quota
  - some adjustments to get nice output with list.php (mostly following
    list-domain.php)
- webformConfig(): switch listview to list.php

configs/menu.conf, templates/adminlistadmin.tpl:
- switch list-domain.php to list.php?table=domain



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1745 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 5605561ca8 functions.inc.php:
- better formatting in db_quota_text() and db_quota_percent() results
  (for example, infinity sign instead of / 0 for unlimited)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1744 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 4bc2d5f691 list.tpl, default.css:
- format unlimited/disabled quota similar to x/y, but no border


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1743 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz aea450625f de.lang:
- fix typo


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1742 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
Christian Boltz 6051729458 list.tpl:
- make "active" a link only if the record is editable


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1741 a1433add-5e2c-0410-b055-b7f2511e0802
9 years ago
David Goodwin feb2424188 stop relying on subversion keyword for database upgrades; just iterate over all user defined functions and find the largest numeric one
git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1740 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 39f9d3ac98 cs.lang:
- translation updates by Jan Laufik (jlaufik @ sf)
  http://sourceforge.net/p/postfixadmin/patches/126/


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1739 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
David Goodwin 75861f40eb debian/control - change to depend on php5-mysql | php5-mysqlnd | php5-pgsql
git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1738 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 5706f146d6 MailboxHandler:
- storemore(): store maildir in the correct variable to fix running
  mailbox_postedit script
  Fix by bit-jockey @SF,
  https://sourceforge.net/p/postfixadmin/bugs/342/


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1737 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 087dc34b01 MailboxHandler:
- check_quota(): deny creating an unlimited mailbox if domain quota is set
  (reported by idaho7 in IRC)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1736 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 7bf5b74a47 MailboxHandler, AliasHandler:
- initStruct: set "display in list" to 1 to allow searching for domain
  with list.php (nevertheless, the domain won't be displayed because
  it doesn't have a column label set)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1735 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 3916ae4104 *.lang:
- add 'edit_not_allowed' (needed by PFAHandler)
- add 'searchparams' (needed by list.tpl)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1734 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz eee25272a6 delete.php:
- allow users (non-admins) to use delete.php


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1733 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 03b0c869dd list.php:
- add search support:
  - new parameters:
    - search[$field] - value to search for
    - searchmode[$field] - search mode (=, <, > etc.)
    - reset_search - if given, empty $search and $searchmode
  - remember $search and $searchmode via session
  - display errormsg and infomsg from $handler, if any
 
list.tpl:
- display current search parameters and a "[x]" link to remove all
  search parameters

This change doesn't add a search form, but you can use ?search[field]=
and ?searchmode[field]= URL parameters


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1732 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 13f1a28b6e PFAHandler:
- read_from_db(), getList(): 
  - add $searchmode parameter (_before_ $limit and $offset!) to be able to 
    use query different query modes, not only "="
  - add a warning that $condition will be changed to array only in the future
- getList(): filter $condition for fields that are available to the user
  to avoid information leaks by using search parameters
  (filter is only applied if $condition is an array!)

functions.inc.php: 
- db_where_clause():
  - add $additional_raw_where parameter for additional query parameters
  - add $searchmode parameter to be able to use query different
    query modes, not only "=" (see $allowed_operators)
  - check for allowed operators in $searchmode
  - split query into WHERE and HAVING (if a parameter has
    $struct[select] set, HAVING is used)

list-virtual.php:
- adopt getList() call to the new syntax

AliasHandler:
- adopt getList() definition and call to the new syntax

 


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1731 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz b76511628d PFAHandler:
- add $this->order_by to allow ordering by any field(s)
  (defaults to $this->id_field)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1730 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 6bfe6706ba PFAHandler:
- add $this->label_field and $this->label (defaults to $this->id_field 
  and $this->id) to allow nicer messages
- use $this->label in various messages



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1729 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz ca76b0fb6e PFAHandler:
- add getMsg() function (needed by list.php)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1728 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz d2490f6153 list.tpl:
- add support for $struct[linkto]



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1727 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 7a23b3cda8 list.tpl:
- add handling for quota fields (visual quota indicator)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1726 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz a826564962 list.php:
- add CSV export

list.tpl:
- add "export as CSV" link

*.lang:
- new text 'download_csv'


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1725 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 50357d276a list.php:
- allow usage for users, not only admins


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1724 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 1e35c579b6 list.php, list.tpl:
- use smarty-style dropdown for admin dropdown instead of select_options()
- only display admin dropdown if more than one admin is available
  (which basically means hiding it for domain admins)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1723 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz b5a6417a6e add list.php and list.tpl - generic files to display lists
(will replace list-admin, list-domain etc.)

list.php:
- generic list view, select *Handler with ?table=

list.tpl:
- display list view
- columns based on $struct (every column with display_in_list and 
  non-empty label will be displayed)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1722 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 1ad0d6832b editform.tpl:
- display cleartext value instead of key for readonly enma fields


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1721 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 3d58d1f092 editform.tpl:
- add handling for 'enma' fields (see PFAHandler r1711)


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1720 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 786a7d665e functions.inc.php:
- pacol():
  - add $linkto parameter (if list mode should link to something)
  - replace $not_in_db with $multiopt - the remaining parameters can
    now be specified as associated array (backwards-compatible)



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1719 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz a4085d287f DomainHandler:
- initStruct: 
  - set column write permissions depending on superadmin status
  - add _can_edit and _can_delete (also depending on superadmin status)
- webformConfig(): reduce required permissions to 'admin'
- add beforestore() - aborts writing for non-superadmins
- delete: allow deletion only for superadmins

*.lang:
- new text 'no_delete_permissions'



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1718 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 1edc38a798 edit.php:
- add user (non-admin) mode


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1717 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz e39d13aa52 PFAHandler:
Add $can_edit and $can_delete flags. This makes it possible to make 
some, but not all items non-editable or non-deletable (based on a 
database column/query or read_from_db_postprocess())

- add $can_edit and $can_delete
- after initStruct, check if $struct contains _can_edit and _can_delete.
  If not, fill with default values (allowed)
- init(): set $this->can_edit and $this->can_delete (only in view/edit mode)
- set(): abort if !$this->can_edit



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1716 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 3fe75c117d PFAHandler:
- add handling of users (non-admins), including permission checks



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1715 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 72d9d42601 PFAHandler:
- add protected $is_superadmin = 1;
  will be set to 0 if $admin_username is set and is not a superadmin



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1714 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz f07281cdc1 PFAHandler:
- automatically skip quot, vnum and vtxt fields in store()
  (as if dont_write_to_db == 1)
- document new field types vtxt and quot and mark field types that will
  never be stored in db



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1713 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 9093a946b4 functions.inc.php:
- add functions db_quota_text() and db_quota_percent() to generate
  queries for used quota ("x/y" and percentage)



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1712 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 647aa39218 PFAHandler:
- add validation for "enma" field type - list of options, must be given
  in column "options" as associative array (value => displayed value)



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1711 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz d9e30fb41b Add CliScheme.php:
- displays the database scheme (for usage in upgrade.php)

PFAHandler:
- add "Scheme" to the list of available tasks

postfixadmin-cli.php:
- add "scheme" to help

This is the first patch of a series sponsored by 
    Bund der Deutschen Landjugend (german rural youth)
	http://bdl.landjugend.info/



git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1710 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz 22839d3695 Cli*.php:
- add SVN $Id header


git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1709 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago
Christian Boltz e8b0198512 2.92 (aka 3.0 beta2) release
git-svn-id: https://svn.code.sf.net/p/postfixadmin/code/trunk@1706 a1433add-5e2c-0410-b055-b7f2511e0802
10 years ago